Re: [PATCH v2 1/2] usb: xhci: correct debug message page size calculation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 13/01/2025 18.00, Michał Pecio wrote:
> On Mon, 13 Jan 2025 16:30:36 +0200, Niklas Neronin wrote:
>> Fix this by subtracting one from the result of ffs(). Note that since
>> variable 'i' is unsigned, subtracting one from zero will result in the
>> maximum unsigned integer value. Consequently, the condition 'if (i <
>> 16)' will still function correctly.
> 
> Is it unsigned? I see a simple 'int' here, so this wouldn't work.
> 

You are correct, it is not unsigned.
Thank you for catching it, don't know how I missed it.

Best Regards,
Niklas Neronin




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux