1. 12 7月, 2011 2 次提交
  2. 10 7月, 2011 1 次提交
  3. 02 7月, 2011 9 次提交
    • R
      PM: Rename clock management functions · 3d5c3036
      Rafael J. Wysocki 提交于
      The common PM clock management functions may be used for system
      suspend/resume as well as for runtime PM, so rename them
      accordingly.  Modify kerneldoc comments describing these functions
      and kernel messages printed by them, so that they refer to power
      management in general rather that to runtime PM.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      3d5c3036
    • R
      PM: Allow the clocks management code to be used during system suspend · b7b95920
      Rafael J. Wysocki 提交于
      The common clocks management code in drivers/base/power/clock_ops.c
      is going to be used during system-wide power transitions as well as
      for runtime PM, so it shouldn't depend on CONFIG_PM_RUNTIME.
      However, the suspend/resume functions provided by it for
      CONFIG_PM_RUNTIME unset, to be used during system-wide power
      transitions, should not behave in the same way as their counterparts
      defined for CONFIG_PM_RUNTIME set, because in that case the clocks
      are managed differently at run time.
      
      The names of the functions still contain the word "runtime" after
      this change, but that is going to be modified by a separate patch
      later.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      b7b95920
    • R
      PM / Domains: Wakeup devices support for system sleep transitions · d4f2d87a
      Rafael J. Wysocki 提交于
      There is the problem how to handle devices set up to wake up the
      system from sleep states during system-wide power transitions.
      In some cases, those devices can be turned off entirely, because the
      wakeup signals will be generated on their behalf anyway.  In some
      other cases, they will generate wakeup signals if their clocks are
      stopped, but only if power is not removed from them.  Finally, in
      some cases, they can only generate wakeup signals if power is not
      removed from them and their clocks are enabled.
      
      To allow platform-specific code to decide whether or not to put
      wakeup devices (and their PM domains) into low-power state during
      system-wide transitions, such as system suspend, introduce a new
      generic PM domain callback, .active_wakeup(), that will be used
      during the "noirq" phase of system suspend and hibernation (after
      image creation) to decide what to do with wakeup devices.
      Specifically, if this callback is present and returns "true", the
      generic PM domain code will not execute .stop_device() for the
      given wakeup device and its PM domain won't be powered off.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NKevin Hilman <khilman@ti.com>
      d4f2d87a
    • R
      PM / Domains: System-wide transitions support for generic domains (v5) · 596ba34b
      Rafael J. Wysocki 提交于
      Make generic PM domains support system-wide power transitions
      (system suspend and hibernation).  Add suspend, resume, freeze, thaw,
      poweroff and restore callbacks to be associated with struct
      generic_pm_domain objects and make pm_genpd_init() use them as
      appropriate.
      
      The new callbacks do nothing for devices belonging to power domains
      that were powered down at run time (before the transition).  For the
      other devices the action carried out depends on the type of the
      transition.  During system suspend the power domain .suspend()
      callback executes pm_generic_suspend() for the device, while the
      PM domain .suspend_noirq() callback runs pm_generic_suspend_noirq()
      for it, stops it and eventually removes power from the PM domain it
      belongs to (after all devices in the domain have been stopped and its
      subdomains have been powered off).
      
      During system resume the PM domain .resume_noirq() callback
      restores power to the PM domain (when executed for it first time),
      starts the device and executes pm_generic_resume_noirq() for it,
      while the .resume() callback executes pm_generic_resume() for the
      device.  Finally, the .complete() callback executes pm_runtime_idle()
      for the device which should put it back into the suspended state if
      its runtime PM usage count is equal to zero at that time.
      
      The actions carried out during hibernation and resume from it are
      analogous to the ones described above.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      596ba34b
    • R
      PM / Domains: Move code from under #ifdef CONFIG_PM_RUNTIME (v2) · 5248051b
      Rafael J. Wysocki 提交于
      There is some code in drivers/base/power/domain.c that will be useful
      for both runtime PM and system-wide power transitions, so make it
      depend on CONFIG_PM instead of CONFIG_PM_RUNTIME.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      5248051b
    • R
      PM: Introduce generic "noirq" callback routines for subsystems (v2) · e5291928
      Rafael J. Wysocki 提交于
      Introduce generic "noirq" power management callback routines for
      subsystems in addition to the "regular" generic PM callback routines.
      
      The new routines will be used, among other things, for implementing
      system-wide PM transitions support for generic PM domains.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      e5291928
    • R
      PM / Domains: Support for generic I/O PM domains (v8) · f721889f
      Rafael J. Wysocki 提交于
      Introduce common headers, helper functions and callbacks allowing
      platforms to use simple generic power domains for runtime power
      management.
      
      Introduce struct generic_pm_domain to be used for representing
      power domains that each contain a number of devices and may be
      parent domains or subdomains with respect to other power domains.
      Among other things, this structure includes callbacks to be
      provided by platforms for performing specific tasks related to
      power management (i.e. ->stop_device() may disable a device's
      clocks, while ->start_device() may enable them, ->power_off() is
      supposed to remove power from the entire power domain
      and ->power_on() is supposed to restore it).
      
      Introduce functions that can be used as power domain runtime PM
      callbacks, pm_genpd_runtime_suspend() and pm_genpd_runtime_resume(),
      as well as helper functions for the initialization of a power
      domain represented by a struct generic_power_domain object,
      adding a device to or removing a device from it and adding or
      removing subdomains.
      
      Introduce configuration option CONFIG_PM_GENERIC_DOMAINS to be
      selected by the platforms that want to use the new code.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NGreg Kroah-Hartman <gregkh@suse.de>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      f721889f
    • R
      PM / Domains: Rename struct dev_power_domain to struct dev_pm_domain · 564b905a
      Rafael J. Wysocki 提交于
      The naming convention used by commit 7538e3db6e015e890825fbd9f86599b
      (PM: Add support for device power domains), which introduced the
      struct dev_power_domain type for representing device power domains,
      evidently confuses some developers who tend to think that objects
      of this type must correspond to "power domains" as defined by
      hardware, which is not the case.  Namely, at the kernel level, a
      struct dev_power_domain object can represent arbitrary set of devices
      that are mutually dependent power management-wise and need not belong
      to one hardware power domain.  To avoid that confusion, rename struct
      dev_power_domain to struct dev_pm_domain and rename the related
      pointers in struct device and struct pm_clk_notifier_block from
      pwr_domain to pm_domain.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NKevin Hilman <khilman@ti.com>
      564b905a
    • J
      drm/i915: apply HWSTAM writes to Ivy Bridge as well · 2b1ecb73
      Jesse Barnes 提交于
      In an attempt to fix 38862 and 38863.
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Tested-by: NKenneth Graunke <kenneth@whitecape.org>
      Signed-off-by: NKeith Packard <keithp@keithp.com>
      2b1ecb73
  4. 01 7月, 2011 1 次提交
  5. 30 6月, 2011 7 次提交
  6. 29 6月, 2011 9 次提交
  7. 28 6月, 2011 11 次提交
    • A
      watchdog: gef_wdt: fix MODULE_ALIAS · ae2a0060
      Axel Lin 提交于
      Remove the space between "platform:" prefix and the driver name.
      Signed-off-by: NAxel Lin <axel.lin@gmail.com>
      Acked-by: NMartyn Welch <martyn.welch@ge.com>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      ae2a0060
    • J
      watchdog: Intel SCU Watchdog: Fix build and remove duplicate code · e376fd66
      Jesper Juhl 提交于
      Trying to build the Intel SCU Watchdog fails for me with gcc 4.6.0 -
      $ gcc --version | head -n 1
      gcc (GCC) 4.6.0 20110513 (prerelease)
      
      like this :
        CC      drivers/watchdog/intel_scu_watchdog.o
      In file included from drivers/watchdog/intel_scu_watchdog.c:49:0:
      /home/jj/src/linux-2.6/arch/x86/include/asm/apb_timer.h: In function ‘apbt_time_init’:
      /home/jj/src/linux-2.6/arch/x86/include/asm/apb_timer.h:65:42: warning: ‘return’ with a value, in function returning void [enabled by default]
      drivers/watchdog/intel_scu_watchdog.c: In function ‘intel_scu_watchdog_init’:
      drivers/watchdog/intel_scu_watchdog.c:468:2: error: implicit declaration of function ‘sfi_get_mtmr’ [-Werror=implicit-function-declaration]
      drivers/watchdog/intel_scu_watchdog.c:468:32: warning: assignment makes pointer from integer without a cast [enabled by default]
      cc1: some warnings being treated as errors
      
      make[1]: *** [drivers/watchdog/intel_scu_watchdog.o] Error 1
      make: *** [drivers/watchdog/intel_scu_watchdog.o] Error 2
      
      Additionally, linux/types.h is needlessly being included twice in 
      drivers/watchdog/intel_scu_watchdog.c
      Signed-off-by: NJesper Juhl <jj@chaosbits.net>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      e376fd66
    • F
      watchdog: mtx1-wdt: fix section mismatch · db98f89a
      Florian Fainelli 提交于
      Fix section mismatch and remove unused variable 'tmp'.
      Signed-off-by: NFlorian Fainelli <florian@openwrt.org>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      db98f89a
    • F
      watchdog: mtx1-wdt: fix GPIO toggling · 2ea4e76e
      Florian Fainelli 提交于
      Commit e391be76 (MIPS: Alchemy: Clean up GPIO registers and accessors)
      changed the way the GPIO was toggled. Prior to this patch, we would
      always actively drive the GPIO output to either 0 or 1, this patch
      drove the GPIO active to 0, and put the GPIO in tristate to drive it
      to 1, unfortunately this does not work, revert back to active driving.
      
      Using a signed variable (gstate) to hold the gpio state and using a bit-
      wise operation on it also resulted in toggling value from 1 to -2 since
      the variable is signed. This value was then passed on to gpio_direction_
      output, which always perform a if (value) ... to set the value to the
      gpio, so we were always writing a 1 to this GPIO instead of 1 -> 0 -> 1 ...
      Signed-off-by: NFlorian Fainelli <florian@openwrt.org>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      Cc: stable <stable@kernel.org>
      2ea4e76e
    • F
      watchdog: mtx1-wdt: request gpio before using it · 9b19d40a
      Florian Fainelli 提交于
      Otherwise, the gpiolib autorequest feature will produce a WARN_ON():
      
      WARNING: at drivers/gpio/gpiolib.c:101 0x8020ec6c()
      autorequest GPIO-215
      [...]
      Signed-off-by: NFlorian Fainelli <florian@openwrt.org>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      Cc: stable <stable@kernel.org>
      9b19d40a
    • M
      watchdog: Handle multiple wm831x watchdogs being registered · 076bad7c
      Mark Brown 提交于
      Due to the whole single instance based watchdog API we use static data
      for the wm831x watchdog which means that if the system tries to register
      a second one we end up trying to register the same miscdevice again,
      corrupting the miscdevice list. Work around this by checking for duplicate
      registrations until we get a watchdog core.
      Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
      Signed-off-by: NWim Van Sebroeck <wim@iguana.be>
      076bad7c
    • N
      md: avoid endless recovery loop when waiting for fail device to complete. · 4274215d
      NeilBrown 提交于
      If a device fails in a way that causes pending request to take a while
      to complete, md will not be able to immediately remove it from the
      array in remove_and_add_spares.
      It will then incorrectly look like a spare device and md will try to
      recover it even though it is failed.
      This leads to a recovery process starting and instantly aborting over
      and over again.
      
      We should check if the device is faulty before considering it to be a
      spare.  This will avoid trying to start a recovery that cannot
      proceed.
      
      This bug was introduced in 2.6.26 so that patch is suitable for any
      kernel since then.
      
      Cc: stable@kernel.org
      Reported-by: NJim Paradis <james.paradis@stratus.com>
      Signed-off-by: NNeilBrown <neilb@suse.de>
      4274215d
    • H
      drm/i915: more struct_mutex locking · ecbec53b
      Hugh Dickins 提交于
      When auditing the locking in i915_gem.c (for a prospective change which
      I then abandoned), I noticed two places where struct_mutex is not held
      across GEM object manipulations that would usually require it.
      
      Since one is in initial setup and the other in driver unload, I'm
      guessing the mutex is not required for either; but post a patch in case
      it is.
      Signed-off-by: NHugh Dickins <hughd@google.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Keith Packard <keithp@keithp.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      ecbec53b
    • H
      drm/i915: use shmem_truncate_range · e2377fe0
      Hugh Dickins 提交于
      The interface to ->truncate_range is changing very slightly: once "tmpfs:
      take control of its truncate_range" has been applied, this can be applied.
       For now there is only a slight inefficiency while this remains unapplied,
      but it will soon become essential for managing shmem's use of swap.
      
      Change i915_gem_object_truncate() to use shmem_truncate_range() directly:
      which should also spare i915 later change if we switch from
      inode_operations->truncate_range to file_operations->fallocate.
      Signed-off-by: NHugh Dickins <hughd@google.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Keith Packard <keithp@keithp.com>
      Cc: Dave Airlie <airlied@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      e2377fe0
    • H
      drm/i915: use shmem_read_mapping_page · 5949eac4
      Hugh Dickins 提交于
      Soon tmpfs will stop supporting ->readpage and read_cache_page_gfp(): once
      "tmpfs: add shmem_read_mapping_page_gfp" has been applied, this patch can
      be applied to ease the transition.
      
      Make i915_gem_object_get_pages_gtt() use shmem_read_mapping_page_gfp() in
      the one place it's needed; elsewhere use shmem_read_mapping_page(), with
      the mapping's gfp_mask properly initialized.
      
      Forget about __GFP_COLD: since tmpfs initializes its pages with memset,
      asking for a cold page is counter-productive.
      
      Include linux/shmem_fs.h also in drm_gem.c: with shmem_file_setup() now
      declared there too, we shall remove the prototype from linux/mm.h later.
      Signed-off-by: NHugh Dickins <hughd@google.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Keith Packard <keithp@keithp.com>
      Cc: Dave Airlie <airlied@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      5949eac4
    • H
      drm/ttm: use shmem_read_mapping_page · 3142b651
      Hugh Dickins 提交于
      Soon tmpfs will stop supporting ->readpage and read_mapping_page(): once
      "tmpfs: add shmem_read_mapping_page_gfp" has been applied, this patch can
      be applied to ease the transition.
      
      ttm_tt_swapin() and ttm_tt_swapout() use shmem_read_mapping_page() in
      place of read_mapping_page(), since their swap_space has been created with
      shmem_file_setup().
      Signed-off-by: NHugh Dickins <hughd@google.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Thomas Hellstrom <thellstrom@vmware.com>
      Cc: Dave Airlie <airlied@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      3142b651