-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Block the connection of any other drivers
- Loading branch information
Showing
4 changed files
with
85 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// | ||
// DummyGraphics.cpp | ||
// UEFIGraphicsFB | ||
// | ||
// Copyright © 2021 Goldfish64. All rights reserved. | ||
// | ||
|
||
#include "DummyGraphics.h" | ||
|
||
OSDefineMetaClassAndStructors(DummyGraphics, IOService); | ||
|
||
IOService *DummyGraphics::probe(IOService *provider, SInt32 *score) { | ||
if (!IOService::probe(provider, score)) { | ||
return nullptr; | ||
} | ||
return this; | ||
} | ||
|
||
bool DummyGraphics::start(IOService *provider) { | ||
// Discard all other drivers as no coexistence is allowed. | ||
if (!IOService::start(provider)) { | ||
return false; | ||
} | ||
return true; | ||
} | ||
|
||
void DummyGraphics::stop(IOService *provider) { | ||
IOService::stop(provider); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// | ||
// DummyGraphics.h | ||
// UEFIGraphicsFB | ||
// | ||
// Copyright © 2021 Goldfish64. All rights reserved. | ||
// | ||
|
||
#ifndef _DUMMY_GRAPHICS_H_ | ||
#define _DUMMY_GRAPHICS_H_ | ||
|
||
#include "UEFIGraphicsFB.h" | ||
|
||
class DummyGraphics : public IOService { | ||
OSDeclareDefaultStructors(DummyGraphics); | ||
|
||
public: | ||
// | ||
// IOService functions. | ||
// | ||
virtual IOService *probe(IOService *provider, SInt32 *score) APPLE_KEXT_OVERRIDE; | ||
virtual bool start(IOService *provider) APPLE_KEXT_OVERRIDE; | ||
virtual void stop(IOService *provider) APPLE_KEXT_OVERRIDE; | ||
|
||
}; | ||
|
||
#endif /* _DUMMY_GRAPHICS_H_ */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters