mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-30 18:47:01 +00:00
parent
c8cf33a251
commit
5bdc88bf57
@ -171,7 +171,7 @@ class Kernel::Cpu : public Genode::Cpu, private Irq::Pool, private Timeout
|
||||
/**
|
||||
* Returns the currently active job
|
||||
*/
|
||||
Job & scheduled_job() const {
|
||||
Job & scheduled_job() {
|
||||
return *static_cast<Job *>(&_scheduler.head())->helping_destination(); }
|
||||
|
||||
unsigned id() const { return _id; }
|
||||
|
@ -313,9 +313,12 @@ void Cpu_scheduler::quota(Share &s, unsigned const q)
|
||||
}
|
||||
|
||||
|
||||
Cpu_share &Cpu_scheduler::head() const
|
||||
Cpu_share &Cpu_scheduler::head()
|
||||
{
|
||||
assert(_head);
|
||||
if (!_head) {
|
||||
Genode::error("attempt to access invalid scheduler head");
|
||||
update(_last_time);
|
||||
}
|
||||
return *_head;
|
||||
}
|
||||
|
||||
|
@ -233,7 +233,7 @@ class Kernel::Cpu_scheduler
|
||||
* Accessors
|
||||
*/
|
||||
|
||||
Share &head() const;
|
||||
Share &head();
|
||||
unsigned head_quota() const {
|
||||
return Genode::min(_head_quota, _residual); }
|
||||
unsigned quota() const { return _quota; }
|
||||
|
Loading…
Reference in New Issue
Block a user