mirror of
https://github.com/RGBCube/serenity
synced 2025-05-24 01:15:07 +00:00
Kernel: Make Processor::id a static function
This eliminates the window between calling Processor::current and the member function where a thread could be moved to another processor. This is generally not as big of a concern as with Processor::current_thread, but also slightly more light weight.
This commit is contained in:
parent
21d288a10e
commit
e2f9e557d3
7 changed files with 48 additions and 38 deletions
|
@ -677,7 +677,7 @@ static bool procfs$cpuinfo(InodeIdentifier, KBufferBuilder& builder)
|
|||
JsonArray features;
|
||||
for (auto& feature : info.features().split(' '))
|
||||
features.append(feature);
|
||||
obj.add("processor", proc.id());
|
||||
obj.add("processor", proc.get_id());
|
||||
obj.add("cpuid", info.cpuid());
|
||||
obj.add("family", info.display_family());
|
||||
obj.add("features", features);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue