Driver Management Stuff.
git-svn-id: https://spexeah.com:8443/svn/Asuro@287 6dbc8c32-bb84-406f-8558-d1cf31a0ab0c
This commit is contained in:
parent
875ce244c3
commit
5ab6edf121
BIN
bin/kernel.bin
BIN
bin/kernel.bin
Binary file not shown.
Binary file not shown.
BIN
lib/kernel.ppu
BIN
lib/kernel.ppu
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
lib/libpsystem.a
BIN
lib/libpsystem.a
Binary file not shown.
@ -85,9 +85,6 @@ begin
|
||||
force_alloc_block(block, 0);
|
||||
map_page(block, block);
|
||||
MMR:= POHCI_MMR(devices[i].address0);
|
||||
MMR^.HcRevision:= 200;
|
||||
console.writestring('HcRevision? ');
|
||||
console.writehexln(getByte(MMR^.HcRevision, 0));
|
||||
end;
|
||||
end;
|
||||
|
||||
|
63
src/driver_management.pas
Normal file
63
src/driver_management.pas
Normal file
@ -0,0 +1,63 @@
|
||||
{ ************************************************
|
||||
* Asuro
|
||||
* Unit: Driver_Management
|
||||
* Description: Manages Driver Loading
|
||||
************************************************
|
||||
* Author: K Morris
|
||||
* Contributors:
|
||||
************************************************ }
|
||||
unit Driver_Management;
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
util, strings;
|
||||
|
||||
type
|
||||
PDevEx = ^TDevEx;
|
||||
TDevEx = record
|
||||
idN : uInt32;
|
||||
ex : PDevEx;
|
||||
end;
|
||||
|
||||
TBusIdentifier = (biUnknown, biPCI, biUSB, bii2c, biPCIe);
|
||||
|
||||
PDeviceIdentifier = ^TDeviceIdentifier;
|
||||
TDeviceIdentifier = record
|
||||
Bus : TBusIdentifier;
|
||||
id0 : uInt32;
|
||||
id1 : uInt32;
|
||||
id2 : uInt32;
|
||||
id3 : uint32;
|
||||
ex : PDevEx;
|
||||
end;
|
||||
|
||||
TDriverLoadCallback = procedure();
|
||||
|
||||
PDriverRegistration = ^TDriverRegistration;
|
||||
TDriverRegistration = record
|
||||
Identifier : TDeviceIdentifier;
|
||||
Driver_Load : TDriverLoadCallback;
|
||||
Loaded : Boolean;
|
||||
Next : PDriverRegistration;
|
||||
end;
|
||||
|
||||
procedure RegisterDriver(DeviceID : PDeviceIdentifier; Load_Callback : TDriverLoadCallback);
|
||||
procedure RegisterDevice(DeviceID : PDeviceIdentifier);
|
||||
|
||||
var
|
||||
Root : PDriverRegistration = nil;
|
||||
|
||||
implementation
|
||||
|
||||
procedure RegisterDriver(DeviceID : PDeviceIdentifier; Load_Callback : TDriverLoadCallback);
|
||||
begin
|
||||
|
||||
end;
|
||||
|
||||
procedure RegisterDevice(DeviceID : PDeviceIdentifier);
|
||||
begin
|
||||
|
||||
end;
|
||||
|
||||
end.
|
@ -26,6 +26,7 @@ uses
|
||||
vmemorymanager,
|
||||
pmemorymanager,
|
||||
lmemorymanager,
|
||||
driver_management,
|
||||
tss,
|
||||
scheduler,
|
||||
PCI,
|
||||
@ -115,7 +116,6 @@ begin
|
||||
console.writestringln('DRIVERS: INIT BEGIN.');
|
||||
pci.init();
|
||||
keyboard.init(keyboard_layout);
|
||||
keyboard.hook(@temphook);
|
||||
mouse.init();
|
||||
USB.init();
|
||||
console.writestringln('DRIVERS: INIT END.');
|
||||
@ -137,6 +137,7 @@ begin
|
||||
console.setdefaultattribute(console.combinecolors(White, Black));
|
||||
console.writestringln('');
|
||||
console.writestringln('Press any key to boot in to Asuro Terminal...');
|
||||
keyboard.hook(@temphook);
|
||||
util.halt_and_dont_catch_fire;
|
||||
end;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user