1. 08 Mar, 2005 40 commits
    • Peter Samuelson's avatar
      [PATCH] cross-compile scripts/lxdialog/ on AIX · 9c329b29
      Peter Samuelson authored
      AIX curses.h defines macros 'clear_screen' and 'color_names' but does not
      define 'scroll()'.
      Signed-Off-By: default avatarPeter Samuelson <peter@p12n.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      9c329b29
    • matthias.kunze@gmx-topmail.de's avatar
      [PATCH] loglevel boot option · 6a9dafd1
      matthias.kunze@gmx-topmail.de authored
      Add a boot-time option to set the loglevel.  We already have `quiet' and
      `debug', which set it to specific levels.  This is better.  
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      6a9dafd1
    • Alexander Nyberg's avatar
      [PATCH] ext3_new_inode() failure handling missing check · b921bc08
      Alexander Nyberg authored
      There's a missing failure handling check here that would possibly lead to a
      null dereference later on, I'm not sure about the correct return value
      however.  I haven't tried it as I'm not sure how to trigger the case ;)
      
      Found by the Coverity tool.
      Signed-off-by: default avatarAlexander Nyberg <alexn@dsv.su.se>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      b921bc08
    • David Howells's avatar
      [PATCH] Keys: Doc update on locking · 97ffe49f
      David Howells authored
      The attached patch updates the documentation on the kernel keys to describe
      the locking associated with keys and key type operations.
      Signed-Off-By: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      97ffe49f
    • Vladimir Saveliev's avatar
      [PATCH] reiserfs: return -EIO instead of calling BUG() when rename goes wrong · b423a99d
      Vladimir Saveliev authored
      This patch makes reiserfs to return -EIO when rename-ing went wrong instead
      of calling BUG().
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      b423a99d
    • a.llano@usyscom.com's avatar
      [PATCH] Fix 1-Wire Dallas in bigendian machines · 4ea5e988
      a.llano@usyscom.com authored
      I've been testing the 1-Wire Dallas in a bigendian machine (through a GPIO)
      and I've found some problems that can easily addressed with the provided
      patch.  (inline at the end of the message).
      
      I have a question about the implementation of w1_smem.
      In the line 90 of drivers/w1/w1_smem.c.
        for (i = 0; i < 9; ++i)
           count += sprintf(buf + count, "%02x ", ((u8 *)&sl->reg_num)[i]);
      I don't see why this loop is execute 9 times when the provided reg_num
      is 8 bytes long. I don't understand the purpose of the last byte.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      4ea5e988
    • Badari Pulavarty's avatar
      [PATCH] Add nobh_writepage() support · a61faa62
      Badari Pulavarty authored
      Add nobh_wripage() support for the filesystems which uses
      nobh_prepare_write/nobh_commit_write().
      
      Idea here is to reduce unnecessary bufferhead creation/attachment to the
      page through pageout()->block_write_full_page().  nobh_wripage() tries to
      operate by directly creating bios, but it falls back to
      __block_write_full_page() if it can't make progress.
      
      Note that this is not really generic routine and can't be used for
      filesystems which uses page->Private for anything other than buffer heads.
      Signed-off-by: default avatarBadari Pulavarty <pbadari@us.ibm.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      a61faa62
    • Badari Pulavarty's avatar
      [PATCH] export kallsyms_lookup_name() · f326c26e
      Badari Pulavarty authored
      Export kallsyms_lookup_name() for kprobe/jprobe module use.
      
      (akpm: modules which use kprobes/jrobes are usually problem-specific and
      will not be merged into the mainline kernel, so we we're actually to see
      actual users of this patch merged)
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      f326c26e
    • smurf@smurf.noris.de's avatar
      [PATCH] bksend example script fix · da18d3e2
      smurf@smurf.noris.de authored
      The "bksend" example script doesn't work if PAGER (used by "bk changes")
      is set to something which doesn't fallback to plain stdout if its output
      isn't a tty.
      
      Fixed by forcing PAGER to be /bin/cat.
      Signed-Off-By: default avatarMatthias Urlichs <smurf@debian.org>
      Acked-by: default avatarJeff Garzik <jgarzik@pobox.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      da18d3e2
    • smurf@smurf.noris.de's avatar
      [PATCH] CREDITS Update · 21bf8934
      smurf@smurf.noris.de authored
      CREDITS update for Mattihas Urlichs.
      Signed-Off-By: default avatarMatthias Urlichs <smurf@debian.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      21bf8934
    • rene.scharfe@lsrfire.ath.cx's avatar
      [PATCH] remove mount option parsing from procfs · 414d718a
      rene.scharfe@lsrfire.ath.cx authored
      This patch removes the mount options of the proc filesystem.  They don't
      have any effect since 2.4.something.
      
      Only proc_fill_super() calls parse_options, notably proc_remount() does
      not.  And proc_fill_super() is only called at the very first mount which in
      turn is the one caused by kern_mount() in fs/proc/root.c and that passes a
      NULL pointer as mount options string.  It is called only once because proc
      is a filesystem with a single super_block (i.e.  it uses get_sb_single()).
      
      Since noone seems to miss the uid and gid options so far I suggest to
      simply remove them.  Their function can be easily performed in userspace.
      E.g.  this (if it worked like intended):
      
          # mount -t proc -o uid=procuser,gid=procgrp proc /proc
      
      can be done like so, probably in some init script:
      
          # mount -t proc proc /proc && chown procuser:procgrp /proc
      
      But I don't see why anyone would want to do that in the first place.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      414d718a
    • Gerd Knorr's avatar
      [PATCH] tv tuner module update. · 7a23550f
      Gerd Knorr authored
      Did some code reorganization: split up the source into four files:
       - tuner-core.c for all the interfacing stuff (register driver,
         handle insmod options, react on v4l ioctls, ...),
       - tuner-simple.c for all those trivial 4-byte-command-sequence tuner
         chips.
       - mt20xx.c for the mt2032 and mt2050 tuners.
       - tda8290.c for the tda8290/8272 combo (this code is new).
      
      I also did a number of cleanups like using dev_printk() for the
      messages everythere.  There should be no functional changes beside
      the new support for the tda8290 tuner.
      Signed-off-by: default avatarGerd Knorr <kraxel@bytesex.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      7a23550f
    • Gerd Knorr's avatar
      [PATCH] minor bttv driver update · 57b951e3
      Gerd Knorr authored
      Just a new PCI Subsystem ID and a PM fix from Pavel.
      Signed-off-by: default avatarGerd Knorr <kraxel@bytesex.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      57b951e3
    • Andrea Arcangeli's avatar
      [PATCH] seccomp: secure computing support · d949d0ec
      Andrea Arcangeli authored
      I'd need it merged into mainline at some point, unless anybody has strong
      arguments against it.  All I can guarantee here, is that I'll back it out
      myself in the future, iff Cpushare will fail and nobody else started using
      it in the meantime for similar security purposes.
      
      (akpm: project details are at http://www.cpushare.com/technical.  It seems
      like a good idea to me, and one which is worth supporting.  I agree that for
      this to be successful, the added robustness of Andrea's simple and specific
      jail is worthwhile).
      Signed-off-by: default avatarAndrea Arcangeli <andrea@cpushare.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      d949d0ec
    • Tim Bird's avatar
      [PATCH] add timing information to printk messages · abbaf4f1
      Tim Bird authored
      Here's a little patch which is useful for showing timing information for
      kernel bootup activities.
      
      This patch adds a new Kconfig option under "Kernel Hacking" and a new
      option for the kernel command line.  It also provides a script for showing
      delta information.
      
      Note that the timing data may not be correct on some platforms until after
      time_init() is called.
      
      Recently (as of about 2.6.10) I found that the message log produced by
      dmesg is truncated when I use this feature.  That is, the first few printk
      messages of the boot sequence are not in the dmesg output, although they
      are printed to console during startup.  This is a new behavior - dmesg
      output was fine as of 2.6.9.  Increasing CONFIG_LOG_BUF_SHIFT had no effect
      on the truncation.
      
      Has something changed with printk recently?
      
      For more information on this patch, see:
      http://tree.celinuxforum.org/CelfPubWiki/InstrumentedPrintk
      
      Here's some sample output:
      ...
      [4294667.296000] Kernel command line: ro root=/dev/nfs ip=dhcp hdc=ide-scsi console=vga console=ttyS0,115200
      [4294667.296000] ide_setup: hdc=ide-scsi
      [4294667.296000] Initializing CPU#0
      [4294667.296000] PID hash table entries: 512 (order: 9, 8192 bytes)
      [    0.000000] Detected 1995.620 MHz processor.
      [   21.397369] Using tsc for high-res timesource
      [   21.399820] Console: colour VGA+ 80x25
      [   21.537244] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
      [   21.544547] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
      [   21.555066] Memory: 125076k/130240k available (2002k kernel code, 4556k reserved, 1006k data, 140k init, 0k highmem)
      [   21.565775] Checking if this processor honours the WP bit even in supervisor mode... Ok.
      [   21.574089] Calibrating delay loop... 3940.35 BogoMIPS (lpj=1970176)
      [   21.596511] Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
      [   21.603263] CPU: After generic identify, caps: bfebfbff 00000000 00000000 00000000 00004400 00000000 00000000
      [   21.603276] CPU: After vendor identify, caps: bfebfbff 00000000 00000000 00000000 00004400 00000000 00000000
      [   21.603287] CPU: Trace cache: 12K uops, L1 D cache: 8K
      [   21.608884] CPU: L2 cache: 128K
      ...
      
      And now the patch...
      Signed-off-by: default avatarTim Bird <tim.bird@am.sony.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      abbaf4f1
    • Anton Altaparmakov's avatar
      [PATCH] a_ops-based loop I/O · f3f28e49
      Anton Altaparmakov authored
      Implements fallback to file_operations->write in the case that
      aops->{prepare,commit}_write are not present on the backing filesystem.
      
      The fallback happens in two different ways:
      
      - For normal loop devices, i.e.  ones which do not do transformation on
        the data but simply pass it along, we simply call fops->write.  This
        should be pretty much just as fast as using aops->{prepare,commit}_write
        directly.
      
      - For all other loop devices (e.g.  xor and cryptoloop), i.e.  all the
        ones which may be doing transformations on the data, we allocate and map
        a page (once for each bio), then for each bio vec we copy the bio vec
        page data to our mapped page, apply the loop transformation, and use
        fops->write to write out the transformed data from our page.  Once all
        bio vecs from the bio are done, we unmap and free the page.
      
      This approach is the absolute minimum of overhead I could come up with and
      for performance hungry people, as you can see I left the address space
      operations method in place for filesystems which implement
      aops->{prepare,commit}_write.
      
      I have tested this patch with normal loop devices using
      aops->{prepare,commit}_write on the backing filesystem, with normal loop
      devices using the fops->write code path and with cryptoloop devices using
      the double buffering + fops->write code path.
      Signed-off-by: default avatarAnton Altaparmakov <aia21@cantab.net>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      f3f28e49
    • Zwane Mwaikambo's avatar
      [PATCH] Run softirqs on proper processor on offline · 20b0bb36
      Zwane Mwaikambo authored
      We take down ksoftirqds at CPU_DEAD time, so there is a brief period whereupon
      there is a ksoftirqd thread for an offline processor, it is at this point that
      ->cpus_allowed won't have it pinned anymore.  An online processor would then
      take down that ksoftirqd and exit it.
      
      Ensure that we only offline the processor when it's safe and never run
      softirqs in another processor's ksoftirqd context.  This also gets rid of the
      warnings in ksoftirqd on cpu offline.
      Signed-off-by: default avatarZwane Mwaikambo <zwane@arm.linux.org.uk>
      Acked-by: default avatarIngo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      20b0bb36
    • Jan Kara's avatar
      [PATCH] Implement quota reading and writing functions for UFS. · ad87b375
      Jan Kara authored
      Attached patch adds functions ufs_quota_read() and ufs_quota_write() to the
      UFS code.  So quotas for UFS should work again (they were broken by the
      quota io redesign).  I don't actually think the patch is too much important
      as I'm not sure anybody uses quotas on UFS but we're in the "stable" branch
      so just dropping a support did not seem right to me.
      Signed-off-by: default avatarJan Kara <jack@suse.cz>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      ad87b375
    • Dave Olien's avatar
      [PATCH] add local bio pool support and modify dm · 63858f83
      Dave Olien authored
      I've had this patch reviewed by Jens, and incorporated his recommended
      fixes.
      
      The patch adds new interfaces to bio.c that support the creation of local
      bio and bvec pools.  This is important for layered drivers that need to
      allocate new bio and bvec structures in response to bio's submitted to it
      from higher up.  The layered drivers can allocate local pools of bio
      structures to preclude deadlock under global bio pool exhaustion.
      
      The device mapper source files have been modified to remove duplicate bio
      code, and to use the new interfaces to create local bio pools.
      
      From: Dave Olien <dmo@osdl.org>
      
      Change bio_clone() to use the global bio_set pool instead of the bio_set pool
      associated with the bio argument.  This is because raid5 and raid6 bio's are
      not allocated from a bio_set and have no bio_set associated with them.  This
      patch along with the patch Linux just accepted allows raid5 and raid6 to
      function.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      63858f83
    • Ingo Molnar's avatar
      [PATCH] clean up and unify asm-*/resource.h files · 98a1031e
      Ingo Molnar authored
      This patch does the final consolidation of asm-*/resource.h file, without
      changing any of the rlimit definitions on any architecture.  Primarily it
      removes the __ARCH_RLIMIT_ORDER method and replaces it with a more compact
      and isolated one that allows architectures to define only the offending
      rlimits.
      
      This method has the positive effect that adding a new rlimit can now be
      purely done via changing asm-generic/resource.h alone.  Previously one
      would have to patch 4 other (sparc, sparc64, alpha and mips) resource.h
      files.
      
      The patch also does style unification, whitespace cleanups and
      simplification of resource.h files and cleans up the asm-generic/resource.h
      file as well.  I've added more comments too.
      
      This patch should have no effect on any code on any architecture.  (i.e.
      it's a pure identity patch.)
      
      Tested on x86 and carefully reviewed to make sure that Sparc, Sparc64,
      MIPS and Alpha rlimits are still the same as required by the ABI.
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      Acked-by: default avatarChris Wright <chrisw@osdl.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      98a1031e
    • ken@mvista.com's avatar
      [PATCH] drivers/char/lp.c race fix · 54f1a7a7
      ken@mvista.com authored
      In lp_write(), copy_from_user() is called to copy data into a statically
      allocated kernel buffer before down_interruptible() is called.  If a second
      thread of execution comes in between the copy_from_user() and the
      down_interruptible() calls, silent data corruption could result.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      54f1a7a7
    • Stephen Hemminger's avatar
      [PATCH] convert /proc/driver/rtc to seq_file. · 4c6672c1
      Stephen Hemminger authored
      The /proc/driver/rtc interface didn't have any module owner hook.  The
      simplest fix is to just convert this to the single version of seq_file. 
      Also, fix initialization of rtc_dev to use C99 form.
      Signed-off-by: default avatarStephen Hemminger <shemminger@osdl.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      4c6672c1
    • Adrian Bunk's avatar
      [PATCH] add compiler-gcc4.h · 6740e938
      Adrian Bunk authored
      With the release of gcc 4.0 being only a few months away and people
      already tring compiling with it, it's time for adding a compiler-gcc4.h .
      
      This patch contains the following changes:
      - remove compiler-gcc+.h
      - compiler-gcc4.h: new file based on a corrected compiler-gcc+.h
      - compiler.h: include compiler-gcc4.h for gcc 4
      - compiler.h: #error for gcc > 4
      - compiler-gcc3.h: remove __compiler_offsetof (there will never be a
                                                     gcc 3.5)
                         small indention corrections
      
      I've tested the compilation with both gcc 3.4.4 and a recent gcc 4.0 
      snapshot from Debian experimental.
      Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      6740e938
    • Ernie Petrides's avatar
      [PATCH] minor conceptual fix for /proc/kcore header size · bcba0212
      Ernie Petrides authored
      While investigating the 2.4 memory corruption problem fixed by the patch
      previously posted, it was noticed that the 2.6 version of get_kcore_size()
      inappropriately uses sizeof(struct memelfnote) in its calculation of the
      /proc/kcore ELF header size.  What is actually stored in the header is an
      "elf_note" structure plus the 4 ASCII chars "CORE".
      
      It just so happens that on 32-bit arches, both calculations result in the
      same value (16).  But on 64-bit arches, the allocated size (24) is larger
      than necessary (16).  This does not result in any possible data corruption,
      but it might be nice to correct this "conceptual" error.
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      bcba0212
    • Yoichi Yuasa's avatar
      [PATCH] serial: update vr41xx_siu · 08d081db
      Yoichi Yuasa authored
      This patch updates serial driver for VR41xx serial unit.  Some check are
      added to verify_port.
      Signed-off-by: default avatarYoichi Yuasa <yuasa@hh.iij4u.or.jp>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      08d081db
    • Arun Sharma's avatar
      [PATCH] add TCSBRKP to compat_ioctl.h · 3a667d2e
      Arun Sharma authored
      Move ioctl TCSBRKP support to compat layer. Same rationale as TCSBRK.
      
      - Remove corresponding code under ppc64, sparc64 and s390.
      - Use ULONG_IOCTL() instead of COMPATIBLE_IOCTL(), since the argument is int, 
        not pointer.
      Signed-off-by: default avatarGordon Jin <gordon.jin@intel.com>
      Signed-off-by: default avatarArun Sharma <arun.sharma@intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      3a667d2e
    • Ingo Molnar's avatar
      [PATCH] sys_setpriority() euid semantics fix · 410a5816
      Ingo Molnar authored
      What _is_ inconsistent is kernel/sys.c's setpriority()/set_one_prio().
      
      It checks current->euid|uid against p->uid, which makes little sense, but
      is how we've been doing it ever since.  It's a Linux quirk documented in
      the manpage.  To make things funnier, SuS requires current->euid|uid match
      against p->euid.
      
      The patch below fixes it (and brings the logic in line with what
      setscheduler()/setaffinity() does), but if we do it then it should be done
      only in 2.6.12 or later, after good exposure in -mm.
      
      (Worst-case this could break an application but i highly doubt it: it at
      most could deny renicing another task to positive (or in very rare cases,
      to negative) nice values, which no application should crash on something
      like that, normally.)
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      410a5816
    • Yoichi Yuasa's avatar
      [PATCH] serial: add the output interface control to VR41xx SIU driver · de1e6c0e
      Yoichi Yuasa authored
      This patch adds the output interface control to VR41xx SIU driver.
      And obsolete function for VR41xx SIU is removed.
      
      And add __init for the function used only for initialization.
      Signed-off-by: default avatarYoichi Yuasa <yuasa@hh.iij4u.or.jp>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      de1e6c0e
    • Yoichi Yuasa's avatar
      [PATCH] serial: add NEC VR4100 series serial support · 26e25c95
      Yoichi Yuasa authored
      This patch adds serial driver for NEC VR4100 series serial interface unit.
      
      The new device numbers have been recorded by LANANA.
      Signed-off-by: default avatarYoichi Yuasa <yuasa@hh.iij4u.or.jp>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      26e25c95
    • Ingo Molnar's avatar
      [PATCH] annotate /proc/<PID>/maps with [heap]/[stack]/[vdso] markers · 1ca55126
      Ingo Molnar authored
      This patch makes the /proc/<PID>/maps file easier to parse (both for humans
      and for applications), by annotating the heap, stack and vdso mappings with
      [heap], [stack] and [vdso] markers.
      
      It makes it easier/faster to determine at a quick glance whether an
      application has a secure VM layout, and it also makes it easier for tools
      to determine whether e.g.  the heap or stack is executable or not.
      
      new maps file, on a patched kernel:
      
       001c4000-001d9000 r-xp 00000000 03:01 19954      /lib/ld-2.3.3.so
       001d9000-001db000 rw-p 00014000 03:01 19954      /lib/ld-2.3.3.so
       001dd000-002fb000 r-xp 00000000 03:01 19960      /lib/tls/libc-2.3.3.so
       002fb000-002fd000 r--p 0011d000 03:01 19960      /lib/tls/libc-2.3.3.so
       002fd000-002ff000 rw-p 0011f000 03:01 19960      /lib/tls/libc-2.3.3.so
       002ff000-00301000 rw-p 002ff000 00:00 0
       08048000-0804c000 r-xp 00000000 03:01 31968      /bin/cat
       0804c000-0804d000 rw-p 00003000 03:01 31968      /bin/cat
       0804d000-0806e000 rw-p 0804d000 00:00 0          [heap]
       b7dbc000-b7dbd000 r--p 009d1000 03:01 83628      /usr/lib/locale/locale-archive
       b7dbd000-b7dc4000 r--p 0097d000 03:01 83628      /usr/lib/locale/locale-archive
       b7dc4000-b7df1000 r--p 0094a000 03:01 83628      /usr/lib/locale/locale-archive
       b7df1000-b7ff1000 r--p 00000000 03:01 83628      /usr/lib/locale/locale-archive
       b7ff1000-b7ff2000 rw-p b7ff1000 00:00 0
       bffeb000-c0000000 rw-p bffeb000 00:00 0          [stack]
       ffffe000-fffff000 ---p 00000000 00:00 0          [vdso]
      
      Tested on x86, but should work on all architectures.
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      1ca55126
    • Jens Axboe's avatar
      [PATCH] blk_execute_rq() oops on fast completion · 0c0ac75f
      Jens Axboe authored
      blk_execute_rq() can oops in wait_for_completion(), if the request has
      completed before we call wait_for_completion() because blk_end_sync_rq()
      clears ->waiting when it is entered.  Fix this by always using the on-stack
      completion variable instead.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      0c0ac75f
    • Jens Axboe's avatar
      [PATCH] scsi_io_completion sense copy · d324f68b
      Jens Axboe authored
      For the flush generated requests, we don't have room for sense info right
      now.  This might change in the future so that the sd end_io function can
      make a better judgement on what to do about an error.  So check this in
      scsi_io_completion(), only copy sense data to request if it has space
      assigned to it.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      d324f68b
    • Jens Axboe's avatar
      [PATCH] rework core barrier support · e18e923a
      Jens Axboe authored
      This reworks the core barrier support to be a lot nicer, so that all the
      nasty code resides outside of drivers/ide.  It requires minimal changes to
      support in a driver, I've added SCSI support as an example.  The ide code
      is adapted to the new code.
      
      With this patch, we support full barriers on sata now.  Bart has acked the
      addition to -mm, I would like for this to be submitted as soon as 2.6.12
      opens.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      e18e923a
    • Jens Axboe's avatar
      [PATCH] Add struct request end_io callback · e8be9091
      Jens Axboe authored
      This is needed for several things, one in-tree user which I will introduce
      after this patch.
      
      This adds a ->end_io callback to struct request, so it can be used with
      async io of any sort.  Right now users have to wait for completion in a
      blocking manner.  In the next iteration, ->waiting can be folded into
      ->end_io_data since it is just a special case of that use.
      
      From: Peter Osterlund <petero2@telia.com>
      
      The problem is that the add-struct-request-end_io-callback patch forgot to
      update pktcdvd.c.  This patch fixes it.
      Signed-off-by: default avatarJens Axboe <axboe@suse.de>
      Signed-off-by: default avatarPeter Osterlund <petero2@telia.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      e8be9091
    • Jan Blunck's avatar
      [PATCH] d_drop should use per dentry lock · cd67725a
      Jan Blunck authored
      d_drop() must use the dentry->d_lock spinlock.  In some cases __d_drop()
      was used without holding the dentry->d_lock spinlock, too.  This could end
      in a race with __d_lookup().
      Signed-off-by: default avatarJan Blunck <j.blunck@tu-harburg.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      cd67725a
    • David Howells's avatar
      [PATCH] Fix kallsyms/insmod/rmmod race · 02721572
      David Howells authored
      The attached patch fixes a race between kallsyms and insmod/rmmod.
      
      The problem is this:
      
       (1) The various kallsyms functions poke around in the module list without any
           locking so that they can be called from the oops handler.
      
       (2) Although insmod and rmmod use locks to exclude each other, these have no
           effect on the kallsyms function.
      
       (3) Although rmmod modifies the module state with the machine "stopped", it
           hasn't removed the metadata from the module metadata list, meaning that
           as soon as the machine is "restarted", the metadata can be observed by
           kallsyms.
      
           It's not possible to say that an item in that list should be ignored if
           it's state is marked as inactive - you can't get at the state information
           because you can't trust the metadata in which it is embedded.
      
           Furthermore, list linkage information is embedded in the metadata too, so
           you can't trust that either...
      
       (4) kallsyms may be walking the module list without a lock whilst either
           insmod or rmmod are busy changing it. insmod probably isn't a problem
           since nothing is going a way, but rmmod is as it's deleting an entry.
      
       (5) Therefore nothing that uses these functions can in any way trust any
           pointers to "static" data (such as module symbol names or module names)
           that are returned.
      
       (6) On ppc64 the problems are exacerbated since the hypervisor may reschedule
           bits of the kernel, making operations that appear adjacent occur a long
           time apart.
      
      This patch fixes the race by only linking/unlinking modules into/from the
      master module list with the machine in the "stopped" state. This means that
      any "static" information can be trusted as far as the next kernel reschedule
      on any given CPU without the need to hold any locks.
      
      However, I'm not sure how this is affected by preemption. I suspect more work
      may need to be done in that case, but I'm not entirely sure.
      
      This also means that rmmod has to bump the machine into the stopped state
      twice... but since that shouldn't be a common operation, I don't think that's
      a problem.
      
      I've amended this patch to not get spinlocks whilst in the machine locked
      state - there's no point as nothing else can be holding spinlocks.
      Signed-Off-By: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      02721572
    • Liam Girdwood's avatar
      [PATCH] OSS Support for AC97 low power codecs · 69bfca0e
      Liam Girdwood authored
      This is a resend of a patch that has been applied to 2.4.  The low power
      codec functionality has also now been included in ALSA.
      
      It checks the codec ID before doing an AC97 register reset.  This allows
      the kernel to support low power codecs that are powered down by a reset
      command.  This patch also fixes some other minor issues.
      
      Changes:-
      
      - Added AC97_DEFAULT_POWER_OFF to ac97_codec_ids[]
      
      - ac97_probe now checks hardwired codec ID's before sending a reset
      
      - Added support for WM9713
      
      - Moved the codec specific inits after the mixer setup as some init
      
      - tings were being clobbered.
      
      - Added extra check so that default_digital_ops doesn't overwrite a valid
        codec_ops.  (SPDIF)
      Signed-off-by: default avatarLiam Girdwood <liam.girdwood@wolfsonmicro.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      69bfca0e
    • Corey Minyard's avatar
      [PATCH] Fix race between the NMI code and the CMOS clock · dd26caf1
      Corey Minyard authored
      This patch fixes a race between the CMOS clock setting and the NMI code.
      The NMI code indiscriminatly sets index registers and values in the same
      place the CMOS clock is set.  If you are setting the CMOS clock and an NMI
      occurs, Bad values could be written to or read from the CMOS RAM, or the
      NMI operation might not occur correctly.
      
      Fixing this requires creating a special lock so the NMI code can know its
      CPU owns the lock an "do the right thing" in that case.
      
      This was discovered and the fix has been tested by a very demanding
      customer who tests the heck of out the software we deliver.
      Signed-off-by: default avatarCorey Minyard <minyard@acm.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      dd26caf1
    • Prasanna Meda's avatar
      [PATCH] ext3_test_root() speedup · ef1ae53d
      Prasanna Meda authored
      Reorder test_root testing from 3,5,7 to 7,5,3 so that average case becomes
      good.  Even number check is added.  
      Signed-off-by: default avatarPrasanna Meda <pmeda@akamai.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      ef1ae53d
    • Matthew Wilcox's avatar
      [PATCH] ext3: free block accounting fix · bb596f36
      Matthew Wilcox authored
      If we chose to "do_more", we would double-count the amount freed in the
      second and subsequent block groups.  Fix it the same way as was done in
      ext2 a couple of years ago.
      Signed-off-by: default avatarMatthew Wilcox <matthew@wil.cx>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      bb596f36