From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailout2.samsung.com (mailout2.samsung.com [203.254.224.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BE54D155747 for ; Mon, 25 Nov 2024 08:08:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=203.254.224.25 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732522084; cv=none; b=ayXFq2rU6b/SXPqOk+5deqK95R9SNZHPxbIiU2wiyaie8DX063L4Q2mvl13wo0aRljuum+svp3Il88I+FBFFkUVkkPWEcm7kJpl8QzGmEzLawCEUR+zZRsrOeYba8FL2v1ncTZo2kpBCmCzsZbDJhPYgK1fZAMW1YWNPdG9bv08= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732522084; c=relaxed/simple; bh=uDUb87C52DXoVA3KvOoAoNEyjHqrw30MJR/Iqxaidaw=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:MIME-Version: Content-Type:References; b=pIWtzcuXSx3/RxVKrSq4ROpH/WV3P+hg4ZKYnaOmC0G7vc3nDhPqxGEAkJTKrLGpAVu73yC0O5eEVBohc8ZyCl0MNvkbzE0nNS7u4uUwavrmzbv7buZoMBqEJSaxHIMue+oyYLSfUrYmK0Zu2MriT9KDkPGYHkQTK5/8nJcOL74= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com; spf=pass smtp.mailfrom=samsung.com; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b=alfVbe9E; arc=none smtp.client-ip=203.254.224.25 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=samsung.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b="alfVbe9E" Received: from epcas5p1.samsung.com (unknown [182.195.41.39]) by mailout2.samsung.com (KnoxPortal) with ESMTP id 20241125080800epoutp022bbbe0f93da945c740d2c7dec08a929f~LJ6dBjR7q2099820998epoutp02W for ; Mon, 25 Nov 2024 08:08:00 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.samsung.com 20241125080800epoutp022bbbe0f93da945c740d2c7dec08a929f~LJ6dBjR7q2099820998epoutp02W DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1732522081; bh=sPCiH7C8otAPeKBQxafGfpBc//4CVwTtOappMXTNYFs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=alfVbe9Eu+Pt2aBRGR9fBRsrXeZ/aDz/UzPYFbowU5UZ4s6ExN1jGwgPeqH+M+AnQ bNW2Bb1yTHwChxqEa+0238WXmAPbZz9W2qNHGeg7mK6RhZXJsdA6994jKINwhgXBU8 UJjU/mQWJzupPg/ERIuRvDieUDvevZenbAsrwYDI= Received: from epsnrtp2.localdomain (unknown [182.195.42.163]) by epcas5p4.samsung.com (KnoxPortal) with ESMTP id 20241125080800epcas5p412d9a5f2601abac0647e31defe6716bc~LJ6cX-_xj1833918339epcas5p43; Mon, 25 Nov 2024 08:08:00 +0000 (GMT) Received: from epsmgec5p1-new.samsung.com (unknown [182.195.38.179]) by epsnrtp2.localdomain (Postfix) with ESMTP id 4XxdcG48MDz4x9Q3; Mon, 25 Nov 2024 08:07:58 +0000 (GMT) Received: from epcas5p4.samsung.com ( [182.195.41.42]) by epsmgec5p1-new.samsung.com (Symantec Messaging Gateway) with SMTP id DB.66.29212.E5034476; Mon, 25 Nov 2024 17:07:58 +0900 (KST) Received: from epsmtrp1.samsung.com (unknown [182.195.40.13]) by epcas5p4.samsung.com (KnoxPortal) with ESMTPA id 20241125071457epcas5p498c0641542bed9057e23cfff9cfc5ff0~LJMH1hjqt1933019330epcas5p4R; Mon, 25 Nov 2024 07:14:57 +0000 (GMT) Received: from epsmgms1p1new.samsung.com (unknown [182.195.42.41]) by epsmtrp1.samsung.com (KnoxPortal) with ESMTP id 20241125071457epsmtrp1eaefa71b882c902d9317ca201b91da3d~LJMH0gPoA0302303023epsmtrp1z; Mon, 25 Nov 2024 07:14:57 +0000 (GMT) X-AuditID: b6c32a50-801fa7000000721c-87-6744305e1ece Received: from epsmtip1.samsung.com ( [182.195.34.30]) by epsmgms1p1new.samsung.com (Symantec Messaging Gateway) with SMTP id 20.08.35203.0F324476; Mon, 25 Nov 2024 16:14:56 +0900 (KST) Received: from localhost.localdomain (unknown [107.99.41.245]) by epsmtip1.samsung.com (KnoxPortal) with ESMTPA id 20241125071454epsmtip149999c09d59b464adb11470b42b63af9~LJMFUPWGQ0361403614epsmtip1c; Mon, 25 Nov 2024 07:14:54 +0000 (GMT) From: Anuj Gupta To: axboe@kernel.dk, hch@lst.de, kbusch@kernel.org, martin.petersen@oracle.com, asml.silence@gmail.com, anuj1072538@gmail.com, brauner@kernel.org, jack@suse.cz, viro@zeniv.linux.org.uk Cc: io-uring@vger.kernel.org, linux-nvme@lists.infradead.org, linux-block@vger.kernel.org, gost.dev@samsung.com, linux-scsi@vger.kernel.org, vishak.g@samsung.com, linux-fsdevel@vger.kernel.org, Anuj Gupta , Kanchan Joshi Subject: [PATCH v10 04/10] fs, iov_iter: define meta io descriptor Date: Mon, 25 Nov 2024 12:36:27 +0530 Message-Id: <20241125070633.8042-5-anuj20.g@samsung.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20241125070633.8042-1-anuj20.g@samsung.com> Precedence: bulk X-Mailing-List: io-uring@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrPJsWRmVeSWpSXmKPExsWy7bCmlm6cgUu6wa818hYfv/5msWia8JfZ Ys6qbYwWq+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P7LGtb/4MWWs8X5lz4cCBR5njTossnlzdP6eCepCVd oFetW5G4s9992U+DvU/0D0bdusVvWTM1QVzUj2/GRcfrAWaBySdfLI//3WztvPudCrv6Rf32 Cf4H/F10M5ir2F5WpXBePrVav5ItISyXZ8cKCWGLBX6PeFpUg5k/R1fFaUYoSp63v/4/eNbS VzKWlXbGX9OUWIozEg21mIuKEwGNW3FuJwMAAA== X-CMS-MailID: 20241125071457epcas5p498c0641542bed9057e23cfff9cfc5ff0 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-Sendblock-Type: REQ_APPROVE CMS-TYPE: 105P DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20241125071457epcas5p498c0641542bed9057e23cfff9cfc5ff0 References: <20241125070633.8042-1-anuj20.g@samsung.com> Add flags to describe checks for integrity meta buffer. Also, introduce a new 'uio_meta' structure that upper layer can use to pass the meta/integrity information. Signed-off-by: Kanchan Joshi Signed-off-by: Anuj Gupta Reviewed-by: Christoph Hellwig --- include/linux/uio.h | 9 +++++++++ include/uapi/linux/fs.h | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/include/linux/uio.h b/include/linux/uio.h index 853f9de5aa05..8ada84e85447 100644 --- a/include/linux/uio.h +++ b/include/linux/uio.h @@ -82,6 +82,15 @@ struct iov_iter { }; }; +typedef __u16 uio_meta_flags_t; + +struct uio_meta { + uio_meta_flags_t flags; + u16 app_tag; + u64 seed; + struct iov_iter iter; +}; + static inline const struct iovec *iter_iov(const struct iov_iter *iter) { if (iter->iter_type == ITER_UBUF) diff --git a/include/uapi/linux/fs.h b/include/uapi/linux/fs.h index 753971770733..9070ef19f0a3 100644 --- a/include/uapi/linux/fs.h +++ b/include/uapi/linux/fs.h @@ -40,6 +40,15 @@ #define BLOCK_SIZE_BITS 10 #define BLOCK_SIZE (1<