1. 03 11月, 2014 1 次提交
    • A
      powerpc: Convert power off logic to pm_power_off · 9178ba29
      Alexander Graf 提交于
      The generic Linux framework to power off the machine is a function pointer
      called pm_power_off. The trick about this pointer is that device drivers can
      potentially implement it rather than board files.
      
      Today on powerpc we set pm_power_off to invoke our generic full machine power
      off logic which then calls ppc_md.power_off to invoke machine specific power
      off.
      
      However, when we want to add a power off GPIO via the "gpio-poweroff" driver,
      this card house falls apart. That driver only registers itself if pm_power_off
      is NULL to ensure it doesn't override board specific logic. However, since we
      always set pm_power_off to the generic power off logic (which will just not
      power off the machine if no ppc_md.power_off call is implemented), we can't
      implement power off via the generic GPIO power off driver.
      
      To fix this up, let's get rid of the ppc_md.power_off logic and just always use
      pm_power_off as was intended. Then individual drivers such as the GPIO power off
      driver can implement power off logic via that function pointer.
      
      With this patch set applied and a few patches on top of QEMU that implement a
      power off GPIO on the virt e500 machine, I can successfully turn off my virtual
      machine after halt.
      Signed-off-by: NAlexander Graf <agraf@suse.de>
      [mpe: Squash into one patch and update changelog based on cover letter]
      Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
      9178ba29
  2. 23 5月, 2014 1 次提交
    • F
      powerpc/fsl: fsl_soc: remove 'fixed-link' parsing code · 1f8c486f
      Florian Fainelli 提交于
      Parsing and registration of fixed PHY devices was needed with the use of
      of_phy_connect_fixed_link() because this function was using the
      designated PHY address identifier (first cell of the property) as the
      address to bind the PHY on the emulated bus.
      
      Since commit 3be2a49e ("of: provide a
      binding for fixed link PHYs") a new pair of functions has been
      introduced which allows for dynamic address allocation of these fixed
      PHY devices, but also parses the old 'fixed-link' 5-digit property.
      
      Registration of fixed PHY early in platform code was needed because we
      could not issue a fixed MDIO bus re-scan within network drivers. The
      fixed PHYs had to be registered before the network drivers would call
      of_phy_connect_fixed_link(). All of these caveats are solved now, such
      that we can safely remove of_add_fixed_phys() now.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1f8c486f
  3. 13 2月, 2013 1 次提交
  4. 06 10月, 2012 1 次提交
  5. 29 3月, 2012 1 次提交
  6. 01 11月, 2011 1 次提交
  7. 27 7月, 2011 1 次提交
  8. 27 6月, 2011 1 次提交
  9. 23 10月, 2010 1 次提交
    • A
      USB: add platform glue driver for FSL USB DR controller · 126512e3
      Anatolij Gustschin 提交于
      Replace FSL USB platform code by simple platform driver for
      creation of FSL USB platform devices.
      
      The driver creates platform devices based on the information
      from USB nodes in the flat device tree. This is the replacement
      for old arch fsl_soc usb code removed by this patch. The driver
      uses usual of-style binding, available EHCI-HCD and UDC
      drivers can be bound to the created devices. The new of-style
      driver additionaly instantiates USB OTG platform device, as the
      appropriate USB OTG driver will be added soon.
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      Cc: Kumar Gala <galak@kernel.crashing.org>
      Cc: Grant Likely <grant.likely@secretlab.ca>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      126512e3
  10. 14 10月, 2010 1 次提交
  11. 21 11月, 2009 1 次提交
  12. 25 8月, 2009 1 次提交
  13. 19 5月, 2009 1 次提交
  14. 09 5月, 2009 1 次提交
  15. 01 4月, 2009 2 次提交
  16. 09 3月, 2009 1 次提交
  17. 17 12月, 2008 1 次提交
  18. 31 10月, 2008 1 次提交
    • T
      gianfar: Fix race in TBI/SerDes configuration · c132419e
      Trent Piepho 提交于
      The init_phy() function attaches to the PHY, then configures the
      SerDes<->TBI link (in SGMII mode).  The TBI is on the MDIO bus with the PHY
      (sort of) and is accessed via the gianfar's MDIO registers, using the
      functions gfar_local_mdio_read/write(), which don't do any locking.
      
      The previously attached PHY will start a work-queue on a timer, and
      probably an irq handler as well, which will talk to the PHY and thus use
      the MDIO bus.  This uses phy_read/write(), which have locking, but not
      against the gfar_local_mdio versions.
      
      The result is that PHY code will try to use the MDIO bus at the same time
      as the SerDes setup code, corrupting the transfers.
      
      Setting up the SerDes before attaching to the PHY will insure that there is
      no race between the SerDes code and *our* PHY, but doesn't fix everything.
      Typically the PHYs for all gianfar devices are on the same MDIO bus, which
      is associated with the first gianfar device.  This means that the first
      gianfar's SerDes code could corrupt the MDIO transfers for a different
      gianfar's PHY.
      
      The lock used by phy_read/write() is contained in the mii_bus structure,
      which is pointed to by the PHY.  This is difficult to access from the
      gianfar drivers, as there is no link between a gianfar device and the
      mii_bus which shares the same MDIO registers.  As far as the device layer
      and drivers are concerned they are two unrelated devices (which happen to
      share registers).
      
      Generally all gianfar devices' PHYs will be on the bus associated with the
      first gianfar.  But this might not be the case, so simply locking the
      gianfar's PHY's mii bus might not lock the mii bus that the SerDes setup
      code is going to use.
      
      We solve this by having the code that creates the gianfar platform device
      look in the device tree for an mdio device that shares the gianfar's
      registers.  If one is found the ID of its platform device is saved in the
      gianfar's platform data.
      
      A new function in the gianfar mii code, gfar_get_miibus(), can use the bus
      ID to search through the platform devices for a gianfar_mdio device with
      the right ID.  The platform device's driver data is the mii_bus structure,
      which the SerDes setup code can use to lock the current bus.
      Signed-off-by: NTrent Piepho <tpiepho@freescale.com>
      CC: Andy Fleming <afleming@freescale.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      c132419e
  19. 14 10月, 2008 1 次提交
  20. 29 9月, 2008 1 次提交
  21. 17 7月, 2008 3 次提交
  22. 13 7月, 2008 1 次提交
  23. 07 6月, 2008 1 次提交
  24. 03 6月, 2008 3 次提交
  25. 02 5月, 2008 1 次提交
  26. 30 4月, 2008 1 次提交
    • J
      i2c: Convert most new-style drivers to use module aliasing · 3760f736
      Jean Delvare 提交于
      Based on earlier work by Jon Smirl and Jochen Friedrich.
      
      Update most new-style i2c drivers to use standard module aliasing
      instead of the old driver_name/type driver matching scheme. I've
      left the video drivers apart (except for SoC camera drivers) as
      they're a bit more diffcult to deal with, they'll have their own
      patch later.
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Cc: Jon Smirl <jonsmirl@gmail.com>
      Cc: Jochen Friedrich <jochen@scram.de>
      3760f736
  27. 28 4月, 2008 1 次提交
  28. 17 4月, 2008 3 次提交
  29. 06 2月, 2008 1 次提交
    • K
      [POWERPC] FSL: fix mpc83xx_spi device registration · dc4e4207
      Kim Phillips 提交于
      calling platform_device_register after platform_device_alloc causes
      this:
      
      kobject (c3841a70): tried to init an initialized object, something is seriously wrong.
      Call Trace:
      [c381fe20] [c0007bb8] show_stack+0x3c/0x194 (unreliable)
      [c381fe50] [c01322a8] kobject_init+0xb8/0xbc
      [c381fe60] [c01591cc] device_initialize+0x30/0x9c
      [c381fe80] [c015ee34] platform_device_register+0x1c/0x34
      [c381fea0] [c02f1fe0] of_fsl_spi_probe+0x21c/0x22c
      [c381ff30] [c02f2044] fsl_spi_init+0x54/0x160
      [c381ff60] [c02f3924] __machine_initcall_mpc832x_rdb_mpc832x_spi_init+0x120/0x138
      [c381ff70] [c02e61b4] kernel_init+0x98/0x284
      [c381fff0] [c000f740] kernel_thread+0x44/0x60
      
      fixed by calling platform_device_add (second half of
      platform_device_register) instead.
      Signed-off-by: NKim Phillips <kim.phillips@freescale.com>
      Signed-off-by: NKumar Gala <galak@kernel.crashing.org>
      dc4e4207
  30. 28 1月, 2008 3 次提交
  31. 24 1月, 2008 1 次提交