From: David Herrmann <dh.herrmann@gmail.com>
To: Daniel Nicoletti <dantti12@gmail.com>
Cc: "open list:HID CORE LAYER" <linux-input@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Jiri Kosina <jkosina@suse.cz>, Anton Vorontsov <cbou@mail.ru>,
David Woodhouse <dwmw2@infradead.org>
Subject: Re: [PATCH] HID: input: return ENODATA if reading battery attrs fails
Date: Fri, 24 May 2013 16:02:06 +0200 [thread overview]
Message-ID: <CANq1E4TirOvzsGCXdVFboXWqeFPJYQF3+hp-C8cLYOVsnCFuYQ@mail.gmail.com> (raw)
In-Reply-To: <CACo8zOceMMJQPXNLM3JL_GMQh8wNVNDkSC5eBaZf3a=--9JGqA@mail.gmail.com>
Hi
On Mon, May 13, 2013 at 11:17 PM, Daniel Nicoletti <dantti12@gmail.com> wrote:
> 2013/5/13 David Herrmann <dh.herrmann@gmail.com>:
>> Anyway, I'd still like to see this patch applied so we have this annoying
>> bug fixed. I'd be willing to change the power_supply core, too, if one of the
>> maintainers agrees on the design (David? Anton?).
>>
>> And, @Daniel, can you check whether this actually fixes the bug? I don't own
>> a device that reports battery-information, but it at least fixes the same bug
>> for the hid-wiimote driver (tested by me).
>
> Yes, it does fixes the bug. Now udevadm properly show add and remove events
> and upower happily get's them.
> But there is around 15 seconds block on the bluetooth stack, in other words
> when connecting a device it seems to probe the device which blocks till
> a timeout, and while that timeout doesn't finish other bluetooth
> devices are also
> blocked. It seems the devices aren't able to be probed so soon, possibly
> because bluetooth didn't finished setting them up. Looking at udevadm output
> I clearly see that it locks for around 3 times.
> My kernel knowledge is rather limited but if you can give me tips or patches to
> test I really want to see this code finally working properly, and sorry for
> not realizing when I sent it that it had this issue...
The block occurs because power_supply core now tries all properties in
a row instead of aborting if the first fails (which is what we want).
However, bluetooth-core didn't allow I/O during probe so the timeout
got quite huge considering 3s for 5 different properties instead of 3s
once (which no-one noticed, yet..)
This is now fixed with the HIDP-patch pending on linux-input and
linux-bluetooth. For usbhid and uhid we already allow I/O during probe
so this does not happen there.
So I hope we can apply this for linux-next (probably after gustavo
applied the HIDP fix)?
Cheers
David
next prev parent reply other threads:[~2013-05-24 14:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-13 15:01 [PATCH] HID: input: return ENODATA if reading battery attrs fails David Herrmann
2013-05-13 21:17 ` Daniel Nicoletti
2013-05-24 14:02 ` David Herrmann [this message]
2013-05-29 13:21 ` Jiri Kosina
2013-05-13 23:20 ` Anton Vorontsov
2013-05-15 14:58 ` David Herrmann
2013-05-16 14:05 ` David Herrmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CANq1E4TirOvzsGCXdVFboXWqeFPJYQF3+hp-C8cLYOVsnCFuYQ@mail.gmail.com \
--to=dh.herrmann@gmail.com \
--cc=cbou@mail.ru \
--cc=dantti12@gmail.com \
--cc=dwmw2@infradead.org \
--cc=jkosina@suse.cz \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).