08 Feb, 2006
29 commits
-
The spinlock-debug wait-loop was using loops_per_jiffy to detect too long
spinlock waits - but on fast CPUs this led to a way too fast timeout and false
messages.The fix is to include a __delay(1) call in the loop, to correctly approximate
the intended delay timeout of 1 second. The code assumes that every
architecture implements __delay(1) to last around 1/(loops_per_jiffy*HZ)
seconds.Signed-off-by: Ingo Molnar
Cc: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Compound pages on SMP systems can now often be freed from pagetables via
the release_pages path. This uses put_page_testzero which does not handle
compound pages at all. Releasing constituent pages from process mappings
decrements their count to a large negative number and leaks the reference
at the head page - net result is a memory leak.The problem was hidden because the debug check in put_page_testzero itself
actually did take compound pages into consideration.Fix the bug and the debug check.
Signed-off-by: Nick Piggin
Acked-by: Hugh Dickins
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Make SELinux depend on AUDIT as it requires the basic audit support to log
permission denials at all. Note that AUDITSYSCALL remains optional for
SELinux, although it can be useful in providing further information upon
denials.Signed-off-by: Stephen Smalley
Acked-by: James Morris
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix compilation problem in PM headers.
Signed-off-by: Rafael J. Wysocki
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
We had a user trigger this message on a box that had a lot of different
mounts, all with different options. It might help narrow down wtf happened
if we print out which device failed.Signed-off-by: Dave Jones
Signed-off-by: Adrian Bunk
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Userspace can alter the string after the kernel has run strlen_user().
Also: the strlen_user() return value includes the \0, so fix that.
Also: handle EFAULT from strlen_user().
It's unlikely anyone is using this code. Very, very unlikely. If I
remember correctly, CONFIG_HPUX turns this code on, but one would actually
need CONFIG_BINFMT_SOM to load a binary that could cause a problem, and
BINFMT_SOM has had an #error in it for quite some time.Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix one-shot support in inotify. We currently drop the IN_ONESHOT flag
during watch addition. Fix is to not do that.Signed-off-by: Robert Love
Cc: John McCutchan
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
A previous patch removed a file from the build without removing it from the
tree.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
We weren't making sure that we initialized the FP registers of new processes
to sane values.This patch also moves some defines in the affected area closer to where they
are used.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The process that UML uses to probe the host's ptrace capabilities can (rarely)
receive a SIGWINCH, confusing the parent. This fixes that by blocking
SIGWINCH.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The network driver added an interface to the "opened" list when it was
configured, not when it was brought up, and removed it when it was taken down.
A sequence of ifconfig up, ifconfig down, ... caused it to be removed
multiple times from the list without being added in between, resulting in a
crash. This patch moves the add to when the interface is brought up.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
When UML opens a TUN/TAP device, the file descriptor could be copied into
later, long-lived threads, holding the device open even after the interface is
taken down, preventing it from being brought up again. This patch makes these
descriptors close-on-exec so that they disappear from helper processes, and
adds CLONE_FILES to a UML helper thread so that the descriptors are closed in
the thread when they are closed elsewhere in UML.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
It doesn't do anything but emit a warning, but there's a user population
that's used to adding 'debug' to the UML command line in order to gdb it.
With skas0 mode, that's not necessary, but these users need some indication
that 'debug' doesn't do what they want.Signed-off-by: Jeff Dike
Cc: Paolo 'Blaisorblade' Giarrusso
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Fix do_path_lookup() to avoid accessing invalid dentry or inode when the
link_path_walk() has failed. This should fix Bugme #5897.Signed-off-by: Suzuki K P
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
With the latest 2.6.15 kernel builds for alpha on Debian, we ran into a
problem with undefined references to __cmpxchg_called_with_bad_pointer() in
a couple of kernel modules (xfs.ko and drm.ko; see
http://bugs.debian.org/347556).It looks like people have been trying to out-clever each other wrt the
definition of "inline" on this architecture :), with the result that
__cmpxchg(), which must be inlined so the compiler can see its argument is
const, is not guaranteed to be inlined. Indeed, it was not being inlined
when building with -Os.The attached patch fixes the issue by adding an
__attribute__((always_inline)) explicitly to the definition of __cmpxchg()
instead of relying on redefines of "inline" elsewhere to make this happen.Cc: Richard Henderson
Cc: Ivan Kokshaysky
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This does not show up unless you #define DEBUG in the file, which most
people wouldn't do. On PPC405, at least, "sector_t" is unsigned long,
which doesn't match %llx/%llu. Since sector# may well be >32 bits, promote
the value to match the format.Signed-off-by: Michael Richardson
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
I just noticed that my patch "don't create on open that fails due to
ERR_GRACE" (recently commited as fb553c0f17444e090db951b96df4d2d71b4f4b6b)
had an obvious problem that causes a deadlock on reboot recovery. Sending
in this now since it seems like a clear 2.6.16 candidate.--b.We're returning with a lock held in some error cases.
Signed-off-by: J. Bruce Fields
Signed-off-by: Neil Brown
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Remove wrong and misleading comments.
Return VM_FAULT_OOM if the hugetlbpage fault handler cannot allocate a
page. do_no_page will end up doing do_exit(SIGKILL).Signed-off-by: Christoph Lameter
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
When hugepages are newly allocated to a file in mm/hugetlb.c, we clear them
with a call to clear_highpage() on each of the subpages. We should be
using clear_user_highpage(): on powerpc, at least, clear_highpage() doesn't
correctly mark the page as icache dirty so if the page is executed shortly
after it's possible to get strange results.Signed-off-by: David Gibson
Acked-by: William Lee Irwin III
Cc:
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Currently, x86_64 and ia64 arches do not clear the corresponding bits in
the node's cpumask when a cpu goes down or cpu bring up is cancelled. This
is buggy since there are pieces of common code where the cpumask is checked
in the cpu down code path to decide on things (like in the slab down path).
PPC does the right thing, but x86_64 and ia64 don't (This was the reason
Sonny hit upon a slab bug during cpu offline on ppc and could not reproduce
on other arches). This patch fixes it for x86_64. I won't attempt ia64 as
I cannot test it.Credit for spotting this should go to Alok.
(akpm: this was applied, then reverted. But it's OK now because we now use
for_each_cpu() in the right places).Signed-off-by: Alok N Kataria
Signed-off-by: Ravikiran Thirumalai
Signed-off-by: Shai Fultheim
Signed-off-by: Andi Kleen
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
- Remove unneeded bio_get() which would cause a bio leak
- Writing doesn't dirty pages. Reading dirties pages.
- We should dirty the pages after the IO completion, not before
(Busy-waiting for disk I/O completion isn't very polite.)
Signed-off-by: Pavel Machek
Cc: "Rafael J. Wysocki"
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
drivers/base/bus.c:166: warning: `driver_attr_unbind' defined but not used
drivers/base/bus.c:194: warning: `driver_attr_bind' defined but not usedLooks like these two attributes and supporting functions want to be
#ifdef HOTPLUG'dSigned-off-by: Russell King
Cc: Greg KH
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
The softirq rq completion handler needs to save/restore interrupt flags
appropriately.Signed-off-by: Jens Axboe
Signed-off-by: Linus Torvalds -
Fix wrong '!' in bad apic fix
I forgot to remove the ! when moving the code from x86-64 to i386 x86-64
tested !disable_apic, but of course for cpu_has_apic it shouldn't be
negated.Credit goes to Jan Beulich for spotting it with eagle eyes.
Cc: Jan Beulich
Cc: Ingo Molnar
Signed-off-by: Andi Kleen
Signed-off-by: Linus Torvalds
07 Feb, 2006
11 commits
-
The reset state is undefined and some firmware doesn't clear this bit
possibly resulting in crashes on entry into userland.Signed-off-by: Ralf Baechle
-
I've noticed that PCI clock was incorrectly reported as 66 MHz while being
mere 33 MHz on RBTX4937 board -- this was due to the different encoding of
the PCI divisor field in CCFG register between TX4927 and TX4937 chips...Also, RBTX49x7 was printed out as a CPU name (e.g., "CPU is RBTX4937");
and some debug printk() were duplicating each other...Signed-off-by: Konstantin Baydarov
Signed-off-by: Sergei Shtylyov
Signed-off-by: Ralf Baechle -
If mfc0 $12 follows store and the mfc0 is last instruction of a
page and fetching the next instruction causes TLB miss, the result
of the mfc0 might wrongly contain EXL bit.ERT-TX49H2-027, ERT-TX49H3-012, ERT-TX49HL3-006, ERT-TX49H4-008
Workaround: mask EXL bit of the result or place a nop before mfc0. It
doesn't harm to always clear those bits, so we change the code to do so.Signed-off-by: Atsushi Nemoto
Signed-off-by: Ralf Baechle -
Very much to my surprise Fuxin Zhang reports this is all it takes to get
the kernel to work for page sizes larger than 4kB. This also paves the
way for support for the R6000 and R8000 which don't support 4kB page size.Signed-off-by: Ralf Baechle
-
Signed-off-by: Ralf Baechle
-
Signed-off-by: Atsushi Nemoto
Signed-off-by: Ralf Baechle -
Signed-off-by: Atsushi Nemoto
Signed-off-by: Ralf Baechle -
From Franck Bui-Huu with modifications by me.
Signed-off-by: Ralf Baechle
-
Signed-off-by: Ralf Baechle
-
Signed-off-by: Atsushi Nemoto
Signed-off-by: Ralf Baechle -
Signed-off-by: Ralf Baechle