16be33864SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 26be33864SEmmanuel Vadot%YAML 1.2 36be33864SEmmanuel Vadot--- 46be33864SEmmanuel Vadot$id: http://devicetree.org/schemas/power/reset/reboot-mode.yaml# 56be33864SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 66be33864SEmmanuel Vadot 76be33864SEmmanuel Vadottitle: Generic reboot mode core map 86be33864SEmmanuel Vadot 96be33864SEmmanuel Vadotmaintainers: 106be33864SEmmanuel Vadot - Andy Yan <andy.yan@rock-chips.com> 116be33864SEmmanuel Vadot 126be33864SEmmanuel Vadotdescription: | 136be33864SEmmanuel Vadot This driver get reboot mode arguments and call the write 146be33864SEmmanuel Vadot interface to store the magic value in special register 156be33864SEmmanuel Vadot or ram. Then the bootloader can read it and take different 166be33864SEmmanuel Vadot action according to the argument stored. 176be33864SEmmanuel Vadot 186be33864SEmmanuel Vadot All mode properties are vendor specific, it is a indication to tell 196be33864SEmmanuel Vadot the bootloader what to do when the system reboots, and should be named 206be33864SEmmanuel Vadot as mode-xxx = <magic> (xxx is mode name, magic should be a non-zero value). 216be33864SEmmanuel Vadot 226be33864SEmmanuel Vadot For example, modes common Android platform are: 236be33864SEmmanuel Vadot - normal: Normal reboot mode, system reboot with command "reboot". 246be33864SEmmanuel Vadot - recovery: Android Recovery mode, it is a mode to format the device or update a new image. 256be33864SEmmanuel Vadot - bootloader: Android fastboot mode, it's a mode to re-flash partitions on the Android based device. 266be33864SEmmanuel Vadot - loader: A bootloader mode, it's a mode used to download image on Rockchip platform, 276be33864SEmmanuel Vadot usually used in development. 286be33864SEmmanuel Vadot 296be33864SEmmanuel Vadotproperties: 306be33864SEmmanuel Vadot mode-normal: 316be33864SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 326be33864SEmmanuel Vadot description: 336be33864SEmmanuel Vadot Default value to set on a reboot if no command was provided. 346be33864SEmmanuel Vadot 356be33864SEmmanuel VadotpatternProperties: 366be33864SEmmanuel Vadot "^mode-.*$": 376be33864SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 386be33864SEmmanuel Vadot 39*354d7675SEmmanuel VadotadditionalProperties: true 406be33864SEmmanuel Vadot 416be33864SEmmanuel Vadotexamples: 426be33864SEmmanuel Vadot - | 436be33864SEmmanuel Vadot reboot-mode { 446be33864SEmmanuel Vadot mode-normal = <0>; 456be33864SEmmanuel Vadot mode-recovery = <1>; 466be33864SEmmanuel Vadot mode-bootloader = <2>; 476be33864SEmmanuel Vadot mode-loader = <3>; 486be33864SEmmanuel Vadot }; 496be33864SEmmanuel Vadot... 50