Skip to content

Commit 1c8284b

Browse files
committed
Add GPIO names
1 parent 3722466 commit 1c8284b

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

gpio-ch341.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -378,6 +378,15 @@ static int ch341_gpio_probe(struct platform_device *pdev)
378378
gpio->set_multiple = ch341_gpio_set_multiple;
379379
gpio->base = -1;
380380
gpio->ngpio = CH341_GPIO_NUM_PINS;
381+
gpio->names = (char const * const []){
382+
"D0", "D1", "D2", "D3", "D4", "D5", "D6", "D7",
383+
// names are from "parallel" mode, seems to be what datasheets us
384+
"ERR#", "PEMP", "INT#", "SLCT", "RST#", "WAIT#", "DS#", "AS#",
385+
// names are from "print port" mode, seems to be what datasheets us
386+
// "ERR#", "PEMP", "ACK#", "SLCT", "INI#", "BUSY", "AFD#", "SIN#",
387+
388+
// No WR#?
389+
};
381390
gpio->can_sleep = true;
382391

383392
girq = &gpio->irq;

0 commit comments

Comments
 (0)