Re: PATCH [1/3] drivers/input/xpad.c: Improve Xbox 360 wireless support and add sysfs interface

From: Andrew Morton
Date: Mon Mar 02 2009 - 17:01:01 EST


On Mon, 2 Mar 2009 16:46:01 -0500
Mike Murphy <mamurph@xxxxxxxxxxxxxx> wrote:

> I had looked up another driver that used a header file in the stable
> tree

Yup, there's lots of crappy code in the tree, and it is regrettable
that maintainers continue to go ahead and merge that crappy code.

There's no easy fix for this - you need to be aware of what is right
and what is wrong, but you cannot look at existing code to determine
this :(

If the code which you're modifying is known (by you) to be wrong then
there are two schools of thought. Some people do like to "match the
existing code". I disagree with that. The code's wrong dammit - we
might as well make the new code "right". If that results in
inconsistent-looking code, well, so be it. We shouldn't have merged
the wrong code in the first place.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/