06 Mar, 2009
6 commits
-
Impact: add debug callbacks for dma_sync_single_range_for_* functions
Signed-off-by: Joerg Roedel
-
Impact: add debug callbacks for dma_sync_single_for_* functions
Signed-off-by: Joerg Roedel
-
Impact: add debug callbacks for dma_[alloc|free]_coherent
Signed-off-by: Joerg Roedel
-
Impact: add debug callbacks for dma_{un}map_sg
Signed-off-by: Joerg Roedel
-
Impact: add debug callbacks for dma_{un}map_[page|single]
Signed-off-by: Joerg Roedel
-
Impact: add code to initialize dma-debug core data structures
Signed-off-by: Joerg Roedel
05 Mar, 2009
2 commits
-
Impact: add groundwork for DMA-API debugging
Signed-off-by: Joerg Roedel
04 Mar, 2009
2 commits
-
…l/git/tip/linux-2.6-tip
* 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
sched: don't allow setuid to succeed if the user does not have rt bandwidth
sched_rt: don't start timer when rt bandwidth disabled -
…/git/tip/linux-2.6-tip
* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
rcu: Teach RCU that idle task is not quiscent state at boot
03 Mar, 2009
1 commit
-
…git/tip/linux-2.6-tip
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
fix warning in io_mapping_map_wc()
x86: i915 needs pgprot_writecombine() and is_io_mapping_possible()
02 Mar, 2009
1 commit
-
Signed-off-by: Venkatesh Pallipadi
Signed-off-by: Ingo Molnar
01 Mar, 2009
3 commits
-
The DCB netlink interface is required for building the userspace tools
available at e1000.sourceforge.netSigned-off-by: Chris Leech
Signed-off-by: David S. Miller -
1) add an include for
2) change dcbmsg.dcb_family from unsigned char to __u8 to be more
consistent with use of kernel typesSigned-off-by: Chris Leech
Acked-by: Sam Ravnborg
Signed-off-by: David S. Miller
28 Feb, 2009
2 commits
-
…git/tip/linux-2.6-tip
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86: enable DMAR by default
xen: disable interrupts early, as start_kernel expects
gpu/drm, x86, PAT: io_mapping_create_wc and resource_size_t
gpu/drm, x86, PAT: Handle io_mapping_create_wc() errors in a clean way
x86, Voyager: fix compile by lifting the degeneracy of phys_cpu_present_map
x86, doc: fix references to Documentation/x86/i386/boot.txt -
free_uid() and free_user_ns() are corecursive when CONFIG_USER_SCHED=n,
but free_user_ns() is called from free_uid() by way of uid_hash_remove(),
which requires uidhash_lock to be held. free_user_ns() then calls
free_uid() to complete the destruction.Fix this by deferring the destruction of the user_namespace.
Signed-off-by: David Howells
Acked-by: Serge Hallyn
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
27 Feb, 2009
1 commit
-
Impact: fix hung task with certain (non-default) rt-limit settings
Corey Hickey reported that on using setuid to change the uid of a
rt process, the process would be unkillable and not be running.
This is because there was no rt runtime for that user group. Add
in a check to see if a user can attach an rt task to its task group.
On failure, return EINVAL, which is also returned in
CONFIG_CGROUP_SCHED.Reported-by: Corey Hickey
Signed-off-by: Dhaval Giani
Acked-by: Peter Zijlstra
Signed-off-by: Ingo Molnar
26 Feb, 2009
5 commits
-
blk_recalc_rq_segments() requires a request structure passed in, which
we don't have from blk_recount_segments(). So the latter allocates one on
the stack, using > 400 bytes of stack for that. This can cause us to spill
over one page of stack from ext4 at least:0) 4560 400 blk_recount_segments+0x43/0x62
1) 4160 32 bio_phys_segments+0x1c/0x24
2) 4128 32 blk_rq_bio_prep+0x2a/0xf9
3) 4096 32 init_request_from_bio+0xf9/0xfe
4) 4064 112 __make_request+0x33c/0x3f6
5) 3952 144 generic_make_request+0x2d1/0x321
6) 3808 64 submit_bio+0xb9/0xc3
7) 3744 48 submit_bh+0xea/0x10e
8) 3696 368 ext4_mb_init_cache+0x257/0xa6a [ext4]
9) 3328 288 ext4_mb_regular_allocator+0x421/0xcd9 [ext4]
10) 3040 160 ext4_mb_new_blocks+0x211/0x4b4 [ext4]
11) 2880 336 ext4_ext_get_blocks+0xb61/0xd45 [ext4]
12) 2544 96 ext4_get_blocks_wrap+0xf2/0x200 [ext4]
13) 2448 80 ext4_da_get_block_write+0x6e/0x16b [ext4]
14) 2368 352 mpage_da_map_blocks+0x7e/0x4b3 [ext4]
15) 2016 352 ext4_da_writepages+0x2ce/0x43c [ext4]
16) 1664 32 do_writepages+0x2d/0x3c
17) 1632 144 __writeback_single_inode+0x162/0x2cd
18) 1488 96 generic_sync_sb_inodes+0x1e3/0x32b
19) 1392 16 sync_sb_inodes+0xe/0x10
20) 1376 48 writeback_inodes+0x69/0xb3
21) 1328 208 balance_dirty_pages_ratelimited_nr+0x187/0x2f9
22) 1120 224 generic_file_buffered_write+0x1d4/0x2c4
23) 896 176 __generic_file_aio_write_nolock+0x35f/0x393
24) 720 80 generic_file_aio_write+0x6c/0xc8
25) 640 80 ext4_file_write+0xa9/0x137 [ext4]
26) 560 320 do_sync_write+0xf0/0x137
27) 240 48 vfs_write+0xb3/0x13c
28) 192 64 sys_write+0x4c/0x74
29) 128 128 system_call_fastpath+0x16/0x1bSplit the segment counting out into a __blk_recalc_rq_segments() helper
to avoid allocating an onstack request just for checking the physical
segment count.Signed-off-by: Jens Axboe
-
This patch fixes a bug located by Vegard Nossum with the aid of
kmemcheck, updated based on review comments from Nick Piggin,
Ingo Molnar, and Andrew Morton. And cleans up the variable-name
and function-name language. ;-)The boot CPU runs in the context of its idle thread during boot-up.
During this time, idle_cpu(0) will always return nonzero, which will
fool Classic and Hierarchical RCU into deciding that a large chunk of
the boot-up sequence is a big long quiescent state. This in turn causes
RCU to prematurely end grace periods during this time.This patch changes the rcutree.c and rcuclassic.c rcu_check_callbacks()
function to ignore the idle task as a quiescent state until the
system has started up the scheduler in rest_init(), introducing a
new non-API function rcu_idle_now_means_idle() to inform RCU of this
transition. RCU maintains an internal rcu_idle_cpu_truthful variable
to track this state, which is then used by rcu_check_callback() to
determine if it should believe idle_cpu().Because this patch has the effect of disallowing RCU grace periods
during long stretches of the boot-up sequence, this patch also introduces
Josh Triplett's UP-only optimization that makes synchronize_rcu() be a
no-op if num_online_cpus() returns 1. This allows boot-time code that
calls synchronize_rcu() to proceed normally. Note, however, that RCU
callbacks registered by call_rcu() will likely queue up until later in
the boot sequence. Although rcuclassic and rcutree can also use this
same optimization after boot completes, rcupreempt must restrict its
use of this optimization to the portion of the boot sequence before the
scheduler starts up, given that an rcupreempt RCU read-side critical
section may be preeempted.In addition, this patch takes Nick Piggin's suggestion to make the
system_state global variable be __read_mostly.Changes since v4:
o Changes the name of the introduced function and variable to
be less emotional. ;-)Changes since v3:
o WARN_ON(nr_context_switches() > 0) to verify that RCU
switches out of boot-time mode before the first context
switch, as suggested by Nick Piggin.Changes since v2:
o Created rcu_blocking_is_gp() internal-to-RCU API that
determines whether a call to synchronize_rcu() is itself
a grace period.o The definition of rcu_blocking_is_gp() for rcuclassic and
rcutree checks to see if but a single CPU is online.o The definition of rcu_blocking_is_gp() for rcupreempt
checks to see both if but a single CPU is online and if
the system is still in early boot.This allows rcupreempt to again work correctly if running
on a single CPU after booting is complete.o Added check to rcupreempt's synchronize_sched() for there
being but one online CPU.Tested all three variants both SMP and !SMP, booted fine, passed a short
rcutorture test on both x86 and Power.Located-by: Vegard Nossum
Tested-by: Vegard Nossum
Tested-by: Paul E. McKenney
Signed-off-by: Paul E. McKenney
Signed-off-by: Ingo Molnar -
During host driver module removal del_gendisk() results in a final
put on drive->gendev and freeing the drive by drive_release_dev().Convert device drivers from using struct kref to use struct device
so device driver's object holds reference on ->gendev and prevents
drive from prematurely going away.Also fix ->remove methods to not erroneously drop reference on a
host driver by using only put_device() instead of ide*_put().Reported-by: Stanislaw Gruszka
Tested-by: Stanislaw Gruszka
Signed-off-by: Bartlomiej Zolnierkiewicz -
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/i915: convert DRM_ERROR to DRM_DEBUG in phys object pwrite path
drm/i915: make hw page ioremap use ioremap_wc
drm: edid revision 0 is valid
drm: Correct unbalanced drm_vblank_put() during mode setting.
drm: disable encoders before re-routing them
drm: Fix ordering of bit fields in EDID structure leading huge vsync values.
drm: Fix shifts of EDID vsync offset/width fields.
drm/i915: handle bogus VBT panel timing
drm/i915: remove PLL debugging messages -
* git://git.infradead.org/iommu-2.6:
intel-iommu: fix endless "Unknown DMAR structure type" loop
VT-d: handle Invalidation Queue Error to avoid system hang
intel-iommu: fix build error with INTR_REMAP=y and DMAR=n
25 Feb, 2009
5 commits
-
io_mapping_create_wc should take a resource_size_t parameter in place of
unsigned long. With unsigned long, there will be no way to map greater than 4GB
address in i386/32 bit.On x86, greater than 4GB addresses cannot be mapped on i386 without PAE. Return
error for such a case.Patch also adds a structure for io_mapping, that saves the base, size and
type on HAVE_ATOMIC_IOMAP archs, that can be used to verify the offset on
io_mapping_map calls.Signed-off-by: Venkatesh Pallipadi
Signed-off-by: Suresh Siddha
Cc: Dave Airlie
Cc: Jesse Barnes
Cc: Eric Anholt
Cc: Keith Packard
Signed-off-by: Ingo Molnar -
In some cases we may receive a mode config that has a different
CRTCencoder map that the current configuration. In that case, we
need to disable any re-routed encoders before setting the mode,
otherwise they may not pick up the new CRTC (if the output types are
incompatible for example).Tested-by: Kristian Høgsberg
Signed-off-by: Jesse Barnes
Signed-off-by: Dave Airlie -
Signed-off-by: Jesse Barnes
Reviewed-by: Eric Anholt
Signed-off-by: Dave Airlie -
The unit in which user-space can set the bus timeout value is jiffies
for historical reasons (back when HZ was always 100.) This is however
not good because user-space doesn't know how long a jiffy lasts. The
timeout value should instead be set in a fixed time unit. Given the
original value of HZ, this unit should be 10 ms, for compatibility.Signed-off-by: Jean Delvare
Acked-by: Wolfram Sang
24 Feb, 2009
1 commit
-
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
netns: fix double free at netns creation
veth : add the set_mac_address capability
sunlance: Beyond ARRAY_SIZE of ib->btx_ring
sungem: another error printed one too early
ISDN: fix sc/shmem printk format warning
SMSC: timeout reaches -1
smsc9420: handle magic field of ethtool_eeprom
sundance: missing parentheses?
smsc9420: fix another postfixed timeout
wimax/i2400m: driver loads firmware v1.4 instead of v1.3
vlan: Update skb->mac_header in __vlan_put_tag().
cxgb3: Add support for PCI ID 0x35.
tcp: remove obsoleted comment about different passes
TG3: &&/|| confusion
ATM: misplaced parentheses?
net/mv643xx: don't disable the mib timer too early and lock properly
net/mv643xx: use GFP_ATOMIC while atomic
atl1c: Atheros L1C Gigabit Ethernet driver
net: Kill skb_truesize_check(), it only catches false-positives.
net: forcedeth: Fix wake-on-lan regression
23 Feb, 2009
1 commit
-
Move the sysdev_suspend/resume from the callee to the callers, with
no real change in semantics, so that we can rework the disabling of
interrupts during suspend/hibernation.This is based on an earlier patch from Linus.
Signed-off-by: Rafael J. Wysocki
Signed-off-by: Linus Torvalds
22 Feb, 2009
2 commits
-
* hibernate:
PM: Fix suspend_console and resume_console to use only one semaphore
PM: Wait for console in resume
PM: Fix pm_notifiers during user mode hibernation
swsusp: clean up shrink_all_zones()
swsusp: dont fiddle with swappiness
PM: fix build for CONFIG_PM unset
PM/hibernate: fix "swap breaks after hibernation failures"
PM/resume: wait for device probing to finish
Consolidate driver_probe_done() loops into one place -
there's a few places that currently loop over driver_probe_done(), and
I'm about to add another one. This patch abstracts it into a helper
to reduce duplication.Signed-off-by: Arjan van de Ven
Signed-off-by: Rafael J. Wysocki
Cc: Len Brown
Acked-by: Greg KH
Signed-off-by: Linus Torvalds
21 Feb, 2009
4 commits
-
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (26 commits)
drm/radeon: update sarea copies of last_ variables on resume.
drm/i915: Keep refs on the object over the lifetime of vmas for GTT mmap.
drm/i915: take struct mutex around fb unref
drm: Use spread spectrum when the bios tells us it's ok.
drm: Collapse identical i8xx_clock() and i9xx_clock().
drm: Bring PLL limits in sync with DDX values.
drm: Add locking around cursor gem operations.
drm: Propagate failure from setting crtc base.
drm: Check for a NULL encoder when reverting on error path
drm/i915: Cleanup the hws on ringbuffer constrution failure.
drm/i915: Don't add panel_fixed_mode to the probed modes list at LVDS init.
drm: Release user fbs in drm_release
drm/i915: Unpin the fb on error during construction.
drm/i915: Unpin the hws if we fail to kmap.
drm/i915: Unpin the ringbuffer if we fail to ioremap it.
drm/i915: unpin for an invalid memory domain.
drm/i915: Release and unlock on mmap_gtt error path.
drm/i915: Set framebuffer alignment based upon the fence constraints.
drm: Do not leak a new reference for flink() on an existing name
drm/i915: Fix potential AB-BA deadlock in i915_gem_execbuffer()
... -
Intel 8257x Ethernet boards have a feature called Serial Over Lan.
This feature works by emulating a serial port, and it is detected by
kernel as a normal 8250 port. However, this emulation is not perfect, as
also noticed on changeset 7500b1f602aad75901774a67a687ee985d85893f.Before this patch, the kernel were trying to check if the serial TX is
capable of work using IRQ's.This were done with a code similar this:
serial_outp(up, UART_IER, UART_IER_THRI);
lsr = serial_in(up, UART_LSR);
iir = serial_in(up, UART_IIR);
serial_outp(up, UART_IER, 0);if (lsr & UART_LSR_TEMT && iir & UART_IIR_NO_INT)
up->bugs |= UART_BUG_TXEN;This works fine for other 8250 ports, but, on 8250-emulated SoL port, the
chip is a little lazy to down UART_IIR_NO_INT at UART_IIR register.Due to that, UART_BUG_TXEN is sometimes enabled. However, as TX IRQ keeps
working, and the TX polling is now enabled, the driver miss-interprets the
IRQ received later, hanging up the machine until a key is pressed at the
serial console.This is the 6 version of this patch. Previous versions were trying to
introduce a large enough delay between serial_outp and serial_in(up,
UART_IIR), but not taking forever. However, the needed delay couldn't be
safely determined.At the experimental tests, a delay of 1us solves most of the cases, but
still hangs sometimes. Increasing the delay to 5us was better, but still
doesn't solve. A very high delay of 50 ms seemed to work every time.However, poking around with delays and pray for it to be enough doesn't
seem to be a good approach, even for a quirk.So, instead of playing with random large arbitrary delays, let's just
disable UART_BUG_TXEN for all SoL ports.[akpm@linux-foundation.org: fix warnings]
Signed-off-by: Mauro Carvalho Chehab
Cc: Alan Cox
Cc:
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This adds more documentation of the lowlevel API to avoid future bugs.
Signed-off-by: Michael Buesch
Acked-by: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
kzfree() is a wrapper for kfree() that additionally zeroes the underlying
memory before releasing it to the slab allocator.Currently there is code which memset()s the memory region of an object
before releasing it back to the slab allocator to make sure
security-sensitive data are really zeroed out after use.These callsites can then just use kzfree() which saves some code, makes
users greppable and allows for a stupid destructor that isn't necessarily
aware of the actual object size.Signed-off-by: Johannes Weiner
Reviewed-by: Pekka Enberg
Cc: Matt Mackall
Acked-by: Christoph Lameter
Cc: Nick Piggin
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
20 Feb, 2009
3 commits
-
This fixes potential fault at fault time if the object was unreferenced
while the mapping still existed. Now, while the mmap_offset only lives
for the lifetime of the object, the object also stays alive while a vma
exists that needs it.Signed-off-by: Jesse Barnes
Signed-off-by: Eric Anholt
Signed-off-by: Dave Airlie -
Check the error paths within intel_pipe_set_base() to first cleanup and
then report back the error.Signed-off-by: Chris Wilson
Signed-off-by: Eric Anholt
Signed-off-by: Dave Airlie -
Avoids leaking fbs and associated buffers on release.
Signed-off-by: Kristian Høgsberg
Tested-by: Tested-by: Chris Wilson
Signed-off-by: Eric Anholt
Signed-off-by: Dave Airlie
19 Feb, 2009
1 commit
-
After moving mac addresses in __vlan_put_tag() skb->mac_header needs
to be updated.Reported-by: Karl Hiramoto
Signed-off-by: Jarek Poplawski
Signed-off-by: David S. Miller