
7.10Unregistering the Card from the Hardware Management Database
The following code shows how the el_unattach( ) routine unregisters the card from the hardware management database:
1
1
Frees up any memory allocated for enhanced hardware management and unregisters this card from the hardware management database.
7.11 Freeing Resources
The following code shows how the el_unattach( ) routine frees data structures and memory that the adapter uses:
FREE(sc, M_DEVBUF); 1 el_softc[unit] = NULL; el_info[unit] = NULL;
return (ESUCCESS);
}
1
Frees all memory that the adapter uses, and returns ESUCCESS to indicate that the unattach operation completed successfully.
Implementing the unattach Routine