Re: [RFC 1/2] USB: Notify OTG errors to user space via uevents

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12/7/2010 8:02 AM, pkondeti@xxxxxxxxxxxxxx wrote:
> Hi Greg,
> 
>> On Mon, Dec 06, 2010 at 06:07:50PM +0530, Pavankumar Kondeti wrote:
>>> OTG specification mandates no silent failures and all errors should
>>> be reported to the user.  The spec itself does not give the exact
>>> error description. But recommends the error message to be self
>>> explanatory.  Provide otg_notify_error() utility for USB core and
>>> OTG driver to send the error codes to user space.  All the error
>>> code values are described in include/linux/usb/ch9.h.  The user space
>>> application can listen to netlink socket and parse the buffer for
>>> "MODULE=OTG" and "ERROR=n", where 'n' contains the error code.
>>
>> How are you going to listen to the netlink socket that is already
>> grabbed by libudev?
>>
> Sorry. I never worked with udev. But I read udev documentation.
> I thought an external script can be invoked by adding a udev rule
> when MODULE=OTG is matched and ERROR value can be accessed
> in the script via env variable.
> 
I ran the sample program @ http://www.kernel.org/doc/pending/hotplug.txt
and udevd concurrently. I am able to capture all the uevents in sample
program.

-- 
Sent by a consultant of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux