isdn: hisax: Fix pnp_irq's error checking for setup_isurf
The pnp_irq() function returns -1 if an error occurs. pnp_irq() error checking for zero is not correct. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
eb545c124a
commit
56cdb919f7
|
@ -238,7 +238,7 @@ int setup_isurf(struct IsdnCard *card)
|
|||
cs->hw.isurf.reset = pnp_port_start(pnp_d, 0);
|
||||
cs->hw.isurf.phymem = pnp_mem_start(pnp_d, 1);
|
||||
cs->irq = pnp_irq(pnp_d, 0);
|
||||
if (!cs->irq || !cs->hw.isurf.reset || !cs->hw.isurf.phymem) {
|
||||
if (cs->irq == -1 || !cs->hw.isurf.reset || !cs->hw.isurf.phymem) {
|
||||
printk(KERN_ERR "ISurfPnP:some resources are missing %d/%x/%lx\n",
|
||||
cs->irq, cs->hw.isurf.reset, cs->hw.isurf.phymem);
|
||||
pnp_disable_dev(pnp_d);
|
||||
|
|
Loading…
Reference in a new issue