[PATCH v3] Bluetooth: Add Broadcom channel priority commands

Sasha Finkelstein k at chaosmail.tech
Mon May 25 07:05:06 PDT 2026


> On May 25, 2026, at 15:58, Joshua Peisach <jpeisach at ubuntu.com> wrote:
> 
> On Mon May 25, 2026 at 8:11 AM EDT, Sasha Finkelstein wrote:
>> 
>> + cmd.enable = !!enable;
>> +
> 
> Probably a dumb question, but worth asking - what is the purpose of the
> "!!"? Wouldn't just passing "enable" be sufficient?

This is a way to enforce that the value is exactly 0 or 1, not 0 or non-zero.

> 
> Also, currently, cmd.enable seems to just be set and used in the case
> of boolean conditions. Would it make sense for the enable field in
> brcm_prio_cmd to be a bool or does it not really matter?
> 
Opposite, actually, this struct is fed to firmware, and it needs to be
specifically a u8.




More information about the linux-arm-kernel mailing list