lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Tue, 29 Mar 2016 03:08:42 +0000 (GMT)
From:	Daeho Jeong <daeho.jeong@...sung.com>
To:	axboe@...com
Cc:	linux-block@...r.kernel.org, linux-ext4@...r.kernel.org
Subject: Question about CFQ queue preemption with REQ_PRIO

Hi,

First of all, I am a big fan of the CFQ I/O scheduler. Thank you for your contribution. :-)
I have a question about the below CFQ queue preemption condition in cfq_should_preempt().

        /*
         * So both queues are sync. Let the new request get disk time if
         * it's a metadata request and the current queue is doing regular IO.
         */
        if ((rq->cmd_flags & REQ_PRIO) && !cfqq->prio_pending)
                return true;

Normally, REQ_PRIO flag is used for READ requests for reading metadata, so then, the CFQ
queue containing "rq" must be a SYNC queue and cfqq is also a SYNC queue because we
already passed through the below condition. Therefore, the comment "So both queues are sync"
is TRUE.

        if (rq_is_sync(rq) && !cfq_cfqq_sync(cfqq))
                return true;

But, I am wordering about the case of that an asynchronous WRITE request with REQ_PRIO
is inserted into the request queue. Actually, ext4 metadata are submitted as asynchronous
WRITE requests with REQ_PRIO by kworker. In this case, asynchronous WRITE requests can
preempt synchronous READ requests. Anyways, I think ext4 metadata write should have
priority for better filesystem call responsiveness, but the comment in the source code,
"So both queues are sync", makes me a little confused.

Could you explain about the meaning of the comment in the source code?

Best Regards,

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ