[PATCH 1/1] power: bq27541 driver - serialize get_property
Alex Hornung
alex at alexhornung.com
Tue Jan 29 14:29:54 UTC 2013
Hi,
this patch fixes bug 1093543[1]. Explanation is further down, as per
commit message.
It is not obvious to me what your upstream repository (that includes
the bq27541 driver) is. The MAINTAINERS file also includes no
information on this file.
I would suspect it's android kernel/tegra[2], but I'm not sure since it
only contains release branches (and an empty master branch). If it is,
which one is the branch you based your master branch on? If not, which
one is it? I'd like to get the patch upstream.
* Currently, get_property() and its callees are not thread-safe, since
they share some global state, which they access without
serialization
or guaranteed atomicity.
* get_property() can be called in a reentrant fashion from either
several concurrent sysfs accesses, or a sysfs access concurrently
with
an access from power_supply_core.c, which in turn are triggered from
a work queue in the driver itself.
* This fixes bogus readings affecting the capacity and the charge_now
values - possibly others as well.
Cheers,
Alex
[1]: https://bugs.launchpad.net/ubuntu-nexus7/+bug/1093543
[2]: https://android.googlesource.com/kernel/tegra/
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0001-power-bq27541-driver-serialize-get_property.patch
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20130129/52b46e1a/attachment.ksh>
More information about the kernel-team
mailing list