On Sun, December 6, 2015 22:10, Ian Darwin wrote:
>
>
> On 2015-12-06 12:23 PM, Stuart Henderson wrote:
>> On 2015/12/06 06:02, Mickael Torres wrote:
>>> Hello,
>>>
>>> This is a kernel patch plus a utility called ugenctl I use to allow
>>> selected USB devices to attach as ugen(4) instead of their more specific
>>> driver. My use case is a Microchip "PICkit 2 Microcontroller Programmer"
>>> that attaches as uhid(4), but the command line utility pk2cmd wants a
>>> udev(4) device. There maybe are some other use cases.
>> If a device is generally pointless with uhid, we can just knock it
>> out completely in the kernel, see the UQ_BAD_HID mechanism. I think this
>> applies to your device.
>>
>> The bigger problem is "dual use" devices; e.g. some want UPS to attach
>> to upd(4), others want ugen(4) for use with NUT/apcupsd. Your code is
>> partially useful for these, but because it just changes things at attach,
>> won't survive a reboot - if it could instead force a device to detach
>> and reattach to ugen it would help a lot more cases.
>>
> One fairly common (I believe) use is with USB printers that attach as ulpt
> but CUPS wants as ugen - for these, this is useful as it stands - just
> run it
> from rc. Do people want their UPS to sometimes be upd and other times be
> a ugen? I can see there might be "I want to change this now" cases, but I
> suspect the majority could be done once at each boot and be quite useful.
>
>
I guess no. I have to configure kernel after every update to make my ups
attach as ugen and not upd. So this tool would be useful for me with a config
file so I can configure it once and don't bother on every reboot/update.

Reply via email to