Re: [PATCH] regulator: renesas-usb-vbus-regulator: Fix module autoloading
From: Nhat Tran
Date: Mon Nov 16 2026 - 04:18:52 EST
Hi Biju,
On Mon, Nov 16, 2026 at 09:00 UTC, Biju Das wrote:
> A patch is already mainlined [1] with these changes as part of RZ/G3L
> regulator support.
Sorry, I missed that series. Please drop this patch.
On Mon, Nov 16, 2026 at 09:06 UTC, Biju Das wrote:
>> +static const struct platform_device_id rzg2l_usb_vbus_regulator_ids[] = {
>> + { .name = "rzg2l-usb-vbus-regulator" },
>
> Have you tested this patch properly?
>
> I had an issue in probing the device related to id_table match due to
> string length restriction in [2]
You are right. "rzg2l-usb-vbus-regulator" is 24 characters long, so it
does not fit in name[PLATFORM_NAME_SIZE] together with its terminating
NUL.
I tested it on an RZ/G2L SMARC EVK with the driver built as a module:
the module was loaded automatically and USB0 probed. But that only
worked by luck: driver_data is 0 and directly follows name[], so
strcmp() stops there. With a non-zero driver_data, as in your RZ/G3L
patch, the match fails. Renaming the device, as you did, is the right
fix.
Thanks for the review,
Nhat