devsw_add() and cdevsw_remove() are no longer needed.

This commit is contained in:
Poul-Henning Kamp 2001-11-04 15:52:44 +00:00
parent d7c2057f75
commit 86af0d1529
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=86026
4 changed files with 0 additions and 27 deletions

View File

@ -157,26 +157,6 @@ static struct cdevsw digi_sw = {
ttykqfilter /* bmaj */
};
int
digi_modhandler(module_t mod, int event, void *arg)
{
static int ref = 0;
switch (event) {
case MOD_LOAD:
if (ref++ == 0)
cdevsw_add(&digi_sw);
break;
case MOD_UNLOAD:
if (--ref == 0)
cdevsw_remove(&digi_sw);
break;
}
return (0);
}
static void
digi_poll(void *ptr)
{

View File

@ -211,7 +211,6 @@ extern const struct digi_control_signals digi_xixe_signals;
extern const struct digi_control_signals digi_normal_signals;
const char *digi_errortxt(int _id);
int digi_modhandler(module_t _mod, int _event, void *_arg);
int digi_attach(struct digi_softc *);
int digi_detach(device_t _dev);
int digi_shutdown(device_t _dev);

View File

@ -469,6 +469,3 @@ static driver_t digi_isa_drv = {
digi_isa_methods,
sizeof(struct digi_softc),
};
DRIVER_MODULE(digi, isa, digi_isa_drv, digi_devclass, digi_modhandler, 0);

View File

@ -225,6 +225,3 @@ static driver_t digi_pci_drv = {
digi_pci_methods,
sizeof(struct digi_softc),
};
DRIVER_MODULE(digi, pci, digi_pci_drv, digi_devclass, digi_modhandler, 0);