Skip to content

enable_uart=1 does not cause corresponding GPIOs to be busy #7020

@webmeister

Description

@webmeister

Describe the bug

I set enable_uart=1 in /boot/config.txt to enable access to a serial console on GPIO14+15. This works perfectly fine. However, the kernel sees those GPIOs still as "unused", even though they are actively used by the UART:

$ lsgpio -n gpiochip0
GPIO chip: gpiochip0, "pinctrl-bcm2711", 58 GPIO lines
[...]
        line 14: "GPIO14" unused [input]
        line 15: "GPIO15" unused [input]

This means that I can execute something like gpioset GPIO15=low and break UART functionality. I would rather expect gpioset to complain gpioset: unable to request lines on chip '/dev/gpiochip0': Device or resource busy as it does for other GPIOs when they are already in use (e.g. when using dtoverlay=gpio-shutdown,gpio_pin=26 and trying to execute gpioset GPIO26=low).

Steps to reproduce the behaviour

  1. Set enable_uart=1 in /boot/config.txt and reboot
  2. Run gpioset GPIO15=low
  3. Observe that the command succeeds unexpectedly and UART functionality is now broken

Device (s)

Raspberry Pi 3 Mod. B+, Raspberry Pi 4 Mod. B

System

Arch Linux ARM

$ vcgencmd version
May 14 2025 12:23:36
Copyright (c) 2012 Broadcom
version 17084b403fb60475b8ee2641c26049a7d54bf153 (clean) (release) (start)
$ uname -a
Linux rpi 6.12.43-1-rpi #1 SMP PREEMPT Tue Aug 26 13:22:07 MDT 2025 aarch64 GNU/Linux

Logs

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions