[RFC PATCH 3/7] bootm: add kexec ELF support

Antony Pavlov antonynpavlov at gmail.com
Fri May 4 06:09:28 PDT 2018


On Fri, 4 May 2018 11:53:48 +0200
Oleksij Rempel <linux at rempel-privat.de> wrote:

> Am 04.05.2018 um 12:08 schrieb Antony Pavlov:
> > On Fri, 4 May 2018 07:54:08 +0200
> > Sascha Hauer <s.hauer at pengutronix.de> wrote:
> > 
> >> On Sun, Apr 29, 2018 at 03:09:03PM +0200, Oleksij Rempel wrote:
> >>> +static int do_bootm_elf(struct image_data *data)
> >>> +{
> >>> +	kexec_load_bootm_data(data);
> >>> +
> >>> +	reboot(LINUX_REBOOT_CMD_KEXEC, data);
> >>> +
> >>> +	return -ERESTARTSYS;
> >>> +}
> >>> +
> >>
> >> I can't really judge this series. This is the only thing I stumbled
> >> upon: I see no reason to name the architecture specific kexec function
> >> 'reboot'. I would expect some kexec specific name, like arch_kexec or
> >> similar.
> >>
> > 
> > This reboot function is copy-n-paste from linux kernel reboot syscall (see linux/kernel/reboot.c
> > for details).
> > At the moment there is only one constant for reboot()'s first argument (LINUX_REBOOT_CMD_KEXEC),
> > so it's reasonable to elimenate this first argument and rename function to kexec_reboot().
> 
> amy be better to rename it to kexec_arch or kexec_mach. kexec_reboot is
> kind if misleading

Linux uses machine_kexec(struct kimage *image) in arch/mips/kernel/machine_kexec.c.

-- 
Best regards,
  Antony Pavlov



More information about the barebox mailing list