Re: [PATCH v2] HID: hid-bigbenff: driver for BigBen Interactive, PS3OFMINIPAD gamepad

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

 



On Tue, Jun 12, 2018 at 6:22 PM, Hanno Zulla <abos@xxxxxxxx> wrote:
> Hi Benjamin,
>
> thanks again for the review.
>
>>> Roderick, you were right that the buttons were mapped wrongly, so
>>> a mapping is added as requested. The descriptor fixup is still
>>> needed, as the original descriptor didn't map the analog triggers
>>> at all. I kept the analog axis remap in the fixup. Also, the
>>> fixup cleans up the output report to avoid the original
>>> descriptor's undefined Usage values.
>>
>> I am not a big fan of having both a rdesc fixup and input_mapping.
>> Can't you also fix the button mapping with the fixup?
>> If it's too hard, the answer 'no' is fine too.
>
> The rationale behind it was this: The device sends the analog
> left/right trigger data in its raw hid data stream, but the original
> descriptor threw those away and didn't map these incoming data to
> any axis. For some games, analog triggers are a desirable feature,
> so a fixup seemed warranted.
>
> Thanks for the hint regarding the buttons. I will try to map them
> in the fixup, too.
>
>> we might want to have this failing harder if the report descriptor
>> doesn't match.
>
> Okay, do you have an example for that?

Sorry, I should have double checked before saying this. You can't
abort a device enumeration here. You should probably put a warning if
the VID/PID matches and the report descriptor is not the one you
expect.

>
>> Unless the device is complete garbage with hid-generic, you can just
>> remove this hunk.
>
> Sorry, I do not understand. Why is it not necessary to add that line to
> hid_have_special_driver?
>

Since v4.16 or v4.17, hid-generic will unbind itself nicely if you
load an other driver that claims the device.
This allows to have your device handled by hid-generic until
hid-bigben is loaded, which is helpful for keyboard devices during the
initrd.
Anyway, if having hid-generic binding the device first doesn't
interfere with your driver, I'd rather keep it that way to reduce the
hid_have_sepcial_driver list.

Cheers,
Benjamin

> Thanks,
>
> Hanno
--
To unsubscribe from this list: send the line "unsubscribe linux-input" 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 Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux