diff options
author | Jiri Slaby <jirislaby@gmail.com> | 2008-04-30 03:53:36 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-30 11:29:41 -0400 |
commit | 37794952a685538f20ac9792e98f1c9b161dbdfe (patch) | |
tree | 20f15710819e3124e638788eae9896550dce832d | |
parent | cbacdd9572285c86848dd323dc764abb3681ddbc (diff) |
Char: moxa, remove static isa support
Static ISA field is empty and probably will never be filled in, remove it.
The driver still supports ISA cards passed through module parameter. This
actually fixes one bug inside the initialization of module-param passed cards
initialization.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Tested-by: Oyvind Aabling <Oyvind.Aabling@uni-c.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | drivers/char/moxa.c | 34 |
1 files changed, 2 insertions, 32 deletions
diff --git a/drivers/char/moxa.c b/drivers/char/moxa.c index 64b7b2b18352..7f4d1ec4b03d 100644 --- a/drivers/char/moxa.c +++ b/drivers/char/moxa.c | |||
@@ -92,17 +92,6 @@ static struct pci_device_id moxa_pcibrds[] = { | |||
92 | MODULE_DEVICE_TABLE(pci, moxa_pcibrds); | 92 | MODULE_DEVICE_TABLE(pci, moxa_pcibrds); |
93 | #endif /* CONFIG_PCI */ | 93 | #endif /* CONFIG_PCI */ |
94 | 94 | ||
95 | struct moxa_isa_board_conf { | ||
96 | int boardType; | ||
97 | int numPorts; | ||
98 | unsigned long baseAddr; | ||
99 | }; | ||
100 | |||
101 | static struct moxa_isa_board_conf moxa_isa_boards[] = | ||
102 | { | ||
103 | /* {MOXA_BOARD_C218_ISA,8,0xDC000}, */ | ||
104 | }; | ||
105 | |||
106 | static struct moxa_board_conf { | 95 | static struct moxa_board_conf { |
107 | int boardType; | 96 | int boardType; |
108 | int numPorts; | 97 | int numPorts; |
@@ -346,7 +335,7 @@ static struct pci_driver moxa_pci_driver = { | |||
346 | 335 | ||
347 | static int __init moxa_init(void) | 336 | static int __init moxa_init(void) |
348 | { | 337 | { |
349 | int i, numBoards, retval = 0; | 338 | int i, numBoards = 0, retval = 0; |
350 | struct moxa_port *ch; | 339 | struct moxa_port *ch; |
351 | 340 | ||
352 | printk(KERN_INFO "MOXA Intellio family driver version %s\n", | 341 | printk(KERN_INFO "MOXA Intellio family driver version %s\n", |
@@ -391,25 +380,6 @@ static int __init moxa_init(void) | |||
391 | 380 | ||
392 | mod_timer(&moxaTimer, jiffies + HZ / 50); | 381 | mod_timer(&moxaTimer, jiffies + HZ / 50); |
393 | 382 | ||
394 | /* Find the boards defined in source code */ | ||
395 | numBoards = 0; | ||
396 | for (i = 0; i < MAX_BOARDS; i++) { | ||
397 | if ((moxa_isa_boards[i].boardType == MOXA_BOARD_C218_ISA) || | ||
398 | (moxa_isa_boards[i].boardType == MOXA_BOARD_C320_ISA)) { | ||
399 | moxa_boards[numBoards].boardType = moxa_isa_boards[i].boardType; | ||
400 | if (moxa_isa_boards[i].boardType == MOXA_BOARD_C218_ISA) | ||
401 | moxa_boards[numBoards].numPorts = 8; | ||
402 | else | ||
403 | moxa_boards[numBoards].numPorts = moxa_isa_boards[i].numPorts; | ||
404 | moxa_boards[numBoards].busType = MOXA_BUS_TYPE_ISA; | ||
405 | moxa_boards[numBoards].baseAddr = moxa_isa_boards[i].baseAddr; | ||
406 | pr_debug("Moxa board %2d: %s board(baseAddr=%lx)\n", | ||
407 | numBoards + 1, | ||
408 | moxa_brdname[moxa_boards[numBoards].boardType-1], | ||
409 | moxa_boards[numBoards].baseAddr); | ||
410 | numBoards++; | ||
411 | } | ||
412 | } | ||
413 | /* Find the boards defined form module args. */ | 383 | /* Find the boards defined form module args. */ |
414 | #ifdef MODULE | 384 | #ifdef MODULE |
415 | for (i = 0; i < MAX_BOARDS; i++) { | 385 | for (i = 0; i < MAX_BOARDS; i++) { |
@@ -425,7 +395,7 @@ static int __init moxa_init(void) | |||
425 | continue; | 395 | continue; |
426 | } | 396 | } |
427 | moxa_boards[numBoards].boardType = type[i]; | 397 | moxa_boards[numBoards].boardType = type[i]; |
428 | if (moxa_isa_boards[i].boardType == MOXA_BOARD_C218_ISA) | 398 | if (type[i] == MOXA_BOARD_C218_ISA) |
429 | moxa_boards[numBoards].numPorts = 8; | 399 | moxa_boards[numBoards].numPorts = 8; |
430 | else | 400 | else |
431 | moxa_boards[numBoards].numPorts = numports[i]; | 401 | moxa_boards[numBoards].numPorts = numports[i]; |