1. 06 3月, 2012 7 次提交
    • P
      ARM: OMAP2+: omap_device: call all suspend, resume callbacks when... · b7c39a3f
      Paul Walmsley 提交于
      ARM: OMAP2+: omap_device: call all suspend, resume callbacks when OMAP_DEVICE_NO_IDLE_ON_SUSPEND is set
      
      During system suspend, when OMAP_DEVICE_NO_IDLE_ON_SUSPEND is set on
      an omap_device, call the corresponding driver's ->suspend() and
      ->suspend_noirq() callbacks (if present).  Similarly, during resume,
      the driver's ->resume() and ->resume_noirq() callbacks must both be
      called, if present.  (The previous code only called ->suspend_noirq()
      and ->resume_noirq().)
      
      If all of these callbacks aren't called, some important driver
      suspend/resume code may not get executed.
      
      In current mainline, the bug fixed by this patch is only a problem
      under the following conditions:
      
      - the kernel is running on an OMAP4
      
      - an OMAP UART is used as a console
      
      - the kernel command line parameter 'no_console_suspend' is specified
      
      - and the system enters suspend ("echo mem > /sys/power/state").
      
      Under this combined circumstance, the system cannot be awakened via
      the serial port after commit be4b0281c
      ("tty: serial: OMAP: block idle while the UART is transferring data in
      PIO mode").  This is because the OMAP UART driver's ->suspend()
      callback is never called.  The ->suspend() callback would have called
      uart_suspend_port() which in turn would call enable_irq_wake().  Since
      enable_irq_wake() isn't called for the UART's IRQ, check_wakeup_irqs()
      would mask off the UART IRQ in the GIC.
      
      On v3.3 kernels prior to the above commit, serial resume from suspend
      presumably occurred via the PRCM interrupt.  The UART was in
      smart-idle mode, so it was able to send a PRCM wakeup which in turn
      would be converted into a PRCM interrupt to the GIC, waking up the
      kernel.  But after the above commit, when the system is suspended in
      the middle of a UART transmit, the UART IP block would be in no-idle
      mode.  In no-idle mode, the UART won't generate wakeups to the PRCM
      when incoming characters are received; only GIC interrupts.  But since
      the UART driver's ->suspend() callback is never called,
      uart_suspend_port() and enable_irq_wake() is never called; so the UART
      interrupt is masked by check_wakeup_irqs() and the UART can't wake up
      the MPU.
      
      The remaining mechanism that could have awakened the system would have
      been I/O chain wakeups.  These wouldn't be active because the console
      UART's clocks are never disabled when no_console_suspend is used,
      preventing the full chip from idling.  Also, current mainline doesn't
      yet support full chip idle states for OMAP4, so I/O chain wakeups are
      not enabled.
      
      This patch is the result of a collaboration.  John Stultz
      <johnstul@us.ibm.com> and Andy Green <andy.green@linaro.org> reported
      the serial wakeup problem that led to the discovery of this problem.
      Kevin Hilman <khilman@ti.com> narrowed the problem down to the use of
      no_console_suspend.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: John Stultz <johnstul@us.ibm.com>
      Cc: Andy Green <andy.green@linaro.org>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      b7c39a3f
    • K
      ARM: OMAP: omap_device: remove omap_device_parent · 3ec2decb
      Kevin Hilman 提交于
      Currently all omap_devices are forced to have the dummy device
      'omap_device_parent' as a parent.  This was used to distinguish
      omap_devices from "normal" platform_devices in the OMAP PM core code.
      
      Now that we implement the PM core using PM domains, this is no longer
      needed, and is removed.
      
      This also frees up omap_devices to have a more complex parent/child
      relationships that model actual device relationships.
      
      The only in-tree user of omap_device_parent was the OMAP PM layer to
      handle lost-context count for omap_devices.  That is now converted to
      use the presence of the omap_device_pm_domain instead.
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      3ec2decb
    • J
      ARM: OMAP2+: PM debug: fix the use of debugfs_create_* API · 401606fd
      Jean Pihet 提交于
      Check the return code pointer value from debugfs_create_dir for error
      or NULL.
      Also added an additional check to prevent the creation of a 'suspend'
      entry at the debugfs root in case a power domain directory cannot be
      created.
      Signed-off-by: NJean Pihet <j-pihet@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      401606fd
    • P
      ARM: OMAP2+: PM: share clkdms_setup() across OMAP2, 3, 4 · 92206fd2
      Paul Walmsley 提交于
      clkdms_setup() is identical across OMAP2, 3, and 4, so share it.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Tested-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      Tested-by: NKevin Hilman <khilman@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      92206fd2
    • P
      ARM: OMAP2+: PM: clean up omap_set_pwrdm_state() · e68e8093
      Paul Walmsley 提交于
      Clean up a few different parts of omap_set_pwrdm_state():
      
      - Remove a superfluous call to pwrdm_state_switch().  Not needed
        unless LOWPOWERSTATECHANGE is used, because the state switch code is
        called by either clkdm_sleep() or clkdm_allow_idle().
      
      - Add code to wait for the power state transition in the OMAP4+ low
        power state change.  This is speculative, so I would particularly
        appreciate feedback on this part.
      
      - Remove a superfluous call to pwrdm_read_pwrst().
      
      - Update variable names to be more meaningful (hopefully) and precise.
      
      - Fix an error path bug that would not place the clockdomain back into
        hardware-supervised idle or sleep mode if the power state could not
        be programmed.
      
      The documentation for this function still needs major improvements;
      that's left for a later patch.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      Tested-by: NTero Kristo <t-kristo@ti.com>
      Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      Tested-by: NKevin Hilman <khilman@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      e68e8093
    • P
      ARM: OMAP3: PM: remove superfluous calls to pwrdm_clear_all_prev_pwrst() · 506c7d79
      Paul Walmsley 提交于
      Remove some superfluous calls to pwrdm_clear_all_prev_pwrst().
      pwrdm_pre_transition(), which appears a few lines after these calls,
      invokes pwrdm_clear_all_prev_pwrst() on each powerdomain -- there's no
      need to do it twice.
      
      N.B.: some of us have observed that accesses to the previous
      powerstate registers seem to be quite slow.  Although the writes
      removed by this patch should be buffered by the write buffer, there is
      a read to a PRM register immediately afterwards.  That will block the
      OMAP3 MPU until all of those writes complete.  So this patch should
      result in a minor performance improvement during idle entry.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      Tested-by: NTero Kristo <t-kristo@ti.com>
      [khilman@ti.com: removed a couple more for OMAP4]
      Tested-by: NKevin Hilman <khilman@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      506c7d79
    • K
  2. 29 2月, 2012 2 次提交
  3. 25 2月, 2012 12 次提交
  4. 23 2月, 2012 1 次提交
  5. 22 2月, 2012 4 次提交
  6. 21 2月, 2012 4 次提交
    • T
      ARM: OMAP2+: Split omap2_hsmmc_init() to properly support I2C GPIO pins · 3b972bf0
      Tony Lindgren 提交于
      Otherwise omap_device_build() and omap_mux related functions
      can't be marked as __init when twl is build as a module.
      
      If a board is using GPIO pins or regulators configured by an
      external chip, such as TWL PMIC on I2C bus, the board must
      mark those MMC controllers as deferred. Additionally both
      omap_hsmmc_init() and omap_hsmmc_late_init() must be called
      by the board.
      
      For MMC controllers using internal GPIO pins for card
      detect and regulators the slots don't need to be marked
      deferred. In this case calling omap_hsmmc_init() is sufficient.
      
      Only mark the MMC slots using gpio_cd or gpio_wd as deferred
      as noted by Igor Grinberg <grinberg@compulab.co.il>.
      
      Note that this patch does not change the behaviour for
      board-4430sdp.c board-omap4panda.c. These boards wrongly
      rely on the omap_hsmmc.c init function callback to configure
      the PMIC GPIO interrupt lines on external chip. If the PMIC
      interrupt lines are not configured during init, they will
      fail.
      Reported-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NRajendra Nayak <rnayak@ti.com>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      3b972bf0
    • O
      ARM: OMAP: omap_device: Expose omap_device_{alloc, delete, register} · 993e4fbd
      Ohad Ben-Cohen 提交于
      Expose omap_device_{alloc, delete, register} so we can use them outside
      of omap_device.c.
      
      This approach allows users, which need to manipulate an archdata member
      of a device before it is registered, to do so. This is also useful
      for users who have their devices created very early so they can be used
      at ->reserve() time to reserve CMA memory.
      
      The immediate use case for this is to set the private iommu archdata
      member, which binds a device to its associated iommu controller.
      This way, generic code will be able to attach omap devices to their
      iommus, without calling any omap-specific API.
      
      With this in hand, we can further clean the existing mainline OMAP iommu
      driver and its mainline users, and focus on generic IOMMU approaches
      for future users (rpmsg/remoteproc and the upcoming generic DMA API).
      
      This patch is still considered an interim solution until DT fully materializes
      for omap; at that point, this functionality will be removed as DT will
      take care of creating the devices and configuring them correctly.
      
      Tested on OMAP4 with a generic rpmsg/remoteproc that doesn't use any
      omap-specific IOMMU API anymore.
      Signed-off-by: NOhad Ben-Cohen <ohad@wizery.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      993e4fbd
    • T
      ARM: OMAP: Fix build error when mmc_omap is built as module · d5171102
      Tony Lindgren 提交于
      Otherwise we get the following error:
      
      arch/arm/mach-omap2/built-in.o: In function `n8x0_mmc_callback':
      twl-common.c:(.text+0x108a0): undefined reference to
      `omap_mmc_notify_cover_event'
      
      Fix this by warning about unusable MMC cover events.
      
      The long term fix needs to change the MMC drivers to
      register board specific callbacks directly with PMIC.
      Reported-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      d5171102
    • T
      ARM: OMAP: Fix kernel panic with HSMMC when twl4030_gpio is a module · 97899e55
      Tony Lindgren 提交于
      On some omaps twl4030_gpio has a callback to try to initialize
      the MMC controller. If twl4030_gpio is compiled as a module,
      bad things can happen because the callback function starts
      calling functions that are supposed to be marked __init:
      
      Kernel panic - not syncing: Attempted to kill the idle task!
      twl4030_gpio twl4030_gpio: can't dispatch IRQs from modules
      gpiochip_add: registered GPIOs 192 to 209 on device: twl4030
      Unable to handle kernel paging request at virtual address b82a4c74
      ...
      
      Additionally if this does not fail, warnings are produced
      about trying to register the MMC multiple times.
      
      Fix this by removing __init from omap_mux_get_by_name,
      and add checks if omap2_hsmmc_init() is getting called more
      than once.
      
      Note that this will get fixed properly later on by splitting
      omap2_hsmmc_init into two functions.
      Reported-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      97899e55
  7. 19 2月, 2012 10 次提交
    • L
      Linux 3.3-rc4 · b01543df
      Linus Torvalds 提交于
      b01543df
    • L
      Merge tag 'fixes-3.3-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · be2874cb
      Linus Torvalds 提交于
      These are the bug fixes that have accumulated since 3.3-rc3 in arm-soc.
      The majority of them are regression fixes for stuff that broke during
      the merge 3.3 window.
      
      The notable ones are:
      
      * The at91 ata drivers both broke because of an earlier cleanup patch that
        some other patches were based on. Jean-Christophe decided to remove
        the legacy at91_ide driver and fix the new-style at91-pata driver while
        keeping the cleanup patch. I almost rejected the patches for being too
        late and too big but in the end decided to accept them because they
        fix a regression.
      
      * A patch fixing build breakage from the sysdev-to-device conversion
        colliding with other changes touches a number of mach-s3c files.
      
      * b0654037 "ARM: orion: Fix Orion5x GPIO regression from MPP cleanup"
        is a mechanical change that unfortunately touches a lot of lines
        that should up in the diffstat.
      
      * tag 'fixes-3.3-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (28 commits)
        ARM: at91: drop ide driver in favor of the pata one
        pata/at91: use newly introduced SMC accessors
        ARM: at91: add accessor to manage SMC
        ARM: at91:rtc/rtc-at91sam9: ioremap register bank
        ARM: at91: USB AT91 gadget registration for module
        ep93xx: fix build of vision_ep93xx.c
        ARM: OMAP2xxx: PM: fix OMAP2xxx-specific UART idle bug in v3.3
        ARM: orion: Fix USB phy for orion5x.
        ARM: orion: Fix Orion5x GPIO regression from MPP cleanup
        ARM: EXYNOS: Add cpu-offset property in gic device tree node
        ARM: EXYNOS: Bring exynos4-dt up to date
        ARM: OMAP3: cm-t35: fix section mismatch warning
        ARM: OMAP2: Fix the OMAP2 only build break seen with 2011+ ARM tool-chains
        ARM: tegra: paz00: fix wrong UART port on mini-pcie plug
        ARM: tegra: paz00: fix wrong SD1 power gpio
        i2c: tegra: Add devexit_p() for remove
        ARM: EXYNOS: Correct M-5MOLS sensor clock frequency on Universal C210 board
        ARM: EXYNOS: Correct framebuffer window size on Nuri board
        ARM: SAMSUNG: Fix missing api-change from subsys_interface change
        ARM: EXYNOS: Fix "warning: initialization from incompatible pointer type"
        ...
      be2874cb
    • L
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 584216b7
      Linus Torvalds 提交于
      1) VETH_INFO_PEER netlink attribute needs to have it's size validated,
         from Thomas Graf.
      
      2) 'poll' module option of bnx2x driver crashes the machine, just remove
         it.  From Michal Schmidt.
      
      3) ks8851_mll driver reads the irq number from two places, but only
         initializes one of them, oops.  Use only one location and fix this
         problem, from Jan Weitzel.
      
      4) Fix buffer overrun and unicast sterring bugs in mellanox mlx4 driver,
         from Eugenia Emantayev.
      
      5) Swapped kcalloc() args in RxRPC and mlx4, from Axel Lin.
      
      6) PHY MDIO device name regression fixes from Florian Fainelli.
      
      7) If the wake event IRQ line is different from the netdevice one, we
         have to properly route it to the stmmac interrupt handler.  From
         Francesco Virlinzi.
      
      8) Fix rwlock lock initialization ordering bug in mac80211, from
         Mohammed Shafi Shajakhan.
      
      9) TCP lost_cnt can get out of sync, and in fact go negative, in certain
         circumstances.  Fix the way we specify what sequence range to operate
         on in tcp_sacktag_one() to fix this bug.  From Neal Cardwell.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (27 commits)
        net/ethernet: ks8851_mll fix irq handling
        veth: Enforce minimum size of VETH_INFO_PEER
        stmmac: update the driver version to Feb 2012 (v2)
        stmmac: move hw init in the probe (v2)
        stmmac: request_irq when use an ext wake irq line (v2)
        stmmac: do not discard frame on dribbling bit assert
        ipheth: Add iPhone 4S
        mlx4: add unicast steering entries to resource_tracker
        mlx4: fix QP tree trashing
        mlx4: fix buffer overrun
        3c59x: shorten timer period for slave devices
        netpoll: netpoll_poll_dev() should access dev->flags
        RxRPC: Fix kcalloc parameters swapped
        bnx2x: remove the 'poll' module option
        tcp: fix tcp_shifted_skb() adjustment of lost_cnt_hint for FACK
        ks8851: Fix NOHZ local_softirq_pending 08 warning
        bnx2x: fix bnx2x_storm_stats_update() on big endian
        ixp4xx-eth: fix PHY name to match MDIO bus name
        octeon: fix PHY name to match MDIO bus name
        fec: fix PHY name to match fixed MDIO bus name
        ...
      584216b7
    • L
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap · bff98bfc
      Linus Torvalds 提交于
      Fixes a bootstrapping issue for some registers when a less commonly used
      method for register cache initialisation is used.  Only affects a fairly
      small proportion of users that both don't use explicit register defaults
      and do use the cache.
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap:
        regmap: Fix cache defaults initialization from raw cache defaults
      bff98bfc
    • L
      Merge tag 'ecryptfs-3.3-rc4-fixes' of... · 46860666
      Linus Torvalds 提交于
      Merge tag 'ecryptfs-3.3-rc4-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs
      
      Fixes maximum filename length and filesystem type reporting in statfs() calls
      and also fixes stale inode mode bits on eCryptfs inodes after a POSIX ACL was
      set on the lower filesystem's inode.
      
      * tag 'ecryptfs-3.3-rc4-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs:
        ecryptfs: remove the second argument of k[un]map_atomic()
        eCryptfs: Copy up lower inode attrs after setting lower xattr
        eCryptfs: Improve statfs reporting
      46860666
    • L
      Merge tag 'pinctrl' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl · 7857b996
      Linus Torvalds 提交于
      pinctrl fixes for v3.3
      
      * tag 'pinctrl-for-torvalds-20120216' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl:
        pinctrl: restore pin naming
      7857b996
    • L
      Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc · 06ca7c43
      Linus Torvalds 提交于
      Here are a few more fixes for powerpc.  Some are regressions, the rest
      is simple/obvious/nasty enough that I deemed it good to go now.
      
      Here's also step one of deprecating legacy iSeries support: we are
      removing it from the main defconfig.
      
      Nobody seems to be using it anymore and the code is nasty to maintain,
      (involves horrible hacks in various low level areas of the kernel) so we
      plan to actually rip it out at some point.  For now let's just avoid
      building it by default.  Stephen will proceed to do the actual removal
      later (probably 3.4 or 3.5).
      
      * 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc:
        powerpc/perf: power_pmu_start restores incorrect values, breaking frequency events
        powerpc/adb: Use set_current_state()
        powerpc: Disable interrupts early in Program Check
        powerpc: Remove legacy iSeries from ppc64_defconfig
        powerpc/fsl/pci: Fix PCIe fixup regression
        powerpc: Fix kernel log of oops/panic instruction dump
      06ca7c43
    • L
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci · 7bcd5b46
      Linus Torvalds 提交于
      One regression fix for SR-IOV on PPC and a couple of misc fixes from
      Yinghai.
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci:
        PCI: Fix pci cardbus removal
        PCI: set pci sriov page size before reading SRIOV BAR
        PCI: workaround hard-wired bus number V2
      7bcd5b46
    • L
      Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux · 58e44baf
      Linus Torvalds 提交于
      3 radeon fixes, I have some exynos fixes to push later but I'll queue
      them separately once I've looked them over a bit.
      
      * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
        drm/radeon/kms: fix MSI re-arm on rv370+
        drm/radeon/kms/atom: bios scratch reg handling updates
        drm/radeon/kms: drop lock in return path of radeon_fence_count_emitted.
      58e44baf
    • L