Files
Chirag Shilwant 9aa2f15556 linux: remove sudo modprobe fallback from metal_linux_probe_driver
A library must not attempt to escalate its own privileges.
The sudo modprobe fallback was incorrect for three reasons:

  1. A library silently attempting privilege escalation on behalf of its
     caller is unexpected behavior and a security concern.

  2. If modprobe failed due to missing CAP_SYS_MODULE, sudo will also
     fail unless passwordless sudo is explicitly configured in sudoers
     making the fallback redundant in practice.

  3. On embedded and production Linux systems, sudo is often not
     installed, causing system() to fail silently or hang waiting for
     a password prompt.

If the driver is not found after modprobe, return -ENODEV and let the
caller handle it.

Fixes: commit 7bda1db4a9 ("Initial commit")

Signed-off-by: Chirag Shilwant <c-shilwant@ti.com>
2026-09-21 09:59:19 +02:00
..
2026-04-28 17:27:01 +02:00
2026-04-28 17:27:01 +02:00
2026-04-28 17:27:01 +02:00
2026-04-28 17:27:01 +02:00