From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay.sgi.com (relay3.corp.sgi.com [198.149.34.15]) by oss.sgi.com (Postfix) with ESMTP id 0A5437CB6 for ; Tue, 29 Mar 2016 02:29:39 -0500 (CDT) Received: from cuda.sgi.com (cuda1.sgi.com [192.48.157.11]) by relay3.corp.sgi.com (Postfix) with ESMTP id 8EBC8AC003 for ; Tue, 29 Mar 2016 00:29:38 -0700 (PDT) Received: from bombadil.infradead.org ([198.137.202.9]) by cuda.sgi.com with ESMTP id almNHZI5IdqshuNM (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for ; Tue, 29 Mar 2016 00:29:37 -0700 (PDT) Date: Tue, 29 Mar 2016 00:29:33 -0700 From: Christoph Hellwig Subject: Re: [PATCH 5/8] fs: xfs: replace BIO_MAX_SECTORS with BIO_MAX_PAGES Message-ID: <20160329072933.GF18920@infradead.org> References: <1458627149-12988-1-git-send-email-ming.lei@canonical.com> <1458627149-12988-6-git-send-email-ming.lei@canonical.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1458627149-12988-6-git-send-email-ming.lei@canonical.com> List-Id: XFS Filesystem from SGI List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: xfs-bounces@oss.sgi.com Sender: xfs-bounces@oss.sgi.com To: Ming Lei Cc: Jens Axboe , Christoph Hellwig , Boaz Harrosh , linux-kernel@vger.kernel.org, xfs@oss.sgi.com, linux-block@vger.kernel.org, Al Viro , Lars Ellenberg , Philipp Reisner , Anton Altaparmakov , drbd-dev@lists.linbit.com > + nr_pages = BIO_MAX_PAGES; > if (nr_pages > total_nr_pages) > nr_pages = total_nr_pages; Looks reasonable, but the whole thing could simply become: nr_pages = min(total_nr_pages, BIO_MAX_PAGES); _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs