All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Bollinger, Seth" <Seth.Bollinger@digi.com>
To: "linux-leds@vger.kernel.org" <linux-leds@vger.kernel.org>
Cc: Pavel Machek <pavel@ucw.cz>, Dan Murphy <dmurphy@ti.com>,
	Seth Bollinger <seth.boll@gmail.com>
Subject: Strange timer LED behavior
Date: Mon, 19 Oct 2020 13:08:25 +0000	[thread overview]
Message-ID: <A2C38AF0-0CE8-4312-8329-54B7E9653223@digi.com> (raw)

Hello All,

We use the sysfs timer trigger of the led subsystem to control our leds (turn on, turn off, and blink).  While doing this we found a strange behavior.  If the values of delay_on and delay_off are ever both zero, the led subsystem will make the decision to blink at a 500ms on and 500ms off rate.

# cd /sys/class/leds/g01
# cat delay_on
0
# cat delay_off
86400
# echo 0 > delay_off
# cat delay_on
500
# cat delay_off
500

drivers/led/led-core.c:184
    /* blink with 1 Hz as default if nothing specified */
    if (!*delay_on && !*delay_off)
        *delay_on = *delay_off = 500;

Is there a reason that the kernel would decide to blink at this default rate instead of leaving the timer disabled?

Thanks,

Seth

             reply	other threads:[~2020-10-19 13:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-19 13:08 Bollinger, Seth [this message]
2020-10-19 14:06 ` Strange timer LED behavior Pavel Machek
2020-10-19 14:16   ` Bollinger, Seth
2020-10-20 12:04     ` Bollinger, Seth
2020-10-20 12:21       ` Pavel Machek
2020-10-20 12:31         ` Bollinger, Seth
2020-10-20 18:08           ` Pavel Machek
2020-10-20 18:28             ` Bollinger, Seth
2020-10-20 18:33               ` Pavel Machek
2020-10-20 18:35                 ` Bollinger, Seth
2020-10-20 18:40                   ` Pavel Machek
2020-10-20 18:51                     ` Bollinger, Seth
2020-10-22 10:06                       ` Pavel Machek
2020-10-22 11:34                         ` Bollinger, Seth
2020-10-24  7:45                           ` Pavel Machek
2020-10-21 20:23                   ` Jacek Anaszewski
2020-10-22 11:35                     ` Bollinger, Seth

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=A2C38AF0-0CE8-4312-8329-54B7E9653223@digi.com \
    --to=seth.bollinger@digi.com \
    --cc=dmurphy@ti.com \
    --cc=linux-leds@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=seth.boll@gmail.com \
    /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 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.