Re: [PATCH v2 1/3] usb: typec: bm92txx: add Rohm BM92TXX support
From: Bartosz Golaszewski
Date: Mon May 11 2026 - 07:10:34 EST
On Sun, May 10, 2026 at 8:32 PM Alexandre Hamamdjian via B4 Relay
<devnull+azkali.limited.gmail.com@xxxxxxxxxx> wrote:
>
> From: CTCaer <ctcaer@xxxxxxxxx>
>
> Add a driver for the Rohm Semiconductor BM92TXX family of USB Type-C
> and Power Delivery controllers. The IC integrates an MCU that runs the
> PD state machine; the host configures it and observes status over I2C
> and reacts to a level-triggered ALERT interrupt.
>
> The driver exposes the controller through extcon and a USB role switch,
> manages the VBUS sink, optional VBUS source and battery-charger
> regulators along with the VCONN-enable GPIO, and applies per-PDO
> charging current limits (5 V, 9 V, 12 V, 15 V) sourced from device
> tree. DisplayPort alternate-mode handling and dock LED behaviour are
> configurable through rohm,* properties so the same driver can serve
> boards that wire the part up differently. A debugfs interface under
> bm92txx/ is provided for register dumps and low-level command access
> when CONFIG_DEBUG_FS is enabled.
>
> Signed-off-by: CTCaer <ctcaer@xxxxxxxxx>
> Signed-off-by: Alexandre Hamamdjian <azkali.limited@xxxxxxxxx>
> ---
...
> diff --git a/drivers/usb/typec/bm92txx.c b/drivers/usb/typec/bm92txx.c
> new file mode 100644
> index 000000000000..39e20a4394c1
> --- /dev/null
> +++ b/drivers/usb/typec/bm92txx.c
> @@ -0,0 +1,2634 @@
> +// SPDX-License-Identifier: GPL-2.0-only
> +
> +/*
> + * Driver for Rohm BM92TXX USB Type-C and Power Delivery controller
> + *
> + * Copyright (c) 2020-2023 CTCaer <ctcaer@xxxxxxxxx>
> + *
> + * Authors:
> + * CTCaer <ctcaer@xxxxxxxxx>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + */
> +
> +#include <linux/module.h>
> +#include <linux/i2c.h>
> +#include <linux/gpio.h>
Sorry but I have to NAK this. This is a legacy header (as per it's
documentation) and must no longer be used in new code. Please refer to
the kernel docs and use the APIs from linux/gpio/consumer.h instead.
Bartosz