Re: [uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-09 Thread Pavel Machek
Hi! > +/** > + * register_poweroff_handler_simple - Register function to be called to > power off > + * the system > + * @handler: Function to be called to power off the system > + * @priority: Handler priority. For priority guidelines see > +

Re: [uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-09 Thread Guenter Roeck
On Thu, Oct 09, 2014 at 12:31:43PM +0200, Pavel Machek wrote: > Hi! > > > +/** > > + * register_poweroff_handler_simple - Register function to be called to > > power off > > + *the system > > + * @handler: Function to be called to power off the system > >

Re: [uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-09 Thread Guenter Roeck
On 10/09/2014 04:31 AM, Geert Uytterhoeven wrote: > On Tue, Oct 7, 2014 at 7:28 AM, Guenter Roeck wrote: >> +int register_poweroff_handler_simple(void (*handler)(void), int priority) >> +{ >> + char symname[KSYM_NAME_LEN]; >> + >> + if (poweroff_handler_data.handler) { >> +

Re: [uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-09 Thread Geert Uytterhoeven
On Tue, Oct 7, 2014 at 7:28 AM, Guenter Roeck wrote: > +int register_poweroff_handler_simple(void (*handler)(void), int priority) > +{ > + char symname[KSYM_NAME_LEN]; > + > + if (poweroff_handler_data.handler) { > + lookup_symbol_name((unsigned > long)poweroff_handler_d

[uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-07 Thread Guenter Roeck
Various drivers implement architecture and/or device specific means to remove power from the system. For the most part, those drivers set the global variable pm_power_off to point to a function within the driver. This mechanism has a number of drawbacks. Typically only one scheme to remove power

Re: [uml-devel] [PATCH 01/44] kernel: Add support for poweroff handler call chain

2014-10-07 Thread Philippe Rétornaz
Hello This seems exactly what I would need on the mc13783 to handle cleanly the poweroff, but after reading this patchset I have the following question: [...] > +/* > + * Notifier list for kernel code which wants to be called > + * to power off the system. > + */ > +static ATOMIC_NOTIFIER_H