public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Charles Keepax <ckeepax@opensource.cirrus.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: "Liao, Bard" <bard.liao@intel.com>,
	"Liao, Bard" <yung-chuan.liao@linux.intel.com>,
	Vinod Koul <vkoul@kernel.org>,
	Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>,
	"Kale, Sanyog R" <sanyog.r.kale@intel.com>,
	Shreyas NC <shreyas.nc@intel.com>,
	"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"stable@vger.kernel.org" <stable@vger.kernel.org>
Subject: Re: [PATCH] soundwire: stream: fix programming slave ports for non-continous port maps
Date: Mon, 9 Sep 2024 15:34:48 +0100	[thread overview]
Message-ID: <Zt8HiDW0gs6hXDPY@opensource.cirrus.com> (raw)
In-Reply-To: <acec443c-f9ab-4c1d-b1ab-b8620dfef77f@linaro.org>

On Wed, Sep 04, 2024 at 01:43:50PM +0200, Krzysztof Kozlowski wrote:
> On 03/09/2024 17:17, Liao, Bard wrote:
> 
> >>>
> >>> then dpn_prop[0].num = 1 and dpn_prop[1].num = 3. And we need to go
> >>>
> >>> throuth dpn_prop[0] and dpn_prop[1] instead of dpn_prop[1] and
> >> dpn_prop[3].
> >>>
> >>
> >> What are the source or sink ports in your case? Maybe you just generate
> >> wrong mask?
> > 
> > I checked my mask is 0xa when I do aplay and it matches the sink_ports of
> > the rt722 codec.
> > 
> >>
> >> It's not only my patch which uses for_each_set_bit(). sysfs_slave_dpn
> >> does the same.
> > 
> > What sysfs_slave_dpn does is 
> >         i = 0;                          
> >         for_each_set_bit(bit, &mask, 32) {
> >                 if (bit == N) {
> >                         return sprintf(buf, format_string,
> >                                        dpn[i].field);
> >                 }
> >                 i++;
> >         }                         
> > It uses a variable "i" to represent the array index of dpn[i].
> > But, it is for_each_set_bit(i, &mask, 32) in your patch and the variable "i"
> > which represents each bit of the mask is used as the index of dpn_prop[i].
> > 
> > Again, the point is that the bits of mask is not the index of the dpn_prop[]
> > array.
> 
> Yes, you are right. I think I cannot achieve my initial goal of using
> same dpn array with different indices. My patch should be reverted, I
> believe.
> 
> I'll send a revert, sorry for the mess.
> 

Hi, apologies for being late to the party (was on holiday), but yeah
this is breaking things for me as well and is clearly wrong.
Agree probably best to revert.

Thanks,
Charles

  reply	other threads:[~2024-09-09 14:35 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-29 14:01 [PATCH] soundwire: stream: fix programming slave ports for non-continous port maps Krzysztof Kozlowski
2024-07-29 14:25 ` Pierre-Louis Bossart
2024-07-30  8:23   ` Krzysztof Kozlowski
2024-07-30  8:39     ` Krzysztof Kozlowski
2024-07-30  8:59       ` Pierre-Louis Bossart
2024-07-30  9:19         ` Krzysztof Kozlowski
2024-07-30  9:28           ` Pierre-Louis Bossart
2024-07-30  9:29             ` Krzysztof Kozlowski
2024-07-30  9:43               ` Pierre-Louis Bossart
2024-07-31  6:56   ` Vinod Koul
2024-09-03  7:34     ` Liao, Bard
2024-09-03 12:50       ` Krzysztof Kozlowski
2024-09-03 15:17         ` Liao, Bard
2024-09-04 11:43           ` Krzysztof Kozlowski
2024-09-09 14:34             ` Charles Keepax [this message]
2024-08-18  7:28 ` Vinod Koul

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=Zt8HiDW0gs6hXDPY@opensource.cirrus.com \
    --to=ckeepax@opensource.cirrus.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=bard.liao@intel.com \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=sanyog.r.kale@intel.com \
    --cc=shreyas.nc@intel.com \
    --cc=stable@vger.kernel.org \
    --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