Re: [PATCH 3/3] ASoC: amd: ps: replace bitwise OR with logical OR in IRQ return check

"Mukunda,Vijendar" <[email protected]> Wed, 8 Jul 2026 07:35:43 +0530
Newsgroups org.alsa-project.alsa-devel,org.kernel.vger.linux-kernel,org.kernel.vger.linux-sound
Message-ID <[email protected]>

On 7/7/26 23:19, Mario Limonciello wrote:
>
>
> On 7/7/26 00:59, Vijendar Mukunda wrote:
>> The condition 'irq_flag | wake_irq_flag' uses bitwise OR to combine two
>> integer flags that are used as booleans. Replace with logical OR '||' to
>> correctly express the intended boolean check.
>>
>> Signed-off-by: Vijendar Mukunda <[email protected]>
> Fixes: 7f91f012c1df0 ("ASoC: amd: ps: fix for irq handler return status")

This is a style/readability cleanup only.
Since irq_flag and wake_irq_flag are strictly used as boolean values (0/1),
using | or || yields the same runtime behavior.
No functional bug is being fixed here, so a Fixes: tag is not warranted.


>> ---
>>   sound/soc/amd/ps/pci-ps.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/sound/soc/amd/ps/pci-ps.c b/sound/soc/amd/ps/pci-ps.c
>> index 1162d13d8505..729f9aaba69e 100644
>> --- a/sound/soc/amd/ps/pci-ps.c
>> +++ b/sound/soc/amd/ps/pci-ps.c
>> @@ -248,7 +248,7 @@ static irqreturn_t acp63_irq_handler(int irq, 
>> void *dev_id)
>>       if (sdw_dma_irq_flag)
>>           return IRQ_WAKE_THREAD;
>>   -    if (irq_flag | wake_irq_flag)
>> +    if (irq_flag || wake_irq_flag)
>>           return IRQ_HANDLED;
>>       else
>>           return IRQ_NONE;
>