From: Florian Fainelli <f.fainelli@gmail.com> To: Matthew Hagan <mnhagan88@gmail.com>, Vladimir Oltean <olteanv@gmail.com> Cc: Florian Fainelli <f.fainelli@gmail.com>, Andrew Lunn <andrew@lunn.ch>, Rob Herring <robh+dt@kernel.org>, Arnd Bergmann <arnd@arndb.de>, Olof Johansson <olof@lixom.net>, soc@kernel.org, Ray Jui <rjui@broadcom.com>, Scott Branden <sbranden@broadcom.com>, bcm-kernel-feedback-list@broadcom.com, Sam Ravnborg <sam@ravnborg.org>, Geert Uytterhoeven <geert+renesas@glider.be>, Viresh Kumar <viresh.kumar@linaro.org>, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 3/5] ARM: dts: NSP: Add common bindings for MX64/MX65 Date: Sat, 12 Jun 2021 19:03:29 -0700 [thread overview] Message-ID: <670e1397-1b90-ca8d-c161-6a4c48d6bff4@gmail.com> (raw) In-Reply-To: <0f3e81be-e99a-41fe-6898-42c4d25b21be@gmail.com> On 6/12/2021 4:14 PM, Matthew Hagan wrote: [snip] >>> + pwm-leds { >>> + compatible = "pwm-leds"; >>> + >>> + red { >>> + label = "red:led"; >>> + pwms = <&pwm 1 50000>; >>> + }; >>> + >>> + green { >>> + label = "green:led"; >>> + pwms = <&pwm 2 50000>; >>> + }; >>> + >>> + blue { >>> + label = "blue:led"; >>> + pwms = <&pwm 3 50000>; >>> + }; >>> + }; [snip] >> What is the reason for overriding this to 2? > > I can't provide an explanation other than that it only works at 2. > > When set to 3 I get the following: > > [ 0.784051] OF: /pwm-leds/red: #pwm-cells = 3 found -1 > [ 0.789201] of_pwm_get(): can't parse "pwms" property > [ 0.794295] leds_pwm pwm-leds: error -EINVAL: unable to request PWM for red:led > [ 0.801628] leds_pwm: probe of pwm-leds failed with error -22 Strange because with a #pwm-cells value of 3, of_pwm_xlate_with_flags() would treat the flags as optional so the way you have put it looks correct to me. I am not sure what the channel sub-nodes are supposed to do, they do not appear to be documented properties or parsed by the PWM core? Is your Device Tree possibly corrupted here? -- Florian
WARNING: multiple messages have this Message-ID (diff)
From: Florian Fainelli <f.fainelli@gmail.com> To: Matthew Hagan <mnhagan88@gmail.com>, Vladimir Oltean <olteanv@gmail.com> Cc: Florian Fainelli <f.fainelli@gmail.com>, Andrew Lunn <andrew@lunn.ch>, Rob Herring <robh+dt@kernel.org>, Arnd Bergmann <arnd@arndb.de>, Olof Johansson <olof@lixom.net>, soc@kernel.org, Ray Jui <rjui@broadcom.com>, Scott Branden <sbranden@broadcom.com>, bcm-kernel-feedback-list@broadcom.com, Sam Ravnborg <sam@ravnborg.org>, Geert Uytterhoeven <geert+renesas@glider.be>, Viresh Kumar <viresh.kumar@linaro.org>, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2 3/5] ARM: dts: NSP: Add common bindings for MX64/MX65 Date: Sat, 12 Jun 2021 19:03:29 -0700 [thread overview] Message-ID: <670e1397-1b90-ca8d-c161-6a4c48d6bff4@gmail.com> (raw) In-Reply-To: <0f3e81be-e99a-41fe-6898-42c4d25b21be@gmail.com> On 6/12/2021 4:14 PM, Matthew Hagan wrote: [snip] >>> + pwm-leds { >>> + compatible = "pwm-leds"; >>> + >>> + red { >>> + label = "red:led"; >>> + pwms = <&pwm 1 50000>; >>> + }; >>> + >>> + green { >>> + label = "green:led"; >>> + pwms = <&pwm 2 50000>; >>> + }; >>> + >>> + blue { >>> + label = "blue:led"; >>> + pwms = <&pwm 3 50000>; >>> + }; >>> + }; [snip] >> What is the reason for overriding this to 2? > > I can't provide an explanation other than that it only works at 2. > > When set to 3 I get the following: > > [ 0.784051] OF: /pwm-leds/red: #pwm-cells = 3 found -1 > [ 0.789201] of_pwm_get(): can't parse "pwms" property > [ 0.794295] leds_pwm pwm-leds: error -EINVAL: unable to request PWM for red:led > [ 0.801628] leds_pwm: probe of pwm-leds failed with error -22 Strange because with a #pwm-cells value of 3, of_pwm_xlate_with_flags() would treat the flags as optional so the way you have put it looks correct to me. I am not sure what the channel sub-nodes are supposed to do, they do not appear to be documented properties or parsed by the PWM core? Is your Device Tree possibly corrupted here? -- Florian _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2021-06-13 2:04 UTC|newest] Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-06-10 23:27 [PATCH v2 0/5] ARM: dts: NSP: add Meraki MX64/MX65 Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` [PATCH v2 1/5] dt-bindings: arm: bcm: " Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-11 19:46 ` Vladimir Oltean 2021-06-11 19:46 ` Vladimir Oltean 2021-06-12 9:21 ` Matthew Hagan 2021-06-12 9:21 ` Matthew Hagan 2021-06-12 15:07 ` Vladimir Oltean 2021-06-12 15:07 ` Vladimir Oltean 2021-06-10 23:27 ` [PATCH v2 2/5] ARM: dts: NSP: Add Meraki MX64/MX65 to Makefile Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-11 20:24 ` Vladimir Oltean 2021-06-11 20:24 ` Vladimir Oltean 2021-06-12 9:23 ` Matthew Hagan 2021-06-12 9:23 ` Matthew Hagan 2021-06-10 23:27 ` [PATCH v2 3/5] ARM: dts: NSP: Add common bindings for MX64/MX65 Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-11 20:30 ` Vladimir Oltean 2021-06-11 20:30 ` Vladimir Oltean 2021-06-12 23:14 ` Matthew Hagan 2021-06-12 23:14 ` Matthew Hagan 2021-06-13 2:03 ` Florian Fainelli [this message] 2021-06-13 2:03 ` Florian Fainelli 2021-06-10 23:27 ` [PATCH v2 4/5] ARM: dts: NSP: Add DT files for Meraki MX64 series Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` [PATCH v2 5/5] ARM: dts: NSP: Add DT files for Meraki MX65 series Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-10 23:27 ` Matthew Hagan 2021-06-11 19:02 ` Matthew Hagan 2021-06-11 19:02 ` Matthew Hagan 2021-06-11 19:02 ` Matthew Hagan 2021-06-11 20:48 ` Vladimir Oltean 2021-06-11 20:48 ` Vladimir Oltean
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=670e1397-1b90-ca8d-c161-6a4c48d6bff4@gmail.com \ --to=f.fainelli@gmail.com \ --cc=andrew@lunn.ch \ --cc=arnd@arndb.de \ --cc=bcm-kernel-feedback-list@broadcom.com \ --cc=devicetree@vger.kernel.org \ --cc=geert+renesas@glider.be \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=mnhagan88@gmail.com \ --cc=olof@lixom.net \ --cc=olteanv@gmail.com \ --cc=rjui@broadcom.com \ --cc=robh+dt@kernel.org \ --cc=sam@ravnborg.org \ --cc=sbranden@broadcom.com \ --cc=soc@kernel.org \ --cc=viresh.kumar@linaro.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.