Received: by 2002:a05:6358:701b:b0:131:369:b2a3 with SMTP id 27csp641702rwo; Fri, 21 Jul 2023 19:15:34 -0700 (PDT) X-Google-Smtp-Source: APBJJlHVuNrefkyunJxoULJmpJ8U7ZOgzjPAHar+gDMo/ACNtrbPaKvo4mCuqjV6aTqFQ/zIphuu X-Received: by 2002:a17:902:cec2:b0:1ac:7345:f254 with SMTP id d2-20020a170902cec200b001ac7345f254mr4407432plg.33.1689992133709; Fri, 21 Jul 2023 19:15:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689992133; cv=none; d=google.com; s=arc-20160816; b=Ebi6sDr+4K78qPhTl2klYHzZj0YZ6Ez+4F0gYqJAco0CnNUSqVsCy8e6ekoPVyJ7xA Z4s0j8vBcTiPq3wFq3aIQRpzbtyiEMQeHBpjMT9oq8NGEYgK6z29cX+vq+NQK75RnfsF K/fvcKtboIg23wbfumJRgiZdflq8UFpjHc+1AzYpRY+qDODoPAVhc/zcNn8DXAGFOntU MTbV2oB2Xm/oeInYVhz/l3B0kb3DpdwFIhtyVaRb0KUkK728/PUUPTk4hXQlsb9M0FXr WRXK29CiJCQ7SFzBjrUhYHYHQgBp17OTVMlSkcxngMfKphSe5bi7/O/nGQe2KYsQqKGd V6SA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature:dkim-filter; bh=hlalfOAh675uEo4Jafv9Q9FFSSyZ0FvKFtA0M9RnTVE=; fh=YbpgU0VyRFYuiiYxVhsvvHH5D320tVR85fLuvmkwbP0=; b=adeL+ppMTYAYe4JtGeCFLE2Ot1omc7y93Gozf7DKs+vhJnrQuRAW1qRvOtm6BgOvEB KirphzNastJXillLBDGUvWen9hg+q1gbY+DQ1ydVgusoRVPfoii6g+5XHervF+4ZXgMr EueKgiiUTEe2g58P3NgGGM5qqHmCq52stuveqOEa8r4gVX6NHHliTlK5yX8ZicbHMZgh vaoGEOJ5Dh/EubjHLFKUd70n1wr+YMAlJe9IpDLS9hyRUSojcSJLiUATVHHoX/oLyAo4 Hv9aJwJH5W1E6wzvFDi7ptVVlN1ImDILY+bkPw+OfGX7Oqin3sBOD0N0LSBr4UHEnhM3 PhuQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=BmFumFmi; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ks15-20020a170903084f00b001bb0ba81053si4131053plb.50.2023.07.21.19.15.21; Fri, 21 Jul 2023 19:15:33 -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; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=BmFumFmi; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229744AbjGVBlM (ORCPT + 99 others); Fri, 21 Jul 2023 21:41:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229529AbjGVBlL (ORCPT ); Fri, 21 Jul 2023 21:41:11 -0400 Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 5C7871721; Fri, 21 Jul 2023 18:41:10 -0700 (PDT) Received: from thinkpad-p16sg1.corp.microsoft.com (unknown [167.220.83.99]) by linux.microsoft.com (Postfix) with ESMTPSA id 4D005236FE14; Fri, 21 Jul 2023 18:41:09 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 4D005236FE14 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1689990069; bh=hlalfOAh675uEo4Jafv9Q9FFSSyZ0FvKFtA0M9RnTVE=; h=From:To:Cc:Subject:Date:From; b=BmFumFmioLwIMPm7/6TdNR7bdL8o57B1Q+GCIXv+i87v/Hdrv9yYeIi8eoeAGmENi MKzHhkcbKfTNXq1QUEqQ91sNjGlXd05lB7x2qxPeHDIlwUVbJvN3eB3Y7lCI/UwTia wNPN+999xORorUK/UI9M0egaCnJ8JOB3TxLj/EKw= From: Shyam Saini To: linux-kernel@vger.kernel.org Cc: linux-mmc@vger.kernel.org, op-tee@lists.trustedfirmware.org, linux-scsi@vger.kernel.org, shyamsaini@linux.microsoft.com Subject: [RFC, PATCH 0/1] Replay Protected Memory Block (RPMB) driver Date: Fri, 21 Jul 2023 18:40:36 -0700 Message-Id: <20230722014037.42647-1-shyamsaini@linux.microsoft.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-19.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL, USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 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 Hi everyone, This is yet another attempt to come up with an RPMB API for the kernel. This patch is based on patch 1 of last submission except few minor changes. The last discussion of this was in the thread: Subject: [PATCH v2 1/4] rpmb: add Replay Protected Memory Block (RPMB) subsystem Date: Tue, 5 Apr 2022 10:37:56 +0100 [thread overview] Message-ID: <20220405093759.1126835-2-alex.bennee@linaro.org> The patch provides a simple RPMB driver. This is a RFC version and this single driver can't be used by its own. It would require further work to make use of API's provided by this driver. Changes since the last posting: drop RPMB char driver drop virtio rpmb frontend driver drop rpmb: add RPBM access tool Rename get_write_count to get_write_counter Make return type for rpmb_set_key() function explicit Alex Bennée (1): rpmb: add Replay Protected Memory Block (RPMB) driver MAINTAINERS | 7 + drivers/Kconfig | 1 + drivers/Makefile | 2 + drivers/rpmb/Kconfig | 11 ++ drivers/rpmb/Makefile | 7 + drivers/rpmb/core.c | 439 ++++++++++++++++++++++++++++++++++++++++++ include/linux/rpmb.h | 182 +++++++++++++++++ 7 files changed, 649 insertions(+) create mode 100644 drivers/rpmb/Kconfig create mode 100644 drivers/rpmb/Makefile create mode 100644 drivers/rpmb/core.c create mode 100644 include/linux/rpmb.h -- 2.34.1