[Gta04-owner] 3.7-kernel: poweroff?

Dr. H. Nikolaus Schaller hns at goldelico.com
Fri Feb 22 08:55:11 CET 2013

Am 22.02.2013 um 02:01 schrieb NeilBrown:

> On Thu, 21 Feb 2013 14:06:17 +0100 "Dr. H. Nikolaus Schaller"
> <hns at goldelico.com> wrote:
>> Hi Neil,
>> I am not sure if I have broken something or if it is not implemented, but I found that "poweroff" does not power off... the console prints "Halt" and the red power LED remains on.
>> I remember that I had a patch for the hw-validation kernel because the default implementation of Linux just ends in a loop but does not notify the TPS65950.
> Works for me...
> I use "poweroff -f" because I don't trust the shutdown scripts, and I don't
> really care about running them. 
>    poweroff -f
> just calls sync() and then the 'reboot' system call with flags to say 'power
> off'.
> Console reports:
> [  365.998046] Power down.

This is missing with my extended kernel.

> and all the LEDs (which it had turned on with
>   for i in /sys/class/leds/*/trigger; do echo default-on > $i; done
> ) turned off.
> This is enabled by code in drivers/mfd/twl4030-power.c, particularly:
> 		pm_power_off = twl4030_power_off;
> which sets the power-off handler.
> This is in mainline since commit 26cc3ab984cd00e95cb58ba5aaea4238ea56c700
> which was in linux-3.3.
> So I suggest testing if "poweroff -f" works.  If it does, then examine your
> init scripts.  If it doesn't, then check if "twl4030_power_off" is getting
> called.
> I just tried "poweroff" (no flags) on my (Debian) phone and it does work.
> It goes through
> [ ok ] Unmounting temporary filesystems...done.
> [ ok ] Deactivating swap...done.
> [ ok ] Unmounting local filesystems...done.
> [info] Will now halt.

After that it hangs.

> and then
> [  115.671386] Power down.
> and power is indeed down.

So I must have some driver that is not properly unloading.
Maybe PVR or Camera (stub) driver.

Apropos Camera. I have found that we will have to mix code from 3 drivers:
* mt9p031 - because it is known to work on the BeagleBoard XM and uses the v4l2 subdevice framework
* ov9655 - because we use this chip and have it partially working on 2.6.32
* ov7670 - because it is in the mainline kernel and quite similar (but does not use the subdevices interface)


More information about the Gta04-owner mailing list