1. 08 5月, 2012 2 次提交
    • J
      jffs2: Fix lock acquisition order bug in gc path · 226bb7df
      Josh Cartwright 提交于
      The locking policy is such that the erase_complete_block spinlock is
      nested within the alloc_sem mutex.  This fixes a case in which the
      acquisition order was erroneously reversed.  This issue was caught by
      the following lockdep splat:
      
         =======================================================
         [ INFO: possible circular locking dependency detected ]
         3.0.5 #1
         -------------------------------------------------------
         jffs2_gcd_mtd6/299 is trying to acquire lock:
          (&c->alloc_sem){+.+.+.}, at: [<c01f7714>] jffs2_garbage_collect_pass+0x314/0x890
      
         but task is already holding lock:
          (&(&c->erase_completion_lock)->rlock){+.+...}, at: [<c01f7708>] jffs2_garbage_collect_pass+0x308/0x890
      
         which lock already depends on the new lock.
      
         the existing dependency chain (in reverse order) is:
      
         -> #1 (&(&c->erase_completion_lock)->rlock){+.+...}:
                [<c008bec4>] validate_chain+0xe6c/0x10bc
                [<c008c660>] __lock_acquire+0x54c/0xba4
                [<c008d240>] lock_acquire+0xa4/0x114
                [<c046780c>] _raw_spin_lock+0x3c/0x4c
                [<c01f744c>] jffs2_garbage_collect_pass+0x4c/0x890
                [<c01f937c>] jffs2_garbage_collect_thread+0x1b4/0x1cc
                [<c0071a68>] kthread+0x98/0xa0
                [<c000f264>] kernel_thread_exit+0x0/0x8
      
         -> #0 (&c->alloc_sem){+.+.+.}:
                [<c008ad2c>] print_circular_bug+0x70/0x2c4
                [<c008c08c>] validate_chain+0x1034/0x10bc
                [<c008c660>] __lock_acquire+0x54c/0xba4
                [<c008d240>] lock_acquire+0xa4/0x114
                [<c0466628>] mutex_lock_nested+0x74/0x33c
                [<c01f7714>] jffs2_garbage_collect_pass+0x314/0x890
                [<c01f937c>] jffs2_garbage_collect_thread+0x1b4/0x1cc
                [<c0071a68>] kthread+0x98/0xa0
                [<c000f264>] kernel_thread_exit+0x0/0x8
      
         other info that might help us debug this:
      
          Possible unsafe locking scenario:
      
                CPU0                    CPU1
                ----                    ----
           lock(&(&c->erase_completion_lock)->rlock);
                                        lock(&c->alloc_sem);
                                        lock(&(&c->erase_completion_lock)->rlock);
           lock(&c->alloc_sem);
      
          *** DEADLOCK ***
      
         1 lock held by jffs2_gcd_mtd6/299:
          #0:  (&(&c->erase_completion_lock)->rlock){+.+...}, at: [<c01f7708>] jffs2_garbage_collect_pass+0x308/0x890
      
         stack backtrace:
         [<c00155dc>] (unwind_backtrace+0x0/0x100) from [<c0463dc0>] (dump_stack+0x20/0x24)
         [<c0463dc0>] (dump_stack+0x20/0x24) from [<c008ae84>] (print_circular_bug+0x1c8/0x2c4)
         [<c008ae84>] (print_circular_bug+0x1c8/0x2c4) from [<c008c08c>] (validate_chain+0x1034/0x10bc)
         [<c008c08c>] (validate_chain+0x1034/0x10bc) from [<c008c660>] (__lock_acquire+0x54c/0xba4)
         [<c008c660>] (__lock_acquire+0x54c/0xba4) from [<c008d240>] (lock_acquire+0xa4/0x114)
         [<c008d240>] (lock_acquire+0xa4/0x114) from [<c0466628>] (mutex_lock_nested+0x74/0x33c)
         [<c0466628>] (mutex_lock_nested+0x74/0x33c) from [<c01f7714>] (jffs2_garbage_collect_pass+0x314/0x890)
         [<c01f7714>] (jffs2_garbage_collect_pass+0x314/0x890) from [<c01f937c>] (jffs2_garbage_collect_thread+0x1b4/0x1cc)
         [<c01f937c>] (jffs2_garbage_collect_thread+0x1b4/0x1cc) from [<c0071a68>] (kthread+0x98/0xa0)
         [<c0071a68>] (kthread+0x98/0xa0) from [<c000f264>] (kernel_thread_exit+0x0/0x8)
      
      This was introduce in '81cfc9f1 jffs2: Fix serious write stall due to erase'.
      
      Cc: stable@kernel.org [2.6.37+]
      Signed-off-by: NJosh Cartwright <joshc@linux.com>
      Signed-off-by: NArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
      Signed-off-by: NDavid Woodhouse <David.Woodhouse@intel.com>
      226bb7df
    • W
      mtd: fix oops in dataflash driver · 7a84477c
      Will Newton 提交于
      I'm seeing an oops in mtd_dataflash.c with Linux 3.3. What appears to
      be happening is that otp_select_filemode calls mtd_read_fact_prot_reg
      with -1 for offset and length and a NULL buffer to test if OTP
      operations are supported. This finds its way down to otp_read in
      mtd_dataflash.c and causes an oops when memcpying the returned data
      into the NULL buf.
      
      None of the checks in otp_read catches the negative length and offset.
      Changing the length of the dummy read to 0 prevents the oops.
      
      Cc: stable@kernel.org [3.3+]
      Signed-off-by: NArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
      Signed-off-by: NDavid Woodhouse <David.Woodhouse@intel.com>
      7a84477c
  2. 22 4月, 2012 6 次提交
    • L
      Linux 3.4-rc4 · 66f75a5d
      Linus Torvalds 提交于
      66f75a5d
    • Y
      sparc32,leon: add notify_cpu_starting() · e9a5ea18
      Yong Zhang 提交于
      Otherwise cpu_active_mask will not set, which lead to other issue.
      Signed-off-by: NYong Zhang <yong.zhang0@gmail.com>
      Signed-off-by: NKonrad Eisele <konrad@gaisler.com>
      Reviewed-by: NSrivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e9a5ea18
    • L
      Merge tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · 8f4f9d4d
      Linus Torvalds 提交于
      Pull "ARM: SoC fixes" from Olof Johansson:
       * at91, ux500, imx, omap and bcmring:
        - at91 fixes for =m driver build issues, irqdomain fixes and config
          dependency fixes
        - ux500 kconfig dependency fixes and a  smp wakeup bugfix
        - imx idle bugfix and build fix due to irq domain changes
        - omap uart pinmux fixes, softreset regression revert and misc fixes
        - bcmring build error regression fix
      
       * ux500 and imx had some small defconfig updates in this branch
      
      * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (27 commits)
        ARM: bcmring: fix UART declarations
        ARM: imx: Fix imx5 idle logic bug
        ARM: imx27-dt: Fix build due to removal of irq_domain_add_simple()
        ARM: imx_v4_v5_defconfig: Add support for CONFIG_REGULATOR_FIXED_VOLTAGE
        ARM: OMAP1: DMTIMER: fix broken timer clock source selection
        ARM: OMAP: serial: Fix the ocp smart idlemode handling bug
        ARM: OMAP2+: UART: Fix incorrect population of default uart pads
        ARM: OMAP: sram: fix BUG in dpll code for !PM case
        dmaengine: Kconfig: fix Atmel at_hdmac entry
        USB: gadget/at91_udc: add gpio_to_irq() function to vbus interrupt
        USB: ohci-at91: change annotations for probe/remove functions
        leds-atmel-pwm.c: Make pwmled_probe() __devinit
        ARM: at91: fix at91sam9261ek Ethernet dm9000 irq
        ARM: at91: fix rm9200ek flash size
        ARM: at91: remove empty at91_init_serial function
        ARM: at91: fix typo in at91_pmc_base assembly declaration
        ARM: at91: Export at91_matrix_base
        ARM: at91: Export at91_pmc_base
        ARM: at91: Export at91_ramc_base
        ARM: at91: Export at91_st_base
        ...
      8f4f9d4d
    • L
      Merge tag 'mmc-fixes-for-3.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc · 126a3483
      Linus Torvalds 提交于
      Pull MMC fixes from Chris Ball:
       - Build fix for omap_hsmmc with OF against 3.4-rc1.
       - Fix CONFIG_MMC_UNSAFE_RESUME semantics regression against 3.3, which
         broke hotplug card detection when UNSAFE_RESUME is set.
       - Fix a race condition in omap_hsmmc with runtime PM.
       - Fix two libertas SDIO-powered-resume regressions.
       - Small fixes for discard/sanitize, dw_mmc, cd-gpio and esdhc-imx.
      
      * tag 'mmc-fixes-for-3.4-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc:
        mmc: core: Do not pre-claim host in suspend
        mmc: dw_mmc: prevent NULL dereference for dma_ops
        mmc: unbreak sdhci-esdhc-imx on i.MX25
        mmc: cd-gpio: Include header to pickup exported symbol prototypes
        mmc: sdhci: refine non-removable card checking for card detection
        mmc: dw_mmc: Fix switch from DMA to PIO
        mmc: remove MMC bus legacy suspend/resume method
        mmc: omap_hsmmc: Get rid of of_have_populated_dt() usage
        mmc: omap_hsmmc: build fix for CONFIG_OF=y and CONFIG_MMC_OMAP_HS=m
        mmc: fixes for eMMC v4.5 sanitize operation
        mmc: fixes for eMMC v4.5 discard operation
      126a3483
    • L
      Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media · 88981596
      Linus Torvalds 提交于
      Pull media fixes from Mauro Carvalho Chehab:
       - Fixes a regression at DVB core when switching from DVB-S2 to DVB-S on
         Kaffeine (Fedora 16 Bugzilla #812895);
       - Fixes a mutex unlock at an error condition at drx-k;
       - Fix winbond-cir set mode;
       - mt9m032: Fix a compilation breakage with some random Kconfig;
       - mt9m032: fix two dead locks;
       - xc5000: don't require an special firmware (that won't be provided by
         the vendor) just because the xtal frequency is different;
       - V4L DocBook: fix some typos at multi-plane formats description.
      
      * 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
        [media] xc5000: support 32MHz & 31.875MHz xtal using the 41.024.5 firmware
        [media] V4L: mt9m032: fix compilation breakage
        [media] V4L: DocBook: Fix typos in the multi-plane formats description
        [media] V4L: mt9m032: fix two dead-locks
        [media] rc-core: set mode for winbond-cir
        [media] drxk: Does not unlock mutex if sanity check failed in scu_command()
        [media] dvb_frontend: Fix a regression when switching back to DVB-S
      88981596
    • L
      Merge tag 'mfd-for-linus-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6 · 9f24ff6f
      Linus Torvalds 提交于
      Pull MFD fixes from Samuel Ortiz:
       "We have 3 build fixes, a OMAP USB host PHY reset fix and the twl6040
        conversion to an i2c driver.  The latter may not sound like a fix but
        the twl6040 MFD driver won't probe without it, triggering an OMAP4
        audio regression."
      
      * tag 'mfd-for-linus-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6:
        mfd: Fix modular builds of rc5t583 regulator support
        mfd: Fix asic3_gpio_to_irq
        ARM: OMAP3: USB: Fix the EHCI ULPI PHY reset issue
        mfd: Convert twl6040 to i2c driver, and separate it from twl core
        mfd : Fix dbx500 compilation error
      9f24ff6f
  3. 21 4月, 2012 28 次提交
  4. 20 4月, 2012 4 次提交