FROMLIST: power: reset: add reboot mode driver

This driver parse the reboot commands like "reboot loader"
and "reboot recovery" to get a boot mode described in the
device tree , then call the write interfae to store the boot
mode in some persistent storage  like special register or ram,
which can be read by the bootloader after system reboot, then
the bootloader can take different action according to the mode
stored.

This is commonly used on Android based devices, which in order
to reboot the device into fastboot or recovery mode.

Signed-off-by: Andy Yan <andy.yan@rock-chips.com>

Conflicts:
drivers/power/reset/Makefile
drivers/power/reset/Kconfig

Bug: 25923642
Patchset: reboot mode PATCH[2/4], reboot fastboot can work.

(am https://patchwork.kernel.org/patch/8016401/)
Signed-off-by: Caesar Wang <wxt@rock-chips.com>
Change-Id: Ibcd3b893fa1895503b8f51ac16a4d5068620a604
5 files changed