[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.44L0.1909271015510.1698-100000@iolanthe.rowland.org>
Date: Fri, 27 Sep 2019 10:21:00 -0400 (EDT)
From: Alan Stern <stern@...land.harvard.edu>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
cc: Andrey Konovalov <andreyknvl@...gle.com>,
"Rafael J. Wysocki" <rafael@...nel.org>,
syzbot <syzbot+e74a998ca8f1df9cc332@...kaller.appspotmail.com>,
LKML <linux-kernel@...r.kernel.org>,
USB list <linux-usb@...r.kernel.org>,
syzkaller-bugs <syzkaller-bugs@...glegroups.com>
Subject: Re: WARNING in pvr2_i2c_core_done
On Fri, 27 Sep 2019, Greg Kroah-Hartman wrote:
> > It turns out the reason for this error is simple: The driver
> > unregisters its subdevices in the release handler instead of in the
> > disconnect handler. There probably is documentation about this
> > somewhere, but I don't know exactly where -- maybe Greg remembers.
>
> Nope, I don't remember. It should happen in the disconnect handler, odd
> of it to be in release, but maybe that's the "easiest" way for v4l to
> handle this?
This isn't a question of "easiest". Unregistering child devices in a
release handler is just _wrong_, plain and simple. That's what gives
rise to the
"sysfs group 'power' not found for kobject 'i2c-0'"
warning in the kernel log. The group can't be found because it has
already been removed; it gets destroyed when the parent USB interface
device is unregistered, because unregistering a device also removes
from sysfs everything below that device.
Alan Stern
Powered by blists - more mailing lists