Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp4452883rwr; Sun, 30 Apr 2023 07:39:34 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7P7houduXlN4vsUVXAS31RVxLmgNlW9mkvraE9VeHrhJMQH5h3JoWJAzCiiJuDSDk5lv3b X-Received: by 2002:a05:6a20:8e19:b0:f2:fe5a:d471 with SMTP id y25-20020a056a208e1900b000f2fe5ad471mr11703788pzj.5.1682865574029; Sun, 30 Apr 2023 07:39:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682865574; cv=none; d=google.com; s=arc-20160816; b=tqq1OZmtaPKCwEcocLMaYV95sNB1ZLPBHbMWyhVkM4BxUJSNYJPtKjgYLI8jWKHEUm zOBAhDYJPE58wTWxG/RZlJUKaN6dLRO51ojGLdXXl54O7haYJyfuLNxGEZMNePGZoOcr BaTEoXlyBvoevaejD2ManmgAQAf8GxoKJxpQ0i42vP2H2jJy1uwXLq2S9Pnx3gyJ9sCV pMKUjkLrNuweJQOc/bmqpp2267AaSOxPn93uJDpICBwDZ/ZNbVc5G2xyn5FyVmqGV3q7 lhHov0FCkc13zjSprRoJjHLOi0X/sYesTSkzs/B0NOFX3m44AdEFuf8pkHL2pFhrg8Qn 2/Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=pjAcu4IcSQRiDt8dUv43LgZPu6LvertkuJ0LwpP92lY=; b=HjFBTWsJ2tDnYZP8OtNnyVyVVHr4niH7rSlcw5H6qV0qdCi0BDncqL0yVBfys68nMO 2BrrQ5N8hwY8fDeXsip3kPA4dhsysVj29N+dfB1/rQPMU/Dc/79WkltD9PkxckA1z2Tj AHx62QuO3nHUQt3f1GsBOQm+v+ORQSdzDH51qu4etSQWdDgHo2AeKyv8ouG1IKD8LW7A UkYfQ44VoJbI/WFF108s4bVptwjI6MNimEIZmys99hAsa9fHI1wnxYat8rhfygnVp2Jw BVqgbw6cGSdX8Lp7htHAz44+KSTJ/tJ1vNse23tM4tVI9f/Gn99pvgjHukOc1fIUhC1a 6ePA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c1-20020a056a00008100b0063b1bfa94dasi25746300pfj.323.2023.04.30.07.39.20; Sun, 30 Apr 2023 07:39:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229663AbjD3OiE (ORCPT + 99 others); Sun, 30 Apr 2023 10:38:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47644 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229452AbjD3OiC (ORCPT ); Sun, 30 Apr 2023 10:38:02 -0400 Received: from mail-wm1-f48.google.com (mail-wm1-f48.google.com [209.85.128.48]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F1996101; Sun, 30 Apr 2023 07:38:01 -0700 (PDT) Received: by mail-wm1-f48.google.com with SMTP id 5b1f17b1804b1-3f1738d0d4cso8668525e9.1; Sun, 30 Apr 2023 07:38:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682865480; x=1685457480; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=pjAcu4IcSQRiDt8dUv43LgZPu6LvertkuJ0LwpP92lY=; b=AwXeeTCvJBDGZrjiIWMTewLQ4Yw6eDrYUWQdc+8D4Y0Zs0pFLk5pZ9KqT2bwNn1vbB 0hLxi+2mKxFbi7bgm+HiNptCqecFwVSJFkLDKoDaUxImXjo/HjEiSK15tPgaskf85FL9 s/8KRzBoJjaM9mkLQ+rW1k1lIj/jOAPdo9IJ3ORuFGlC2jwnadh9wFM3MmFMERPlNFW3 6dAeXzhWDjQIbSWNeEMNprJnYYwiF2F6O9qBsaLhqzhKEBTGAATOrsviacSOC0GEb3cw tDU9AzPyPbxlB5sh7gV1DLU+jzSPVg0Ldei7svgmYQ7LUWJUO2RAjewgQUyH/zpVt1Se 0nag== X-Gm-Message-State: AC+VfDzDafdcBe5M1LmwXg8cBgVU5+dYUyNCvE5YWXykfliFESTidgpF FvUY+qYcgw1xYulqVbVbqnc= X-Received: by 2002:a05:600c:b45:b0:3f2:5922:d955 with SMTP id k5-20020a05600c0b4500b003f25922d955mr9291474wmr.8.1682865480436; Sun, 30 Apr 2023 07:38:00 -0700 (PDT) Received: from gmail.com (fwdproxy-cln-013.fbsv.net. [2a03:2880:31ff:d::face:b00c]) by smtp.gmail.com with ESMTPSA id j32-20020a05600c1c2000b003f173987ec2sm33667582wms.22.2023.04.30.07.37.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 30 Apr 2023 07:37:59 -0700 (PDT) Date: Sun, 30 Apr 2023 07:37:58 -0700 From: Breno Leitao To: Christoph Hellwig Cc: io-uring@vger.kernel.org, linux-nvme@lists.infradead.org, asml.silence@gmail.com, axboe@kernel.dk, leit@fb.com, linux-kernel@vger.kernel.org, linux-block@vger.kernel.org, sagi@grimberg.me, kbusch@kernel.org, ming.lei@redhat.com Subject: Re: [PATCH 1/2] io_uring: Pass whole sqe to commands Message-ID: References: <20230419102930.2979231-1-leitao@debian.org> <20230419102930.2979231-2-leitao@debian.org> <20230420045712.GA4239@lst.de> <20230420123139.GA32030@lst.de> <20230420124615.GA733@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230420124615.GA733@lst.de> X-Spam-Status: No, score=1.7 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,FSL_HELO_FAKE, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 20, 2023 at 02:46:15PM +0200, Christoph Hellwig wrote: > On Thu, Apr 20, 2023 at 05:38:02AM -0700, Breno Leitao wrote: > > Since we are not coping the payload anymore, this is not necessary. Now > > we are copying 64 bytes for the single SQE or 128 bytes for double SQE. > > > > Do you prefer I create a helper that returns the SQE size, instead of > > doing the left shift? > > I think a helper would be nice. And adding another sizeof(sqe) seems > more self documenting then the shift, but if you really prefer the > shift at least write a good comment explaining it. Agree, this is a good idea. I've fixed it in the nvme code by creating a function helper. The same problem happen on the ublkd_drv, and I've also fixed it there in a new patch. https://lkml.org/lkml/2023/4/30/94 Thanks for the review.