mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Charles Keepax <ckeepax@opensource.cirrus.com>
To: Lee Jones <lee@kernel.org>
Cc: vkoul@kernel.org, yung-chuan.liao@linux.intel.com,
	pierre-louis.bossart@linux.dev, linux-sound@vger.kernel.org,
	patches@opensource.cirrus.com, mfd@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 2/2] mfd: cs42l43: Move to core detach helper
Date: Wed, 16 Sep 2026 17:01:24 +0100	[thread overview]
Message-ID: <aqq9VDQ61TWjCmQI@opensource.cirrus.com> (raw)
In-Reply-To: <20260916152148.GF1605367@google.com>

On Wed, Sep 16, 2026 at 04:21:48PM +0100, Lee Jones wrote:
> On Mon, 31 Aug 2026, Charles Keepax wrote:
> > Now the core has a helper to signal a device will detach from
> > the SoundWire bus, there is no need for the cs42l43 driver code
> > to separately track that. Switch to using the new core helper.
> > 
> > Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
> > ---
> >  	case SDW_SLAVE_UNATTACHED:
> >  		dev_dbg(cs42l43->dev, "Device detach\n");
> 
> Is this now superfluous?

It is still very useful to see attach/detach when debugging the
driver, so I would very much like to keep the print. The function
still has to do twiddling the IRQ mask on attach so its not like
the function exists only to do the debug prints.

> > -	reinit_completion(&cs42l43->device_detach);
> > +	sdw_slave_signal_unattach(cs42l43->sdw);
> 
> If this call NULL safe?

Yup.

+static inline void sdw_slave_signal_unattach(struct sdw_slave *slave)
+{
+       if (!slave)
+               return;

Thanks,
Charles

  reply	other threads:[~2026-09-16 16:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-31 14:01 [PATCH v2 0/2] Add SoundWire " Charles Keepax
2026-08-31 14:01 ` [PATCH v2 1/2] soundwire: Add a helper function to indicate a device will detach Charles Keepax
2026-08-31 14:01 ` [PATCH v2 2/2] mfd: cs42l43: Move to core detach helper Charles Keepax
2026-09-16 15:21   ` Lee Jones
2026-09-16 16:01     ` Charles Keepax [this message]
2026-09-04  7:20 ` [PATCH v2 0/2] Add SoundWire " Pierre-Louis Bossart
2026-09-17 10:59 ` Lee Jones

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=aqq9VDQ61TWjCmQI@opensource.cirrus.com \
    --to=ckeepax@opensource.cirrus.com \
    --cc=lee@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=mfd@lists.linux.dev \
    --cc=patches@opensource.cirrus.com \
    --cc=pierre-louis.bossart@linux.dev \
    --cc=vkoul@kernel.org \
    --cc=yung-chuan.liao@linux.intel.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

all inboxes | Powered by JetHome®