From: Allen Pais <allen.lkml@gmail.com>
To: perex@perex.cz, tiwai@suse.com, broonie@kernel.org
Cc: alsa-devel@alsa-project.org, timur@kernel.org,
Xiubo.Lee@gmail.com, clemens@ladisch.de,
Allen Pais <allen.lkml@gmail.com>,
nicoleotsuka@gmail.com, Romain Perier <romain.perier@gmail.com>
Subject: [PATCH v2 05/10] ALSA: hdsp: convert tasklets to use new tasklet_setup() API
Date: Wed, 2 Sep 2020 09:32:16 +0530 [thread overview]
Message-ID: <20200902040221.354941-6-allen.lkml@gmail.com> (raw)
In-Reply-To: <20200902040221.354941-1-allen.lkml@gmail.com>
In preparation for unconditionally passing the
struct tasklet_struct pointer to all tasklet
callbacks, switch to using the new tasklet_setup()
and from_tasklet() to pass the tasklet pointer explicitly.
Signed-off-by: Romain Perier <romain.perier@gmail.com>
Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
sound/pci/rme9652/hdsp.c | 6 +++---
sound/pci/rme9652/hdspm.c | 7 +++----
2 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/sound/pci/rme9652/hdsp.c b/sound/pci/rme9652/hdsp.c
index 227aece17e39..dda56ecfd33b 100644
--- a/sound/pci/rme9652/hdsp.c
+++ b/sound/pci/rme9652/hdsp.c
@@ -3791,9 +3791,9 @@ static int snd_hdsp_set_defaults(struct hdsp *hdsp)
return 0;
}
-static void hdsp_midi_tasklet(unsigned long arg)
+static void hdsp_midi_tasklet(struct tasklet_struct *t)
{
- struct hdsp *hdsp = (struct hdsp *)arg;
+ struct hdsp *hdsp = from_tasklet(hdsp, t, midi_tasklet);
if (hdsp->midi[0].pending)
snd_hdsp_midi_input_read (&hdsp->midi[0]);
@@ -5182,7 +5182,7 @@ static int snd_hdsp_create(struct snd_card *card,
spin_lock_init(&hdsp->lock);
- tasklet_init(&hdsp->midi_tasklet, hdsp_midi_tasklet, (unsigned long)hdsp);
+ tasklet_setup(&hdsp->midi_tasklet, hdsp_midi_tasklet);
pci_read_config_word(hdsp->pci, PCI_CLASS_REVISION, &hdsp->firmware_rev);
hdsp->firmware_rev &= 0xff;
diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c
index 0fa49f4d15cf..572350aaf18d 100644
--- a/sound/pci/rme9652/hdspm.c
+++ b/sound/pci/rme9652/hdspm.c
@@ -2169,9 +2169,9 @@ static int snd_hdspm_create_midi(struct snd_card *card,
}
-static void hdspm_midi_tasklet(unsigned long arg)
+static void hdspm_midi_tasklet(struct tasklet_struct *t)
{
- struct hdspm *hdspm = (struct hdspm *)arg;
+ struct hdspm *hdspm = from_tasklet(hdspm, t, midi_tasklet);
int i = 0;
while (i < hdspm->midiPorts) {
@@ -6836,8 +6836,7 @@ static int snd_hdspm_create(struct snd_card *card,
}
- tasklet_init(&hdspm->midi_tasklet,
- hdspm_midi_tasklet, (unsigned long) hdspm);
+ tasklet_setup(&hdspm->midi_tasklet, hdspm_midi_tasklet);
if (hdspm->io_type != MADIface) {
--
2.25.1
next prev parent reply other threads:[~2020-09-02 4:06 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-02 4:02 [PATCH v2 00/10] ALSA: convert tasklets to use new Allen Pais
2020-09-02 4:02 ` [PATCH v2 01/10] ALSA: core: convert tasklets to use new tasklet_setup() API Allen Pais
2020-09-02 4:02 ` [PATCH v2 02/10] ALSA: firewire: " Allen Pais
2020-09-02 8:44 ` Takashi Sakamoto
2020-09-02 9:14 ` Takashi Iwai
2020-09-02 4:02 ` [PATCH v2 03/10] ALSA: pci/asihpi: " Allen Pais
2020-09-02 4:02 ` [PATCH v2 04/10] ALSA: riptide: " Allen Pais
2020-09-02 4:02 ` Allen Pais [this message]
2020-09-02 4:02 ` [PATCH v2 06/10] ASoc: fsl_esai: " Allen Pais
2020-09-02 10:08 ` Mark Brown
2020-09-02 4:02 ` [PATCH v2 07/10] ASoC: siu: " Allen Pais
2020-09-02 10:10 ` Mark Brown
2020-09-02 4:02 ` [PATCH v2 08/10] ASoC: txx9: " Allen Pais
2020-09-02 10:10 ` Mark Brown
2020-09-02 4:02 ` [PATCH v2 09/10] ALSA: usb-audio: " Allen Pais
2020-09-02 4:02 ` [PATCH v2 10/10] ALSA: ua101: " Allen Pais
2020-09-02 11:57 ` [PATCH v2 00/10] ALSA: convert tasklets to use new Takashi Iwai
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=20200902040221.354941-6-allen.lkml@gmail.com \
--to=allen.lkml@gmail.com \
--cc=Xiubo.Lee@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=clemens@ladisch.de \
--cc=nicoleotsuka@gmail.com \
--cc=perex@perex.cz \
--cc=romain.perier@gmail.com \
--cc=timur@kernel.org \
--cc=tiwai@suse.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox