Thread (24 messages) 24 messages, 3 authors, 2019-01-10

Re: [PATCH v4 01/15] ARM: export arm_pm_restart()

From: Lubomir Rintel <lkundrak@v3.sk>
Date: 2019-01-09 07:24:19
Also in: linux-devicetree, linux-pm, lkml, platform-driver-x86

On Tue, 2019-01-08 at 23:31 +0000, Russell King - ARM Linux wrote:
On Tue, Jan 08, 2019 at 06:58:04PM +0100, Lubomir Rintel wrote:
quoted
The OLPC XO 1.75 laptop is rebooted with a command to the Embedded
Controller. The EC driver should be a module, since most people don't need
it to be compiled in.
Why do you need this - is there a reason why you can't hook onto the
restart_handler_list using register_restart_handler()?  The registered
handlers are passed the command.
Actually, yes. The restart handlers are invoked in atomic context, but
the EC communication needs to block. (The 1.75 EC is actually a SPI
master: a command it initiated by poking a GPIO and waiting until EC
tells us it's ready to read a command.)

Sorry for not mentioning that earlier, I forgot that it is the case.
I would rather this is not exported to modules, it is generally unsafe
to hook stuff by directly poking function pointers from module code.
Lubo


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help