Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp5759040imu; Mon, 26 Nov 2018 04:59:46 -0800 (PST) X-Google-Smtp-Source: AFSGD/UMQbMEhw9almxqdXJlc8UR7xDgiB+/9BdD0y0y7qE93J+Zr6ZiUxYB2UdCKwTp3D1uMIvW X-Received: by 2002:a63:1a4b:: with SMTP id a11mr24982066pgm.254.1543237186509; Mon, 26 Nov 2018 04:59:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543237186; cv=none; d=google.com; s=arc-20160816; b=MAztZ6wYApMolXQM+ga2ljRuZkcfX8etESZij5anOwAUwiZx6VXVj+v9OqkdqpHz97 TAi/kmFwgiuMxhUO9+8HJ2inQLaTqnAVwnJbRYmalNL2hpcJ7VkLiisewiQiwyWHzkqI 2j+adjOmDmHM3rQHuzbqgQmeYEWD3Lvv39K/J/8kMq/7UH8yjeMhdyX5z6ztPTVXox+N D38r6IHrunwDHy/R1Ur4n7FSAglK9kYLNJGSHxs7GkqTCsHwf35dnTLUqziCdM3SLslL FrM0rpJXPQAYpj+dnXJ/IMcs6WyfFencDEOclsuQEQplFDUv/CnaY3j77llcIw4j3+9V ttrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=HB4i2q6g2eA3n+ce19Jgg1JvDjIsix/LU2q9HJtqWl4=; b=mQaU0DgdtbKCHnswmmiQDePANUd1nGqLpmGBcbPocG6S1vjBmB9x9a/+6d20qBEwsx ylKFby+KKFMdthtx7YlueSFP62VzuALmeU91FWsKqDPFT4GW81/ndCyXiKKy2RY0VpQC 8BaelVSrOjIXBU4e/3HOLSVNcxGWUVUHYAyyAJT6cH4ujX2MqMZnosFXzlGKMTqtPMMs 05DJuRBOgagnKp6/YZgLHsv0xpNCloniOoJcUeLjLkX8YBKUAEOqWrCNgQGPtP7aB4UT bvc1gWDhRIHoWqhaE3SoJ0ziDFxKg4rwGZuumEEhsOZwYrJLIVyHZpPWtIXsXpNygaCa 7+Fw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u11si330864plm.8.2018.11.26.04.59.20; Mon, 26 Nov 2018 04:59:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726916AbeKZXwt (ORCPT + 99 others); Mon, 26 Nov 2018 18:52:49 -0500 Received: from verein.lst.de ([213.95.11.211]:51886 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726206AbeKZXwt (ORCPT ); Mon, 26 Nov 2018 18:52:49 -0500 Received: by newverein.lst.de (Postfix, from userid 2407) id D638568BF4; Mon, 26 Nov 2018 13:58:42 +0100 (CET) Date: Mon, 26 Nov 2018 13:58:42 +0100 From: Christoph Hellwig To: Ming Lei Cc: Jens Axboe , linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Theodore Ts'o , Omar Sandoval , Sagi Grimberg , Dave Chinner , Kent Overstreet , Mike Snitzer , dm-devel@redhat.com, Alexander Viro , linux-fsdevel@vger.kernel.org, Shaohua Li , linux-raid@vger.kernel.org, David Sterba , linux-btrfs@vger.kernel.org, "Darrick J . Wong" , linux-xfs@vger.kernel.org, Gao Xiang , Christoph Hellwig , linux-ext4@vger.kernel.org, Coly Li , linux-bcache@vger.kernel.org, Boaz Harrosh , Bob Peterson , cluster-devel@redhat.com Subject: Re: [PATCH V12 16/20] block: enable multipage bvecs Message-ID: <20181126125842.GE6383@lst.de> References: <20181126021720.19471-1-ming.lei@redhat.com> <20181126021720.19471-17-ming.lei@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181126021720.19471-17-ming.lei@redhat.com> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > + phys_addr_t vec_end_addr = page_to_phys(bv->bv_page) + > + bv->bv_offset + bv->bv_len; The name is a little confusing, as the real end addr would be -1. Maybe throw the -1 in here, and adjust for it in the contigous check below?