On Tue, Jun 03, 2014 at 02:26:24PM -0400, Vivek Goyal wrote:
[..]
> elif [ "$force_rebuild" != "0" ]; then
> - echo -n "Force rebuild $kdump_initrd"; echo
> + if [ $DUMP_MODE == "kdump" ]; then
> + echo -n "Force rebuild $kdump_initrd"; echo
> + else
> + echo -n "Force rebuild $default_initrd with fadump support"; echo
> + fi
This nested if block looks horrible. This needs to be simplified.
Why do we need to give two different messages. Why not just say.
echo -n "Force rebuild $kdump_initrd".
And initialize kdump_initrd to eitehr fadump or kdump initrd based on
dump mode.
In fact we could call the variable "target_initrd" which could represent
either kdump intird or fadump initrd depdning on mode and should be
set early during initialization.
Thanks
Vivek