public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Sean Young <sean@mess.org>
To: linux-media@vger.kernel.org,
	Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com>
Cc: Sean Young <sean@mess.org>
Subject: [PATCH v2 0/3] Improve pwm-ir-tx precision
Date: Fri, 13 Oct 2023 11:46:13 +0100	[thread overview]
Message-ID: <cover.1697193646.git.sean@mess.org> (raw)

The pwm-ir-tx driver has to turn the pwm signal on and off, and suffers
from delays as this is done in process context. Make this work in atomic
context.

changes:

v2:
 - Simplified the pwm ir tx based on Ivaylo Dimitrov suggestions
 - Renamed pwm_can_sleep() to pwm_is_atomic
 - Fix sleeping issue in pwm-bcm2835 (clk_get_rate() can sleep)
 - use non_block_start() in pwm to check atomic-ness

Sean Young (3):
  pwm: make it possible to apply pwm changes in atomic context
  pwm: bcm2835: allow pwm driver to be used in atomic context
  media: pwm-ir-tx: trigger edges from hrtimer interrupt context

 drivers/media/rc/pwm-ir-tx.c  | 79 +++++++++++++++++++++++++++++++++--
 drivers/pwm/core.c            | 62 ++++++++++++++++++++++-----
 drivers/pwm/pwm-bcm2835.c     | 21 ++++++----
 drivers/pwm/pwm-renesas-tpu.c |  1 -
 include/linux/pwm.h           | 29 ++++++++++++-
 5 files changed, 166 insertions(+), 26 deletions(-)

-- 
2.42.0


             reply	other threads:[~2023-10-13 10:47 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-13 10:46 Sean Young [this message]
2023-10-13 10:46 ` [PATCH v2 1/3] pwm: make it possible to apply pwm changes in atomic context Sean Young
2023-10-13 11:51   ` Thierry Reding
2023-10-13 14:58     ` Sean Young
2023-10-13 15:34       ` Thierry Reding
2023-10-13 18:04         ` Uwe Kleine-König
2023-10-14  8:31           ` Sean Young
2023-10-13 10:46 ` [PATCH v2 2/3] pwm: bcm2835: allow pwm driver to be used " Sean Young
2023-10-13 11:04   ` Stefan Wahren
2023-10-13 11:13     ` Alexander Stein
2023-10-13 11:44       ` Stefan Wahren
2023-10-13 17:51       ` Uwe Kleine-König
2023-10-14  6:51         ` Ivaylo Dimitrov
2023-10-14  8:47           ` Uwe Kleine-König
2023-10-13 10:46 ` [PATCH v2 3/3] media: pwm-ir-tx: trigger edges from hrtimer interrupt context Sean Young
2023-10-15  6:31   ` Ivaylo Dimitrov
2023-10-15 21:25     ` Sean Young

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=cover.1697193646.git.sean@mess.org \
    --to=sean@mess.org \
    --cc=ivo.g.dimitrov.75@gmail.com \
    --cc=linux-media@vger.kernel.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: 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