1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-02-09 02:26:27 +00:00

fix a bug to handling the argument that it passed `device_t' but it's

handled as `struct ndis_softc'.  It'll cause a panic when the driver is
detached.
This commit is contained in:
Weongyo Jeong 2008-12-27 09:42:17 +00:00
parent 511080ae53
commit e3a7c990ff
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=186509

View File

@ -1205,11 +1205,13 @@ ndis_pnpevent_nic(arg, type)
void *arg;
int type;
{
device_t dev;
struct ndis_softc *sc;
ndis_handle adapter;
ndis_pnpevent_handler pnpeventfunc;
sc = arg;
dev = arg;
sc = device_get_softc(arg);
NDIS_LOCK(sc);
adapter = sc->ndis_block->nmb_miniportadapterctx;
pnpeventfunc = sc->ndis_chars->nmc_pnpevent_handler;