|
|
Subscribe / Log in / New account

Intentionally buggy commits for fame—and papers

Intentionally buggy commits for fame—and papers

Posted Apr 22, 2021 10:22 UTC (Thu) by excors (subscriber, #95769)
In reply to: Intentionally buggy commits for fame—and papers by bronson
Parent article: Intentionally buggy commits for fame—and papers

It looks like the 'useless' first chunk was added by Guenter Roeck to tidy up the code - the commit message says "[groeck: One variable for return values is enough]", and the original patch from Kangjie Lu (https://www.mail-archive.com/linux-kernel@vger.kernel.org...) didn't have that change.

The second chunk looks like it's addressing a real problem that's not impossible to hit - lm80_read_value can return negative error codes and that wasn't being handled. Maybe that's only possible if there's a bizarre hardware failure (I2C/SMBus devices shouldn't just stop responding at arbitrary times) but it seems good practice for the kernel to handle those situations properly. (But the patch fixes the problem wrongly, because it returns without unlocking the mutex.)


to post comments

Intentionally buggy commits for fame—and papers

Posted Apr 22, 2021 14:06 UTC (Thu) by bronson (subscriber, #4806) [Link]

Great investigation, I would have lost the wager.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds