From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4E3C0C4363D for ; Thu, 24 Sep 2020 15:03:32 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id C01912311A for ; Thu, 24 Sep 2020 15:03:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="IKbUluUB" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C01912311A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 432838E0005; Thu, 24 Sep 2020 11:03:31 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3E27A8E0001; Thu, 24 Sep 2020 11:03:31 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 2F98D8E0005; Thu, 24 Sep 2020 11:03:31 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0201.hostedemail.com [216.40.44.201]) by kanga.kvack.org (Postfix) with ESMTP id 18DF78E0001 for ; Thu, 24 Sep 2020 11:03:31 -0400 (EDT) Received: from smtpin02.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id C650E180AD811 for ; Thu, 24 Sep 2020 15:03:30 +0000 (UTC) X-FDA: 77298273780.02.shade28_4106a882715f Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin02.hostedemail.com (Postfix) with ESMTP id 9291C1016C8D2 for ; Thu, 24 Sep 2020 15:03:30 +0000 (UTC) X-HE-Tag: shade28_4106a882715f X-Filterd-Recvd-Size: 3405 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by imf32.hostedemail.com (Postfix) with ESMTP for ; Thu, 24 Sep 2020 15:03:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600959809; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=CuPbzvXQosIYzpsTmyDB+PWCFgx3pRZznwdDq166LWs=; b=IKbUluUBlNINh996O+RKMbH4p1TuesSGuv2sE3xB98vIqE3nYLAdyw9+kt7iDm7BAzNJ1K CG+M8f5Oy9fI5yvidOYu/UJ2xvA9Rs8lEvfXIs77/dUGkBzMkCINAatJAIYR2s8jTfm89t g28a2lipLgQdQp9Rd2uoPMfINmJHzRc= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-283-iUJ3YX6mN1eUqjWHfNMFxw-1; Thu, 24 Sep 2020 11:03:27 -0400 X-MC-Unique: iUJ3YX6mN1eUqjWHfNMFxw-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5C924802B75; Thu, 24 Sep 2020 15:03:24 +0000 (UTC) Received: from localhost (unknown [10.18.25.174]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 92FD35C1D7; Thu, 24 Sep 2020 15:03:19 +0000 (UTC) Date: Thu, 24 Sep 2020 11:03:19 -0400 From: Mike Snitzer To: Christoph Hellwig Cc: Jens Axboe , linux-raid@vger.kernel.org, Hans de Goede , Justin Sanders , Minchan Kim , Johannes Thumshirn , cgroups@vger.kernel.org, linux-bcache@vger.kernel.org, Coly Li , linux-block@vger.kernel.org, Song Liu , dm-devel@redhat.com, linux-mtd@lists.infradead.org, Richard Weinberger , drbd-dev@tron.linbit.com, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 07/13] block: lift setting the readahead size into the block layer Message-ID: <20200924150318.GE13849@redhat.com> References: <20200924065140.726436-1-hch@lst.de> <20200924065140.726436-8-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200924065140.726436-8-hch@lst.de> User-Agent: Mutt/1.5.21 (2010-09-15) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu, Sep 24 2020 at 2:51am -0400, Christoph Hellwig wrote: > Drivers shouldn't really mess with the readahead size, as that is a VM > concept. Instead set it based on the optimal I/O size by lifting the > algorithm from the md driver when registering the disk. Also set > bdi->io_pages there as well by applying the same scheme based on > max_sectors. To ensure the limits work well for stacking drivers a > new helper is added to update the readahead limits from the block > limits, which is also called from disk_stack_limits. > > Signed-off-by: Christoph Hellwig > Acked-by: Coly Li > Reviewed-by: Johannes Thumshirn Thanks for adding blk_queue_update_readahead() Reviewed-by: Mike Snitzer