Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp52517ybh; Mon, 20 Jul 2020 10:05:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwLZVn8dapRa0ST09L61Zqgd0q8MW9ycMFUbFGadlDWl4+8IlCT5MdfKGneCrC5RmyTEuvl X-Received: by 2002:a17:906:1f94:: with SMTP id t20mr21048156ejr.233.1595264735330; Mon, 20 Jul 2020 10:05:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595264735; cv=none; d=google.com; s=arc-20160816; b=hC0soYeoCM2KFETzp2qf0ADE5+NnD+cpO7QCXWCBpHNQPSFSaBxdtfty/y/eC66r2k CaSiAbBxMCZLt9jW1i1/fE1wmBzmJFUIElsV4gjpiDyX6bLgCXXmugj9ihD9hduGx829 ntDHQ7790OIpTB/Dk+JB6QJkdwD7lW1kGbADl8TA9kIrsqXyNCg/8pNSexEo0q+SqFSy vs3r9pZ+DxUavu673KS2v8qJZRrGCFgUfTCpbsxfHFnsjp8oG+4fpnhZfMih7t8ejB/P 5Gqp+RbpdzPuoLk8OaHOjwfxFL4fU6u0b0vIeFNuscF1ss5AfvHGR0Ed20fmm1Q80DeW OohQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=2z6vfRN45O58360WXxB9JosENc0eD1jtyLCvWHGh1YY=; b=YhllCH4aj5DaW6lE0K++GECZWn2NhQR153JHPao3rB1penWbasvtMrGBu5KQvGCpFe eWWZKjlekEGaI2HkwmgAVqNsGyKWzFZGvzX+vmEu1ooTUFi0ltndG9n2AuZtPgqNQMpW FxDXU4UbOnOBNjPnRgxlMIGv06eW88jm0dWRLrtFmaCY4WnLg/i+3Jfl2YUvOrr5p1Kz 2JqxvsZSAnUxVPobrlwODjHei59mZWVO/1vwGflsgFxdfKBS8t2+ZnX2O3UA1Q9WxNsN XnxoPX52348TXJIK3f4nE26eM+4GqkjcAGgqtXpmcD63HtIBGEJkPTRgyq7W1No1MI3Y y/fA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NDSdkoTt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c4si10758734edq.372.2020.07.20.10.05.10; Mon, 20 Jul 2020 10:05:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NDSdkoTt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729780AbgGTRDP (ORCPT + 99 others); Mon, 20 Jul 2020 13:03:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51880 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728346AbgGTRDO (ORCPT ); Mon, 20 Jul 2020 13:03:14 -0400 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 16861C061794; Mon, 20 Jul 2020 10:03:14 -0700 (PDT) Received: by mail-wr1-x441.google.com with SMTP id a15so3637538wrh.10; Mon, 20 Jul 2020 10:03:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=2z6vfRN45O58360WXxB9JosENc0eD1jtyLCvWHGh1YY=; b=NDSdkoTtQtN9k8e5yU0/Q6OJPgewxcja66aFKP8Z7ADQhogTJURkNUpGl91G2fpCCU oIkZoqpmJ/x1DP3gXTsvgKPG2qkgxg7rLWiYBSMsPyfyECt8X4/CYlT8TvVEBnGbPnvO yhxBYdlA2ZXvEuMIGUxXzn75G7Kua2nEsR2NMUAkmMiJg5uOmfWYmmVFAbfbQbesJWEt LlS6Ou/POWTJOLnbo/h7xECwdjuxZ1t2atpEjWmxDllEDUmevYK9J1jM8unZROSC3aJf TER0ScfQ2MpTlWMVo4cYQaU10tOokxlhrgFoiZVHfW2W4jXw8xxyOoPY/JVpEy8KWQ/C V9Ew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=2z6vfRN45O58360WXxB9JosENc0eD1jtyLCvWHGh1YY=; b=rNTqgr0YeqS5MJRRck2jJ1YubKfKVvWigWXM0S4618NGxcbRyAxKc1sh2Foej0fZhu +ofG0U/2CfPSX+VWDj3uj15ovuULmAC+By0O20VKi9DN6TBuyGNnFetAAojkKMYHdZXJ 5pHH16LjotwTm7CPZmIW2NOnuUu8WKzN7s+ho9VGkfeKaszCeeNfP0tz9InarT8w/L/J MphzfIxTe1IAqrDFpa5PaEdjD0dvRAkkHyoyuiKXaqE4LwkLisVvfxZr/70kLXHerrUb zv/nz2PnjpEhjQeS/9YhEnONw+r16lkXzrLeBfU6TOFPDVcYjnRQ94DNXZ88PBgO/jx6 jRRQ== X-Gm-Message-State: AOAM532a58aXQpjytQf7UTc9NmbqDEbbcmi+t6LMo1xibH88B85pNdpA pLPaRhplkjA5QV+QcU6j+nGVIyhcOqvYfaT2DQ0= X-Received: by 2002:adf:f0ce:: with SMTP id x14mr22109097wro.137.1595264592763; Mon, 20 Jul 2020 10:03:12 -0700 (PDT) MIME-Version: 1.0 References: <1593974870-18919-5-git-send-email-joshi.k@samsung.com> <20200709085501.GA64935@infradead.org> <20200709140053.GA7528@infradead.org> <2270907f-670c-5182-f4ec-9756dc645376@kernel.dk> <20200710130912.GA7491@infradead.org> <20200710134350.GA14704@infradead.org> In-Reply-To: <20200710134350.GA14704@infradead.org> From: Kanchan Joshi Date: Mon, 20 Jul 2020 22:32:45 +0530 Message-ID: Subject: Re: [PATCH v3 4/4] io_uring: add support for zone-append To: Christoph Hellwig Cc: Jens Axboe , Kanchan Joshi , viro@zeniv.linux.org.uk, bcrl@kvack.org, Damien.LeMoal@wdc.com, asml.silence@gmail.com, linux-fsdevel@vger.kernel.org, "Matias Bj??rling" , linux-kernel@vger.kernel.org, linux-aio@kvack.org, io-uring@vger.kernel.org, linux-block@vger.kernel.org, Selvakumar S , Nitesh Shetty , Javier Gonzalez Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 10, 2020 at 7:13 PM Christoph Hellwig wrote: > > On Fri, Jul 10, 2020 at 06:59:45PM +0530, Kanchan Joshi wrote: > > > block doesn't work for the case of writes to files that don't have > > > to be aligned in any way. And that I think is the more broadly > > > applicable use case than zone append on block devices. > > > > But when can it happen that we do zone-append on a file (zonefs I > > asssume), and device returns a location (write-pointer essentially) > > which is not in multiple of 512b? > > All the time. You open a file with O_APPEND. You write a record to > it of any kind of size, then the next write will return the position > it got written at, which can be anything. I understand if this is about cached write and we are talking about O_APPEND in general. But for direct block I/O write and ZoneFS writes, page-cache is not used, so write(and zone-append result) will be aligned to underlying block size. Even though this patchset uses O_APPEND, it filters regular files and non zoned-block devices by using new FMODE_ZONE_APPEND flag. -- Joshi