From patchwork Fri Nov 22 18:04:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shiju Jose X-Patchwork-Id: 13883506 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 968A2E69185 for ; Fri, 22 Nov 2024 18:05:04 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 37B9E6B009E; Fri, 22 Nov 2024 13:05:00 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 239856B00A2; Fri, 22 Nov 2024 13:05:00 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EC19B6B009E; Fri, 22 Nov 2024 13:04:59 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id B5D716B009F for ; Fri, 22 Nov 2024 13:04:59 -0500 (EST) Received: from smtpin07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 689B681740 for ; Fri, 22 Nov 2024 18:04:59 +0000 (UTC) X-FDA: 82814504304.07.BCE37DA Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) by imf18.hostedemail.com (Postfix) with ESMTP id 357371C0009 for ; Fri, 22 Nov 2024 18:04:32 +0000 (UTC) Authentication-Results: imf18.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf18.hostedemail.com: domain of shiju.jose@huawei.com designates 185.176.79.56 as permitted sender) smtp.mailfrom=shiju.jose@huawei.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1732298629; a=rsa-sha256; cv=none; b=2ACybaKEjFTALMzKjibjBkn/vhstbEmMxwzP206PO6AMwHX/p6Gtm/FssI3kFEiTVeqMxD Be/kqQ2dsu4w4T543WwoCwCsOi2vFwhRT4qZJAVrnRxN1gY0RDluoxOAcPzL0b1ZfEvsHC WrdLdgL6dyqtgv1ISSMHfSlusM91ExY= ARC-Authentication-Results: i=1; imf18.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf18.hostedemail.com: domain of shiju.jose@huawei.com designates 185.176.79.56 as permitted sender) smtp.mailfrom=shiju.jose@huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1732298629; 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-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=v2Q8+qDCkZvDQR7CiimKeMduRYRg/dEfThkNHEetMVo=; b=NUUl94WwFY9gYFiBK/0PMxcqe0+EPzoiwqRoS7twZzXS4dZ0DEwpbkeB3yXsMR1oA7MYVd lLKl1fjEwlm81HjoEJkbEFM+mtZVz/lj6OOlU2pkrzoSTTljDDWaBeYJ6B4en6+W2KfFOg h0it5vb4MdBzHV+4lRgLyQXskV8AxJ0= Received: from mail.maildlp.com (unknown [172.18.186.216]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4Xw2wD3yMMz6K6CG; Sat, 23 Nov 2024 02:01:16 +0800 (CST) Received: from frapeml500007.china.huawei.com (unknown [7.182.85.172]) by mail.maildlp.com (Postfix) with ESMTPS id F279D140C72; Sat, 23 Nov 2024 02:04:54 +0800 (CST) Received: from P_UKIT01-A7bmah.china.huawei.com (10.126.171.16) by frapeml500007.china.huawei.com (7.182.85.172) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Fri, 22 Nov 2024 19:04:52 +0100 From: To: , , , , CC: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: [PATCH v17 07/18] cxl: Add Get Feature command support for user submission Date: Fri, 22 Nov 2024 18:04:04 +0000 Message-ID: <20241122180416.1932-8-shiju.jose@huawei.com> X-Mailer: git-send-email 2.43.0.windows.1 In-Reply-To: <20241122180416.1932-1-shiju.jose@huawei.com> References: <20241122180416.1932-1-shiju.jose@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.126.171.16] X-ClientProxiedBy: lhrpeml500002.china.huawei.com (7.191.160.78) To frapeml500007.china.huawei.com (7.182.85.172) X-Rspam-User: X-Rspamd-Queue-Id: 357371C0009 X-Rspamd-Server: rspam11 X-Stat-Signature: 7hxkspbcxxe9hfsp3ixeoem8fsrox96k X-HE-Tag: 1732298672-768510 X-HE-Meta: U2FsdGVkX19dUZCgp1VV/sh/+kfmIf0NuubG5JhWld45sNg0IX1EpmrFKguEUgj4EpG432bZyfVu4pvfNJV4w0Ml/NubmozXJNYVIp2tk3hocMoB/3FrXhsMe0RCGW9Zvbeg+w2zA23Hno66VLEnhbUjyJCNR5B+IUr5iB+3nNFfLDddChXtUcw1jhWwO08du+xXZO2YSiW0wxW4OtV0/pxNW0nAL4otv/vp+YFdqfe22Lcqjs1jVhC0kvhB0w4Bg3fPjvZrPC7MsUunckNXs08VFoHi3nLAuZy503mSNw5vxzSOfBNQhHgJ5ZUK+8VcFvPkczraFHdEmqHsUWjflzZqz5pioxZiR6o+ASvhpHUjTsjKza34LlkhmcVLUPRZn+kfmaafwCkUG+o2Jn9xgt2ofH8CZqVzTW2Y1X0G2e8COxrXJbZ8Ay3jzNuCbEN2LLmLiO5fkCEubxN0Ds4l4jSYVy+QAVE4tenD+EB/vYfLjjJI0A3NnxCZ8o1Rbi1mWe8vJd0C1Ns/9UbROuy4VaDvCgztsu4+0EuEtKGyHVB9dHwo10gq+VIwImh1vILIZa5Oh7Lg9KdhUCGy8O/inigOmx4vopOxi0MLLiszt11kDSxUON0ZmwICBw2vAvVXSP65Ym+cY3WknZpi1jvot1EcFc0HCKAlBzhV2sAmshFT79+W6kIxWS4q4s2A7j/74Xg0uTu/0/Qw6jx2D/BOHVKC2G/Fw0GWMWF0du6639hzPLOLKxtCNiUuHPLWnHOIjkEpoz6AI5rn5Lj+WL7H+cL8eM8U3v/WM560Bs/+DbEw8SNQoUWgG9tNB96qnrZ2rBox6R+M3K1uF3QeeSJGqj+TtVEJoSUVbwSU5jjoCxJvH2Gm1t5awOO3QZJh+0PGYAZXQYK//QTR7Dmk+nlmlszmCD/ws6ShutQCics+756h9iERC4S1jdDLEVIxWyd+QB2cXUztmB8G/VvAegN 0xxhp+t/ jZBDzvTKt/kuaROwUgOgXxDdSD3Ne/i0PrkR3HPcq1487kNi0Db5hlFHkxh1ZO9zQRZVSXXvot3EqTkCkj1S0mdrL1GS9MxjNtgH84f1lRAwXwQ53/4PtdbCCx2AIXFDTLeYmJh7nUsRk9I+c0ShYse9qTuezl/0eGXoJ6T2XfmHB+qk9ChmQegMv9pw5ve8tY+dvJIIVmZR4BGatxWVRsfz47MrPKCc4Gf7PISaU3DBX8F0= 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: From: Dave Jiang Add enumeration of Get Feature mailbox command for the kernel to recognize the command being passed in from user space. CXL spec r3.1 8.2.9.6.2 Get Feature (Opcode 0501h) The feature requested is identified by specific UUID. Signed-off-by: Dave Jiang Reviewed-by: Jonathan Cameron Signed-off-by: Shiju Jose --- drivers/cxl/core/mbox.c | 1 + include/uapi/linux/cxl_mem.h | 1 + 2 files changed, 2 insertions(+) diff --git a/drivers/cxl/core/mbox.c b/drivers/cxl/core/mbox.c index f96648c7a0c6..37764d3d470d 100644 --- a/drivers/cxl/core/mbox.c +++ b/drivers/cxl/core/mbox.c @@ -68,6 +68,7 @@ static struct cxl_mem_command cxl_mem_commands[CXL_MEM_COMMAND_ID_MAX] = { CXL_CMD(GET_SCAN_MEDIA_CAPS, 0x10, 0x4, 0), CXL_CMD(GET_TIMESTAMP, 0, 0x8, 0), CXL_CMD(GET_SUPPORTED_FEATURES, 0x8, CXL_VARIABLE_PAYLOAD, 0), + CXL_CMD(GET_FEATURE, 0x15, CXL_VARIABLE_PAYLOAD, 0), }; /* diff --git a/include/uapi/linux/cxl_mem.h b/include/uapi/linux/cxl_mem.h index bd2535962f70..90dcb9723997 100644 --- a/include/uapi/linux/cxl_mem.h +++ b/include/uapi/linux/cxl_mem.h @@ -51,6 +51,7 @@ ___C(CLEAR_LOG, "Clear Log"), \ ___C(GET_SUP_LOG_SUBLIST, "Get Supported Logs Sub-List"), \ ___C(GET_SUPPORTED_FEATURES, "Get Supported Features"), \ + ___C(GET_FEATURE, "Get Feature"), \ ___C(MAX, "invalid / last command") #define ___C(a, b) CXL_MEM_COMMAND_ID_##a