From patchwork Thu Dec 7 21:21:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Howells X-Patchwork-Id: 13484064 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0EC1DC4167B for ; Thu, 7 Dec 2023 21:24:48 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 9C9236B00CC; Thu, 7 Dec 2023 16:24:47 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 9793E6B00CD; Thu, 7 Dec 2023 16:24:47 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 7F1786B00CE; Thu, 7 Dec 2023 16:24:47 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 554556B00CC for ; Thu, 7 Dec 2023 16:24:47 -0500 (EST) Received: from smtpin30.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 162AC120276 for ; Thu, 7 Dec 2023 21:24:47 +0000 (UTC) X-FDA: 81541301814.30.70D412B Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf23.hostedemail.com (Postfix) with ESMTP id 621AD140004 for ; Thu, 7 Dec 2023 21:24:45 +0000 (UTC) Authentication-Results: imf23.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=RNc5B3RG; spf=pass (imf23.hostedemail.com: domain of dhowells@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1701984285; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=OEFFzyp4bFEviL1/y5nIotsUE5u5dYojlggq/vI/x7I=; b=d60fXGlSQJ9OcAjQMd2qpLEESzNSwZVcWX6gCKyu70j7OlbEk4V4o6o4UhjKwj/sdAfF4J YVa9/iNXmYu6ZE5LhWMlFQJ8SSAiDpgJ1ivD4g0PteY9uXO8O1C39tkNR+UiFqxRVO+Jz7 Jkoy1w+rft+XFtDd9mVhJZwSlL4SALo= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=RNc5B3RG; spf=pass (imf23.hostedemail.com: domain of dhowells@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=dhowells@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1701984285; a=rsa-sha256; cv=none; b=g1bzOKUY8S9kYlaOlg2d2AWuxJjVfRB1NvICsbDN6eLoyQgbQysoZyfZE/AMiS7Nwl3WYl VrN0Ci8YJuR2fliRqxWm0E7Cahp7h2kOOYm5bfal6NipD+vh29t8tf5k8JncFQbQ33wQTo OFl81sZwnXzZ3KTDQRSniq5kJDKFM+k= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1701984284; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=OEFFzyp4bFEviL1/y5nIotsUE5u5dYojlggq/vI/x7I=; b=RNc5B3RGDt2Y/vaMnCYjdWDpOIm3PbF4u51nIofv+RNClK4GAC1ZooO5+Hxmf54k9pZD6a xlEgnuOMk6LgxQkvh8QwJ5hLcHyiY5iI8aOg+pwiLlZBdBCpzAT3gQiIpIFGEwGxIcI7nj LT2sAsLewmD4c1x+CbEblF8BkYe1ZaA= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-389-G-WYgG5wPfyVHGlg3gwHxQ-1; Thu, 07 Dec 2023 16:24:40 -0500 X-MC-Unique: G-WYgG5wPfyVHGlg3gwHxQ-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 762F2185A784; Thu, 7 Dec 2023 21:24:39 +0000 (UTC) Received: from warthog.procyon.org.com (unknown [10.42.28.161]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6B7058174; Thu, 7 Dec 2023 21:24:36 +0000 (UTC) From: David Howells To: Jeff Layton , Steve French Cc: David Howells , Matthew Wilcox , Marc Dionne , Paulo Alcantara , Shyam Prasad N , Tom Talpey , Dominique Martinet , Eric Van Hensbergen , Ilya Dryomov , Christian Brauner , linux-cachefs@redhat.com, linux-afs@lists.infradead.org, linux-cifs@vger.kernel.org, linux-nfs@vger.kernel.org, ceph-devel@vger.kernel.org, v9fs@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Steve French , Shyam Prasad N , Rohith Surabattula Subject: [PATCH v3 43/59] netfs: Rearrange netfs_io_subrequest to put request pointer first Date: Thu, 7 Dec 2023 21:21:50 +0000 Message-ID: <20231207212206.1379128-44-dhowells@redhat.com> In-Reply-To: <20231207212206.1379128-1-dhowells@redhat.com> References: <20231207212206.1379128-1-dhowells@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.5 X-Rspamd-Queue-Id: 621AD140004 X-Rspam-User: X-Stat-Signature: 7iabrwhrs316gnyxzei9rceydc3151u3 X-Rspamd-Server: rspam01 X-HE-Tag: 1701984285-56111 X-HE-Meta: U2FsdGVkX19pG9dnTcQxlx2eYNMyLS74G1/2jb52i+bN86LzQugnrGR7eF+m3sb3G2rbvG1t8QY71qvF9b7XRRvr1h+2oRCCd9Y58caYprTn9V98nxmlZ346kg34835HemnyJKbjWXavhLFWM5JeTiGBkLq2r2gubax+thOEzxsUljMz3pJT4dUzcARGG5X8Xt9Hb7u2sQanbOGli5MZ1SMUGJolJKKc+juR6QW/kpHd0l2EMjGtcgQLsmId+wIXAxxqMB6Cq0sBBN8kWeP+1E9edMsQu2AEQZmwiSfraHbbqI0q/gLkwKYB4cIu+AUzEX6g0jCp2VMF7RT9jy5t1ELYNue0HxYrxpx1Pw5t7sK7jH1dFZ5UFlAri3lrsuTqNAxRO/3/CFpEUa1haQ1Nz7fgURGhgDg/Idv47j9is5fnVovdqqct2uqkBpP3zgVuQ7xny5Atuqm4ipTPTBTiyYRxr0FL/5rvSILvmNtM2Tjvkk3Kor/g37dVmy95UeRk62W1pAa66fNLELILdoz5OPxHTCnPIMwU+dNUGfafgOjREOGYEHZx05xWZXyTC6QwiHpEcZA5UUmKS/PUbgXE9mLNEL1tvFBxoP/FV0QoHhdLF6EiCt3PZIMOW/8gL3fzkrwNmnYkm6SLHNiLC9l3RwpEacdhy6haUj8iaaMaKjavb7fYZFcpsA0qP00hUTP8aNnG+j0qetWxfbIxQr4GNfs1wvLee8hrERH36nbks14RPRIpd+KfE+cOPCySDsGqDUAN5Lt6fL41xwjpAxchYmYJk0/ZttsLN6WoiE6V66jai5IKoMW7aG06Kro2EVhwGezq5KhOJ9/AmzJxjCyb61EUZ2yAiNHGLCrGorcPrwNUs3M0FM8ZkIM5j56hYNN108sauWOxMEMcJNdUT6O6lAIEvIhQ7bsl50qMX6Ap2jZcopHeel13/41z1WyzzjcdBk1WbhmI3YV10HRjDpD e2xfmolV g167Xo23M2JbVnRK+FAhcRDezxn7J4eTwddjwUyOD5AlXxzNUlZA/ckZRwpBkMRIqTNcq7cd+wPczqw2ZQodyGkBwh2louayEJYm2tsIQz5nhTIcNcAZvN+Cte5+K5KbqVvlCcT6jhBrvh4UnExYJ+p8yPmkCDgOkTP+B6Ui/tI16ypBykuhtcFC0n+SBgLdEjvPHnt6/0LXGLrBJYj6hQMoQyAEaJYF9tcYDMkod6At2hGKNa3zmTpOEOMYI5DRALxqvSB1ihX1bUAVHE5BoeQSGGEeD+7Q8j9hKs50Ox2NMChM1ET/omuFrmQIAuGEuEdZ1fGZT7doez0+9MMX8i21rpw8/SSCBuQSNuiXN/yVWf62ttv7YfO2yyzXbyvlkuFnsMqFyl0l+LuivHx9uZyPRSuqCfUyG4ZrmhL9ibXqT9XdiBpGfnsjjta+rQ/PBYUfGZnaUB0S6nEU55DD5vOk7DG0HzQ+B9cTOeAPsdQ4EFxkJyK+aaPh9Hg== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Rearrange the netfs_io_subrequest struct to put the netfs_io_request pointer (rreq) first. This then allows netfs_io_subrequest to be put in a union with a pointer to a wrapper around netfs_io_request for cifs. Signed-off-by: David Howells cc: Steve French cc: Shyam Prasad N cc: Rohith Surabattula cc: Jeff Layton cc: linux-cifs@vger.kernel.org cc: linux-cachefs@redhat.com cc: linux-fsdevel@vger.kernel.org cc: linux-mm@kvack.org --- include/linux/netfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/netfs.h b/include/linux/netfs.h index e44508850ba2..08040da65336 100644 --- a/include/linux/netfs.h +++ b/include/linux/netfs.h @@ -207,8 +207,8 @@ struct netfs_cache_resources { * the pages it points to can be relied on to exist for the duration. */ struct netfs_io_subrequest { - struct work_struct work; struct netfs_io_request *rreq; /* Supervising I/O request */ + struct work_struct work; struct list_head rreq_link; /* Link in rreq->subrequests */ struct iov_iter io_iter; /* Iterator for this subrequest */ loff_t start; /* Where to start the I/O */