Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1170137pxb; Thu, 28 Jan 2021 09:33:12 -0800 (PST) X-Google-Smtp-Source: ABdhPJw5VyheEx62RY3kaVK1zPfT9DinWRxIan2J1XGQIlQyL+byRVGDE8StmGQXH6/oK6O6No2W X-Received: by 2002:a05:6402:70a:: with SMTP id w10mr731731edx.184.1611855192203; Thu, 28 Jan 2021 09:33:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611855192; cv=none; d=google.com; s=arc-20160816; b=UvU4kLIEGmbqFNsdyeaIySi1s0k+bS7jQzLjiUjAR9OXo+sZfGyQ0EUVmqqS/wtRhS 88IyUqMREvNtxNrndidTLDflRJ9j7xcyI+6MzstSL+ng6MIfydmuA/RVnDUehm7SINXO MJydBBLkIxY0e4j9Ro3P4MHnfbT1LMLugBEB/dxYTFBo6kPMPbArclewVlXh9JvP73ZE oHMMoz2ewf6b0i0nzF/DL4CIZTKs8TPhB55BtiOQRCQEXbMURZTPCZ8tpEJOwQNzoocW Cg4Lv4l01TtN6Hqy7g/8ofp7cn1MwluKP/YEAaxCV2wbOj5soLnGP9+Ni1+bmNG18Imm 9WQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=FspasjBdvOyQr6r45W+eIjHtBw+6zev/SfrwICE1x+E=; b=ZDYhGki8z6d6J1ghwE7HmmWVT8tNrhzo8FngH8d2gc0rwMoQ6psiqDlqg2W3DNI3su oGMIYRyA2P6hUgc2zOMbnGkofS8zmz1PdcPdnx/VC6pxBfv7hLKS5wc5MbIiPBQm5L/A rz6eBTxjNizbN5dfuzXIQleBkfwyt7VrHazJx3SiEjqdUcy7Nw7Di/MQeiE9abe5xmi/ ztgINSH3uFrkDx/OUBgX6kVxitltXnOB8a/i6I51K3NWz2zvJ6XbS3JqW7xzJvi3YYHM XiOXNV3qq3zPMxcHRddybMqeEeMqrURIefhYaZRlS85vzKFChuEkmr5k3xtCeBf8vZ+A Tiwg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=M4blj2lA; 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 y12si3590061edr.418.2021.01.28.09.32.48; Thu, 28 Jan 2021 09:33:12 -0800 (PST) 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=M4blj2lA; 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 S233204AbhA1R3S (ORCPT + 99 others); Thu, 28 Jan 2021 12:29:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52856 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233122AbhA1R0u (ORCPT ); Thu, 28 Jan 2021 12:26:50 -0500 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C126C061756; Thu, 28 Jan 2021 09:26:10 -0800 (PST) Received: by mail-wm1-x32e.google.com with SMTP id j18so4948089wmi.3; Thu, 28 Jan 2021 09:26:10 -0800 (PST) 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=FspasjBdvOyQr6r45W+eIjHtBw+6zev/SfrwICE1x+E=; b=M4blj2lAzwljc11390CinZGBi0ydd5QI0CCu45Tj5PhQGdcUSCE8b2Tc9hoho3g22S agCTwHalauhPkOOxRsPCf91BAO9tmGmA/SPZQXHPrsx3lrcVzOgxJSBI06BgHSLIKqkZ Dh6cZ681hcvvWJVnqkqgYmVWj+MM5j0Wn5guMLjWQNAUlE+IMTAVybQPWQlbkA+iyGnf vCEX7rU+XsJtbzZZBrTi6jE9d4GwdNcrmAr3ntZo3y7xjfaHWIGJKSGYzA7xJdBRHKvQ NDyUWpmzSLCeF3Rcsl/iA+jdu2koTbJ6CPFhUgaBSxBs07wvqL1GwORoM1SsETsq9cg0 Tcrg== 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=FspasjBdvOyQr6r45W+eIjHtBw+6zev/SfrwICE1x+E=; b=CJniC295G5wb6EFAy3VSSvUKW7EWf1CFHiLhvgHZiTIphHJKRVzVWJGf+lITnZrVw0 Uz136kp/BBtRYbm+GNWMGrt0DD72qCm+r04KgmJy5qPT//e2MC7XaXXMaLFXe11FyJ9N CgJEGWp4PAYXSX5z/9TZAYi4aSf/3pGdprQecWbEbD+VmiYFYPJw6JcfITndJ6dOZ86f 8YyZ8KFlktd35Ge1hb/ynV4DFKOiNqdGo4cd5h2Tq8lhwk+xG0mwN1jHXiZH9SGa2dKz z5ZG02gsG07cipIzqcrCJ4oKm8eizoe2jGT11aaY0BZpGA4e4XyjGtwaOFxI1gNHU+ac RiZQ== X-Gm-Message-State: AOAM533KTRO1AyL1ZJtGD2Dss+BjUP8/GErpDpgvGalQCIRzZZqEjCAs 0bsj/UnrDff53pCWkIn14QtuHyYc+Hx+FzttOFM= X-Received: by 2002:a1c:5f54:: with SMTP id t81mr283428wmb.25.1611854769125; Thu, 28 Jan 2021 09:26:09 -0800 (PST) MIME-Version: 1.0 References: <20210127150029.13766-1-joshi.k@samsung.com> <489691ce-3b1e-30ce-9f72-d32389e33901@gmail.com> <6d847f4a-65a5-bc62-1d36-52e222e3d142@kernel.dk> In-Reply-To: <6d847f4a-65a5-bc62-1d36-52e222e3d142@kernel.dk> From: Kanchan Joshi Date: Thu, 28 Jan 2021 22:55:41 +0530 Message-ID: Subject: Re: [RFC PATCH 0/4] Asynchronous passthrough ioctl To: Jens Axboe Cc: Pavel Begunkov , Kanchan Joshi , Keith Busch , Christoph Hellwig , sagi@grimberg.me, linux-nvme@lists.infradead.org, io-uring@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Javier Gonzalez , Nitesh Shetty , anuj20.g@samsung.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 28, 2021 at 8:20 PM Jens Axboe wrote: > > On 1/28/21 5:04 AM, Kanchan Joshi wrote: > > And for some ioctls, driver may still need to use task-work to update > > the user-space pointers (embedded in uring/ioctl cmd) during > > completion. > > For this use case, we should ensure that just io_uring handles this > part. It's already got everything setup for it, and I'd rather avoid > having drivers touch any of those parts. Could be done by having an > io_uring helper ala: > > io_uring_cmd_complete_in_task(cmd, handler); > > which takes care of the nitty gritty details. Ah right. With that, I can do away with exporting task-work. NVMe completion can invoke (depending on ioctl) this uring-helper with a handler that does the ioctl-specific update in task context. -- Kanchan