Small changes to make it work with 2.1.x kernels. Hopefully,
nothing major will change before official release of Linux 2.2.
-
+
Merged with 2.2 - Alan Cox
*/
unsigned short ioaddr[2], irq;
unsigned int serial_number;
int error = -ENODEV;
-
+
if (pnp_device_attach(pdev) < 0)
return -ENODEV;
if (pnp_activate_dev(pdev) < 0)
goto out_disable;
if (!pnp_irq_valid(pdev, 0))
goto out_disable;
-
+
serial_number = pdev->card->serial;
-
+
ioaddr[0] = pnp_port_start(pdev, 0);
ioaddr[1] = pnp_port_start(pdev, 0);
-
+
irq = pnp_irq(pdev, 0);
if (!request_region(ioaddr[0], 16, "sb1000"))
goto out_release_regions;
}
-
+
dev->base_addr = ioaddr[0];
/* mem_start holds the second I/O address */
dev->mem_start = ioaddr[1];
.remove = sb1000_remove_one,
};
-\f
+
/*
* SB1000 hardware routines to be used during open/configuration phases
*/
return 0;
}
-\f
+
/*
* SB1000 hardware routines to be used during frame rx interrupt
*/
return;
}
-\f
+
/*
* SB1000 commands for open/configuration
*/
return sb1000_end_get_set_command(ioaddr, name);
}
-\f
+
static inline void
sb1000_print_status_buffer(const char* name, unsigned char st[],
unsigned char buffer[], int size)
return;
}
-\f
+
/*
* Linux interface functions
*/
printk(KERN_DEBUG "%s: Shutting down sb1000.\n", dev->name);
netif_stop_queue(dev);
-
+
ioaddr[0] = dev->base_addr;
/* mem_start holds the second I/O address */
ioaddr[1] = dev->mem_start;