Re: [bug report] HID: playstation: DS4: Don't fail on calibration data request

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

 



On 4/8/24 09:41, Dan Carpenter wrote:
Hello Max Staudt,

Commit a48a7cd85f55 ("HID: playstation: DS4: Don't fail on
calibration data request") from Feb 8, 2024 (linux-next), leads to
the following Smatch static checker warning:

drivers/hid/hid-playstation.c:1904 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_x_minus'.
drivers/hid/hid-playstation.c:1904 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_x_plus'.
drivers/hid/hid-playstation.c:1910 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_y_minus'.
drivers/hid/hid-playstation.c:1910 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_y_plus'.
drivers/hid/hid-playstation.c:1916 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_z_minus'.
drivers/hid/hid-playstation.c:1916 dualshock4_get_calibration_data() error: uninitialized symbol 'acc_z_plus'.


Hi Dan, Jiri,

Thanks for the report!


Jiri, if you prefer to do so, please feel free to stop/revert this patch for now, and I'll send a better one soon.

The label "no_buffer_tail_check" was meant to jump straight to the sanity checks in order to have them write the fallback calibration values. But I missed that the part in between the two sanity checks can actually make the second sanity check pass with bogus values - as shown by Dan's check.


Max





[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux