On 28 July 2015 at 19:37, Joachim Eastwood <[email protected]> wrote: > On 27 July 2015 at 06:45, Ariel D'Alessandro <[email protected]> > wrote: >> Add the devicetree binding document for NXP LPC18xx PWM/SCT. >> >> Signed-off-by: Ariel D'Alessandro <[email protected]> >> --- >> .../devicetree/bindings/pwm/lpc1850-pwm.txt | 20 >> ++++++++++++++++++++ >> 1 file changed, 20 insertions(+) >> create mode 100644 Documentation/devicetree/bindings/pwm/lpc1850-pwm.txt >> >> diff --git a/Documentation/devicetree/bindings/pwm/lpc1850-pwm.txt >> b/Documentation/devicetree/bindings/pwm/lpc1850-pwm.txt >> new file mode 100644 >> index 0000000..3055429 >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/pwm/lpc1850-pwm.txt >> @@ -0,0 +1,20 @@ >> +* NXP LPC18xx Pulse Width Modulator driver >> + >> +Required properties: >> + - compatible: Should be "nxp,lpc1850-pwm" >> + - reg: Should contain physical base address and length of pwm registers. >> + - clocks: Must contain an entry for each entry in clock-names. >> + See ../clock/clock-bindings.txt for details. >> + - clock-names: Must include the following entries. >> + - pwm: PWM operating clock. >> + - #pwm-cells: Should be 3. See pwm.txt in this directory for the >> description >> + of the cells format. >> + >> +Example: >> + pwm: pwm@40000000 { >> + compatible = "nxp,lpc1850-pwm"; > > I would prefer "nxp,lpc1850-sct" for a couple of reasons. SCT is the > name of hardware block as described in the user manual and while PWM > is the most obvious usage for this block on Linux, the hardware is not > limited to just doing that. So as a bit of future proofing if someone > wants to use this block for more than PWM I would prefer SCT. >
Shouldn't we use something like "nxp,lpc1850-sct-pwm"? Sounds like the word PWM should be in the compatible as it describes not only the device, but the device used in a certain way. Otherwise, how would we use "nxp,lpc1850-sct" to distinguish a PWM from e.g. a clocksource/clockevents (we can also use SCT for that)? -- Ezequiel GarcĂa, VanguardiaSur www.vanguardiasur.com.ar -- To unsubscribe from this list: send the line "unsubscribe linux-pwm" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
