linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* bq27x00_battery status report issue
@ 2012-01-14 21:10 Grazvydas Ignotas
  2012-01-19 10:56 ` Pali Rohár
  0 siblings, 1 reply; 5+ messages in thread
From: Grazvydas Ignotas @ 2012-01-14 21:10 UTC (permalink / raw)
  To: Pali Rohár; +Cc: Anton Vorontsov, linux-kernel

Hi,

After 270968c0984ae "bq27x00_battery: Fix reporting status value for
bq27500 battery" status doesn't seem to be reported correctly when the
battery is close to fully charged state. It reports "Not charging"
while in fact there is >130mA current flowing to the battery according
to current_now.

This status report seems to be based on CHG bit in status register,
but looking at the datasheet the description says "(Fast) charging
allowed", which I guess means that the chip recommends charging and
not that charging is actually going on? If you check the bit while
battery is discharging and it's not full, the bit is also set.


-- 
Gražvydas

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

* Re: bq27x00_battery status report issue
  2012-01-14 21:10 bq27x00_battery status report issue Grazvydas Ignotas
@ 2012-01-19 10:56 ` Pali Rohár
  2012-01-20 11:02   ` Grazvydas Ignotas
  0 siblings, 1 reply; 5+ messages in thread
From: Pali Rohár @ 2012-01-19 10:56 UTC (permalink / raw)
  To: Grazvydas Ignotas; +Cc: Anton Vorontsov, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 963 bytes --]

On Saturday 14 January 2012 23:10:05 Grazvydas Ignotas wrote:
> Hi,
> 
> After 270968c0984ae "bq27x00_battery: Fix reporting status value for
> bq27500 battery" status doesn't seem to be reported correctly when the
> battery is close to fully charged state. It reports "Not charging"
> while in fact there is >130mA current flowing to the battery according
> to current_now.
> 
> This status report seems to be based on CHG bit in status register,
> but looking at the datasheet the description says "(Fast) charging
> allowed", which I guess means that the chip recommends charging and
> not that charging is actually going on? If you check the bit while
> battery is discharging and it's not full, the bit is also set.

Now I do not have device with bq27500 chip for testing. I read datasheet again 
and I think that your interpretation may be correct. Can you write patch for 
this problem and test it?

-- 
Pali Rohár
pali.rohar@gmail.com

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

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

* Re: bq27x00_battery status report issue
  2012-01-19 10:56 ` Pali Rohár
@ 2012-01-20 11:02   ` Grazvydas Ignotas
  2012-01-20 13:38     ` Pali Rohár
  0 siblings, 1 reply; 5+ messages in thread
From: Grazvydas Ignotas @ 2012-01-20 11:02 UTC (permalink / raw)
  To: Pali Rohár; +Cc: Anton Vorontsov, linux-kernel

On Thu, Jan 19, 2012 at 12:56 PM, Pali Rohár <pali.rohar@gmail.com> wrote:
> Now I do not have device with bq27500 chip for testing. I read datasheet again
> and I think that your interpretation may be correct. Can you write patch for
> this problem and test it?

What about just reverting 270968c0984ae instead? I think my patch
would look almost exactly like that..


-- 
Gražvydas

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

* Re: bq27x00_battery status report issue
  2012-01-20 11:02   ` Grazvydas Ignotas
@ 2012-01-20 13:38     ` Pali Rohár
  2012-02-01 17:37       ` Anton Vorontsov
  0 siblings, 1 reply; 5+ messages in thread
From: Pali Rohár @ 2012-01-20 13:38 UTC (permalink / raw)
  To: Grazvydas Ignotas; +Cc: Anton Vorontsov, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 521 bytes --]

On Friday 20 January 2012 13:02:46 Grazvydas Ignotas wrote:
> On Thu, Jan 19, 2012 at 12:56 PM, Pali Rohár <pali.rohar@gmail.com> wrote:
> > Now I do not have device with bq27500 chip for testing. I read datasheet
> > again and I think that your interpretation may be correct. Can you write
> > patch for this problem and test it?
> 
> What about just reverting 270968c0984ae instead? I think my patch
> would look almost exactly like that..

Ok, then revert this commit.

-- 
Pali Rohár
pali.rohar@gmail.com

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

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

* Re: bq27x00_battery status report issue
  2012-01-20 13:38     ` Pali Rohár
@ 2012-02-01 17:37       ` Anton Vorontsov
  0 siblings, 0 replies; 5+ messages in thread
From: Anton Vorontsov @ 2012-02-01 17:37 UTC (permalink / raw)
  To: Pali Rohár; +Cc: Grazvydas Ignotas, linux-kernel

On Fri, Jan 20, 2012 at 02:38:08PM +0100, Pali Rohár wrote:
> On Friday 20 January 2012 13:02:46 Grazvydas Ignotas wrote:
> > On Thu, Jan 19, 2012 at 12:56 PM, Pali Rohár <pali.rohar@gmail.com> wrote:
> > > Now I do not have device with bq27500 chip for testing. I read datasheet
> > > again and I think that your interpretation may be correct. Can you write
> > > patch for this problem and test it?
> > 
> > What about just reverting 270968c0984ae instead? I think my patch
> > would look almost exactly like that..
> 
> Ok, then revert this commit.

Reverted in battery-urgent.git, thanks!

-- 
Anton Vorontsov
Email: cbouatmailru@gmail.com

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

end of thread, other threads:[~2012-02-01 17:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-01-14 21:10 bq27x00_battery status report issue Grazvydas Ignotas
2012-01-19 10:56 ` Pali Rohár
2012-01-20 11:02   ` Grazvydas Ignotas
2012-01-20 13:38     ` Pali Rohár
2012-02-01 17:37       ` Anton Vorontsov

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).