Changes between Version 7 and Version 8 of FlattenedDeviceTree


Ignore:
Timestamp:
Nov 24, 2009, 3:58:10 PM (14 years ago)
Author:
Nicolas Pouillon
Comment:

IRQ syntax change

Legend:

Unmodified
Added
Removed
Modified
  • FlattenedDeviceTree

    v7 v8  
    4444There is a couple of optional attributes:
    4545
    46  `ipi_icudev`::
    47    This is a reference to the ICU device handling IPIs for this CPU
    48  `ipi_no`::
    49    This is the IPI register number in the said ICU device.
     46 `ipi`::
     47   This is a reference to the ICU device handling IPIs for this CPU, and the ipi number, like
     48   {{{
     49ipi = <&{/xicu@0/out@2} 2>;
     50   }}}
    5051
    5152== Memories ==
     
    7576
    7677Interrupts controller are referenced from one node to another in order to describe the interrupt tree. References are handled through the following properties:
    77  `icudev`::
    78    Must be a path to an existing ICU device, enclosing in `&{}` is syntactic
    7978 `irq`::
    80    Is the irq number in `icudev`.
     79   Must be a path to an existing ICU device, and the icu irq number, enclosed in `<&{path} no>`. This syntax is mandatory. Example:
     80   {{{
     81irq = <&{/cpus/Mips,32@0} 0>;
     82}}}
    8183
    8284Example:
     
    8688        input_count = <2>;
    8789        reg = <0x20600000 0x20>;
    88         icudev = &{/cpus/Mips,32@0};
    89         irq = <0>;
     90        irq = <&{/cpus/Mips,32@0} 0>;
    9091};
    9192
     
    9495        tty_count = <1>;
    9596        reg = <0x90600000 0x10>;
    96         icudev = &{/icu@0};
    97         irq = <1>;
     97        irq = <&{/icu@0} 1>;
    9898};
    9999}}}
     
    126126
    127127{{{
    128 struct soclib_xicu_param_s
    129 {
    130         size_t output_line_no;
     128struct xicu_root_param_s
     129{
     130        size_t input_lines;
     131        size_t ipis;
     132        size_t timers;
    131133};
    132134}}}
     
    134136In the driver, the id definition is:
    135137{{{
    136 static const struct driver_param_binder_s xicu_param_binder[] =
    137 {
    138         PARAM_BIND(struct soclib_xicu_param_s, output_line_no, PARAM_DATATYPE_INT),
    139         { 0 }
    140 };
    141 
    142 static const struct devenum_ident_s     xicu_soclib_ids[] =
    143 {
    144         DEVENUM_FDTNAME_ENTRY("soclib:xicu", sizeof(struct soclib_xicu_param_s), xicu_param_binder),
    145         { 0 }
     138static const struct driver_param_binder_s xicu_root_binder[] =
     139{
     140        PARAM_BIND(struct xicu_root_param_s, input_lines, PARAM_DATATYPE_INT),
     141        PARAM_BIND(struct xicu_root_param_s, ipis, PARAM_DATATYPE_INT),
     142        PARAM_BIND(struct xicu_root_param_s, timers, PARAM_DATATYPE_INT),
     143        { 0 }
     144};
     145
     146static const struct devenum_ident_s     xicu_root_ids[] =
     147{
     148        DEVENUM_FDTNAME_ENTRY("soclib:xicu:root", sizeof(struct xicu_root_param_s), xicu_root_binder),
     149        { 0 }
    146150};
    147151}}}
     
    170174        tty_count = <1>;
    171175        reg = <0x90600000 0x10>;
    172         icudev = &{/icu@0};
    173         irq = <1>;
     176        irq = <&{/icu@0} 1>;
    174177};
    175178}}}