lkml.org 
[lkml]   [2025]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 0/1] Input: xpad - add disable_xboxone module parameter
Any thoughts on considering this patch?

On Wed, May 21, 2025 at 2:45 PM Apoorv Parle <apparle@gmail.com> wrote:
>
> From what I've read on udev rules so far, I'm not sure if there's a
> clean deterministic way of unbinding one driver and binding it to
> another.
> As I understand, I'll have to write a script to run for either the
> "add" action or the "bind" action. The "add" script runs asynchronous
> to kernel's binding, so it could happen before or after xpad binding
> is done; and even if I unbind it, kernel can re-bind it again while
> scanning the USB bus, which again creates a race with the script. If I
> use the "bind" action instead of "add" action, the script can recurse
> depending on timing of kernel's attempt to rebind. I tried to look for
> similar examples but couldn't find any -- just a few very high cpu
> usage bugs due to similar recursion.
> Other similar scenarios (like graphics drivers) that I tried to find,
> just blacklist whole kernel modules or used some module param.
>
> Though I'll admit, my knowledge of udev rules is somewhat limited.
>
>
> On Mon, May 19, 2025 at 11:23 PM A. Bosch <progandy@progandy.de> wrote:
> >
> > Hi,
> >
> > could you not create udev rules to perform these actions?
> >
> > - Andreas
> >
> >
> > Am 20. Mai 2025 06:04:36 MESZ schrieb Apoorv Parle <apparle@gmail.com>:
> >>
> >> Ah, yes, that's possible. But it's too hard to generally use -
> >> requires manual command line intervention each time the xbox dongle is
> >> plugged-in and/or computer reboots.There's no easy way to robustly
> >> automate this especially for layperson linux gamers.
> >> A stripped-down and hand-compiled version of xpad is at least fully
> >> automated, but only until the linux kernel is updated by the distro.
> >>
> >> On Mon, May 19, 2025 at 2:36 PM Dmitry Torokhov
> >> <dmitry.torokhov@gmail.com> wrote:
> >>>
> >>>
> >>> I understand. However you can unbind and bind individual devices to
> >>> individual drivers via sysfs by writing into
> >>> /sys/bus/usb/drivers/{xpad|xone}/{un}bind.
> >>>
> >>> Thanks.
> >>>
> >>> --
> >>> Dmitry
> >>
> >>

\
 
 \ /
  Last update: 2025-05-25 12:42    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog