Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1310450

Re: [PATCH v2 2/4] power: reset: add reboot mode driver

From John Stultz <john.stultz@linaro.org>
Newsgroups linux.kernel
Subject Re: [PATCH v2 2/4] power: reset: add reboot mode driver
Date 2016-01-15 21:30 +0100
Message-ID <qRjar-2FM-23@gated-at.bofh.it> (permalink)
References <qQ5jc-cc-29@gated-at.bofh.it> <qQ5sT-fW-27@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Jan 12, 2016 at 3:31 AM, Andy Yan <andy.yan@rock-chips.com> wrote:
> 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>


Hey Andy!
  Thanks for keeping this work going! I've just successfully reworked
my Nexus7 tree to use your implementation (using the syscon version,
setting up a syscon for IMEM as Bjorn had requested earlier).

All is working well so far!

The one thing I was working on supporting with my own version that
seems to be missing here are for devices that use string based codes,
rather then magic numbers.

This was mostly a theoretical issue. I think the Galaxy Nexus used it,
and when I was looking at some of the HTC devices, they support a text
based reason along with the magic code, but at least in some
implementations the text mode isn't used, so I suspect there its just
for extra debugging.  So this may not be critical to solve until
someone tries to add support for such a device.

Anyway, I'm going to look at porting this to the HiKey board next
(which just uses reserved ram, not syscon), so I'll try to do a an
SRAM driver implementaiton to see how that goes.

thanks!
-john

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2 0/4] add reboot mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-12 12:30 +0100
  [PATCH v2 3/4] ARM: dts: rockchip: add syscon-reboot-mode node Andy Yan <andy.yan@rock-chips.com> - 2016-01-12 12:40 +0100
    Re: [PATCH v2 3/4] ARM: dts: rockchip: add syscon-reboot-mode node Matthias Brugger <matthias.bgg@gmail.com> - 2016-01-21 09:40 +0100
  [PATCH v2 4/4] ARM64: dts: rockchip: add syscon-reboot-mode DT node Andy Yan <andy.yan@rock-chips.com> - 2016-01-12 12:40 +0100
  [PATCH v2 2/4] power: reset: add reboot mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-12 12:40 +0100
    Re: [PATCH v2 2/4] power: reset: add reboot mode driver John Stultz <john.stultz@linaro.org> - 2016-01-15 21:30 +0100
      Re: [PATCH v2 2/4] power: reset: add reboot mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-19 09:40 +0100
    Re: [PATCH v2 2/4] power: reset: add reboot mode driver Matthias Brugger <matthias.bgg@gmail.com> - 2016-01-21 09:40 +0100
    Re: [PATCH v2 2/4] power: reset: add reboot mode driver Moritz Fischer <moritz.fischer@ettus.com> - 2016-01-27 12:00 +0100
  [PATCH v2 1/4] dt-bindings: power: reset: add document for reboot-mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-12 12:40 +0100
    Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver John Stultz <john.stultz@linaro.org> - 2016-01-15 23:50 +0100
      Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-19 09:40 +0100
    Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Rob Herring <robh@kernel.org> - 2016-01-20 19:30 +0100
      Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver John Stultz <john.stultz@linaro.org> - 2016-01-20 19:50 +0100
        Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Rob Herring <robh@kernel.org> - 2016-01-20 21:00 +0100
          Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver John Stultz <john.stultz@linaro.org> - 2016-01-20 21:30 +0100
      Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-21 07:30 +0100
        Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Rob Herring <robh@kernel.org> - 2016-01-25 18:20 +0100
          Re: [PATCH v2 1/4] dt-bindings: power: reset: add document for  reboot-mode driver Andy Yan <andy.yan@rock-chips.com> - 2016-01-26 08:40 +0100
  Re: [PATCH v2 0/4] add reboot mode driver Caesar Wang <caesar.upstream@gmail.com> - 2016-01-13 03:20 +0100

csiph-web