battery2 git repository
Hi all,
David Woodhouse has been *very* kind enough to provide git repository for the battery stuff I've posted recently.
Much thanks, David!
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \git://git.infradead.org/users/cbou/battery2-2.6.git" command.
Now anyone interested can track changes and/or improve it.
As time will permit I'll port Apple PMU and OLPC drivers to new battery class.
Good luck,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 3 lines · Anton Vorontsov
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
thanks,
greg k-h
Quoted 8 lines · Greg KH
Quoted 3 lines · Anton Vorontsov
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
[ Of course David will answer for himself better. Below is what I'm
seeing. ]
David said he intend to port his OLPC and Apple PMU work to battery2 class implementation (and I volunteered to assist, i.e. port them myself ;-). So, when these two drivers will be ported, then there will no reasons for battery-2.6 existence anymore.
As for the competition... No competition took place at all, there was two parallel works, each for two *independent* projects (OLPC and handhelds.org). battery2 should be suitable for both.
David?
Quoted 3 lines
thanks,
greg k-h
Sincerely,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 3 lines · Greg KH
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
Anton hasn't pulled my changes -- it's a separate implementation, although very similar. In return for the account on git.infradead.org he said he was going to port the two drivers I already had (PMU and OLPC) to his framework.
I have no particular attachment to my own version. I'm perfectly happy just to use Anton's. Mine's still present just for reference, and hasn't actually been touched in months -- I haven't had the time.
Signature · 1 line
dwmw2
Quoted 2 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.
I added this to the -mm lineup.
Welcome to git. This means that nobody looks at your code any more and you get free rein to experiment with interesting innovations in VFS, MM and security in the mainline kernel (well, not really - Linus does squint at the diffstat).
But we do have a general problem that code which travels the developer->git->mainline route is not getting sufficient review. Please be aware of this, and be as pushy as you like in sending your changes out to mailing lists (including linux-kernel) to get them reviewed.
If you don't think they have received adequate review then send them again, and shout at people - we'd all admire that.
Thanks.
Quoted 7 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.
i386 `make allmodconfig':
ERROR: "battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined!
Quoted 10 lines · Andrew Morton
Quoted 7 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.
Quoted 6 lines
i386 `make allmodconfig':
ERROR: "
battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined!
:-/
It should be fixed 37 hours ago by
Should I ask git-pull when such fixes happens? And I wonder why it isn't already in -mm, because you've added this git repository after that commit...
Though, I'm doing "allmodconfig" once again, to be sure, it will take some time. (I've done defconfig, with modular W1, BATTERY, DS2760_BATTERY already, and error doesn't show up).
---
Also, much thanks for accepting it to the -mm.
I have one question though... battery2-2.6 have two branches, "linus" (clean Linus' tree) and "master" (with battery stuff).
When I'll want to sync battery tree with Linus' once again, should I just pull from linus, or it's better to rebase master against linus, and then "git push -f" to the battery2-2.6 master branch? Or it will break something on your side (as commits will change their hash)?
Thanks,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 18 lines · Anton Vorontsov
Quoted 10 lines · Andrew Morton
Quoted 7 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.Quoted 6 lines
i386 `make allmodconfig':
ERROR: "
battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined!
Quoted 5 lines
:-/
It should be fixed 37 hours ago by
[1]
Quoted 3 lines
Though, I'm doing "allmodconfig" once again, to be sure, it will take some time. (I've done defconfig, with modular W1, BATTERY,
DS2760_BATTERYalready, and error doesn't show up).
Finally allmodconfig finished (yup, my machine is old and slow), and no error happened. So, [1] should have been really fix this.
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 13 lines · Andrew Morton
Quoted 2 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.I added this to the -mm lineup.
Welcome to git. This means that nobody looks at your code any more and you get free rein to experiment with interesting innovations in VFS, MM and security in the mainline kernel (well, not really - Linus does squint at the diffstat).
Quoted 7 lines
But we do have a general problem that code which travels the
developer->git->mainlineroute is not getting sufficient review. Please be aware of this, and be as pushy as you like in sending your changes out to mailing lists (including linux-kernel) to get them reviewed.If you don't think they have received adequate review then send them again, and shout at people - we'd all admire that.
Heh. Yes, feel free to send me these patches to review, I don't mind.
thanks,
greg k-h
Quoted 9 lines · David Woodhouse
Quoted 3 lines · Greg KH
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
Anton hasn't pulled my changes -- it's a separate implementation, although very similar. In return for the account on git.infradead.org he said he was going to port the two drivers I already had (PMU and OLPC) to his framework.
Hopefully he took the driver model fixes you did. Anton, care to send a new set of patches, so we can review them?
thanks,
greg k-h
Quoted 6 lines · Greg KH
Quoted 5 lines · David Woodhouse
Quoted 3 lines · Greg KH
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
Quoted 6 lines
Quoted 4 lines
Anton hasn't pulled my changes -- it's a separate implementation, although very similar. In return for the account on git.infradead.org he said he was going to port the two drivers I already had (PMU and OLPC) to his framework.
Hopefully he took the driver model fixes you did.
Like class_device -> device transition? Yup.
Quoted 2 lines
Anton, care to send a
new set of patches, so we can review them?
Sure! But please let me do it tomorrow, to send it I need merge intermediate commits, and I'm in OLPC battery writing mood. ;-)
If cumulative "git diff linus" is acceptable, I can send it now.
Quoted 3 lines
thanks,
greg k-h
Good day,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 18 lines · On Sat, 28 Apr 2007 16:31:29 +0400 Anton Vorontsov <[email protected]> wrote:
Quoted 10 lines · Andrew Morton
Quoted 7 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.Quoted 6 lines
i386 `make allmodconfig':
ERROR: "
battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined!
Quoted 5 lines
:-/
It should be fixed 37 hours ago by
I had that. I just did a fresh fetch and it still happens
akpm2:/usr/src/25> cd /usr/src/git26
akpm2:/usr/src/git26> cat .git/branches/git-batterygit://git.infradead.org/users/cbou/battery2-2.6.git
akpm2:/usr/src/git26> git-fetch git-battery
akpm2:/usr/src/git26> git-checkout git-battery
Switched to branch "git-battery"
akpm2:/usr/src/git26> setenv ARCH i386
akpm2:/usr/src/git26> make allmodconfig > /dev/null
akpm2:/usr/src/git26> make vmlinux modules
...
WARNING: "battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined! make[1]: *** [__modpost] Error 1
Quoted 1 line
Should I ask git-pull when such fixes happens?
No thanks. I pull all the git trees approximately once per day.
Quoted 3 lines
And I wonder why it isn't
already in -mm, because you've added this git repository after that commit...
Yes, I had it all.
Quoted 4 lines
Though, I'm doing "allmodconfig" once again, to be sure, it will take some time. (I've done defconfig, with modular W1, BATTERY,
DS2760_BATTERYalready, and error doesn't show up).
You did `make vmlinux modules'?
Quoted 5 lines
Also, much thanks for accepting it to the -mm.
I have one question though... battery2-2.6 have two branches, "linus" (clean Linus' tree) and "master" (with battery stuff).
hm, I'm not using the "battery" branch. Should I?
akpm2:/usr/src/git26> cat .git/branches/git-batterygit://git.infradead.org/users/cbou/battery2-2.6.git
I triedgit://git.infradead.org/users/cbou/battery2-2.6.git#battery
but it doesn't exist.
Quoted 5 lines
When I'll want to sync battery tree with Linus' once again, should I just pull from linus, or it's better to rebase master against linus, and then "git push -f" to the battery2-2.6 master branch? Or it will break something on your side (as commits will change their hash)?
I always do `git-branch -d git-battery' prior to every pull, so rebasings like that are OK.
Quoted 20 lines · Andrew Morton
Quoted 18 lines · On Sat, 28 Apr 2007 16:31:29 +0400 Anton Vorontsov <[email protected]> wrote:
Quoted 16 lines · Andrew Morton
Quoted 7 lines · On Fri, 27 Apr 2007 03:29:02 +0400 Anton Vorontsov <[email protected]> wrote:
To not confuse with David own battery-2.6 repository, it's called battery2-2.6, and can be found here:
http://git.infradead.org/?p=users/cbou/battery2-2.6.git;a=summary
You can get it using "git clone --reference linux-2.6 \
git://git.infradead.org/users/cbou/battery2-2.6.git" command.i386 `make allmodconfig':
ERROR: "
battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
ERROR: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined!
Quoted 7 lines
Quoted 5 lines
:-/
It should be fixed 37 hours ago by
I had that. I just did a fresh fetch and it still happens
%-[ ]|floor
Andrew, I'm wondering if "make clean" would help...
I'm not lying, it works here. :-/
Quoted 9 lines
akpm2:/usr/src/25> cd
/usr/src/git26akpm2:/usr/src/git26> cat .git/branches/git-batterygit://git.infradead.org/users/cbou/battery2-2.6.git
akpm2:/usr/src/git26> git-fetch git-battery akpm2:/usr/src/git26> git-checkout git-battery Switched to branch "git-battery" akpm2:/usr/src/git26> setenv ARCH i386 akpm2:/usr/src/git26> make allmodconfig >/dev/nullakpm2:/usr/src/git26> make vmlinux modules
I've done these steps, 1:1, copy-pasted, assuming that git26 is Linus' tree.
So, I have:
cbou:~/linux-2.6$ git log --pretty=oneline | head -n 15 045e09c3c8c71d41e9b2d98f2781cf0fa19ac3f9 Apple PMU Battery Kconfig: should also depend on BATTERY 8a7c6667b37e9fe407f68c4a53b8ff90e375d06a pda_power: fix copy-paste artifact 5f2a90ceccd3cc25a607c5658e986d07aa660a40 apm_power: add ability to calculate capacity using energy ed2702e9eedb16c65017cbd1313fdc7ee3f2c5ff pmu_battery: Apple PMU battery initial commit d38e1fb5612d950d64d09b2513af85edaa696d71 battery: add "model_name" and "present" attributes cbb1e1b9e3a2cbf62ce4c13ef95d146ebc5e7274 battery: fix modular build c565f9872f7f84f5e62b5ec1c90f140d443b756c ds2760_battery: use less "#ifdefs" fe0c0cd7c0f98f479b2d2895194460139cec566a ds2760 W1 slave bbb555a9edc8c5610ec5351bf984b6477d7486d4 remove "#if 0" from find_bus function, export it. ed061df82fbbb6d2228e9d1d5051a6f70b6849bd 1-Wire ds2760 chip battery driver a3e39e1b92d5cbe4a51be5f33208868dcf14da35 APM emulation driver for class batteries 8f6b1c2027c967ac9fe69a2cca74a0e682189e5a Universal battery class fa1099f32ef0d2dc64b09a1de034167cf0db1f37 pda power driver a9d7bc2ccadd2b6cb7eee75664c73fb75c58fa08 External power framework de46c33745f5e2ad594c72f2cf5f490861b16ce1 Linux 2.6.21
cbou:~/linux-2.6$ git status # On branch git-battery nothing to commit (working directory clean)
Quoted 6 lines
....
WARNING: "battery_is_external_power_supplied" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_unregister" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_register" [drivers/battery/ds2760_battery.ko] undefined!
WARNING: "battery_status_changed" [drivers/battery/ds2760_battery.ko] undefined! make[1]: *** [__modpost] Error 1
And logs:
cbou:~/linux-2.6$ export ARCH=i386 cbou:~/linux-2.6$ make allmodconfig > /dev/null cbou:~/linux-2.6$ make vmlinux modules ... CC [M] drivers/battery/battery_core.o CC [M] drivers/battery/battery_sysfs.o CC [M] drivers/battery/battery_leds.o LD [M] drivers/battery/battery.o CC [M] drivers/battery/ds2760_battery.o LD drivers/block/built-in.o CC [M] drivers/block/floppy.o ... LD drivers/power/built-in.o CC [M] drivers/power/external_power.o CC [M] drivers/power/pda_power.o ... CC drivers/battery/battery.mod.o LD [M] drivers/battery/battery.ko CC drivers/battery/ds2760_battery.mod.o LD [M] drivers/battery/ds2760_battery.ko CC drivers/block/DAC960.mod.o LD [M] drivers/block/DAC960.ko CC drivers/block/aoe/aoe.mod.o ... CC drivers/power/external_power.mod.o LD [M] drivers/power/external_power.ko CC drivers/power/pda_power.mod.o LD [M] drivers/power/pda_power.ko ... LD [M] sound/usb/snd-usb-lib.ko CC sound/usb/usx2y/snd-usb-usx2y.mod.o LD [M] sound/usb/usx2y/snd-usb-usx2y.ko cbou:~/linux-2.6$
Here is my setup:
cbou:~$ make -v GNU Make 3.81 Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
This program built for i686-pc-linux-gnu
cbou:~$ gcc -v Using built-in specs. Target: i686-pc-linux-gnu Configured with: ../gcc-4.1.2/configure --prefix=/usr --libexecdir=/usr/lib --enable-languages=c,c++ --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-shared --disable-nls --with-x=no Thread model: posix gcc version 4.1.2 (CRUX)
cbou:~$ ld -v GNU ld version 2.17.50.0.12 20070128
Quoted 6 lines
Quoted 4 lines
Though, I'm doing "allmodconfig" once again, to be sure, it will take some time. (I've done defconfig, with modular W1, BATTERY,
DS2760_BATTERYalready, and error doesn't show up).You did `make vmlinux modules'?
No, previously I did "make", i.e. "all" target. It's should be exactly vmlinux and modules.. But now, I just copy-pasted your steps, and done exactly what you've done. No errors.
Quoted 4 lines
Quoted 2 lines
I have one question though... battery2-2.6 have two branches, "linus" (clean Linus' tree) and "master" (with battery stuff).
hm, I'm not using the "battery" branch. Should I?
No no. There is no "battery" branch, only "master" and "linus". Default is "master", and "linus" is just clean Linus' tree. So everything is correct.
Quoted 8 lines
Quoted 5 lines
When I'll want to sync battery tree with Linus' once again, should I just pull from linus, or it's better to rebase master against linus, and then "git push -f" to the battery2-2.6 master branch? Or it will break something on your side (as commits will change their hash)?
I always do `git-branch -d git-battery' prior to every pull, so rebasings like that are OK.
Nice, thanks!
Sincerely,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2
Quoted 6 lines · Greg KH
Quoted 5 lines · David Woodhouse
Quoted 3 lines · Greg KH
So, I'm still not quite understanding this, is David giving up on his code now that you have pulled his changes into your tree? Or is there some reason there are still two competing versions here?
Quoted 7 lines
Quoted 4 lines
Anton hasn't pulled my changes -- it's a separate implementation, although very similar. In return for the account on git.infradead.org he said he was going to port the two drivers I already had (PMU and OLPC) to his framework.
Hopefully he took the driver model fixes you did. Anton, care to send a new set of patches, so we can review them?
Okay... Today in IRC conversation David came to conclusion that we can merge "external_power" and "battery" meanings, thus merge these classes.
So, new set of patches will delay a bit more... how long is depends on David and further testing on real world devices. I'm still in hope that we'll be in time for 2.6.22.
Quoted 3 lines
thanks,
greg k-h
Thanks,
Signature · 4 lines
Anton Vorontsov email: [email protected] backup email: [email protected] irc://irc.freenode.org/bd2