Skip to content

Commit

Permalink
serial: cyclades: allow overriding ISA defaults also when the driver …
Browse files Browse the repository at this point in the history
…is built-in

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Bartlomiej Zolnierkiewicz authored and Greg Kroah-Hartman committed Mar 2, 2010
1 parent a357e77 commit 2090436
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions drivers/char/cyclades.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,13 +158,11 @@ static unsigned int cy_isa_addresses[] = {

#define NR_ISA_ADDRS ARRAY_SIZE(cy_isa_addresses)

#ifdef MODULE
static long maddr[NR_CARDS];
static int irq[NR_CARDS];

module_param_array(maddr, long, NULL, 0);
module_param_array(irq, int, NULL, 0);
#endif

#endif /* CONFIG_ISA */

Expand Down Expand Up @@ -3310,13 +3308,10 @@ static int __init cy_detect_isa(void)
unsigned short cy_isa_irq, nboard;
void __iomem *cy_isa_address;
unsigned short i, j, cy_isa_nchan;
#ifdef MODULE
int isparam = 0;
#endif

nboard = 0;

#ifdef MODULE
/* Check for module parameters */
for (i = 0; i < NR_CARDS; i++) {
if (maddr[i] || i) {
Expand All @@ -3326,7 +3321,6 @@ static int __init cy_detect_isa(void)
if (!maddr[i])
break;
}
#endif

/* scan the address table probing for Cyclom-Y/ISA boards */
for (i = 0; i < NR_ISA_ADDRS; i++) {
Expand All @@ -3347,11 +3341,10 @@ static int __init cy_detect_isa(void)
iounmap(cy_isa_address);
continue;
}
#ifdef MODULE

if (isparam && i < NR_CARDS && irq[i])
cy_isa_irq = irq[i];
else
#endif
/* find out the board's irq by probing */
cy_isa_irq = detect_isa_irq(cy_isa_address);
if (cy_isa_irq == 0) {
Expand Down

0 comments on commit 2090436

Please sign in to comment.