public inbox for devicetree@vger.kernel.org
 help / color / mirror / Atom feed
From: Sean Young <sean@mess.org>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Biswapriyo Nath <nathbappai@gmail.com>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>, Lee Jones <lee@kernel.org>,
	Pavel Machek <pavel@kernel.org>,
	Michael Turquette <mturquette@baylibre.com>,
	Stephen Boyd <sboyd@kernel.org>,
	Martin Botka <martin.botka@somainline.org>,
	linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org,
	linux-clk@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht,
	phone-devel@vger.kernel.org
Subject: Re: [PATCH 4/7] dt-bindings: leds: irled: ir-spi-led: Add new duty-cycle value
Date: Fri, 27 Mar 2026 10:18:20 +0000	[thread overview]
Message-ID: <acZZbKhXe5kLMfTt@gofer.mess.org> (raw)
In-Reply-To: <ad7a0675-84cc-424a-b583-47c342f02fb0@kernel.org>

On Fri, Mar 27, 2026 at 10:38:17AM +0100, Krzysztof Kozlowski wrote:
> On 27/03/2026 09:41, Sean Young wrote:
> > On Fri, Mar 27, 2026 at 08:51:18AM +0100, Krzysztof Kozlowski wrote:
> >> On Wed, Mar 25, 2026 at 06:07:27PM +0000, Biswapriyo Nath wrote:
> >>> 30 duty cycle for IR transmitter is used in Xiaomi Redmi Note 8 (ginkgo).
> >>>
> >>> Signed-off-by: Biswapriyo Nath <nathbappai@gmail.com>
> >>> ---
> >>>  Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml | 2 +-
> >>>  1 file changed, 1 insertion(+), 1 deletion(-)
> >>>
> >>> diff --git a/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
> >>> index 72cadebf6e3..0297bfbb275 100644
> >>> --- a/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
> >>> +++ b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
> >>> @@ -25,7 +25,7 @@ properties:
> >>>  
> >>>    duty-cycle:
> >>>      $ref: /schemas/types.yaml#/definitions/uint8
> >>> -    enum: [50, 60, 70, 75, 80, 90]
> >>> +    enum: [30, 50, 60, 70, 75, 80, 90]
> >>
> >> Hm, why is this enum, instead of 1-99, in the first place?
> > 
> > Well in reality only a few different duty cycles are used by IR protocols.
> > 30% is quite common so that should part of the list. 
> > 
> > Having said that a range of 1-99 would be nicer. Do we set this like so:
> > 
> >  - minimum: 1
> >  - maximum: 99
> 
> I asked, because I don't know what hardware is really there. This should
> match reality, so if you say continuous range is never used, it does not
> have the be changed to 1-99.

So the transmit hardware can do an continuous range (almost). It's the
real life usage which doesn't really use many different values.

The value set here is just the default duty cycle. There is also an ioctl 
LIRC_SET_SEND_DUTY_CYCLE which sets the duty cycle for transmission.

Most IR drivers just have a hardcoded default value for the duty cycle,
I think ir-spi is the only one which allows this to be set via dt.

I'd say allowing the default to be set via dt is not necessary. If this had
occurred to be during review I would've asked for it to be removed. It's
there now, so:

Reviewed-by: Sean Young <sean@mess.org>

Sean

  reply	other threads:[~2026-03-27 10:18 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-25 18:07 [PATCH 0/7] Add vibrator, IR transmitter and USB-C handling in xiaomi-ginkgo Biswapriyo Nath
2026-03-25 18:07 ` [PATCH 1/7] arm64: dts: qcom: sm6125-xiaomi-ginkgo: Enable vibrator Biswapriyo Nath
2026-03-25 22:40   ` Dmitry Baryshkov
2026-03-26  9:40   ` Konrad Dybcio
2026-03-25 18:07 ` [PATCH 2/7] arm64: dts: qcom: sm6125: Enable USB-C port handling Biswapriyo Nath
2026-03-25 20:08   ` Dmitry Baryshkov
2026-03-25 22:40   ` Dmitry Baryshkov
2026-03-26  9:41   ` Konrad Dybcio
2026-03-26 18:28     ` Biswapriyo Nath
2026-03-27  9:55       ` Konrad Dybcio
2026-03-25 18:07 ` [PATCH 3/7] arm64: dts: qcom: sm6125-xiaomi-ginkgo: Add PMI632 Type-C property Biswapriyo Nath
2026-03-26  9:39   ` Konrad Dybcio
2026-03-25 18:07 ` [PATCH 4/7] dt-bindings: leds: irled: ir-spi-led: Add new duty-cycle value Biswapriyo Nath
2026-03-27  7:51   ` Krzysztof Kozlowski
2026-03-27  8:41     ` Sean Young
2026-03-27  9:38       ` Krzysztof Kozlowski
2026-03-27 10:18         ` Sean Young [this message]
2026-03-25 18:07 ` [PATCH 5/7] arm64: dts: qcom: sm6125-xiaomi-ginkgo: Add IR transmitter Biswapriyo Nath
2026-03-26  9:29   ` Konrad Dybcio
2026-03-26 18:41     ` Biswapriyo Nath
2026-03-27  9:19       ` Konrad Dybcio
2026-03-27 10:20   ` Sean Young
2026-03-25 18:07 ` [PATCH 6/7] arm64: dts: qcom: sm6125: Use 64 bit addressing Biswapriyo Nath
2026-03-25 22:41   ` Dmitry Baryshkov
2026-03-26 10:54   ` Konrad Dybcio
2026-03-25 18:07 ` [PATCH 7/7] dt-bindings: clock: qcom, dispcc-sm6125: Add #reset-cells property Biswapriyo Nath
2026-03-25 22:42   ` Dmitry Baryshkov
2026-03-25 22:10 ` [PATCH 0/7] Add vibrator, IR transmitter and USB-C handling in xiaomi-ginkgo Sean Young
2026-03-26  6:03   ` Biswapriyo Nath
2026-03-26  9:39 ` Konrad Dybcio
2026-03-26 17:48   ` barnabas.czeman
2026-03-27  9:11     ` Konrad Dybcio
2026-03-29  4:54 ` Biswapriyo Nath

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=acZZbKhXe5kLMfTt@gofer.mess.org \
    --to=sean@mess.org \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=krzk@kernel.org \
    --cc=lee@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=martin.botka@somainline.org \
    --cc=mturquette@baylibre.com \
    --cc=nathbappai@gmail.com \
    --cc=pavel@kernel.org \
    --cc=phone-devel@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=sboyd@kernel.org \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /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: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox