Re: [PATCH 1/1] platform: x86: Deletion of checks before backlight_device_unregister()

Dan Carpenter
2015-06-27T13:17:23Z

On Fri, Jun 26, 2015 at 04:06:55PM -0700, Darren Hart wrote:
> Julia, do you have any particular objection to this specific patch? I didn't see
> a reason to prevent it going in.

I hate these patches...

We're saying "these functions have sanity checks so let's pass nonsense
values to them, it's fine." It makes the code harder to understand.
There is no way for a human being to remember the complete list of
functions with sanity checks and which don't have sanity checks.

Markus has introduced quite a few bugs as well (people have so far
managed to catch his bugs before they were committed). He so far has
resisted any suggestion that he should manually review his patches
before sending them.

Btw do have a scripts/coccinelle/free/ifnullfree.cocci which removes
checks before kfree, debugfs_remove, debugfs_remove_recursive, and
usb_free_urb.

regards,
dan carpenter