Public bug reported: SRU Justification:
[Impact] Running the following LTP (linux-test-project) script, causes a kernel panic and a reboot of the DPU: ltp/testcases/bin/read_all -d /sys -q -r 10 The above test reads all directory and files under /sys. Reading the sysfs entry "large_icm" causes the kernel panic due to a garbage value returned via i2c read. That garbage value causes a buffer overflow in sprintf. [Fix] * Replace sprintf with snprintf. And also add missing lock and increase the buffer size to PAGE_SIZE. [Test Case] * Run from linux: ltp/testcases/bin/read_all -d /sys -q -r 10 [Regression Potential] no known regression ** Affects: linux-bluefield (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux-bluefield in Ubuntu. https://bugs.launchpad.net/bugs/2028309 Title: mlxbf-bootctl: Fix kernel panic due to buffer overflow Status in linux-bluefield package in Ubuntu: New Bug description: SRU Justification: [Impact] Running the following LTP (linux-test-project) script, causes a kernel panic and a reboot of the DPU: ltp/testcases/bin/read_all -d /sys -q -r 10 The above test reads all directory and files under /sys. Reading the sysfs entry "large_icm" causes the kernel panic due to a garbage value returned via i2c read. That garbage value causes a buffer overflow in sprintf. [Fix] * Replace sprintf with snprintf. And also add missing lock and increase the buffer size to PAGE_SIZE. [Test Case] * Run from linux: ltp/testcases/bin/read_all -d /sys -q -r 10 [Regression Potential] no known regression To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux-bluefield/+bug/2028309/+subscriptions -- Mailing list: https://launchpad.net/~kernel-packages Post to : kernel-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~kernel-packages More help : https://help.launchpad.net/ListHelp