The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/contrib/device-tree/Bindings/power/reset/gpio-restart.txt

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 Drive a GPIO line that can be used to restart the system from a restart
    2 handler.
    3 
    4 This binding supports level and edge triggered reset.  At driver load
    5 time, the driver will request the given gpio line and install a restart
    6 handler. If the optional properties 'open-source' is not found, the GPIO line
    7 will be driven in the inactive state.  Otherwise its not driven until
    8 the restart is initiated.
    9 
   10 When the system is restarted, the restart handler will be invoked in
   11 priority order.  The gpio is configured as an output, and driven active,
   12 triggering a level triggered reset condition. This will also cause an
   13 inactive->active edge condition, triggering positive edge triggered
   14 reset. After a delay specified by active-delay, the GPIO is set to
   15 inactive, thus causing an active->inactive edge, triggering negative edge
   16 triggered reset. After a delay specified by inactive-delay, the GPIO
   17 is driven active again.  After a delay specified by wait-delay, the
   18 restart handler completes allowing other restart handlers to be attempted.
   19 
   20 Required properties:
   21 - compatible : should be "gpio-restart".
   22 - gpios : The GPIO to set high/low, see "gpios property" in
   23   Documentation/devicetree/bindings/gpio/gpio.txt. If the pin should be
   24   low to reset the board set it to "Active Low", otherwise set
   25   gpio to "Active High".
   26 
   27 Optional properties:
   28 - open-source : Treat the GPIO as being open source and defer driving
   29   it to when the restart is initiated.  If this optional property is not
   30   specified, the GPIO is initialized as an output in its inactive state.
   31 - priority : A priority ranging from 0 to 255 (default 128) according to
   32   the following guidelines:
   33         0:      Restart handler of last resort, with limited restart
   34                 capabilities
   35         128:    Default restart handler; use if no other restart handler is
   36                 expected to be available, and/or if restart functionality is
   37                 sufficient to restart the entire system
   38         255:    Highest priority restart handler, will preempt all other
   39                 restart handlers
   40 - active-delay: Delay (default 100) to wait after driving gpio active [ms]
   41 - inactive-delay: Delay (default 100) to wait after driving gpio inactive [ms]
   42 - wait-delay: Delay (default 3000) to wait after completing restart
   43   sequence [ms]
   44 
   45 Examples:
   46 
   47 gpio-restart {
   48         compatible = "gpio-restart";
   49         gpios = <&gpio 4 0>;
   50         priority = <128>;
   51         active-delay = <100>;
   52         inactive-delay = <100>;
   53         wait-delay = <3000>;
   54 };

Cache object: 31271b9e42f1e80e3a3a39c47a5e957a


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.