1. 19 4月, 2008 1 次提交
  2. 18 4月, 2008 1 次提交
    • B
      ide: rework PowerMac media-bay support (take 2) · 2dde7861
      Bartlomiej Zolnierkiewicz 提交于
      Rework PowerMac media-bay support in such way that instead of
      un/registering the IDE interface we un/register IDE devices:
      
      * Add ide_port_scan() helper for probing+registerering devices on a port.
      
      * Rename ide_port_unregister_devices() to __ide_port_unregister_devices().
      
      * Add ide_port_unregister_devices() helper for unregistering devices on a port.
      
      * Add 'ide_hwif_t *cd_port' to 'struct media_bay_info', pass 'hwif' instead
        of hwif->index to media_bay_set_ide_infos() and use it to setup 'cd_port'.
      
      * Use ide_port_unregister_devices() instead of ide_unregister()
        and ide_port_scan() instead of ide_register_hw() in media_bay_step().
      
      * Unexport ide_register_hw() and make it static.
      
      v2:
      * Fix build by adding <linux/ide.h> include to <asm-powerpc/mediabay.h>.
        (Reported by Michael/Kamalesh/Andrew).
      
      Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
      Cc: Michael Ellerman <michael@ellerman.id.au>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      2dde7861
  3. 13 3月, 2008 2 次提交
  4. 24 2月, 2008 1 次提交
    • R
      PM: Introduce PM_EVENT_HIBERNATE callback state · 3a2d5b70
      Rafael J. Wysocki 提交于
      During the last step of hibernation in the "platform" mode (with the
      help of ACPI) we use the suspend code, including the devices'
      ->suspend() methods, to prepare the system for entering the ACPI S4
      system sleep state.
      
      But at least for some devices the operations performed by the
      ->suspend() callback in that case must be different from its operations
      during regular suspend.
      
      For this reason, introduce the new PM event type PM_EVENT_HIBERNATE and
      pass it to the device drivers' ->suspend() methods during the last phase
      of hibernation, so that they can distinguish this case and handle it as
      appropriate.  Modify the drivers that handle PM_EVENT_SUSPEND in a
      special way and need to handle PM_EVENT_HIBERNATE in the same way.
      
      These changes are necessary to fix a hibernation regression related
      to the i915 driver (ref. http://lkml.org/lkml/2008/2/22/488).
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NPavel Machek <pavel@ucw.cz>
      Tested-by: NJeff Chua <jeff.chua.linux@gmail.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      3a2d5b70
  5. 15 2月, 2008 1 次提交
  6. 08 2月, 2008 1 次提交
    • B
      [POWERPC] Disable G5 NAP mode during SMU commands on U3 · 592a607b
      Benjamin Herrenschmidt 提交于
      It appears that with the U3 northbridge, if the processor is in NAP
      mode the whole time while waiting for an SMU command to complete,
      then the SMU will fail.  It could be related to the weird backward
      mechanism the SMU uses to get to system memory via i2c to the
      northbridge that doesn't operate properly when the said bridge is
      in napping along with the CPU.  That is on U3 at least, U4 doesn't
      seem to be affected.
      
      This didn't show before NO_HZ as the timer wakeup was enough to make
      it work it seems, but that is no longer the case.
      
      This fixes it by disabling NAP mode on those machines while
      an SMU command is in flight.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      592a607b
  7. 06 2月, 2008 2 次提交
  8. 04 2月, 2008 1 次提交
  9. 03 2月, 2008 3 次提交
  10. 28 1月, 2008 2 次提交
  11. 27 1月, 2008 1 次提交
  12. 25 1月, 2008 2 次提交
  13. 17 1月, 2008 3 次提交
    • S
      [POWERPC] therm_adt746x: Eliminate some build warnings · 10804f0f
      Stephen Rothwell 提交于
      We don't care if the device_create_file calls fail, the driver will work
      just as well without them, so just issue a runtime warning.
      
      drivers/macintosh/therm_adt746x.c: In function 'thermostat_init':
      drivers/macintosh/therm_adt746x.c:615: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:616: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:617: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:618: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:619: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:620: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:621: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:622: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:623: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_adt746x.c:625: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      Signed-off-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      10804f0f
    • S
      [POWERPC] therm_windtunnel: Eliminate some build warnings · 98894dff
      Stephen Rothwell 提交于
      We don't care if the device_create_file calls fail, the driver will work
      just as well without them, so just issue a runtime warning.
      
      drivers/macintosh/therm_windtunnel.c: In function 'setup_hardware':
      drivers/macintosh/therm_windtunnel.c:268: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_windtunnel.c:269: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      Signed-off-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      98894dff
    • S
      [POWERPC] therm_pm72: Suppress some compile warnings · 97759e49
      Stephen Rothwell 提交于
      We don't really care if any of these calls to device_create_file fails,
      so just issue warnings in that case.
      
      drivers/macintosh/therm_pm72.c: In function 'init_cpu_state':
      drivers/macintosh/therm_pm72.c:1185: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1186: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1187: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1188: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1189: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1191: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1192: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1193: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1194: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1195: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c: In function 'init_backside_state':
      drivers/macintosh/therm_pm72.c:1383: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1384: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c: In function 'init_drives_state':
      drivers/macintosh/therm_pm72.c:1503: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1504: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c: In function 'init_dimms_state':
      drivers/macintosh/therm_pm72.c:1625: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c: In function 'init_slots_state':
      drivers/macintosh/therm_pm72.c:1743: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      drivers/macintosh/therm_pm72.c:1744: warning: ignoring return value of 'device_create_file', declared with attribute warn_unused_result
      Signed-off-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      97759e49
  14. 15 1月, 2008 1 次提交
  15. 21 12月, 2007 2 次提交
  16. 19 12月, 2007 8 次提交
    • J
      [POWERPC] powermac: Use generic suspend code · f91266ed
      Johannes Berg 提交于
      This adds platform_suspend_ops for PMU based machines, directly in
      the PMU driver.  This allows suspending via /sys/power/state
      on powerbooks.
      
      The patch also replaces the PMU ioctl with a simple call to
      pm_suspend(PM_SUSPEND_MEM).
      
      Additionally, it cleans up some debug code.
      Signed-off-by: NJohannes Berg <johannes@sipsolutions.net>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      f91266ed
    • P
      [POWERPC] Fix sleep on powerbook 3400 · 887ef35a
      Paul Mackerras 提交于
      Sleep on the powerbook 3400 has been broken since the change that made
      powerbook_sleep_3400 call pmac_suspend_devices(), which disables
      interrupts.  There are a couple of loops in powerbook_sleep_3400 that
      depend on interrupts being enabled, and in fact it has to have
      interrupts enabled at the point of going to sleep since it is an
      interrupt from the PMU that wakes it up.
      
      This fixes it by using pmu_wait_complete() instead of a spinloop, and
      by explicitly enabling interrupts before putting the CPU into sleep
      mode (which is OK since all interrupts except the PMU interrupt have
      been disabled at the interrupt controller by this stage).
      
      This changes the logic so that it keeps putting the CPU into sleep mode
      until the completion of the interrupt transaction from the PMU that
      signals the end of sleep.  Also, we now call pmu_unlock() before sleep
      so that the via_pmu_interrupt() code can process the interrupt event
      from the PMU properly.
      
      Now that generic code saves and restores PCI state, it is no longer
      necessary to do that here.  Thus pbook_pci_save/restore and related
      functions are no longer necessary, so this removes them.
      
      Lastly, this moves the ioremap of the memory controller to init code
      rather than doing it on every sleep/wakeup cycle.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      887ef35a
    • P
      [POWERPC] Convert therm_windtunnel.c to use the kthread API · 98f6740e
      Paul Mackerras 提交于
      This is fairly straightforward, and lets us get rid of x.completion
      as well.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      98f6740e
    • P
      [POWERPC] Convert therm_pm72.c to use the kthread API · 39d183d8
      Paul Mackerras 提交于
      This converts the therm_pm72.c driver to use the kthread API.  I
      thought about making it use kthread_stop() instead of the `state'
      variable and the `ctrl_complete' completion, but that isn't simple and
      will require changing the way that `state' is used.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      39d183d8
    • P
      [POWERPC] Convert adb.c to use kthread API and not spin on ADB requests · c61dace9
      Paul Mackerras 提交于
      This converts adb.c to use the kthread API.
      
      It also changes adb_request so that if the ADBREQ_SYNC flag is
      specified, we now sleep waiting for the request to finish using an
      on-stack completion rather than spinning.  To implement this, we now
      require that if the ADBREQ_SYNC flag is set, the `done' parameter must
      be NULL.  All of the existing callers of adb_request that pass
      ADBREQ_SYNC appear to be in process context and have done == NULL.
      Doing this allows us to get rid of an awful hack in adb_request()
      where we used to test whether the request was coming from the adb
      probe task and use a completion if it was, and otherwise spin.
      
      This also gets rid of a static request block that was used if the req
      parameter to adb_request was NULL.  None of the callers do that any
      more, so the static request block is no longer necessary.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      c61dace9
    • P
      [POWERPC] Convert media-bay.c to use the kthread API · 33f6e794
      Paul Mackerras 提交于
      We aren't supposed to use kernel_thread directly in drivers any more,
      and in fact using kthread_run is a bit simpler.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      33f6e794
    • J
      [POWERPC] via-pmu: Kill sleep notifiers completely · b819a9bf
      Johannes Berg 提交于
      This kills off the remnants of the old sleep notifiers now that they
      are no longer used.
      Signed-off-by: NJohannes Berg <johannes@sipsolutions.net>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      b819a9bf
    • J
      [POWERPC] adb: Replace sleep notifier with platform driver suspend/resume hooks · c9f6d3d5
      Johannes Berg 提交于
      This replaces the pmu sleep notifier that adb had with suspend/resume
      hooks in a new platform driver/device.
      Signed-off-by: NJohannes Berg <johannes@sipsolutions.net>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      c9f6d3d5
  17. 18 12月, 2007 1 次提交
  18. 03 12月, 2007 2 次提交
  19. 08 11月, 2007 1 次提交
  20. 20 10月, 2007 3 次提交
  21. 17 10月, 2007 1 次提交