[Skiboot] [PATCH v2 1/2] hw/lpc-uart.c: Fix uninitialised comparison

Reza Arbab arbab at linux.ibm.com
Sat May 17 01:00:21 AEST 2025


On Fri, Apr 11, 2025 at 03:09:52PM +0530, Aditya Gupta wrote:
>Hi Abhishek,
>
>On 25/04/10 06:13AM, ABHISHEK SINGH TOMAR wrote:
>> From: Abhishek Singh Tomar <abhishek at linux.ibm.com>
>>
>> The __length variable is not initialized in the Linux
>> kernel source code but is compared against a value in
>> uart_opal_write_buffer_space. This results in invalid behavior.
>>
>> Changes include:
>>
>> Removing the invalid comparison of __length.
>> Adding a temporary log statement for testing purposes:
>> 	Inside uart_opal_write_buffer_space: __length=0xf03baaaa050000c0.
>
>This line might not be required now ^^, as you seem to have removed the
>log statement.
>
>>
>> opal_console_write_buffer_space is called twice in the
>> kernel code, but __length remains uninitialized in both
>> cases. This fix ensures correct behavior by eliminating
>> the problematic comparison.
>>
>> This can finally lead to hang/softlock issue in older hardware.
>>
>> Signed-off-by: Abhishek Singh Tomar <abhishek at linux.ibm.com>

I fixed up the commit log and applied this to master.

-- 
Reza Arbab


More information about the Skiboot mailing list