lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 25 Apr 2012 22:01:49 +0530
From:	Jassi Brar <jaswinder.singh@...aro.org>
To:	Ulf Hansson <ulf.hansson@...ricsson.com>
Cc:	Mark Brown <broonie@...nsource.wolfsonmicro.com>,
	Liam Girdwood <lrg@...mlogic.co.uk>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Mattias WALLIN <mattias.wallin@...ricsson.com>,
	Jonas ABERG <jonas.aberg@...ricsson.com>,
	Lee Jones <lee.jones@...aro.org>
Subject: Re: [PATCH] regulator: core: Keep boot_on regulators powered during init

On 25 April 2012 21:14, Ulf Hansson <ulf.hansson@...ricsson.com> wrote:
> On 04/25/2012 05:34 PM, Jassi Brar wrote:
>>>
>>  Shouldn't the bootloader be responsible for ensuring MMC is
>> put down after using it and before passing control to the kernel.
>
> This is kind of complicated. eMMC is powered by two regulators. VCC and
> VCCQ. Cutting VCC uncontrolled is not allowed. If doing so anyway there is
> two options to recover.
>
> 1. Cut VCCQ as well and do full reinit of the eMMC
> 2. Pull a hw-reset pin to the eMMC and do a full reinit of the eMMC.
>
> In some cases neither is possible due to HW constraints. Thus we have to
> make sure VCC is not cut.
>
I meant power-down to whatever extent your h/w permits. The rest you'll
have to take care by appropriately flagging supplies in the kernel.

If not full power-off, couldn't your bootloader atleast send eMMC the necessary
"power-down sequence of commands", so that it responds well to next
power-up sequence of commands ?

The point being, the board files, in both your bootloader and kernel, ought to
know the h/w constraints and program the regulator api accordingly.

Generalizing the case, IMHO it's not feasible for every stack in the kernel to
assume it has to first cleanly shutdown the h/w before probing it.

>>  Even if the bootloader didn't power off properly, unless there is
>> some outstanding data to be written when the kernel is passed
>> control, perhaps it's not that serious?
>
> The kernel will not be to re-init the eMMC... quite serious. :-)
>
Not unless your board files flag the supplies accordingly, always_on,
and the bootloader sent eMMC the "deadly command seq" ;)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ