Re: [patch] kernel sysfs events layer

Robert Love
2004-09-05T03:59:42Z

On Sat, 2004-09-04 at 02:54 +0200, Greg KH wrote:

> But transports are important, I agree.

Oh, I have another thought (see my previous email first).

The proper course of action based on your suggestion is to cleanly
abstract the concept of the "backend transport" from the notifier, and
offer a compile-time option of hotplug, netlink, and/or whatever else.
Make the transport pluggable and configurable. Do it cleanly. Yada
yada.

But that is a lot of code and a lot of work. More than I think is
warranted, right?

Accepting that the above is the clean and proper way to do what you say,
let's carry it through. What is the ideal situation? People pick
either hotplug or netlink or foo as their transport. Why pick more than
one? Most people select hotplug because that is there now and works.
Maybe in the future people would choose netlink and move to that. This
is all ideally.

In practice, however, we get people enabling both hotplug and netlink,
because they need hotplug for hotplug and want netlink for the new
kevent stuff. So this approach leads to no one ever picking the ideal.

What we want is people using hotplug for hotplug, and kevent over
netlink for the event stuff.

So why stick the two together?

We have kobject_hotplug() and kobject_notify() and everything makes
sense.

Robert Love