Re: [PATCH v3 0/2] iio: proximity: add driver for ST VL53L1X ToF sensor
From: David Lechner
Date: Sat Mar 14 2026 - 10:39:12 EST
On 3/12/26 10:12 AM, Sirat wrote:
> On Thu, Mar 12, 2026 at 8:28 PM Andy Shevchenko
> <andriy.shevchenko@xxxxxxxxx> wrote:
>>
>> On Thu, Mar 12, 2026 at 04:40:35AM +0600, Siratul Islam wrote:
> ...
>>> ---
>>> Changes in v3:
>>> - Merge DT binding into existing st,vl53l0x.yaml (per Krzysztof).
>>> - Use "reset-gpios" in the binding but xshut_gpio in the driver since that's the actual pin name.
>>
>> But why is it "reset" in the bindings? If it's a power rail or enable pin, why
>> not call it as a such in the bindings? The connection on PCB level is different story.
>>
> In v2, I actually used a separate st,vl53l1x.yaml binding with
> `xshut-gpios` and a required `vdd-supply`.
> But Krzysztof pointed out that they share the same pins so the
> existing st,vl53l0x.yaml should suffice,
> using reset as the xshut pin.
>
> I think a choice has to be made here:
> 1. Either I use the st,vl53l0x.yaml binding with wrong pin name and
> optional vdd-supply to not break existing code.
> 2. Or use a separate binding st,vl53l1x.yaml with 1. correct pin name,
> and 2. require vdd-supply
We can modify the existing binding to make the supply required based
on the compatible.
allOf:
# Technically supply is required to power device, but we keep it
# optional for "st,vl53l0x" for backwards compatibility.
- if:
not:
properties:
compatible:
const: "st,vl53l0x"
then:
required:
vdd-supply
And we can add a description to reset-gpios to explain that it is actually the
XSHUT pin.
>
> Krzysztof, do you have a preference on how we should handle this?
>>
>>