1. 29 11月, 2013 1 次提交
  2. 28 11月, 2013 10 次提交
    • F
      i2c: bcm2835: Linking platform nodes to adapter nodes · 07a27a00
      Florian Meier 提交于
      In order to find I2C devices in the device tree, the platform nodes
      have to be known by the I2C core. This requires setting the
      dev.of_node parameter of the adapter.
      Signed-off-by: NFlorian Meier <florian.meier@koalo.de>
      Tested-by: NStephen Warren <swarren@wwwdotorg.org>
      Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
      07a27a00
    • I
    • D
      drm/sysfs: fix OOM verification · a1f84f57
      David Herrmann 提交于
      Copy/Paste typo.. we need to test for ->kdev instead of ->dev.
      Reported-by: NJuha Leppänen <juha_efku@dnainternet.net>
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      a1f84f57
    • D
      remove obsolete references to powertweak · dad33750
      Dave Jones 提交于
      This tool hasn't been maintained in over a decade, and is pretty much
      useless these days.  Let's pretend it never happened.
      
      Also remove a long-dead email address.
      Signed-off-by: NDave Jones <davej@fedoraproject.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      dad33750
    • N
      md/raid5: fix newly-broken locking in get_active_stripe. · 6d183de4
      NeilBrown 提交于
      commit 566c09c5 raid5: relieve lock contention in get_active_stripe()
      
      modified the locking in get_active_stripe() reducing the range
      protected by the (highly contended) device_lock.
      Unfortunately it reduced the range too much opening up some races.
      
      One race can occur if get_priority_stripe runs between the
      test on sh->count and device_lock being taken.
      This will mean that sh->lru is not empty while get_active_stripe
      thinks ->count is zero resulting in a 'BUG' firing.
      
      Another race happens if __release_stripe is called immediately
      after sh->count is tested and found to be non-zero.  If STRIPE_HANDLE
      is not set, get_active_stripe should increment ->active_stripes
      when it increments ->count from 0, but as it didn't think it was 0,
      it doesn't.
      
      Extending device_lock to cover the test on sh->count close these
      races.
      
      While we are here, fix the two BUG tests:
       -If count is zero, then lru really must not be empty, or we've
        lock the stripe_head somehow - no other tests are relevant.
       -STRIPE_ON_RELEASE_LIST is completely independent of ->lru so
        testing it is pointless.
      Reported-and-tested-by: NBrassow Jonathan <jbrassow@redhat.com>
      Reviewed-by: NShaohua Li <shli@kernel.org>
      Fixes: 566c09c5Signed-off-by: NNeilBrown <neilb@suse.de>
      6d183de4
    • N
      md: test mddev->flags more safely in md_check_recovery. · 142d44c3
      NeilBrown 提交于
      commit 7a0a5355 md: Don't test all of mddev->flags at once.
      made most tests on mddev->flags safer, but missed one.
      
      When
      commit 260fa034 md: avoid deadlock when dirty buffers during md_stop.
      added MD_STILL_CLOSED, this caused md_check_recovery to misbehave.
      It can think there is something to do but find nothing.  This can
      lead to the md thread spinning during array shutdown.
      
      https://bugzilla.kernel.org/show_bug.cgi?id=65721Reported-and-tested-by: NRichard W.M. Jones <rjones@redhat.com>
      Fixes: 260fa034
      Cc: stable@vger.kernel.org (3.12)
      Signed-off-by: NNeilBrown <neilb@suse.de>
      142d44c3
    • N
      md/raid5: fix new memory-reference bug in alloc_thread_groups. · 0c775d52
      NeilBrown 提交于
      In alloc_thread_groups, worker_groups is a pointer to an array,
      not an array of pointers.
      So
         worker_groups[i]
      is wrong.  It should be
         &(*worker_groups)[i]
      
      Found-by: coverity
      Fixes: 60aaf933Reported-by: NBen Hutchings <bhutchings@solarflare.com>
      Cc: majianpeng <majianpeng@gmail.com>
      Signed-off-by: NNeilBrown <neilb@suse.de>
      0c775d52
    • R
      ATA: Fix port removal ordering · c5700766
      Rafael J. Wysocki 提交于
      After commit bcdde7e2 (sysfs: make __sysfs_remove_dir() recursive)
      Mika Westerberg sees traces analogous to the one below in Thunderbolt
      hot-remove testing:
      
       WARNING: CPU: 0 PID: 4 at fs/sysfs/group.c:214 sysfs_remove_group+0xc6/0xd0()
       sysfs group ffffffff81c6f1e0 not found for kobject 'host7'
       Modules linked in:
       CPU: 0 PID: 4 Comm: kworker/0:0 Not tainted 3.12.0+ #13
       Hardware name:                  /D33217CK, BIOS GKPPT10H.86A.0042.2013.0422.1439 04/22/2013
       Workqueue: kacpi_hotplug acpi_hotplug_work_fn
        0000000000000009 ffff8801002459b0 ffffffff817daab1 ffff8801002459f8
        ffff8801002459e8 ffffffff810436b8 0000000000000000 ffffffff81c6f1e0
        ffff88006d440358 ffff88006d440188 ffff88006e8b4c28 ffff880100245a48
       Call Trace:
        [<ffffffff817daab1>] dump_stack+0x45/0x56
        [<ffffffff810436b8>] warn_slowpath_common+0x78/0xa0
        [<ffffffff81043727>] warn_slowpath_fmt+0x47/0x50
        [<ffffffff811ad319>] ? sysfs_get_dirent_ns+0x49/0x70
        [<ffffffff811ae526>] sysfs_remove_group+0xc6/0xd0
        [<ffffffff81432f7e>] dpm_sysfs_remove+0x3e/0x50
        [<ffffffff8142a0d0>] device_del+0x40/0x1b0
        [<ffffffff8142a24d>] device_unregister+0xd/0x20
        [<ffffffff8144131a>] scsi_remove_host+0xba/0x110
        [<ffffffff8145f526>] ata_host_detach+0xc6/0x100
        [<ffffffff8145f578>] ata_pci_remove_one+0x18/0x20
        [<ffffffff812e8f48>] pci_device_remove+0x28/0x60
        [<ffffffff8142d854>] __device_release_driver+0x64/0xd0
        [<ffffffff8142d8de>] device_release_driver+0x1e/0x30
        [<ffffffff8142d257>] bus_remove_device+0xf7/0x140
        [<ffffffff8142a1b1>] device_del+0x121/0x1b0
        [<ffffffff812e43d4>] pci_stop_bus_device+0x94/0xa0
        [<ffffffff812e437b>] pci_stop_bus_device+0x3b/0xa0
        [<ffffffff812e437b>] pci_stop_bus_device+0x3b/0xa0
        [<ffffffff812e44dd>] pci_stop_and_remove_bus_device+0xd/0x20
        [<ffffffff812fc743>] trim_stale_devices+0x73/0xe0
        [<ffffffff812fc78b>] trim_stale_devices+0xbb/0xe0
        [<ffffffff812fc78b>] trim_stale_devices+0xbb/0xe0
        [<ffffffff812fcb6e>] acpiphp_check_bridge+0x7e/0xd0
        [<ffffffff812fd90d>] hotplug_event+0xcd/0x160
        [<ffffffff812fd9c5>] hotplug_event_work+0x25/0x60
        [<ffffffff81316749>] acpi_hotplug_work_fn+0x17/0x22
        [<ffffffff8105cf3a>] process_one_work+0x17a/0x430
        [<ffffffff8105db29>] worker_thread+0x119/0x390
        [<ffffffff8105da10>] ? manage_workers.isra.25+0x2a0/0x2a0
        [<ffffffff81063a5d>] kthread+0xcd/0xf0
        [<ffffffff81063990>] ? kthread_create_on_node+0x180/0x180
        [<ffffffff817eb33c>] ret_from_fork+0x7c/0xb0
        [<ffffffff81063990>] ? kthread_create_on_node+0x180/0x180
      
      The source of this problem is that SCSI hosts are removed from
      ATA ports after calling ata_tport_delete() which removes the
      port's sysfs directory, among other things.  Now, after commit
      bcdde7e2, the sysfs directory is removed along with all of
      its subdirectories that include the SCSI host's sysfs directory
      and its subdirectories at this point.  Consequently, when
      device_del() is finally called for any child device of the SCSI
      host and tries to remove its "power" group (which is already
      gone then), it triggers the above warning.
      
      To make the warnings go away, change the removal ordering in
      ata_port_detach() so that the SCSI host is removed from the
      port before ata_tport_delete() is called.
      
      References: https://bugzilla.kernel.org/show_bug.cgi?id=65281Reported-and-tested-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Tested-by: NJingoo Han <jg1.han@samsung.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      c5700766
    • V
      i2c: omap: raw read and write endian fix · 40b13ca8
      Victor Kamensky 提交于
      All OMAP IP blocks expect LE data, but CPU may operate in BE mode.
      Need to use endian neutral functions to read/write h/w registers.
      I.e instead of __raw_read[lw] and __raw_write[lw] functions code
      need to use read[lw]_relaxed and write[lw]_relaxed functions.
      If the first simply reads/writes register, the second will byteswap
      it if host operates in BE mode.
      
      Changes are trivial sed like replacement of __raw_xxx functions
      with xxx_relaxed variant.
      Signed-off-by: NVictor Kamensky <victor.kamensky@linaro.org>
      Signed-off-by: NTaras Kondratiuk <taras.kondratiuk@linaro.org>
      Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
      40b13ca8
    • G
      Staging: tidspbridge: disable driver · 930ba4a3
      Greg Kroah-Hartman 提交于
      There seems to be no active maintainer for the driver, and there is an
      unfixed security bug, so disable the driver for now.
      
      Hopefully someone steps up to be the maintainer, and works to get this
      out of staging, otherwise it will be deleted soon.
      Reported-by: NNico Golde <nico@ngolde.de>
      Reported-by: NDan Carpenter <dan.carpenter@oracle.com>
      Cc: Omar Ramirez Luna <omar.ramirez@copitl.com>
      Cc: Omar Ramirez Luna <omar.ramirez@ti.com>
      Cc: Kanigeri, Hari <h-kanigeri2@ti.com>
      Cc: Ameya Palande <ameya.palande@nokia.com>
      Cc: Guzman Lugo, Fernando <fernando.lugo@ti.com>
      Cc: Hebbar, Shivananda <x0hebbar@ti.com>
      Cc: Ramos Falcon, Ernesto <ernesto@ti.com>
      Cc: Felipe Contreras <felipe.contreras@gmail.com>
      Cc: Anna, Suman <s-anna@ti.com>
      Cc: Gupta, Ramesh <grgupta@ti.com>
      Cc: Gomez Castellanos, Ivan <ivan.gomez@ti.com>
      Cc: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
      Cc: Armando Uribe De Leon <x0095078@ti.com>
      Cc: Deepak Chitriki <deepak.chitriki@ti.com>
      Cc: Menon, Nishanth <nm@ti.com>
      Cc: Phil Carmody <ext-phil.2.carmody@nokia.com>
      Cc: Ohad Ben-Cohen <ohad@wizery.com>
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      930ba4a3
  3. 27 11月, 2013 4 次提交
    • M
      gpio: bcm281xx: Fix return value of bcm_kona_gpio_get() · e2f0b005
      Markus Mayer 提交于
      We need to return the corresponding bit for a particular GPIO. This bit
      contains shift not mask.
      Signed-off-by: NMarkus Mayer <markus.mayer@linaro.org>
      Reviewed-by: NTim Kryger <tim.kryger@linaro.org>
      Reviewed-by: NMatt Porter <matt.porter@linaro.org>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      e2f0b005
    • L
      gpio: pl061: move irqdomain initialization · 2ba3154d
      Linus Walleij 提交于
      The PL061 driver had the irqdomain initialization in an unfortunate
      place: when used with device tree (and thus passing the base IRQ
      0) the driver would work, as this registers an irqdomain and waits
      for mappings to be done dynamically as the devices request their
      IRQs, whereas when booting using platform data the irqdomain core
      would attempt to allocate IRQ descriptors dynamically (which works
      fine) but also to associate the irq_domain_associate_many() on all
      IRQs, which in turn will call the mapping function which at this
      point will try to set the type of the IRQ and then tries to acquire
      a non-initialized spinlock yielding a backtrace like this:
      
      CPU: 0 PID: 1 Comm: swapper Not tainted 3.13.0-rc1+ #652
      Backtrace:
      [<c0016f0c>] (dump_backtrace) from [<c00172ac>] (show_stack+0x18/0x1c)
       r6:c798ace0 r5:00000000 r4:c78257e0 r3:00200140
      [<c0017294>] (show_stack) from [<c0329ea0>] (dump_stack+0x20/0x28)
      [<c0329e80>] (dump_stack) from [<c004fa80>] (__lock_acquire+0x1c0/0x1b80)
      [<c004f8c0>] (__lock_acquire) from [<c0051970>] (lock_acquire+0x6c/0x80)
       r10:00000000 r9:c0455234 r8:00000060 r7:c047d798 r6:600000d3 r5:00000000
       r4:c782c000
      [<c0051904>] (lock_acquire) from [<c032e484>] (_raw_spin_lock_irqsave+0x60/0x74)
       r6:c01a1100 r5:800000d3 r4:c798acd0
      [<c032e424>] (_raw_spin_lock_irqsave) from [<c01a1100>] (pl061_irq_type+0x28/0x)
       r6:00000000 r5:00000000 r4:c798acd0
      [<c01a10d8>] (pl061_irq_type) from [<c0059ef4>] (__irq_set_trigger+0x70/0x104)
       r6:00000000 r5:c01a10d8 r4:c046da1c r3:c01a10d8
      [<c0059e84>] (__irq_set_trigger) from [<c005b348>] (irq_set_irq_type+0x40/0x60)
       r10:c043240c r8:00000060 r7:00000000 r6:c046da1c r5:00000060 r4:00000000
      [<c005b308>] (irq_set_irq_type) from [<c01a1208>] (pl061_irq_map+0x40/0x54)
       r6:c79693c0 r5:c798acd0 r4:00000060
      [<c01a11c8>] (pl061_irq_map) from [<c005d27c>] (irq_domain_associate+0xc0/0x190)
       r5:00000060 r4:c046da1c
      [<c005d1bc>] (irq_domain_associate) from [<c005d604>] (irq_domain_associate_man)
       r8:00000008 r7:00000000 r6:c79693c0 r5:00000060 r4:00000000
      [<c005d5d0>] (irq_domain_associate_many) from [<c005d864>] (irq_domain_add_simp)
       r8:c046578c r7:c035b72c r6:c79693c0 r5:00000060 r4:00000008 r3:00000008
      [<c005d814>] (irq_domain_add_simple) from [<c01a1380>] (pl061_probe+0xc4/0x22c)
       r6:00000060 r5:c0464380 r4:c798acd0
      [<c01a12bc>] (pl061_probe) from [<c01c0450>] (amba_probe+0x74/0xe0)
       r10:c043240c r9:c0455234 r8:00000000 r7:c047d7f8 r6:c047d744 r5:00000000
       r4:c0464380
      
      This moves the irqdomain initialization to a point where the spinlock
      and GPIO chip are both fully propulated, so the callbacks can be used
      without crashes.
      
      I had some problem reproducing the crash, as the devm_kzalloc():ed
      zeroed memory would seemingly mask the spinlock as something OK,
      but by poisoning the lock like this:
      
      u32 *dum;
      dum = (u32 *) &chip->lock;
      *dum = 0xaaaaaaaaU;
      
      I could reproduce, fix and test the patch.
      Reported-by: NRussell King <linux@arm.linux.org.uk>
      Cc: Rob Herring <robherring2@gmail.com>
      Cc: Haojian Zhuang <haojian.zhuang@linaro.org>
      Cc: Baruch Siach <baruch@tkos.co.il>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      2ba3154d
    • D
      HID: uhid: fix leak for 64/32 UHID_CREATE · 80897aa7
      David Herrmann 提交于
      UHID allows short writes so user-space can omit unused fields. We
      automatically set them to 0 in the kernel. However, the 64/32 bit
      compat-handler didn't do that in the UHID_CREATE fallback. This will
      reveal random kernel heap data (of random size, even) to user-space.
      
      Fixes: befde022 ('HID: uhid: make creating devices work on 64/32 systems')
      Reported-by: NBen Hutchings <ben@decadent.org.uk>
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      80897aa7
    • B
      powerpc/windfarm: Fix XServe G5 fan control Makefile issue · 721cb59e
      Benjamin Herrenschmidt 提交于
      We are missing building windfarm_max6690_sensor.o when building
      CONFIG_WINDFARM_RM31. Usually all the windfarm drivers are built
      and thus this isn't a problem but some more "tailored" setups
      (Gentoo ?) building only that driver are not working because
      the require sensor module is missing.
      Reported-by: NStanislav Ponomarev <devhexorg@gmail.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      721cb59e
  4. 26 11月, 2013 25 次提交