mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-05-27 15:04:33 +00:00
Create a thread instead of a new process
This commit is contained in:
parent
a592b85ce5
commit
de5d8154ab
@ -76,10 +76,10 @@ namespace NetworkInterfaceManager
|
||||
{
|
||||
TaskManager->GetCurrentThread()->SetPriority(Tasking::TaskPriority::Critical);
|
||||
DeviceInterface *DefaultDevice = nullptr;
|
||||
foreach (auto var in Interfaces)
|
||||
if (var && var->DriverCallBackAddress)
|
||||
foreach (auto inf in Interfaces)
|
||||
if (inf && inf->DriverCallBackAddress)
|
||||
{
|
||||
DefaultDevice = var;
|
||||
DefaultDevice = inf;
|
||||
break;
|
||||
}
|
||||
|
||||
@ -156,8 +156,8 @@ namespace NetworkInterfaceManager
|
||||
|
||||
void NetworkInterface::StartService()
|
||||
{
|
||||
this->NetSvcProcess = TaskManager->CreateProcess(TaskManager->GetCurrentProcess(), "Network Service", Tasking::TaskTrustLevel::System);
|
||||
this->NetSvcThread = TaskManager->CreateThread(this->NetSvcProcess, (Tasking::IP)CallStartNetworkStackWrapper);
|
||||
this->NetSvcThread = TaskManager->CreateThread(TaskManager->GetCurrentProcess(), (Tasking::IP)CallStartNetworkStackWrapper);
|
||||
this->NetSvcThread->Rename("Network Service");
|
||||
}
|
||||
|
||||
void NetworkInterface::DrvSend(unsigned int DriverID, unsigned char *Data, unsigned short Size)
|
||||
|
@ -52,7 +52,6 @@ namespace NetworkInterfaceManager
|
||||
int CardIDs = 0;
|
||||
Vector<DeviceInterface *> Interfaces;
|
||||
|
||||
Tasking::PCB *NetSvcProcess;
|
||||
Tasking::TCB *NetSvcThread;
|
||||
void StopNetworkStack();
|
||||
void FetchNetworkCards(unsigned long DriverUID);
|
||||
|
Loading…
x
Reference in New Issue
Block a user