The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: "Arnd Bergmann" <arnd@arndb.de>
To: "Harsh Jain" <h.jain@amd.com>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Michal Simek" <michal.simek@amd.com>,
	linux-kernel@vger.kernel.org, sarat.chand.savitala@amd.com,
	nkowlaku@amd.com
Subject: Re: [PATCH 2/2] misc: Add Xilinx PUF driver
Date: Tue, 07 Jul 2026 12:04:07 +0200	[thread overview]
Message-ID: <d27d7d9e-2dca-4ae5-8d7c-070425f273f3@app.fastmail.com> (raw)
In-Reply-To: <20260707095620.2795456-3-h.jain@amd.com>

On Tue, Jul 7, 2026, at 11:56, Harsh Jain wrote:
> Versal devices contain a physically unclonable function (PUF) block
> that derives device-unique secrets from intrinsic silicon
> characteristics. The PUF generates a Key Encryption Key (KEK) used
> internally by the AES engine for secure key storage, which is not
> externally accessible. In addition, the PUF provides a readable
> device-unique identifier derived from the same entropy source.
>
> Add a misc character driver to support PUF registration and regeneration.
> Registration generates a unique secret and outputs binary helper data
> that can later be used during regeneration to reproduce the same
> secrets.
>
> The driver also implements PUF_CLEAR_ID and PUF_CLEAR_KEY ioctls to clear
> the PUF ID and PUF-derived AES key via firmware. They are disabled by default
> unless puf_clear is set.
>
> Signed-off-by: Harsh Jain <h.jain@amd.com>

Hi Harsh,

This description sounds like it should be integrated into the
existing crypto infrastructure of the kernel. I'm not sure
what the exact feature set in your hardware is like, but
please work with the crypto and keyctl maintainers to either
use that infrastructure, or extend it to your requirements
instead of adding a custom ioctl interface.

My guess would be that you can have a driver similar
to drivers/platform/cznic/turris-omnia-mcu-keyctl.c
for managing private keys in the hardware and managing
it through the keyctl(2) infrastructure. Have you looked
at this already?

      Arnd

  reply	other threads:[~2026-07-07 10:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-07  9:56 [PATCH 0/2] Add Versal PUF support Harsh Jain
2026-07-07  9:56 ` [PATCH 1/2] firmware: xilinx: Add Versal PUF PM API support Harsh Jain
2026-07-07  9:56 ` [PATCH 2/2] misc: Add Xilinx PUF driver Harsh Jain
2026-07-07 10:04   ` Arnd Bergmann [this message]
2026-07-07 10:41     ` Jain, Harsh (AECG-SSW)
2026-07-07 10:12   ` Greg KH
2026-07-07 10:52     ` Jain, Harsh (AECG-SSW)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d27d7d9e-2dca-4ae5-8d7c-070425f273f3@app.fastmail.com \
    --to=arnd@arndb.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=h.jain@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michal.simek@amd.com \
    --cc=nkowlaku@amd.com \
    --cc=sarat.chand.savitala@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox