Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp4038613ybl; Mon, 12 Aug 2019 10:18:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqz1MvrETTOwoqGFBh/XVTWqP3CpcbbtFmRrzfy9xoaRsCSUWeSn34m3+1SAmU34hp66o7To X-Received: by 2002:a65:62d7:: with SMTP id m23mr31121921pgv.358.1565630334135; Mon, 12 Aug 2019 10:18:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565630334; cv=none; d=google.com; s=arc-20160816; b=r7MlViPjH7W8vsaDNAZ/69Fp0LVh9cTncdevXQDzGjT/m/UWungvG5WILmtW6fB+Zv XASoOgrLs6SzgqekzPY2YbR3xTJ9MkBuVwz/i67Aelsie+JpQZrSiG7NC7KuIs1Q1wEQ L85BZNelV98oBAQFm8PBvJu8UCmPpIDVksqI/aY5kkoKmbrk9kLjEsOHt8oguBVOP1h2 p3pUUVUJ8vzZOBUIBjrMRXIH11BZdbI8CaWp4vLRt2FNeWjPC58Dz9jilqiHsrsILPqu aCEbzGERubXXb436O6ABcMOHISHZwaMbdcssQnUZET1hL7vTaFG0pyi9Bt1qOP9qMAgk 8aUg== 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:dkim-signature; bh=+YNZsLLrlPEHgxpe/aXTTjPaVKmiuk5SL+l/sNwb+ns=; b=a0TaDvwIn2xTlwXEQkO5clXspIXfJbj11CPU7sM6+Q0omi1p5ueLRKowiwIh6iKhv6 l9JPRnVQa45fInykawrzQALSyl4NPJ+5OwLgmjQ7OvxgtYGYjWIu1kSlU0modacdzf26 Nq29H7YeCTa5H1C+Ttuju0rXe/snVgcW1purZZWPu9AcqXw60dKcDqEP6Jtzuuw8Hugk 301v6kiNerxePWmIWWVPUVR0/4/xsNWwLlOBrYmm+CHxKu15DFZtsy/MWAEFhzXGcSyX SUVMqd+/hwET7Vg/BC12iO3NjYRBDAKwLIuiVy7syWxBzs0E7TU2HZsxaA2o+h8ww2oU vO0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=WKjvzGbY; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-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 v3si71329pjr.26.2019.08.12.10.18.35; Mon, 12 Aug 2019 10:18:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=WKjvzGbY; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725843AbfHLRSd (ORCPT + 99 others); Mon, 12 Aug 2019 13:18:33 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:37254 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725822AbfHLRSd (ORCPT ); Mon, 12 Aug 2019 13:18:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=+YNZsLLrlPEHgxpe/aXTTjPaVKmiuk5SL+l/sNwb+ns=; b=WKjvzGbYVhYzvQjOTh2WsDgiT 6hxUSVu9+fTGD94fmSJtIGQEk9R79K5WuN9GVnWNHw525ZtBf6q7le7b1cXTsbWxoRhcl0jKKh6RS rOXYfhF+XI9EmNidIXBwxX6lt1V8ZA7V0qFHLBpo24OOpzf3eLDA5/g/Kmk11DSy3uN+zyKwJikjN poMe2UL1OklLd7Dar2GoMkgdCV/tNHOk0wVp+xYLaYkjyal0tGQKCmOILf4Iyz7wJgXFJ2iYNN5Ns td4KwsHm/lxUztsD1iOQNHUp50ZDbJJoJ2mnS8A7mvYB/JfaTPRz8C1mKXSjJ4l/nKPPl9FOIRUpO jlnOoXV5A==; Received: from hch by bombadil.infradead.org with local (Exim 4.92 #3 (Red Hat Linux)) id 1hxDxo-0001Lt-I3; Mon, 12 Aug 2019 17:18:32 +0000 Date: Mon, 12 Aug 2019 10:18:32 -0700 From: Christoph Hellwig To: Matthew Bobrowski Cc: linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org, jack@suse.cz, tytso@mit.edu, riteshh@linux.ibm.com Subject: Re: [PATCH 3/5] iomap: modify ->end_io() calling convention Message-ID: <20190812171832.GA24564@infradead.org> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.4 (2019-03-13) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org please add linux-xfs to the cc list for the whole series. Besides touching xfs itself it is also mentioned in MAINTAINERS for the iomap code. On Mon, Aug 12, 2019 at 10:53:11PM +1000, Matthew Bobrowski wrote: > - if (size <= 0) > - return size; > + if (error || !size) > + return error ? error : size; This should be: if (error) return error; if (!size) return 0; > if (flags & IOMAP_DIO_COW) { > - error = xfs_reflink_end_cow(ip, offset, size); > - if (error) > + ret = xfs_reflink_end_cow(ip, offset, size); > + if (ret) I think we can just keep reusing error here. > +typedef int (iomap_dio_end_io_t)(struct kiocb *iocb, ssize_t size, > + ssize_t error, unsigned int flags); error should be an int and not a ssize_t.