1. 26 May, 2009 3 commits
    • Mathieu Desnoyers's avatar
      [CPUFREQ] remove rwsem lock from CPUFREQ_GOV_STOP call · 42a06f21
      Mathieu Desnoyers authored
      * Rafael J. Wysocki (rjw@sisk.pl) wrote:
      > This message has been generated automatically as a part of a report
      > of regressions introduced between 2.6.28 and 2.6.29.
      >
      > The following bug entry is on the current list of known regressions
      > introduced between 2.6.28 and 2.6.29.  Please verify if it still should
      > be listed and let me know (either way).
      >
      >
      > Bug-Entry	: http://bugzilla.kernel.org/show_bug.cgi?id=13186
      > Subject		: cpufreq timer teardown problem
      > Submitter	: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
      > Date		: 2009-04-23 14:00 (24 days old)
      > References	: http://marc.info/?l=linux-kernel&m=124049523515036&w=4
      > Handled-By	: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
      > Patch		: http://patchwork.kernel.org/patch/19754/
      > 		  http://patchwork.kernel.org/patch/19753/
      
      The patches linked above depend on the following patch to remove
      circular locking dependency :
      
      cpufreq: remove rwsem lock from CPUFREQ_GOV_STOP call
      
      (the following issue was faced when using cancel_delayed_work_sync() in the
      timer teardown (which fixes a race).
      
      * KOSAKI Motohiro (kosaki.motohiro@jp.fujitsu.com) wrote:
      > Hi
      >
      > my box output following warnings.
      > it seems regression by commit 7ccc7608b836e58fbacf65ee4f8eefa288e86fac.
      >
      > A: work -> do_dbs_timer()  -> cpu_policy_rwsem
      > B: store() -> cpu_policy_rwsem -> cpufreq_governor_dbs() -> work
      >
      >
      
      Hrm, I think it must be due to my attempt to fix the timer teardown race
      in ondemand governor mixed with new locking behavior in 2.6.30-rc.
      
      The rwlock seems to be taken around the whole call to
      cpufreq_governor_dbs(), when it should be only taken around accesses to
      the locked data, and especially *not* around the call to
      dbs_timer_exit().
      
      Reverting my fix attempt would put the teardown race back in place
      (replacing the cancel_delayed_work_sync by cancel_delayed_work).
      Instead, a proper fix would imply modifying this critical section :
      
      cpufreq.c: __cpufreq_remove_dev()
      ...
              if (cpufreq_driver->target)
                      __cpufreq_governor(data, CPUFREQ_GOV_STOP);
      
              unlock_policy_rwsem_write(cpu);
      
      To make sure the __cpufreq_governor() callback is not called with rwsem
      held. This would allow execution of cancel_delayed_work_sync() without
      being nested within the rwsem.
      
      Applies on top of the 2.6.30-rc5 tree.
      
      Required to remove circular dep in teardown of both conservative and
      ondemande governors so they can use cancel_delayed_work_sync().
      CPUFREQ_GOV_STOP does not modify the policy, therefore this locking seemed
      unneeded.
      Signed-off-by: default avatarMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
      CC: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
      Cc: Greg KH <greg@kroah.com>
      CC: Ingo Molnar <mingo@elte.hu>
      CC: "Rafael J. Wysocki" <rjw@sisk.pl>
      CC: Ben Slusky <sluskyb@paranoiacs.org>
      CC: Chris Wright <chrisw@sous-sol.org>
      CC: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarDave Jones <davej@redhat.com>
      42a06f21
    • Dave Jones's avatar
      [CPUFREQ] powernow-k7 build fix when ACPI=n · d38e73e8
      Dave Jones authored
      arch/x86/kernel/cpu/cpufreq/powernow-k7.c:172: warning: 'invalidate_entry' defined but not used
      Reported-by: default avatarToralf Förster <toralf.foerster@gmx.de>
      Signed-off-by: default avatarDave Jones <davej@redhat.com>
      d38e73e8
    • Jarod Wilson's avatar
      [CPUFREQ] add atom family to p4-clockmod · 43195037
      Jarod Wilson authored
      Some atom procs don't do freq scaling (such as the atom 330 on my own
      littlefalls2 board). By adding the atom family here, we at least get
      the benefit of passive cooling in a thermal emergency. Not sure how
      to see that its actually helping any, but the driver does bind and
      claim its functioning on my atom 330.
      Signed-off-by: default avatarJarod Wilson <jarod@redhat.com>
      Signed-off-by: default avatarDave Jones <davej@redhat.com>
      43195037
  2. 25 May, 2009 6 commits
  3. 24 May, 2009 3 commits
  4. 23 May, 2009 5 commits
    • Linus Torvalds's avatar
      Linux 2.6.30-rc7 · 59a3759d
      Linus Torvalds authored
      59a3759d
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6 · 4a5dacec
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6:
        [SCSI] mpt2sas: fix driver version inconsistency
        [SCSI] 3w-xxxx: scsi_dma_unmap fix
        [SCSI] 3w-9xxx: scsi_dma_unmap fix
        [SCSI] ses: fix problems caused by empty SES provided name
        [SCSI] fc-transport: Close state transition-window during rport deletion.
        [SCSI] initialize max_target_blocked in scsi_alloc_target
        [SCSI] fnic: Add new Cisco PCI-Express FCoE HBA
      4a5dacec
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6 · 3eb9c8be
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
        [CIFS] Avoid open on possible directories since Samba now rejects them
      3eb9c8be
    • Steve French's avatar
      [CIFS] Avoid open on possible directories since Samba now rejects them · 8db14ca1
      Steve French authored
      Small change (mostly formatting) to limit lookup based open calls to
      file create only.
      
      After discussion yesteday on samba-technical about the posix lookup
      regression,  and looking at a problem with cifs posix open to one
      particular Samba version, Jeff and JRA realized that Samba server's
      behavior changed in this area (posix open behavior on files vs.
      directories).   To make this behavior consistent, JRA just made a
      fix to Samba server to alter how it handles open of directories (now
      returning the equivalent of EISDIR instead of success). Since we don't
      know at lookup time whether the inode is a directory or file (and
      thus whether posix open will succeed with most current Samba server),
      this change avoids the posix open code on lookup open (just issues
      posix open on creates).    This gets the semantic benefits we want
      (atomicity, posix byte range locks, improved write semantics on newly
      created files) and file create still is fast, and we avoid the problem
      that Jeff noticed yesterday with "openat" (and some open directory
      calls) of non-cached directories to one version of Samba server, and
      will work with future Samba versions (which include the fix jra just
      pushed into Samba server).  I confirmed this approach with jra
      yesterday and with Shirish today.
      
      Posix open is only called (at lookup time) for file create now.
      For opens (rather than creates), because we do not know if it
      is a file or directory yet, and current Samba no longer allows
      us to do posix open on dirs, we could end up wasting an open call
      on what turns out to be a dir. For file opens, we wait to call posix
      open till cifs_open.  It could be added here (lookup) in the future
      but the performance tradeoff of the extra network request when EISDIR
      or EACCES is returned would have to be weighed against the 50%
      reduction in network traffic in the other paths.
      Reviewed-by: default avatarShirish Pargaonkar <shirishp@us.ibm.com>
      Tested-by: default avatarJeff Layton <jlayton@redhat.com>
      CC: Jeremy Allison <jra@samba.org>
      Signed-off-by: default avatarSteve French <sfrench@us.ibm.com>
      8db14ca1
    • Breno Leitao's avatar
      icom: fix rmmod crash · 95caa0a9
      Breno Leitao authored
      Actually the icom driver is crashing when is being removed because
      the driver is kfreeing the adapter structure before calling
      pci_release_regions(), which result in the following error:
      
        Unable to handle kernel paging request for data at address 0x6b6b6b6b6b6b6d33
        Faulting instruction address: 0xc000000000246b80
        Oops: Kernel access of bad area, sig: 11 [#1]
        ....
        [c000000012d436a0] [c0000000001002d0] .kfree+0x120/0x34c (unreliable)
        [c000000012d43730] [c000000000246d60] .pci_release_selected_regions+0x3c/0x68
        [c000000012d437c0] [d000000002d54700] .icom_kref_release+0xf4/0x118 [icom]
        [c000000012d43850] [c000000000232e50] .kref_put+0x74/0x94
        [c000000012d438d0] [d000000002d56c58] .icom_remove+0x40/0xa4 [icom]
        [c000000012d43960] [c000000000249e48] .pci_device_remove+0x50/0x90
        [c000000012d439e0] [c0000000002d68d8] .__device_release_driver+0x94/0xd4
        [c000000012d43a70] [c0000000002d7104] .driver_detach+0xf8/0x12c
        [c000000012d43b00] [c0000000002d549c] .bus_remove_driver+0xbc/0x11c
        [c000000012d43b90] [c0000000002d71dc] .driver_unregister+0x60/0x80
        [c000000012d43c20] [c00000000024a07c] .pci_unregister_driver+0x44/0xe8
        [c000000012d43cb0] [d000000002d56bf4] .icom_exit+0x1c/0x40 [icom]
        [c000000012d43d30] [c000000000095fa8] .SyS_delete_module+0x214/0x2a8
        [c000000012d43e30] [c00000000000852c] syscall_exit+0x0/0x40
      Signed-off-by: default avatarBreno Leitao <leitao@linux.vnet.ibm.com>
      Cc: stable@kernel.org
      Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      95caa0a9
  5. 22 May, 2009 23 commits