On Mon, 2012-08-06 at 14:38 -0300, Herton Ronaldo Krzesinski wrote: > Please consider including in stables (3.0 and later) the following > commit: > > commit 720bb6436ff30fccad05cf5bdf961ea5b1f5686d > Author: Douglas Bagnall <[email protected]> > Date: Fri Jul 6 23:27:57 2012 -0300 > > [media] Avoid sysfs oops when an rc_dev's raw device is absent > > The fix was made for this reported bug: > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1015836 > > It addresses an oops, that for example can happen on USB DVB tuner > removal (according to the report, which also contains the oops that > happen. Quick checking debugging symbols here against one of the > oops, the patch should fix the issue). The bug reports the problem > happening on 3.2 at least, but the same code is present on 3.0, and I > expect it possible happen with it as well, and no Cc to stable was > placed. Earlier stable releases still supported don't look to be > affected (not same rc code, show_protocols not present).
Looking at the content of that patch:
> --- a/drivers/media/rc/rc-main.c
> +++ b/drivers/media/rc/rc-main.c
> @@ -775,10 +775,11 @@ static ssize_t show_protocols(struct device *device,
> if (dev->driver_type == RC_DRIVER_SCANCODE) {
> enabled = dev->rc_map.rc_type;
> allowed = dev->allowed_protos;
> - } else {
> + } else if (dev->raw) {
> enabled = dev->raw->enabled_protocols;
> allowed = ir_raw_get_allowed_protocols();
> - }
> + } else
> + return -ENODEV;
>
> IR_dprintk(1, "allowed - 0x%llx, enabled - 0x%llx\n",
> (long long)allowed,
This returns without unlocking dev->lock, which isn't much of an
improvement. Please get that fixed in mainline, and then I can apply
both of the changes to 3.2.y at once.
Ben.
--
Ben Hutchings
Theory and practice are closer in theory than in practice.
- John Levine, moderator of comp.compilers
signature.asc
Description: This is a digitally signed message part
