All of lore.kernel.org
 help / color / mirror / Atom feed
* sixaxis patch proposal
@ 2020-12-07 17:04 Lionel Jeanson
  2020-12-08  9:01 ` Bastien Nocera
  0 siblings, 1 reply; 9+ messages in thread
From: Lionel Jeanson @ 2020-12-07 17:04 UTC (permalink / raw)
  To: linux-bluetooth

Hi;

I'd like to propose the following patch to fix the following issue :

 - if an already paired PS3 DualShock is plugged to USB, while it is
turned off (PS button wasn't pushed or no more battery for instance),
then it's connection will be reset and it will have to be paired again

 - to fix this, I removed the device connection check

 - tested on Ubuntu 20.x (bluez-5.53 and bluez-5.55) and works fine in
all cases.

Thank you;
Lionel



diff --git a/plugins/sixaxis.c b/plugins/sixaxis.c
index d693a86c0..ccede193e 100644
--- a/plugins/sixaxis.c
+++ b/plugins/sixaxis.c
@@ -337,7 +337,6 @@ static bool setup_device(int fd, const char *sysfs_path,
        device = btd_adapter_find_device(adapter, &device_bdaddr,
                                                        BDADDR_BREDR);
        if (device != NULL &&
-               btd_device_is_connected(device) &&
                g_slist_find_custom(btd_device_get_uuids(device), HID_UUID,
                                                (GCompareFunc)strcasecmp)) {
                char device_addr[18];

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-12-08 12:20 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-07 17:04 sixaxis patch proposal Lionel Jeanson
2020-12-08  9:01 ` Bastien Nocera
2020-12-08  9:45   ` Lionel Jeanson
2020-12-08  9:53     ` Bastien Nocera
2020-12-08 10:46       ` Lionel Jeanson
2020-12-08 10:58         ` Bastien Nocera
2020-12-08 11:25           ` Lionel Jeanson
     [not found]           ` <CADrX+XvHL76f8mT29MO8xUGwKzhjeZTXqiSUAQnR5_JrCZ65_Q@mail.gmail.com>
2020-12-08 11:29             ` Bastien Nocera
     [not found]               ` <CADrX+Xtq=cCudHvKZG1=WdwM-vinPegXWTd-JdvpiLk4GykfbQ@mail.gmail.com>
2020-12-08 12:19                 ` Lionel Jeanson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.