Re: [PATCH RFC v4 1/6] dt-bindings: iio: add Open Sensor Fusion device
From: Jonathan Cameron
Date: Sun Jun 14 2026 - 13:56:14 EST
On Wed, 10 Jun 2026 18:33:54 +0900
Kim Jinseob <kimjinseob88@xxxxxxxxx> wrote:
> > Do you think it makes sense to permit a regulator here, so that the
> > "host" OS can power on/off the board running the osf stack?
>
> From the OSF hardware side, yes, that makes sense.
>
> The current prototype used for testing is powered independently, but an OSF
> device may also be integrated as a host-powered UART peripheral. In that case
> allowing the host to control the board supply through an optional regulator
> would be useful.
>
> Unless the IIO side prefers otherwise, I will add an optional supply property
> to the binding and matching optional regulator handling in the driver in the
> next revision.
When a device needs power, the regulator is required, not optional from a binding
point of view. If it is always one people can use a fixed regulator to represent it.
Now from a driver point of view, the regulator framework in linux provides stub regulators
for missing ones - on assumption they are always on. So we can just request the
regulators in the driver. Keep it simple for now and use a
devm_regulator_get_enable() in probe so we have power on for all the time
the driver is loaded. Can do fancy stuff later when you have a board where the
power is controlled.
>
> Jinseob
>
>
> 2026년 6월 10일 (수) 오전 1:19, Conor Dooley <conor@xxxxxxxxxx>님이 작성:
> >
> > Jonathan/IIO folks,
> >
> > On Mon, Jun 08, 2026 at 08:43:38AM +0900, Jinseob Kim wrote:
> >
> > > diff --git a/Documentation/devicetree/bindings/iio/opensensorfusion,osf.yaml b/Documentation/devicetree/bindings/iio/opensensorfusion,osf.yaml
> > > new file mode 100644
> > > index 000000000..a4049715a
> > > --- /dev/null
> > > +++ b/Documentation/devicetree/bindings/iio/opensensorfusion,osf.yaml
> > > @@ -0,0 +1,43 @@
> > > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > > +%YAML 1.2
> > > +---
> > > +$id: http://devicetree.org/schemas/iio/opensensorfusion,osf.yaml#
> > > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > > +
> > > +title: Open Sensor Fusion Sensor Aggregation Hub
> > > +
> > > +maintainers:
> > > + - Jinseob Kim <kimjinseob88@xxxxxxxxx>
> > > +
> > > +description: |
> > > + Open Sensor Fusion is a sensor aggregation hub. The hub exposes an OSF
> > > + protocol data stream over its host interface and may report capabilities and
> > > + samples for multiple sensor classes. The Linux driver discovers the actual
> > > + sensor channels from OSF capability reports instead of describing those
> > > + sensors in Device Tree.
> > > +
> > > + Open Sensor Fusion is not a generic industry standard. Public project
> > > + documentation is available at:
> > > +
> > > + https://github.com/opensensorfusion
> > > +
> > > +allOf:
> > > + - $ref: /schemas/serial/serial-peripheral-props.yaml#
> > > +
> > > +properties:
> > > + compatible:
> > > + const: opensensorfusion,osf
> > > +
> > > +required:
> > > + - compatible
> >
> > Do you think it makes sense to permit a regulator here, so that the
> > "host" OS can power on/off the board running the osf stack?
> >
> > > +
> > > +unevaluatedProperties: false
> > > +
> > > +examples:
> > > + - |
> > > + serial {
> > > + sensor {
> > > + compatible = "opensensorfusion,osf";
> > > + };
> > > + };
> > > +...