[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1479286065.2000.1.camel@suse.com>
Date: Wed, 16 Nov 2016 09:47:45 +0100
From: Oliver Neukum <oneukum@...e.com>
To: Guenter Roeck <linux@...ck-us.net>
Cc: Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
Greg KH <gregkh@...uxfoundation.org>,
Bin Gao <bin.gao@...ux.intel.com>,
Felipe Balbi <felipe.balbi@...ux.intel.com>,
linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [PATHCv10 1/2] usb: USB Type-C connector class
On Mon, 2016-11-14 at 06:34 -0800, Guenter Roeck wrote:
> >>> +int typec_connect(struct typec_port *port, struct
> typec_connection *con)
> >>> +{
> >>> + int ret;
> >>> +
> >>> + if (!con->partner && !con->cable)
> >>> + return -EINVAL;
> >>> +
> >>> + port->connected = 1;
> >>> + port->data_role = con->data_role;
> >>> + port->pwr_role = con->pwr_role;
> >>> + port->vconn_role = con->vconn_role;
> >>> + port->pwr_opmode = con->pwr_opmode;
> >>> +
> >>> + kobject_uevent(&port->dev.kobj, KOBJ_CHANGE);
> >>
> >> This worries me. Who is listening for it? What will you do with
> it?
> >> Shouldn't you just poll on an attribute file instead?
> >
> > Oliver! Did you need this or can we remove it?
> >
>
> I'll also have to make sure that the Android folks don't use it.
How then do we notify user space? poll()? Yet another demon.
I do not specifically need this, but I note that uevents are the
general tool we use to notify user space of that kind of events.
Regards
Oliver
Powered by blists - more mailing lists