OpenVZ Forum


Home » Mailing lists » Devel » [PATCH] block layer: ioprio_best function fix
Re: [PATCH] block layer: ioprio_best function fix [message #7382 is a reply to message #7379] Thu, 12 October 2006 13:09 Go to previous message
Jens Axboe is currently offline  Jens Axboe
Messages: 30
Registered: October 2006
Member
On Thu, Oct 12 2006, Vasily Tarasov wrote:
> Currently ioprio_best function first checks wethere aioprio or bioprio equals
> IOPRIO_CLASS_NONE (ioprio_valid() macros does that) and if it is so it returns
> bioprio/aioprio appropriately. Thus the next four lines, that set aclass/bclass
> to IOPRIO_CLASS_BE, if aclass/bclass == IOPRIO_CLASS_NONE, are never executed.
>
> The second problem: if aioprio from class IOPRIO_CLASS_NONE and bioprio from
> class IOPRIO_CLASS_IDLE are passed to ioprio_best function, it will return
> IOPRIO_CLASS_IDLE. It means that during __make_request we can merge two
> requests and set the priority of merged request to IDLE, while one of
> the initial requests originates from a process with NONE (default) priority.
> So we can get a situation when a process with default ioprio will experience
> IO starvation, while there is no process from real-time class in the system.
>
> Just removing ioprio_valid check should correct situation.

Analysis looks correct, thanks.

--
Jens Axboe
 
Read Message
Read Message
Previous Topic: Re: IMPORTANT: latest RHEL4 kernel has a root exploit!! (2.6.9-023stab016.2)
Next Topic: [PATCH] logger: make console output independent from loglevel
Goto Forum:
  


Current Time: Tue Sep 09 12:06:14 GMT 2025

Total time taken to generate the page: 0.07433 seconds