1. 23 5月, 2017 1 次提交
  2. 09 5月, 2017 1 次提交
  3. 05 5月, 2017 4 次提交
    • R
      of: fix sparse warnings in fdt, irq, reserved mem, and resolver code · 17a70355
      Rob Herring 提交于
      sparse generates the following warnings in drivers/of/:
      
      ../drivers/of/fdt.c:63:36: warning: cast to restricted __be32
      ../drivers/of/fdt.c:68:33: warning: cast to restricted __be32
      ../drivers/of/irq.c:105:88: warning: incorrect type in initializer (different base types)
      ../drivers/of/irq.c:105:88:    expected restricted __be32
      ../drivers/of/irq.c:105:88:    got int
      ../drivers/of/irq.c:526:35: warning: incorrect type in assignment (different modifiers)
      ../drivers/of/irq.c:526:35:    expected int ( *const [usertype] irq_init_cb )( ... )
      ../drivers/of/irq.c:526:35:    got void const *const data
      ../drivers/of/of_reserved_mem.c:200:50: warning: incorrect type in initializer (different modifiers)
      ../drivers/of/of_reserved_mem.c:200:50:    expected int ( *[usertype] initfn )( ... )
      ../drivers/of/of_reserved_mem.c:200:50:    got void const *const data
      ../drivers/of/resolver.c:95:42: warning: incorrect type in assignment (different base types)
      ../drivers/of/resolver.c:95:42:    expected unsigned int [unsigned] [usertype] <noident>
      ../drivers/of/resolver.c:95:42:    got restricted __be32 [usertype] <noident>
      
      All these are harmless type mismatches fixed by adjusting the types.
      Signed-off-by: NRob Herring <robh@kernel.org>
      17a70355
    • R
      of: fix sparse warning in of_pci_range_parser_one · eb310036
      Rob Herring 提交于
      sparse gives the following warning for 'pci_space':
      
      ../drivers/of/address.c:266:26: warning: incorrect type in assignment (different base types)
      ../drivers/of/address.c:266:26:    expected unsigned int [unsigned] [usertype] pci_space
      ../drivers/of/address.c:266:26:    got restricted __be32 const [usertype] <noident>
      
      It appears that pci_space is only ever accessed on powerpc, so the endian
      swap is often not needed.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: NRob Herring <robh@kernel.org>
      eb310036
    • R
      of: fix sparse warnings in of_find_next_cache_node · 91d96749
      Rob Herring 提交于
      sparse gives a warning that 'handle' is not a __be32:
      
      ../drivers/of/base.c:2261:61: warning: incorrect type in argument 1 (different base types)
      ../drivers/of/base.c:2261:61:    expected restricted __be32 const [usertype] *p
      ../drivers/of/base.c:2261:61:    got unsigned int const [usertype] *[assigned] handle
      
      We could just change the type, but the code can be improved by using
      of_parse_phandle instead of open coding it with of_get_property and
      of_find_node_by_phandle.
      Signed-off-by: NRob Herring <robh@kernel.org>
      91d96749
    • D
      of/unittest: Missing unlocks on error · 8756cd1d
      Dan Carpenter 提交于
      Static checkers complain that we should unlock before returning.  Which
      is true.
      Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
      Reviewed-by: NFrank Rowand <frank.rowand@sony.com>
      Signed-off-by: NRob Herring <robh@kernel.org>
      8756cd1d
  4. 03 5月, 2017 1 次提交
  5. 29 4月, 2017 1 次提交
  6. 28 4月, 2017 1 次提交
  7. 25 4月, 2017 1 次提交
    • R
      mdio_bus: Issue GPIO RESET to PHYs. · 69226896
      Roger Quadros 提交于
      Some boards [1] leave the PHYs at an invalid state
      during system power-up or reset thus causing unreliability
      issues with the PHY which manifests as PHY not being detected
      or link not functional. To fix this, these PHYs need to be RESET
      via a GPIO connected to the PHY's RESET pin.
      
      Some boards have a single GPIO controlling the PHY RESET pin of all
      PHYs on the bus whereas some others have separate GPIOs controlling
      individual PHY RESETs.
      
      In both cases, the RESET de-assertion cannot be done in the PHY driver
      as the PHY will not probe till its reset is de-asserted.
      So do the RESET de-assertion in the MDIO bus driver.
      
      [1] - am572x-idk, am571x-idk, a437x-idk
      Signed-off-by: NRoger Quadros <rogerq@ti.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      69226896
  8. 20 4月, 2017 4 次提交
  9. 19 4月, 2017 1 次提交
  10. 03 4月, 2017 1 次提交
  11. 23 3月, 2017 1 次提交
    • R
      of: Add function for generating a DT modalias with a newline · 0634c295
      Rob Herring 提交于
      The modalias sysfs attr is lacking a newline for DT aliases on platform
      devices. The macio and ibmebus correctly add the newline, but open code it.
      Introduce a new function, of_device_modalias(), that fills the buffer with
      the modalias including the newline and update users of the old
      of_device_get_modalias function.
      Signed-off-by: NRob Herring <robh@kernel.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: Frank Rowand <frowand.list@gmail.com>
      Cc: linuxppc-dev@lists.ozlabs.org
      Acked-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      0634c295
  12. 22 3月, 2017 1 次提交
    • R
      of: fix of_device_get_modalias returned length when truncating buffers · bcf54d53
      Rob Herring 提交于
      If the length of the modalias is greater than the buffer size, then the
      modalias is truncated. However the untruncated length is returned which
      will cause an error. Fix this to return the truncated length. If an error
      in the case was desired, then then we should just return -ENOMEM.
      
      The reality is no device will ever have 4KB of compatible strings to hit
      this case.
      Signed-off-by: NRob Herring <robh@kernel.org>
      Cc: Frank Rowand <frowand.list@gmail.com>
      bcf54d53
  13. 15 3月, 2017 1 次提交
  14. 28 2月, 2017 1 次提交
  15. 20 2月, 2017 1 次提交
  16. 15 2月, 2017 1 次提交
  17. 09 2月, 2017 3 次提交
  18. 24 1月, 2017 1 次提交
  19. 20 1月, 2017 2 次提交
  20. 17 1月, 2017 1 次提交
  21. 10 1月, 2017 1 次提交
  22. 09 1月, 2017 1 次提交
    • G
      of/irq: improve error report on irq discovery process failure · f1aa5484
      Guilherme G. Piccoli 提交于
      On PowerPC machines some PCI slots might not have level triggered
      interrupts capability (also know as level signaled interrupts),
      leading of_irq_parse_pci() to complain by presenting error messages
      on the kernel log - in this case, the properties "interrupt-map" and
      "interrupt-map-mask" are not present on device's node in the device
      tree.
      
      This patch introduces a different message for this specific case,
      and also reduces its level from error to warning. Besides, we warn
      (once) that possibly some PCI slots on the system have no level
      triggered interrupts available.
      We changed some error return codes too on function of_irq_parse_raw()
      in order other failure's cases can be presented in a more precise way.
      
      Before this patch, when an adapter was plugged in a slot without level
      interrupts capabilitiy on PowerPC, we saw a generic error message
      like this:
      
          [54.239] pci 002d:70:00.0: of_irq_parse_pci() failed with rc=-22
      
      Now, with this applied, we see the following specific message:
      
          [16.154] pci 0014:60:00.1: of_irq_parse_pci: no interrupt-map found,
          INTx interrupts not available
      
      Finally, we standardize the error path in of_irq_parse_raw() by always
      taking the fail path instead of returning directly from the loop.
      Signed-off-by: NGuilherme G. Piccoli <gpiccoli@linux.vnet.ibm.com>
      Signed-off-by: NRob Herring <robh@kernel.org>
      f1aa5484
  23. 05 1月, 2017 2 次提交
  24. 03 1月, 2017 2 次提交
  25. 13 12月, 2016 1 次提交
  26. 10 12月, 2016 3 次提交
  27. 30 11月, 2016 1 次提交