Article View: linux.kernel.netdev
Article #13028[PATCH v2 00/19] driver core: Authorize device trust before driver binding
From: Leon Romanovsky
Date: Mon, 09 Nov 2026 07:33
Date: Mon, 09 Nov 2026 07:33
96 lines
13093 bytes
13093 bytes
Device trust policies need to precede driver setup, including manual
attachment, so userspace can authorize devices before they operate.
Introduce disabled, adversary and full policies with boot-time selection,
sysfs authorization and lifetime commitment. Apply them to PCI and USB.
Keep serio and generic PHY attachment under their existing subsystem
locks through an API restricted to device_trust.default=full. Freeze
runtime policy changes in that mode and require per-device boot entries
to exclude driver rules from manual attachment.
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
Changes in v2:
- Replace the serio and PHY attachment conversions with
device_driver_attach_full(), restricted to device_trust.default=full.
- Add USB authorization on top of device trust: export
device_trust_set_policy() and convert the USB authorized attributes.
- Documentation and commit messages fixes
- Small USB patches rewrote and split
- Link to v1: https://patch.msgid.link/20261105-device-trust-core-v1-0-1e536825b4eb@nvidia.com
---
Leon Romanovsky (19):
Input: gameport - attach manual drivers through the driver core
wifi: mac80211_hwsim: lock device for manual driver binding
USB: Lock registered interfaces during manual driver binding
USB: Release interface claims refused during registration
PNP: Attach card devices through the driver core
cdx: Propagate DMA configuration errors
driver core: Report deferred probes through sysfs drivers_probe
driver core: Add a compatibility API for manual driver attachment
Input: serio - use the compatibility driver attachment API
net: phy: Use the compatibility driver attachment API
driver core: Introduce a generic device trust level
driver core: Expose device trust authorization interfaces
driver core: Accept device trust policy on the kernel command line
driver core: Accept device trust policy by driver name
driver core: Expose committed device trust level
driver core: Cover trust authorization and binding with KUnit
driver core: Document trust admission and initrd authorization
PCI: Replace untrusted state with device trust
USB: Authorize devices and interfaces through device trust
Documentation/ABI/testing/sysfs-bus-drivers-probe | 13 +
Documentation/ABI/testing/sysfs-bus-usb | 11 +
Documentation/ABI/testing/sysfs-devices-trust | 33 +
Documentation/admin-guide/kernel-parameters.txt | 29 +
.../driver-api/driver-model/device-trust.rst | 289 ++++
Documentation/driver-api/driver-model/index.rst | 1 +
Documentation/usb/authorization.rst | 20 +
MAINTAINERS | 2 +
drivers/base/Makefile | 2 +-
drivers/base/base.h | 31 +
drivers/base/bus.c | 9 +-
drivers/base/core.c | 18 +-
drivers/base/dd.c | 108 +-
drivers/base/test/Makefile | 1 +
drivers/base/test/device-trust-test.c | 1720 ++++++++++++++++++++
drivers/base/trust.c | 406 +++++
drivers/bluetooth/btusb_main.c | 42 +-
drivers/cdx/cdx.c | 2 +-
drivers/input/gameport/gameport.c | 21 +-
drivers/input/serio/serio.c | 24 +-
drivers/iommu/amd/iommu.c | 3 +-
drivers/iommu/dma-iommu.c | 14 +-
drivers/iommu/intel/iommu.c | 17 +-
drivers/iommu/iommu.c | 17 +-
drivers/net/phy/phy_device.c | 29 +-
drivers/net/wireless/virtual/mac80211_hwsim_main.c | 2 +
drivers/pci/ats.c | 4 +-
drivers/pci/pci.c | 5 +-
drivers/pci/probe.c | 23 +-
drivers/pci/quirks.c | 7 +-
drivers/pnp/card.c | 12 +-
drivers/usb/core/driver.c | 29 +-
drivers/usb/core/generic.c | 2 +-
drivers/usb/core/hub.c | 17 +-
drivers/usb/core/message.c | 34 +-
drivers/usb/core/sysfs.c | 9 +-
drivers/usb/core/trace.h | 2 +-
drivers/usb/core/usb.c | 5 +-
drivers/usb/core/usb.h | 4 +-
include/linux/device.h | 20 +
include/linux/device/bus.h | 10 +
include/linux/device/trust.h | 47 +
include/linux/pci.h | 30 +-
include/linux/usb.h | 29 +-
44 files changed, 2988 insertions(+), 165 deletions(-)
---
base-commit: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4
change-id: 20260915-device-trust-core-12934e618489
Best regards,
--
Leon Romanovsky <leonro@nvidia.com>
Technical Details
Message-ID:
<20261109-device-trust-core-v2-0-3b12d9a9f861@nvidia.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-359070-linux-kernel-netdev=dewy.ruShow Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-359070-linux-kernel-netdev=dewy.ru From: leon@kernel.org (Leon Romanovsky) Newsgroups: linux.kernel.netdev Subject: [PATCH v2 00/19] driver core: Authorize device trust before driver binding Date: Mon, 9 Nov 2026 09:33:30 +0200 Organization: Usenet Network Message-ID: <20261109-device-trust-core-v2-0-3b12d9a9f861@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Injection-Info: usenet.network; logging-data="298321"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:QCasiponICUlLAlzlmRbA6apf4Y= sha256:xSjrKmG87v48yVr3k6nYxPErb0pBba1sYbh2VQCNTsI= sha1:yV2gJbNTo6F3cvZuIMXtnsdgnEQ= sha256:TuWtDmQ9xh1FBfTlnAkp8hlbTmsvxF5p9Q01L9SndpM= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 4585C113702; Mon, 9 Nov 2026 10:36:01 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.401 X-Spam-Status: No, score=-3.401 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GxeB2C-v0UGc; Mon, 9 Nov 2026 10:35:57 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-359070-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id AB30E1136FC; Mon, 9 Nov 2026 10:35:48 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 5145BE76B1; Mon, 9 Nov 2026 07:34:04 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794209643; b=SJ6KcCvA6l74FRshQi/cxoyVC+4e2T8CQt/hnWHQORfwuvSb5RWv09Q3l5AGrLQro0Xd nhXLu72x1dlEtQ0Q+YgvsAZNl7x+wet0GTlXFk9AuPP9WpGq+oEt597Om/aQEr/U/G62n iT9tCBNnU9kQRf3MWITDm2RxuUiknqTDHI+n4jXb3JMOLIyQ5goPZvTw/m64WkeQcSHgS JfgncqdS8l6B/W+rX6KClvc6JlekNQZrWOvsuP5fpptRTdEZanErXLkTgy30n6CYwalhG cqRPpjORsoSYO8J68U2br2iYADbbhrrua+lEHhHmWyiKgtT9oUymn1n5l8AbnvIjciQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794209643; h=X-Original-To:Received:Received:DKIM-Signature:From:To:Cc:Subject: Date:Message-ID:X-Mailer:X-Mailing-List:List-Id:List-Post:List-Help: List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Type:X-Change-ID:X-Mailer:Content-Transfer-Encoding; bh=BOudLxnS5pVPT2tPMn88TB0pOWjmfO5Gatem6QmrQcA=; b=KOGPOV9enX6J9uFSDvodsatD4b5Ty9z7s33RN2XuzUIDYxWi0TDwgJ7m9TG5qFk8A9Ms 7UuIGQbNMl5zqEMgFLNzvcH3oEB9dk+1Uv1h/OwSrzMatPXwxyLH7/NLA9yxGNb4XYt6A /arcc6yMlOmWnOkVBqehb4cKcTnuSX1SQR3QTzjJJdHyD7BkpgR8jClRpWYMxlUSei2GY U4QJHTtLnbv8octDd43TYmL1vhQIJZ0PBXupoxSADMn3SVUvbU+I/EeZnWSo2X6uyedtT o/6t4Yo+clIIsWRtgCcwkXDGBUA0PaARpcOpHj0F57aj7MYIQf/cIBsXr5ivfrmpdyQ== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=jhnY8YMd; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3A5BF606D80D; Mon, 9 Nov 2026 07:34:03 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=jhnY8YMd X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794209642; b=0VTEjbG0GvErYj+d1hmSiYOmZ184gXCWdcIrheTp7A5Vx3LOlv8dMhDENa9U8Cn+kMMb eIqTgPOCvLgZG4hejlJY7/SJZhC7qSKvsvHLQ3AC9YX7dTdBJSdp9oi7RMYqQ1MZLlWZ/ W8+pzzoUbWQjBMDtOb/oA7M0/ElSxg+vttBdXyaLSyo2C25aV1PeocN82KdMy6WEn929y LdxuqIzifxV8hlsSyn+F42QQdOLrJs/BV7ZS6uCPq63vmMaM5YaGL7WBhYYtq2gxcTeaO UBr7zYrKFCli3a1d0EWbN0hbhCcXiQu/N5jdzWMbLeBOJIgWjna3G7+L8ivjPgDtGOw== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794209642; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: MIME-Version:Content-Type:X-Change-ID:X-Mailer: Content-Transfer-Encoding; bh=BOudLxnS5pVPT2tPMn88TB0pOWjmfO5Gatem6QmrQcA=; b=ufzSu7dIOYzt2fI4maPaYxuvpsMcTADk6Ja5irIMGVlwxE8AENRl87nQdF9OfDF1CVhT UuhuHEcbh5JJaXxFGNTUhXDhoFLhg4uJJm9UfFLMW3U00MqhCeg6Y60XSn19RWtv0JedK KvX2A4Y+hJImjaYmwSmlSPZrZN2K/QkDKdN4lK1S3xQ3U99rU7dcqCEnaW6ewnC41KR7o avLWjYecy/S+f3B7IWxZMOtG4DN4g5IygAmbXcWehPzlPZ8Hh+X9Z7V2QUfU5X8HGZBSv DBqqxUE0pf8gy+SdOch8mACbDj8y5XpyXd88mC4ukPwgpN4FdM59NqkWQdZRgpo0qKg== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=jhnY8YMd; arc=none smtp.remote-ip=100.103.45.18 X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E567A606A31C; Mon, 9 Nov 2026 07:34:01 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9CCF61F0089F; Mon, 9 Nov 2026 07:34:00 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1794209641; bh=BOudLxnS5pVPT2tPMn88TB0pOWjmfO5Gatem6QmrQcA=; h=From:To:Cc:Subject:Date; b=jhnY8YMdt8nGcYBaSKvJbCx3LFW8GkUkfxG2KVQyfFPxlK/zuviCXPcVmAKOjjqep OJwKBI+522F08dkhOUewjW7oWj3wn3XyzARmmIbVOrDxcxSRGcS40fmfCdvk4AMyhp MOjTYj5wCRejfz+oJhv1T4pVMKG3/VZeEHqKSqdLPc4a5x8apUuXMnQ1aIaY9WUDP+ qG+bmJlMqJWo98xyXORHh1De0UINQ9Ms5bi+a/yYR9oTHj1OSMGHFyMwzSujrBUncm Ztid65rG+5tchiq/F8VP8JJGHkylUG+CZBGVjKcamjj2pAddBJRgS+/eioJ1UGNvSY J5UdD+59m5jow== X-Cc: linux-kernel@vger.kernel.org, driver-core@lists.linux.dev, linux-input@vger.kernel.org, netdev@vger.kernel.org, linux-wireless@vger.kernel.org, linux-usb@vger.kernel.org, linux-bluetooth@vger.kernel.org, linux-acpi@vger.kernel.org, linux-doc@vger.kernel.org, linux-pci@vger.kernel.org, iommu@lists.linux.dev, Jason Gunthorpe <jgg@ziepe.ca> X-Mailer: git-send-email 2.56.0 X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list X-Change-ID: 20260915-device-trust-core-12934e618489 X-Mailer: b4 0.15-dev-18f8f