From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-yw1-xc42.google.com ([2607:f8b0:4864:20::c42]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gEVKI-00079T-CT for linux-mtd@lists.infradead.org; Mon, 22 Oct 2018 08:12:39 +0000 Received: by mail-yw1-xc42.google.com with SMTP id m127-v6so15659820ywb.0 for ; Mon, 22 Oct 2018 01:12:27 -0700 (PDT) Subject: Re: [PATCH v2] block: BFQ default for single queue devices To: Linus Walleij , bgurney@redhat.com Cc: Bart Van Assche , Jan Kara , Paolo Valente , linux-block , linux-mmc , linux-mtd@lists.infradead.org, Pavel Machek , Ulf Hansson , Richard Weinberger , Adrian Hunter , Artem Bityutskiy , Christoph Hellwig , One Thousand Gnomes , Mark Brown , Damien Le Moal , Johannes Thumshirn , Oleksandr Natalenko , Jonathan Corbet References: <20181015141059.26579-1-linus.walleij@linaro.org> <307F6078-0A77-4AAA-BE1A-55C2ACC328CC@linaro.org> <689F28AA-92B5-48B5-BBE7-0B589F163228@linaro.org> <7375c004-ac6e-c692-4282-46de554285d5@kernel.dk> <20181017100526.GB23493@quack2.suse.cz> From: Jens Axboe Message-ID: Date: Mon, 22 Oct 2018 02:12:15 -0600 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On 10/19/18 2:42 AM, Linus Walleij wrote: > On Wed, Oct 17, 2018 at 4:59 PM Bryan Gurney wrote: > >> I feel strongly about the prevention of users running into errors >> because of an incorrect scheduler default, because I encountered that >> situation three times in my testing with zoned block devices. The >> switch to SCSI_MQ would resolve that, since mq-deadline is the >> default, but in my case, I was using Fedora 28, which disables >> CONFIG_SCSI_MQ_DEFAULT (which is enabled in the 4.18 kernel), so my >> default scheduler was cfq. > > I think we should make a patch to the kernel that makes it > impossible (even from sysfs) to choose a non-zone aware > scheduler for these devices. > > It's another topic than $SUBJECT patch though. I take this > into account in this version. Yes I agree, and I'd be happy to take such a patch. The only matching we do now is mq-sched for mq-device, and vice versa. And that will be going away in 4.21, when there are no more !mq devices that use scheduling. If your device is zoned, then you should not be able to switch to a scheduler that doesn't have support for that. The right approach here would be to add a capability flag to the IO schedulers. -- Jens Axboe