Re: [patch 2.6.21-rc5-git 1/2] fix hotplug for legacy platform drivers

From: David Brownell
Date: Mon Apr 02 2007 - 15:07:21 EST


On Monday 02 April 2007 3:49 am, Cornelia Huck wrote:
> On Sat, 31 Mar 2007 14:55:38 -0700,
> David Brownell <david-b@xxxxxxxxxxx> wrote:
>
> > This fix uses the newish per-device flag controlling issuance of "add" events.
> > (A previous version of this patch used a per-device "driver can hotplug" flag,
> > which only scrubbed $MODALIAS from the environment rather than suppressing the
> > entire hotplug event.) It also shrinks that flag to one bit, saving a word in
> > "struct device".
>
> Would this still work on top of
> driver-core-suppress-uevents-via-filter.patch (in -mm), which
> suppresses all uevents (not just the add event)? I'd think yes, but I'm
> not that familiar with platform devices :)

It depends what "yes" means. ;)

Yes, as far as I can tell the only additional change (today) from
that "supress all events" patch would be that "remove" events would
also go away ... last time I checked, only add/remove events were
issued for those devices.

But long term, I wonder. Isn't "no kevents issued" an extremely
blunt tool, which could cause lots of damage? It might be better
to have selective filters, one per event family: core (add/remove),
online/offline, mount/unmount, etc.

Specifically with respect to legacy drivers, it might make sense
that managing the devices they create not be confusable with managing
"real" devices, so I don't immediately suspect that suppressing ALL
the hotplug events might be troublesome.

But in general it's worth thinking about. The comments on that
"suppress all kevents" patch didn't include any motivation at all.
Why do you want to prevent all kevents, rather than just a subset?

- Dave
-
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/