Fixed broken driver unloading on shutdown/crash

This commit is contained in:
Alex
2022-12-17 18:20:47 +02:00
parent d33a812703
commit ed49b3ab7c
7 changed files with 28 additions and 38 deletions

View File

@ -42,7 +42,7 @@ namespace Driver
{
fixme("Generic driver: %s", fexExtended->Driver.Name);
DriverFile *DrvFile = new DriverFile;
DrvFile->DriverUID = KAPI.Info.DriverUID;
DrvFile->DriverUID = this->DriverUIDs - 1;
DrvFile->Address = (void *)fex;
Drivers.push_back(DrvFile);
break;
@ -142,7 +142,7 @@ namespace Driver
KCallback->Reason = CallbackReason::InterruptReason;
DriverFile *DrvFile = new DriverFile;
DrvFile->DriverUID = KAPI.Info.DriverUID;
DrvFile->DriverUID = this->DriverUIDs - 1;
DrvFile->Address = (void *)fex;
DrvFile->InterruptHook[0] = InterruptHook;
Drivers.push_back(DrvFile);