1. 13 Sep, 2019 2 commits
    • Uwe Kleine-König's avatar
      of: Let of_for_each_phandle fallback to non-negative cell_count · e42ee610
      Uwe Kleine-König authored
      Referencing device tree nodes from a property allows to pass arguments.
      This is for example used for referencing gpios. This looks as follows:
      
      	gpio_ctrl: gpio-controller {
      		#gpio-cells = <2>
      		...
      	}
      
      	someothernode {
      		gpios = <&gpio_ctrl 5 0 &gpio_ctrl 3 0>;
      		...
      	}
      
      To know the number of arguments this must be either fixed, or the
      referenced node is checked for a $cells_name (here: "#gpio-cells")
      property and with this information the start of the second reference can
      be determined.
      
      Currently regulators are referenced with no additional arguments. To
      allow some optional arguments without having to change all referenced
      nodes this change introduces a way to specify a default cell_count. So
      when a phandle is parsed we check for the $cells_name property and use
      it as before if present. If it is not present we fall back to
      cells_count if non-negative and only fail if cells_count is smaller than
      zero.
      Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      e42ee610
    • Uwe Kleine-König's avatar
      iommu: pass cell_count = -1 to of_for_each_phandle with cells_name · c680e9ab
      Uwe Kleine-König authored
      Currently of_for_each_phandle ignores the cell_count parameter when a
      cells_name is given. I intend to change that and let the iterator fall
      back to a non-negative cell_count if the cells_name property is missing
      in the referenced node.
      
      To not change how existing of_for_each_phandle's users iterate, fix them
      to pass cell_count = -1 when also cells_name is given which yields the
      expected behaviour with and without my change.
      Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
      Acked-by: default avatarJoerg Roedel <jroedel@suse.de>
      Signed-off-by: default avatarRob Herring <robh@kernel.org>
      c680e9ab
  2. 11 Sep, 2019 2 commits
  3. 06 Sep, 2019 2 commits
  4. 03 Sep, 2019 1 commit
  5. 02 Sep, 2019 6 commits
  6. 29 Aug, 2019 1 commit
  7. 28 Aug, 2019 3 commits
  8. 27 Aug, 2019 5 commits
  9. 21 Aug, 2019 3 commits
  10. 20 Aug, 2019 5 commits
  11. 16 Aug, 2019 1 commit
  12. 15 Aug, 2019 2 commits
  13. 13 Aug, 2019 7 commits