13 years agofirewire: reorder struct fw_card for better cache efficiency
Stefan Richter [Sat, 29 Nov 2008 18:00:56 +0000 (19:00 +0100)]
firewire: reorder struct fw_card for better cache efficiency

topology_map is by far the largest member in struct fw_card.  Move it to
the very end of the struct so that card pointer dereferences have better
chances to hit the CPU cache.

This requires to increase the topology_map backing store to the size
specified in IEEE 1394, i.e. 256 rather than 255 quadlets.  Otherwise
the topology_map response handler may access invalid memory.

Signed-off-by: Stefan Richter <>
13 years agofirewire: fix resetting of bus manager retry counter
Stefan Richter [Sat, 29 Nov 2008 17:56:47 +0000 (18:56 +0100)]
firewire: fix resetting of bus manager retry counter

An earlier change, maybe long ago, removed the copying of self_id_count
into card->self_id_count.  Since then each bus reset cleared
card->bm_retries even when it shouldn't.

Signed-off-by: Stefan Richter <>
13 years agofirewire: improve refcounting of fw_card
Jay Fenlason [Sat, 29 Nov 2008 16:44:57 +0000 (17:44 +0100)]
firewire: improve refcounting of fw_card

Take a reference to the card whenever fw_card_bm_work() is scheduled on
that card and release it when the work is done.  This allows us to
remove the cancel_delayed_work_sync() in fw_core_remove_card().

Signed-off-by: Jay Fenlason <>
Signed-off-by: Stefan Richter <> (patch update)
13 years agofirewire: typo in comment
Jay Fenlason [Wed, 22 Oct 2008 19:59:42 +0000 (15:59 -0400)]
firewire: typo in comment

Signed-off-by: Jay Fenlason <>
Signed-off-by: Stefan Richter <>
13 years agofirewire: fix small memory leak at module removal
Stefan Richter [Mon, 24 Nov 2008 19:40:00 +0000 (20:40 +0100)]
firewire: fix small memory leak at module removal

Signed-off-by: Stefan Richter <>
13 years agofirewire: fw-sbp2: remove unnecessary locking
Stefan Richter [Sun, 26 Oct 2008 10:04:20 +0000 (11:04 +0100)]
firewire: fw-sbp2: remove unnecessary locking

What was I thinking when I added sbp2_set_generation()?  Its locking did
nothing (except for implicitly providing the necessary barrier between
node IDs update and generation update).

Signed-off-by: Stefan Richter <>
13 years agoieee1934: dv1394: interrupt enabling/disabling broken on big-endian
Harvey Harrison [Sat, 13 Dec 2008 23:21:29 +0000 (15:21 -0800)]
ieee1934: dv1394: interrupt enabling/disabling broken on big-endian

After annotating the frame structs, this was left:
drivers/ieee1394/dv1394.c:2113:23: warning: invalid assignment: |=
drivers/ieee1394/dv1394.c:2113:23:    left side has type restricted __le32
drivers/ieee1394/dv1394.c:2113:23:    right side has type int
drivers/ieee1394/dv1394.c:2121:24: warning: invalid assignment: &=
drivers/ieee1394/dv1394.c:2121:24:    left side has type restricted __le32
drivers/ieee1394/dv1394.c:2121:24:    right side has type int
drivers/ieee1394/dv1394.c:2123:24: warning: invalid assignment: |=
drivers/ieee1394/dv1394.c:2123:24:    left side has type restricted __le32
drivers/ieee1394/dv1394.c:2123:24:    right side has type int

Which looks like a real bug on a big-endian arch as it would set/clear
the wrong bit.

Signed-off-by: Harvey Harrison <>
Bill Fink writes:

I finally got a chance to test the patch on my kernel, and live DV
viewing using xine still worked fine.  Although I admit to being
mystified how it works both before and after the patch, since the
cpu_to_le32() calls that were added should result in byte swapping on
PPC that wasn't being done before.  I guess that either the code paths
involved aren't actually being triggered by my xine DV viewing, or
there's some fortuitous palindromic setting of bits.

Tested-by: Bill Fink <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: dv1394: annotate frame input/output structs as little endian
Harvey Harrison [Sat, 13 Dec 2008 23:20:39 +0000 (15:20 -0800)]
ieee1394: dv1394: annotate frame input/output structs as little endian

No Functional changes.

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: eth1394: trivial sparse annotations
Harvey Harrison [Sat, 13 Dec 2008 23:03:06 +0000 (15:03 -0800)]
ieee1394: eth1394: trivial sparse annotations

Mostly annotations of ether_type as a be16.

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: mark bus_info_data as a __be32 array
Harvey Harrison [Sat, 13 Dec 2008 23:02:34 +0000 (15:02 -0800)]
ieee1394: mark bus_info_data as a __be32 array

Two access functions get_max_rom and set_hw_config_rom are
changed to take __be32 as well.  Only bus_info_data was
ever passed in so this is OK.  All other uses of bus_info_data
treated it as a be32 value already.

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: replace CSR_SET_BUS_INFO_GENERATION macro
Harvey Harrison [Sat, 13 Dec 2008 23:02:21 +0000 (15:02 -0800)]
ieee1394: replace CSR_SET_BUS_INFO_GENERATION macro

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: pcilynx: trivial endian annotation
Harvey Harrison [Sat, 13 Dec 2008 23:01:50 +0000 (15:01 -0800)]
ieee1394: pcilynx: trivial endian annotation

bus_info_block was treated as a be32 everywhere, annotate
as such.  Removes plenty of sparse warnings.

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: ignore nonzero Bus_Info_Block.max_rom, fetch config ROM in quadlets
Stefan Richter [Sat, 13 Dec 2008 22:12:06 +0000 (23:12 +0100)]
ieee1394: ignore nonzero Bus_Info_Block.max_rom, fetch config ROM in quadlets

It is already known that buggy firmwares exist which report a bogus
link_spd in their config ROM bus info block.  We now got the first
report of a bogus max_rom too (Freecom FireWire Hard Drive 1TB,

I suspect other OSs only use quadlet reads to fetch the config ROM,
otherwise the firmware authors would have noticed their mistake.
Hence limit ieee1394's config ROM fetching routine to quadlets as the
safe minimum regardless of what the bus info block says.

This will potentially slow the bus reset handling by nodemgr somewhat
down.  But most existing devices support only quadlet reads anyway,
hence there will often be no actual difference to before this change.

Signed-off-by: Stefan Richter <>
13 years agoieee1394: consolidate uses of IEEE1934_BUSID_MAGIC
Harvey Harrison [Sat, 13 Dec 2008 05:57:50 +0000 (21:57 -0800)]
ieee1394: consolidate uses of IEEE1934_BUSID_MAGIC

Move the definition out of nodemgr.h and use it in csr.c/pcilynx.c

Signed-off-by: Harvey Harrison <>
Signed-off-by: Stefan Richter <>
13 years agoieee1394: ohci1394: flush MMIO writes before delay in initialization
Stefan Richter [Sat, 6 Dec 2008 16:35:59 +0000 (17:35 +0100)]
ieee1394: ohci1394: flush MMIO writes before delay in initialization

and replace busy-wait by msleep.

Signed-off-by: Stefan Richter <>
13 years agoieee1394: ohci1394: pass error codes from request_irq through
Stefan Richter [Sat, 6 Dec 2008 16:35:20 +0000 (17:35 +0100)]
ieee1394: ohci1394: pass error codes from request_irq through

Signed-off-by: Stefan Richter <>
13 years agoieee1394: ohci1394: don't leave interrupts enabled during suspend/resume
Frans Pop [Sat, 6 Dec 2008 14:36:47 +0000 (15:36 +0100)]
ieee1394: ohci1394: don't leave interrupts enabled during suspend/resume

On my HP 2510p I get the following in dmesg during near the end of most
resumes from suspend to RAM:

irq 19: nobody cared (try booting with the "irqpoll" option)
Pid: 0, comm: swapper Not tainted 2.6.28-rc7 #67
Call Trace:
 <IRQ>  [<ffffffffa00ee9e1>] ? ohci_irq_handler+0x60/0x7e9 [ohci1394]
 [<ffffffff8026aa4d>] __report_bad_irq+0x38/0x87
 [<ffffffff8026abaa>] note_interrupt+0x10e/0x174
 [<ffffffff8026b262>] handle_fasteoi_irq+0xa7/0xd1
 [<ffffffff8020eb87>] do_IRQ+0x73/0xe4
 [<ffffffff8020c626>] ret_from_intr+0x0/0xa
 <EOI>  [<ffffffffa0012606>] ? acpi_idle_enter_bm+0x26b/0x2b2 [processor]
 [<ffffffffa00125fc>] ? acpi_idle_enter_bm+0x261/0x2b2 [processor]
 [<ffffffff8024f30f>] ? notifier_call_chain+0x33/0x5b
 [<ffffffff803b9c64>] ? cpuidle_idle_call+0x8c/0xc4
 [<ffffffff8020b312>] ? cpu_idle+0x4a/0x9a
 [<ffffffff8042c5c8>] ? rest_init+0x5c/0x5e
[<ffffffffa00ee981>] (ohci_irq_handler+0x0/0x7e9 [ohci1394])
Disabling IRQ #19

There also seems to be an interrupt storm during suspend/resume when this
 19:      99968         33   IO-APIC-fasteoi   ohci1394

This patch gets rid of both issues and makes the resume as a whole
significantly faster.

Signed-off-by: Frans Pop <>
As was pointed out in, this does not
fix the cause of the interrupt storm.  However, since the source of the
interrupts could not be determined yet, we make the system at least more
usable with this change.

Signed-off-by: Stefan Richter <>
13 years agoieee1394: mark all hpsb_address_ops instances as const
Stefan Richter [Wed, 26 Nov 2008 00:35:21 +0000 (01:35 +0100)]
ieee1394: mark all hpsb_address_ops instances as const

These are never modified.

Signed-off-by: Stefan Richter <>
13 years agoieee1394: replace a GFP_ATOMIC by GFP_KERNEL allocation
Stefan Richter [Wed, 26 Nov 2008 00:34:55 +0000 (01:34 +0100)]
ieee1394: replace a GFP_ATOMIC by GFP_KERNEL allocation

All callers of hpsb_register_addrspace() can sleep.

Signed-off-by: Stefan Richter <>
13 years agoLinux 2.6.28 v2.6.28
Linus Torvalds [Wed, 24 Dec 2008 23:26:37 +0000 (15:26 -0800)]
Linux 2.6.28

Happy holidays..

13 years agoMerge branch 'for_linus' of git://
Linus Torvalds [Wed, 24 Dec 2008 18:24:52 +0000 (10:24 -0800)]
Merge branch 'for_linus' of git://git./linux/kernel/git/mchehab/linux-2.6

* 'for_linus' of git://
  V4L/DVB (9920): em28xx: fix NULL pointer dereference in call to VIDIOC_INT_RESET command
  V4L/DVB (9908a): MAINTAINERS: mark linux-uvc-devel as subscribers only
  V4L/DVB (9906): v4l2-compat: test for unlocked_ioctl as well.
  V4L/DVB (9885): drivers/media Kconfig's: fix bugzilla #12204
  V4L/DVB (9875): gspca - main: Fix vidioc_s_jpegcomp locking.
  V4L/DVB (9781): [PATCH] Cablestar 2 I2C retries (fix CableStar2 support)
  V4L/DVB (9780): dib0700: Stop repeating after user stops pushing button

13 years agoMerge branch 'x86-fixes-for-linus' of git://
Linus Torvalds [Wed, 24 Dec 2008 18:24:14 +0000 (10:24 -0800)]
Merge branch 'x86-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://
  x86: disable X86_PTRACE_BTS

13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Wed, 24 Dec 2008 18:23:21 +0000 (10:23 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://
  ALSA: hda - Add missing terminators in patch_sigmatel.c

13 years agoALSA: hda - Add missing terminators in patch_sigmatel.c
Herton Ronaldo Krzesinski [Tue, 23 Dec 2008 18:53:00 +0000 (16:53 -0200)]
ALSA: hda - Add missing terminators in patch_sigmatel.c

Signed-off-by: Herton Ronaldo Krzesinski <>
Signed-off-by: Takashi Iwai <>
13 years agox86: disable X86_PTRACE_BTS
Ingo Molnar [Wed, 24 Dec 2008 09:49:51 +0000 (10:49 +0100)]
x86: disable X86_PTRACE_BTS

there's a new ptrace arch level feature in .28:

  config X86_PTRACE_BTS
  bool "Branch Trace Store"

it has broken fork() handling: the old DS area gets copied over into
a new task without clearing it.

Fixes exist but they came too late:

  c5dee61: x86, bts: memory accounting
  bf53de9: x86, bts: add fork and exit handling

and are queued up for v2.6.29. This shows that the facility is still not
tested well enough to release into a stable kernel - disable it for now and
reactivate in .29. In .29 the hardware-branch-tracer will use the DS/BTS
facilities too - hopefully resulting in better code.

Signed-off-by: Ingo Molnar <>
13 years agoparisc: disable UP-optimized flush_tlb_mm
Kyle McMartin [Tue, 23 Dec 2008 13:44:30 +0000 (08:44 -0500)]
parisc: disable UP-optimized flush_tlb_mm

flush_tlb_mm's "optimized" uniprocessor case of allocating a new
context for userspace is exposing a race where we can suddely return
to a syscall with the protection id and space id out of sync, trapping
on the next userspace access.

Debugged-by: James Bottomley <>
Tested-by: Helge Deller <>
Signed-off-by: Kyle McMartin <>
Signed-off-by: Linus Torvalds <>
13 years agoMerge branch 'drm-fixes' of git://
Linus Torvalds [Wed, 24 Dec 2008 01:01:40 +0000 (17:01 -0800)]
Merge branch 'drm-fixes' of git://git./linux/kernel/git/airlied/drm-2.6

* 'drm-fixes' of git://
  drm/radeon: fix correctness of irq_enabled check for radeon.

13 years agoedac: fix edac core deadlock when removing a device
Harry Ciao [Tue, 23 Dec 2008 21:57:16 +0000 (13:57 -0800)]
edac: fix edac core deadlock when removing a device

When deleting an edac device, we have to wait for its to be
completed before deleting the whole edac_dev structure.  Since we have no
idea which work in current edac_poller's workqueue is the work we are
conerned about, we wait for all work in the edac_poller's workqueue to be
proceseed.  This is done via flush_cpu_workqueue() which inserts a
wq_barrier into the tail of the workqueue and then sleeping on the
completion of this wq_barrier.  The edac_poller will wake up sleepers when
it is found.

EDAC core creates only one kernel worker thread, edac_poller, to run the
works of all current edac devices.  They share the same callback function
of edac_device_workq_function(), which would grab the mutex of
device_ctls_mutex first before it checks the device.  This is exactly
where edac_poller and rmmod would have a great chance to deadlock.

In below call trace of rmmod > ... >
edac_device_del_device >
edac_device_workq_teardown > flush_workqueue > flush_cpu_workqueue,

device_ctls_mutex would have already been grabbed by
edac_device_del_device().  So, on one hand rmmod would sleep on the
completion of a wq_barrier, holding device_ctls_mutex; on the other hand
edac_poller would be blocked on the same mutex when it's running any one
of works of existing edac evices(Note, this is likely to be
totally irrelevant to the one that is being removed right now)and never
would have a chance to run the work of above wq_barrier to wake rmmod up.

edac_device_workq_teardown() should not be called within the critical
region of device_ctls_mutex.  Just like is done in edac_pci_del_device()
and edac_mc_del_mc(), where edac_pci_workq_teardown() and
edac_mc_workq_teardown() are called after related mutex are released.

Moreover, an should check first if it is being removed.  If
this is the case, then it should bail out immediately.  Since not all of
existing edac devices are to be removed, this "shutting flag" should be
contained to edac device being removed.  The current edac_dev.op_state can
be used to serve this purpose.

The original deadlock problem and the solution have been witnessed and
tested on actual hardware.  Without the solution, rmmod an edac driver
would result in below deadlock:

root@localhost:/root> rmmod mv64x60_edac
EDAC DEBUG: mv64x60_dma_err_remove()
EDAC DEBUG: edac_device_del_device()
EDAC DEBUG: find_edac_device_by_dev()

(hang for a moment)

INFO: task edac-poller:2030 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
edac-poller   D 00000000     0  2030      2
Call Trace:
[df159dc0] [c0071e3c] free_hot_cold_page+0x17c/0x304 (unreliable)
[df159e80] [c000a024] __switch_to+0x6c/0xa0
[df159ea0] [c03587d8] schedule+0x2f4/0x4d8
[df159f00] [c03598a8] __mutex_lock_slowpath+0xa0/0x174
[df159f40] [e1030434] edac_device_workq_function+0x28/0xd8 [edac_core]
[df159f60] [c003beb4] run_workqueue+0x114/0x218
[df159f90] [c003c674] worker_thread+0x5c/0xc8
[df159fd0] [c004106c] kthread+0x5c/0xa0
[df159ff0] [c0013538] original_kernel_thread+0x44/0x60
INFO: task rmmod:2062 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
rmmod         D 0ff2c9fc     0  2062   1839
Call Trace:
[df119c00] [c0437a74] 0xc0437a74 (unreliable)
[df119cc0] [c000a024] __switch_to+0x6c/0xa0
[df119ce0] [c03587d8] schedule+0x2f4/0x4d8
[df119d40] [c03591dc] schedule_timeout+0xb0/0xf4

Signed-off-by: Linus Torvalds <>
13 years agocgroups: avoid accessing uninitialized data in failure path
Li Zefan [Tue, 23 Dec 2008 21:57:14 +0000 (13:57 -0800)]
cgroups: avoid accessing uninitialized data in failure path

If cgroup_get_rootdir() failed, free_cg_links() will be called in the
failure path, but tmp_cg_links hasn't been initialized at that time.

I introduced this bug in the 2.6.27 merge window.

Signed-off-by: Li Zefan <>
Acked-by: Serge Hallyn <>
Cc: Paul Menage <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
13 years agocgroups: suppress bogus warning messages
Sharyathi Nagesh [Tue, 23 Dec 2008 21:57:12 +0000 (13:57 -0800)]
cgroups: suppress bogus warning messages

Remove spurious warning messages that are thrown onto the console during
cgroup operations.

Signed-off-by: Alexey Dobriyan <>
Signed-off-by: Sharyathi Nagesh <>
Acked-by: Serge E. Hallyn <>
Cc: Paul Menage <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
13 years agow1: fix slave selection on big-endian systems
Evgeniy Polyakov [Tue, 23 Dec 2008 21:57:12 +0000 (13:57 -0800)]
w1: fix slave selection on big-endian systems

During test of the w1-gpio driver i found that in "w1.c:679
w1_slave_found()" the device id is converted to little-endian with
"cpu_to_le64()", but its not converted back to cpu format in "w1_io.c:293

Based on a patch created by Andreas Hummel.

[ remove unneeded cast]
Reported-by: Andreas Hummel <>
Signed-off-by: Evgeniy Polyakov <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
13 years agortc: rtc-isl1208: reject invalid dates
Chris Elston [Tue, 23 Dec 2008 21:57:10 +0000 (13:57 -0800)]
rtc: rtc-isl1208: reject invalid dates

This patch for the rtc-isl1208 driver makes it reject invalid dates.

Signed-off-by: Chris Elston <>
[ added comment explaining the check]
Signed-off-by: Alessandro Zummo <>
Cc: Hebert Valerio Riedel <>
Cc: David Brownell <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
13 years agoV4L/DVB (9920): em28xx: fix NULL pointer dereference in call to VIDIOC_INT_RESET...
Devin Heitmueller [Wed, 17 Dec 2008 02:09:35 +0000 (23:09 -0300)]
V4L/DVB (9920): em28xx: fix NULL pointer dereference in call to VIDIOC_INT_RESET command

Fix a NULL pointer dereference that would occur if the video decoder tied to
the em28xx supports the VIDIOC_INT_RESET call (for example: the cx25840 driver)

Signed-off-by: Devin Heitmueller <>
Signed-off-by: Mauro Carvalho Chehab <>
13 years agodrm/radeon: fix correctness of irq_enabled check for radeon.
Dave Airlie [Mon, 22 Dec 2008 07:11:02 +0000 (17:11 +1000)]
drm/radeon: fix correctness of irq_enabled check for radeon.

This check was introduced with the logic the wrong way around.

Fixes regression:

Tested-by: Fran├žois Valenduc <>
Signed-off-by: Dave Airlie <>
13 years agoMerge branch 'release' of git://
Linus Torvalds [Mon, 22 Dec 2008 22:52:00 +0000 (14:52 -0800)]
Merge branch 'release' of git://git./linux/kernel/git/lenb/linux-acpi-2.6

* 'release' of git://
  ACPI: don't cond_resched() when irqs_disabled()
  ACPI: fix 2.6.28 acpi.debug_level regression

13 years agoMerge git://
Linus Torvalds [Mon, 22 Dec 2008 22:40:48 +0000 (14:40 -0800)]
Merge git://git./linux/kernel/git/bart/ide-2.6

* git://
  drivers/ide/{cs5530.c,sc1200.c}: Move a dereference below a NULL test

13 years agodrivers/ide/{cs5530.c,sc1200.c}: Move a dereference below a NULL test
Julia Lawall [Mon, 22 Dec 2008 22:05:06 +0000 (23:05 +0100)]
drivers/ide/{cs5530.c,sc1200.c}: Move a dereference below a NULL test

In each case, if the NULL test is necessary, then the dereference should be
moved below the NULL test.

The semantic patch that makes this change is as follows:

// <smpl>
type T;
expression E;
identifier i,fld;
statement S;

- T i = E->fld;
+ T i;
  ... when != E
      when != i
  if (E == NULL) S
+ i = E->fld;
// </smpl>

Signed-off-by: Julia Lawall <>
Acked-by: Sergei Shtylyov <>
Signed-off-by: Bartlomiej Zolnierkiewicz <>
13 years agoMerge branch 'upstream' of git://
Linus Torvalds [Mon, 22 Dec 2008 18:17:19 +0000 (10:17 -0800)]
Merge branch 'upstream' of git://

* 'upstream' of git://
  MIPS: MIPS64R2: Fix buggy __arch_swab64
  MIPS: Fix preprocessor warnings flaged by GCC 4.4

13 years agoMerge git://
Linus Torvalds [Mon, 22 Dec 2008 18:12:54 +0000 (10:12 -0800)]
Merge git://git./linux/kernel/git/davem/net-2.6

* git://
  ppp: fix segfaults introduced by netdev_priv changes
  net: Fix module refcount leak in kernel_accept()

13 years agoMIPS: MIPS64R2: Fix buggy __arch_swab64
David Daney [Wed, 17 Dec 2008 21:28:39 +0000 (13:28 -0800)]
MIPS: MIPS64R2: Fix buggy __arch_swab64

The way the code is written it was assuming dshd has the function of a
hypothetical dshw instruction ...

Signed-off-by: David Daney <>
Signed-off-by: Ralf Baechle <>
13 years agoMIPS: Fix preprocessor warnings flaged by GCC 4.4
David Daney [Thu, 18 Dec 2008 02:19:18 +0000 (18:19 -0800)]
MIPS: Fix preprocessor warnings flaged by GCC 4.4

Signed-off-by: David Daney <>
Signed-off-by: Ralf Baechle <>
13 years agoNull pointer deref with hrtimer_try_to_cancel()
Thomas Gleixner [Sat, 20 Dec 2008 20:27:34 +0000 (21:27 +0100)]
Null pointer deref with hrtimer_try_to_cancel()

Impact: Prevent kernel crash with posix timer clockid CLOCK_MONOTONIC_RAW

commit 2d42244ae71d6c7b0884b5664cf2eda30fb2ae68 (clocksource:
introduce CLOCK_MONOTONIC_RAW) introduced a new clockid, which is only
available to read out the raw not NTP adjusted system time.

The above commit did not prevent that a posix timer can be created
with that clockid. The timer_create() syscall succeeds and initializes
the timer to a non existing hrtimer base. When the timer is deleted
either by timer_delete() or by the exit() cleanup the kernel crashes.

Prevent the creation of timers for CLOCK_MONOTONIC_RAW by setting the
posix clock function to no_timer_create which returns an error code.

Reported-and-tested-by: Eric Sesterhenn <>
Signed-off-by: Thomas Gleixner <>
Acked-by: Oleg Nesterov <>
Signed-off-by: Linus Torvalds <>
13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Sat, 20 Dec 2008 19:07:31 +0000 (11:07 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/ericvh/v9fs

* 'for-linus' of git://
  fs/9p: change simple_strtol to simple_strtoul
  9p: convert d_iname references to
  9p: Remove potentially bad parameter from function entry debug print.

13 years agoMerge branch 'x86-fixes-for-linus' of git://
Linus Torvalds [Sat, 20 Dec 2008 19:07:18 +0000 (11:07 -0800)]
Merge branch 'x86-fixes-for-linus' of git://git./linux/kernel/git/tip/linux-2.6-tip

* 'x86-fixes-for-linus' of git://
  x86: fix resume (S2R) broken by Intel microcode module, on A110L
  x86 gart: don't complain if no AMD GART found
  AMD IOMMU: panic if completion wait loop fails
  AMD IOMMU: set cmd buffer pointers to zero manually
  x86: re-enable MCE on secondary CPUS after suspend/resume
  AMD IOMMU: allocate rlookup_table with __GFP_ZERO

13 years agox86: fix resume (S2R) broken by Intel microcode module, on A110L
Dmitry Adamushko [Fri, 19 Dec 2008 23:15:24 +0000 (00:15 +0100)]
x86: fix resume (S2R) broken by Intel microcode module, on A110L

Impact: fix deadlock

This is in response to the following bug report:

Bug-Entry       :
Subject         : resume (S2R) broken by Intel microcode module, on A110L
Submitter       : Andreas Mohr <>
Date            : 2008-11-25 08:48 (19 days old)
Handled-By      : Dmitry Adamushko <>

[ The deadlock scenario has been discovered by Andreas Mohr ]

I think I might have a logical explanation why the system:


might hang upon resuming, OTOH it should have likely hanged each and every time.

(1) possible deadlock in microcode_resume_cpu() if either 'if' section is

(2) now, I don't see it in spec. and can't experimentally verify it (newer
ucodes don't seem to be available for my Core2duo)... but logically-wise, I'd
think that when read upon resuming, the 'microcode revision' (MSR 0x8B) should
be back to its original one (we need to reload ucode anyway so it doesn't seem
logical if a cpu doesn't drop the version)... if so, the comparison with
memcmp() for the full 'struct cpu_signature' is wrong... and that's how one of
the aforementioned 'if' sections might have been triggered - leading to a

Obviously, in my tests I simulated loading/resuming with the ucode of the same
version (just to see that the file is loaded/re-loaded upon resuming) so this
issue has never popped up.

I'd appreciate if someone with an appropriate system might give a try to the
2nd patch (titled "fix a comparison && deadlock...").

In any case, the deadlock situation is a must-have fix.

Reported-by: Andreas Mohr <>
Signed-off-by: Dmitry Adamushko <>
Tested-by: Andreas Mohr <>
Signed-off-by: Ingo Molnar <>
Cc: <>
Signed-off-by: Ingo Molnar <>
13 years agofs/9p: change simple_strtol to simple_strtoul
Julia Lawall [Fri, 19 Dec 2008 22:50:22 +0000 (16:50 -0600)]
fs/9p: change simple_strtol to simple_strtoul

Since v9ses->uid is unsigned, it would seem better to use simple_strtoul that

A simplified version of the semantic patch that makes this change is as
follows: (

// <smpl>
long e;
position p;

e = simple_strtol@p(...)

position p != r2.p;
type T;
T e;

e =
- simple_strtol@p
+ simple_strtoul
// </smpl>

Signed-off-by: Julia Lawall <>
Acked-by: Eric Van Hensbergen <>
13 years ago9p: convert d_iname references to
Wu Fengguang [Fri, 19 Dec 2008 22:47:40 +0000 (16:47 -0600)]
9p: convert d_iname references to

d_iname is rubbish for long file names.
Use in printks instead.

Signed-off-by: Wu Fengguang <>
Acked-by: Eric Van Hensbergen <>
13 years ago9p: Remove potentially bad parameter from function entry debug print.
Duane Griffin [Fri, 19 Dec 2008 22:45:21 +0000 (16:45 -0600)]
9p: Remove potentially bad parameter from function entry debug print.

Signed-off-by: Duane Griffin <>
Signed-off-by: Eric Van Hensbergen <>
13 years agoMerge git://
Linus Torvalds [Fri, 19 Dec 2008 19:37:23 +0000 (11:37 -0800)]
Merge git://git./linux/kernel/git/jejb/scsi-rc-fixes-2.6

* git://
  [SCSI] mpt fusion: clear list of outstanding commands on host reset
  [SCSI] scsi_lib: only call scsi_unprep_request() under queue lock
  [SCSI] ibmvstgt: move crq_queue_create to the end of initialization
  [SCSI] libiscsi REGRESSION: fix passthrough support with older iscsi tools
  [SCSI] aacraid: disable Dell Percraid quirk on Adaptec 2200S and 2120S

13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Fri, 19 Dec 2008 19:37:07 +0000 (11:37 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/tiwai/sound-2.6

* 'for-linus' of git://
  ALSA: Fix a Oops bug in omap soc driver.
  ALSA: hda - Remove non-working headphone control for Dell laptops
  ALSA: hda - Add no-jd model for IDT 92HD73xx
  ALSA: Revert "ALSA: hda: removed unneeded hp_nid references"
  ALSA: hda - Add quirk for Dell Studio 17
  ALSA: hda - Fix silent HP output on D975

13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Fri, 19 Dec 2008 19:36:49 +0000 (11:36 -0800)]
Merge branch 'for-linus' of git://

* 'for-linus' of git://
  cciss: fix problem that deleting multiple logical drives could cause a panic

13 years agoMerge branch 'drm-fixes' of git://
Linus Torvalds [Fri, 19 Dec 2008 19:36:04 +0000 (11:36 -0800)]
Merge branch 'drm-fixes' of git://git./linux/kernel/git/airlied/drm-2.6

* 'drm-fixes' of git://
  drm/i915: GEM on PAE has problems - disable it for now.
  drm/i915: Don't return busy for buffers left on the flushing list.

13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Fri, 19 Dec 2008 19:34:36 +0000 (11:34 -0800)]
Merge branch 'for-linus' of git://

* 'for-linus' of git://
  md: Don't read past end of bitmap when reading bitmap.

13 years agoMerge branch 'for-linus' of git://
Linus Torvalds [Fri, 19 Dec 2008 19:33:10 +0000 (11:33 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/jbarnes/pci-2.6

* 'for-linus' of git://
  PCI hotplug: ibmphp: Fix module ref count underflow
  PCI hotplug: acpiphp wants a 64-bit _SUN
  PCI: pciehp: fix unexpected power off with pciehp_force
  PCI: fix aer resume sanity check

13 years agoMerge branch 'fix/asoc' into for-linus
Takashi Iwai [Fri, 19 Dec 2008 14:37:12 +0000 (15:37 +0100)]
Merge branch 'fix/asoc' into for-linus

13 years agoALSA: Fix a Oops bug in omap soc driver.
Stanley Miao [Fri, 19 Dec 2008 14:08:22 +0000 (22:08 +0800)]
ALSA: Fix a Oops bug in omap soc driver.

There will be a Oops or frequent underrun messages when playing music with
omap soc driver, this is because a data region is incorretly sized, other data
region will be overwriten when writing to this data region.

Signed-off-by: Stanley Miao <>
Acked-by: Jarkko Nikula <>
Signed-off-by: Takashi Iwai <>
13 years agoALSA: hda - Remove non-working headphone control for Dell laptops
Takashi Iwai [Fri, 19 Dec 2008 13:02:32 +0000 (14:02 +0100)]
ALSA: hda - Remove non-working headphone control for Dell laptops

The previous commit re-enabled hp_nid setup for IDT92HD73*, but
it's unneeded indeed for Dell laptops that have multiple headphones.
Setting the extra hp_nid results in a non-working "Headpohne" mixer
control.  Thus hp_nid should be 0 for these dell models.

Also, the automatic addition of hp_nid should check whether it's
a dual-HP model or not.  For dual-HPs, the pins are already checked
by the early workaround.

Signed-off-by: Takashi Iwai <>
13 years agoACPI: don't cond_resched() when irqs_disabled()
Wu Fengguang [Wed, 26 Nov 2008 06:35:22 +0000 (14:35 +0800)]
ACPI: don't cond_resched() when irqs_disabled()

The ACPI interpreter usually runs with irqs enabled.
However, during suspend/resume it runs with
irqs disabled to evaluate _GTS/_BFS, as well as
by irqrouter_resume() which evaluates _CRS, _PRS, _SRS.

Signed-off-by: Wu Fengguang <>
Signed-off-by: Len Brown <>
13 years agoACPI: fix 2.6.28 acpi.debug_level regression
Bjorn Helgaas [Thu, 13 Nov 2008 23:30:13 +0000 (17:30 -0600)]
ACPI: fix 2.6.28 acpi.debug_level regression

acpi_early_init() was changed to over-write the cmdline param,
making it really inconvenient to set debug flags at boot-time.

This sets the default level to "info", which is what all the ACPI
drivers use.  So to enable messages from drivers, you only have to
supply the "layer" (a.k.a. "component").  For non-"info" ACPI core
and ACPI interpreter messages, you have to supply both level and
layer masks, as before.

Signed-off-by: Bjorn Helgaas <>
Signed-off-by: Len Brown <>
13 years agoALSA: hda - Add no-jd model for IDT 92HD73xx
Takashi Iwai [Wed, 17 Dec 2008 13:51:01 +0000 (14:51 +0100)]
ALSA: hda - Add no-jd model for IDT 92HD73xx

Added the model without the jack-detection for some desktops that
have really no jack-detection.  The recent driver caused regressions
regarding the sound output on such machines.

Signed-off-by: Takashi Iwai <>
13 years agoALSA: Revert "ALSA: hda: removed unneeded hp_nid references"
Takashi Iwai [Fri, 19 Dec 2008 07:20:38 +0000 (08:20 +0100)]
ALSA: Revert "ALSA: hda: removed unneeded hp_nid references"

This reverts commit 07f455f779acfb3eba4921fd1399761559b10fa9.
    ALSA: hda: removed unneeded hp_nid references

    Removed unneeded hp_nid references for 92hd73xx codec family.

This caused the silent output on some Intel desktops due to missing
routing of widget 0x0a and 0x0d.

Signed-off-by: Takashi Iwai <>
13 years agocciss: fix problem that deleting multiple logical drives could cause a panic
Stephen M. Cameron [Thu, 18 Dec 2008 13:55:11 +0000 (14:55 +0100)]
cciss: fix problem that deleting multiple logical drives could cause a panic

Fix problem that deleting multiple logical drives could cause a panic.

It fixes a panic which can be easily reproduced in the following way: Just
create several "arrays," each with multiple logical drives via hpacucli,
then delete the first array, and it will blow up in deregister_disk(), in
the call to get_host() when it tries to dig the hba pointer out of a NULL
queue pointer.

The problem has been present since my code to make rebuild_lun_table
behave better went in.

Signed-off-by: Stephen M. Cameron <>
Signed-off-by: Jens Axboe <>
13 years agoALSA: hda - Add quirk for Dell Studio 17
Joerg Schirottke [Fri, 19 Dec 2008 07:13:49 +0000 (08:13 +0100)]
ALSA: hda - Add quirk for Dell Studio 17

Added the matching model=dell-m6 for Dell Studio 17 laptop.

Signed-off-by: Joerg Schirottke <>
Signed-off-by: Takashi Iwai <>
13 years agodrm/i915: GEM on PAE has problems - disable it for now.
Dave Airlie [Fri, 19 Dec 2008 05:38:34 +0000 (15:38 +1000)]
drm/i915: GEM on PAE has problems - disable it for now.

On PAE systems, GEM allocates pages using shmem, and passes these
pages to be bound into AGP, however the AGP interfaces + the x86
set_memory interfaces all take unsigned long not dma_addr_t.

The initial fix for this was a mess, so we need to do this correctly
for 2.6.29.

Signed-off-by: Dave Airlie <>
13 years agodrm/i915: Don't return busy for buffers left on the flushing list.
Eric Anholt [Mon, 15 Dec 2008 03:05:04 +0000 (19:05 -0800)]
drm/i915: Don't return busy for buffers left on the flushing list.

These buffers don't have active rendering still occurring to them, they just
need either a flush to be emitted or a retire_requests to occur so that we
notice they're done.  Return unbusy so that one of the two occurs.  The two
expected consumers of this interface (OpenGL and libdrm_intel BO cache) both
want this behavior.

Signed-off-by: Eric Anholt <>
Acked-by: Keith Packard <>
Signed-off-by: Dave Airlie <>
13 years agomd: Don't read past end of bitmap when reading bitmap.
NeilBrown [Fri, 19 Dec 2008 05:25:01 +0000 (16:25 +1100)]
md: Don't read past end of bitmap when reading bitmap.

When we read the write-intent-bitmap off the device, we currently
read a whole number of pages.
When PAGE_SIZE is 4K, this works due to the alignment we enforce
on the superblock and bitmap.
When PAGE_SIZE is 64K, this case read past the end-of-device
which causes an error.

When we write the superblock, we ensure to clip the last page
to just be the required size.  Copy that code into the read path
to just read the required number of sectors.

Signed-off-by: Neil Brown <>
13 years agoppp: fix segfaults introduced by netdev_priv changes
James Chapman [Wed, 17 Dec 2008 12:02:16 +0000 (12:02 +0000)]
ppp: fix segfaults introduced by netdev_priv changes

This patch fixes a segfault in ppp_shutdown_interface() and
ppp_destroy_interface() when a PPP connection is closed. I bisected
the problem to the following commit:

  commit c8019bf3aff653cceb64f66489fc299ee5957b57
  Author: Wang Chen <>
  Date:   Thu Nov 20 04:24:17 2008 -0800

    netdevice ppp: Convert directly reference of netdev->priv

    1. Use netdev_priv(dev) to replace dev->priv.
    2. Alloc netdev's private data by alloc_netdev().

Signed-off-by: Wang Chen <>
Signed-off-by: David S. Miller <>
The original ppp_generic code treated the netdev and struct ppp as
independent data structures which were freed separately. In moving the
ppp struct into the netdev, it is now possible for the private data to
be freed before the call to ppp_shutdown_interface(), which is bad.

The kfree(ppp) in ppp_destroy_interface() is also wrong; presumably
ppp hasn't worked since the above commit.

The following patch fixes both problems.

Signed-off-by: James Chapman <>
Reviewed-by: Wang Chen <>
Signed-off-by: David S. Miller <>
13 years agonet: Fix module refcount leak in kernel_accept()
Wei Yongjun [Fri, 19 Dec 2008 03:35:10 +0000 (19:35 -0800)]
net: Fix module refcount leak in kernel_accept()

The kernel_accept() does not hold the module refcount of newsock->ops->owner,
so we need __module_get(newsock->ops->owner) code after call kernel_accept()
by hand.
In sunrpc, the module refcount is missing to hold. So this cause kernel panic.

Used following script to reproduct:

while [ 1 ];
    mount -t nfs4 /mnt
    touch /mnt/file
    umount /mnt
    lsmod | grep ipv6

This patch fixed the problem by add __module_get(newsock->ops->owner) to
kernel_accept(). So we do not need to used __module_get(newsock->ops->owner)
in every place when used kernel_accept().

Signed-off-by: Wei Yongjun <>
Signed-off-by: David S. Miller <>
13 years agoLinux 2.6.28-rc9 v2.6.28-rc9
Linus Torvalds [Fri, 19 Dec 2008 01:20:13 +0000 (17:20 -0800)]
Linux 2.6.28-rc9

13 years agoMerge branch 'fixes' of git://
Linus Torvalds [Thu, 18 Dec 2008 20:05:53 +0000 (12:05 -0800)]
Merge branch 'fixes' of git://git./linux/kernel/git/djbw/async_tx

* 'fixes' of git://
  async_xor: dma_map destination DMA_BIDIRECTIONAL
  dmaengine: protect 'id' from concurrent registrations
  ioat: wait for self-test completion

13 years agoMerge branch 'fixes' of git://
Linus Torvalds [Thu, 18 Dec 2008 20:01:02 +0000 (12:01 -0800)]
Merge branch 'fixes' of git://git./linux/kernel/git/hskinnemoen/avr32-2.6

* 'fixes' of git://
  avr32: favr-32 build fix
  ATSTK1006: Fix boot from NAND flash
  avr32: remove section when making vmlinux.bin
  avr32: Enable pullup on USART TX lines

13 years agoMerge git://
Linus Torvalds [Thu, 18 Dec 2008 20:00:46 +0000 (12:00 -0800)]
Merge git://git./linux/kernel/git/davem/net-2.6

* git://
  bnx2: Fix bug in bnx2_free_rx_mem().
  irda: Add irda_skb_cb qdisc related padding
  jme: Fixed a typo
  net: kernel BUG at drivers/net/phy/mdio_bus.c:165!
  drivers/net: starfire: Fix napi ->poll() weight handling
  tlan: Fix pci memory unmapping
  enc28j60: use netif_rx_ni() to deliver RX packets
  tlan: Fix small (< 64 bytes) datagram transmissions
  netfilter: ctnetlink: fix missing CTA_NAT_SEQ_UNSPEC

13 years agoMerge git://
Linus Torvalds [Thu, 18 Dec 2008 20:00:01 +0000 (12:00 -0800)]
Merge git://git./linux/kernel/git/davem/sparc-2.6

* git://
  sparc: We need to implement arch_ptrace_stop().

13 years agoMaintainer email fixes for inotify
John McCutchan [Thu, 18 Dec 2008 01:43:02 +0000 (17:43 -0800)]
Maintainer email fixes for inotify

Update John McCutchan and Robert Love's email addresses for
maintenance of inotify

Signed-off-by: John McCutchan <>
Acked-by: Robert Love <>
Signed-off-by: Linus Torvalds <>
13 years agoavr32: favr-32 build fix
Haavard Skinnemoen [Thu, 18 Dec 2008 15:20:47 +0000 (16:20 +0100)]
avr32: favr-32 build fix

The favr-32 board code still refers to the old asm/arch header files
which were moved to mach/ some time ago.

Signed-off-by: Haavard Skinnemoen <>
13 years agoATSTK1006: Fix boot from NAND flash
Haavard Skinnemoen [Thu, 18 Dec 2008 15:13:24 +0000 (16:13 +0100)]
ATSTK1006: Fix boot from NAND flash

Enable JFFS2 write buffer support so that the kernel can access a root
filesystem in NAND flash.

Signed-off-by: Haavard Skinnemoen <>
13 years agoMerge branch 'iommu-fixes-2.6.28' of git://
Ingo Molnar [Thu, 18 Dec 2008 12:28:11 +0000 (13:28 +0100)]
Merge branch 'iommu-fixes-2.6.28' of git://git./linux/kernel/git/joro/linux-2.6-iommu into x86/urgent

13 years agox86 gart: don't complain if no AMD GART found
Bjorn Helgaas [Wed, 17 Dec 2008 19:52:34 +0000 (12:52 -0700)]
x86 gart: don't complain if no AMD GART found

Impact: remove annoying bootup printk

It's perfectly normal for no AMD GART to be present, e.g., if you have
Intel CPUs.  None of the other iommu_init() functions makes noise when
it finds nothing.

Signed-off-by: Bjorn Helgaas <>
Acked-by: Joerg Roedel <>
Signed-off-by: Ingo Molnar <>
13 years agoALSA: hda - Fix silent HP output on D975
Takashi Iwai [Wed, 17 Dec 2008 12:48:29 +0000 (13:48 +0100)]
ALSA: hda - Fix silent HP output on D975

Some desktops seems to have no HP/mic jack detection on the front panel,
which results in the silent output in the recent driver, because the
driver mutes the output (to save power) when no plug is detected.

This patch adds a new model that disables the jack-detection.

Signed-off-by: Takashi Iwai <>
13 years agobnx2: Fix bug in bnx2_free_rx_mem().
Michael Chan [Thu, 18 Dec 2008 03:06:08 +0000 (19:06 -0800)]
bnx2: Fix bug in bnx2_free_rx_mem().

DMA memory for the jumbo rx page rings was freed incorrectly using the
wrong local variable as the array index.

Signed-off-by: Michael Chan <>
Signed-off-by: David S. Miller <>
13 years agoPCI hotplug: ibmphp: Fix module ref count underflow
Neil Horman [Thu, 18 Dec 2008 00:07:47 +0000 (16:07 -0800)]
PCI hotplug: ibmphp: Fix module ref count underflow

I happened to notice that the ibmphp hotplug driver does something
rather silly in its init routine.  It purposely calls module_put so as
to underflow its module ref count to avoid being removed from the
kernel.  This is bad practice, and wrong, since it provides a window for
subsequent module_gets to reset the refcount to zero, allowing an unload
to race in and cause all sorts of mysterious panics.  If the module is
unsafe to load, simply omitting the module_exit parameter is sufficient
to prevent the kernel from allowing the unload.

Acked-by: Greg Kroah-Hartman <>
Signed-off-by: Neil Horman <>
Signed-off-by: Jesse Barnes <>
13 years agoirda: Add irda_skb_cb qdisc related padding
Samuel Ortiz [Wed, 17 Dec 2008 23:44:58 +0000 (15:44 -0800)]
irda: Add irda_skb_cb qdisc related padding

We need to pad irda_skb_cb in order to keep it safe accross dev_queue_xmit()
calls. This is some ugly and temporary hack triggered by recent qisc code
Even though it fixes bug #11795, it will be replaced by a
proper fix before 2.6.29 is released.

Signed-off-by: Samuel Ortiz <>
Signed-off-by: David S. Miller <>
13 years agoMerge branch 'i2c-fixes' of git://
Linus Torvalds [Wed, 17 Dec 2008 23:05:26 +0000 (15:05 -0800)]
Merge branch 'i2c-fixes' of git://

* 'i2c-fixes' of git://
  i2c-s3c2410: fix check for being in suspend.
  i2c-cpm: Detect and report NAK right away instead of timing out

13 years agoMerge branch 'upstream-linus' of git://
Linus Torvalds [Wed, 17 Dec 2008 23:01:23 +0000 (15:01 -0800)]
Merge branch 'upstream-linus' of git://git./linux/kernel/git/mfasheh/ocfs2

* 'upstream-linus' of git://
  ocfs2: Add JBD2 compat feature bit.
  ocfs2: Always update xattr search when creating bucket.

13 years agoMerge git://
Linus Torvalds [Wed, 17 Dec 2008 23:01:06 +0000 (15:01 -0800)]
Merge git://git./linux/kernel/git/gregkh/usb-2.6

* git://
  USB: pl2303: add id for Hewlett-Packard LD220-HP POS pole display
  USB: set correct configuration in probe of ti_usb_3410_5052
  USB: add 5372:2303 to pl2303
  USB: skip Set-Interface(0) if already in altsetting 0
  USB: fix comment about endianness of descriptors
  USB: Documentation/usb/gadget_serial.txt: update to match driver use_acm behaviour
  usbmon: drop bogus 0t from usbmon.txt
  USB: gadget: fix rndis working at high speed
  USB: ftdi_sio: Adding Ewert Energy System's CANdapter PID
  USB: tty: SprogII DCC controller identifiers
  usb-storage: update unusual_devs entry for Nokia 5310
  USB: Unusual devs patch for Nokia 3500c
  USB: storage: unusual_devs.h: Nokia 3109c addition
  USB: fix problem with usbtmc driver not loading properly

13 years agoMerge git://
Linus Torvalds [Wed, 17 Dec 2008 23:00:54 +0000 (15:00 -0800)]
Merge git://git./linux/kernel/git/gregkh/driver-core-2.6

* git://
  STAGING: Move staging drivers back to staging-specific menu
  driver core: add newlines to debugging enabled/disabled messages
  xilinx_hwicap: remove improper wording in license statement
  driver core: fix using 'ret' variable in unregister_dynamic_debug_module

13 years agocifs: fix buffer overrun in parse_DFS_referrals
Jeff Layton [Wed, 17 Dec 2008 11:31:53 +0000 (06:31 -0500)]
cifs: fix buffer overrun in parse_DFS_referrals

While testing a kernel with memory poisoning enabled, I saw some warnings
about the redzone getting clobbered when chasing DFS referrals. The
buffer allocation for the unicode converted version of the searchName is
too small and needs to take null termination into account.

Signed-off-by: Jeff Layton <>
Acked-by: Steve French <>
Signed-off-by: Linus Torvalds <>
13 years agoMerge branch 'merge' of git://
Linus Torvalds [Wed, 17 Dec 2008 22:58:56 +0000 (14:58 -0800)]
Merge branch 'merge' of git://git./linux/kernel/git/galak/powerpc

* 'merge' of git://
  powerpc: Fix corruption error in rh_alloc_fixed()
  powerpc/fsl-booke: Fix the miss interrupt restore

13 years agoSTAGING: Move staging drivers back to staging-specific menu
Dmitry Baryshkov [Thu, 27 Nov 2008 21:01:28 +0000 (00:01 +0300)]
STAGING: Move staging drivers back to staging-specific menu

Signed-off-by: Dmitry Baryshkov <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agodriver core: add newlines to debugging enabled/disabled messages
Marcel Holtmann [Sun, 30 Nov 2008 13:01:26 +0000 (14:01 +0100)]
driver core: add newlines to debugging enabled/disabled messages

Both messages are missing the newline and thus dmesg output gets

Signed-off-by: Marcel Holtmann <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoxilinx_hwicap: remove improper wording in license statement
Greg Kroah-Hartman [Sun, 7 Dec 2008 05:10:51 +0000 (21:10 -0800)]
xilinx_hwicap: remove improper wording in license statement

GPLv2 doesn't allow additional restrictions to be imposed on any
code, so this wording needs to be removed from these files.

Signed-off-by: Stephen Neuendorffer <>
Cc: stable <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agodriver core: fix using 'ret' variable in unregister_dynamic_debug_module
Johann Felix Soden [Thu, 30 Oct 2008 21:44:39 +0000 (22:44 +0100)]
driver core: fix using 'ret' variable in unregister_dynamic_debug_module

The 'ret' variable is assigned, but not used in the return statement. Fix this.

Signed-off-by: Johann Felix Soden <>
Acked-by: Jason Baron <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: pl2303: add id for Hewlett-Packard LD220-HP POS pole display
Mike Provencher [Tue, 16 Dec 2008 20:30:14 +0000 (14:30 -0600)]
USB: pl2303: add id for Hewlett-Packard LD220-HP POS pole display

Add id for the Hewlett-Packard LD220-HP POS pole display.

Bus 002 Device 002: ID 03f0:3524 Hewlett-Packard

Signed-off-by: Mike Provencher <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: set correct configuration in probe of ti_usb_3410_5052
Oliver Neukum [Tue, 16 Dec 2008 11:25:55 +0000 (12:25 +0100)]
USB: set correct configuration in probe of ti_usb_3410_5052

This driver transfers firmware. It may just as well set the correct

Signed-off-by: Oliver Neukum <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: add 5372:2303 to pl2303
Matthew Arnold [Sat, 13 Dec 2008 11:42:53 +0000 (22:42 +1100)]
USB: add 5372:2303 to pl2303

This patch adds the "Superial" USB-Serial converter to pl2303 so that it
is detected, by the correct driver.  Adds the relevant vendor:product
(5372:2303) to the device tables in pl2303.c & pl2303.h.  The patch has
been tested against 2.6.24-22-generic.

Signed-off-by: Matthew D Arnold <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: skip Set-Interface(0) if already in altsetting 0
Alan Stern [Mon, 1 Dec 2008 15:24:41 +0000 (10:24 -0500)]
USB: skip Set-Interface(0) if already in altsetting 0

When a driver unbinds from an interface, usbcore always sends a
Set-Interface request to reinstall altsetting 0.  Unforunately, quite
a few devices have buggy firmware that crashes when it receives this

To avoid such problems, this patch (as1180) arranges to send the
Set-Interface request only when the interface is not already in
altsetting 0.

Signed-off-by: Alan Stern <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: fix comment about endianness of descriptors
Phil Endecott [Mon, 1 Dec 2008 15:22:33 +0000 (10:22 -0500)]
USB: fix comment about endianness of descriptors

This patch fixes a comment and clarifies the documentation about the
endianness of descriptors. The current policy is that descriptors will
be little-endian at the API even on big-endian systems; however the
/proc/bus/usb API predates this policy and presents descriptors with
some multibyte fields byte-swapped.

Signed-off-by: Phil Endecott <>
Signed-off-by: Alan Stern <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: Documentation/usb/gadget_serial.txt: update to match driver use_acm behaviour
Peter Korsgaard [Thu, 4 Dec 2008 15:30:53 +0000 (16:30 +0100)]
USB: Documentation/usb/gadget_serial.txt: update to match driver use_acm behaviour

Commit 7bb5ea54 (usb gadget serial: use composite gadget framework)
changed the default for the use_acm parameter from 0 to 1.
Update the documentation to match.

Signed-off-by: Peter Korsgaard <>
Acked-by: David Brownell <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agousbmon: drop bogus 0t from usbmon.txt
Pete Zaitcev [Thu, 4 Dec 2008 23:17:00 +0000 (16:17 -0700)]
usbmon: drop bogus 0t from usbmon.txt

The example is incorrect: there is no 0t socket (the '1t' format has no
bus number in it). Also, correct the broken sentence for USB Tag.

Signed-off-by: Pete Zaitcev <>
Signed-off-by: Greg Kroah-Hartman <>
13 years agoUSB: gadget: fix rndis working at high speed
David Brownell [Tue, 25 Nov 2008 07:11:03 +0000 (23:11 -0800)]
USB: gadget: fix rndis working at high speed

Fix a bug specific to highspeed mode in the recently updated RNDIS
support:  it wasn't setting up the high speed notification endpoint,
which prevented high speed RNDIS links from working.

Signed-off-by: David Brownell <>
Tested-by: Anand Gadiyar <>
Cc: stable <>
Signed-off-by: Greg Kroah-Hartman <>