1. 31 Aug, 2003 40 commits
    • Andrew Morton's avatar
      [PATCH] HPET 3/6: makefile and config changes · 669692e4
      Andrew Morton authored
      From: "Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
      
      Miscallaneous makefile and config changes
      669692e4
    • Andrew Morton's avatar
      [PATCH] HPET 1/6: Support for HPET based timer · 3c732c3b
      Andrew Morton authored
      From: "Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
      
      High Precision Event Timer (HPET) is next generation timer
      hardware and has various advantages over legacy 8254
      (PIT) timer, like:
      - Associated registers are mapped to memory space. So, we no
        longer require in and out on legacy ioports
      - Memory map address is reported by ACPI (and are not
        hard-coded)
      - Each timer can be configured to generate separate interrupts,
        even sharing lines with PCI devices
      - HPET has a minimum period of 100 nanosecs and is not fixed.
        Giving a flexibility of increasing the resolution in future.
      - Most current implementations has 3 counters, but in future,
        we can have as many as 32 timers per block, and 8
        HPET timer blocks (total 256 timers)
      - Can support 32bit and 64bit counting
      
      (Refer to http://www.intel.com/labs/platcomp/hpet/hpetspec.htm
       for complete specs)
      
      The patchset that follow adds support for High Precision Event
      Timer (HPET) based timer in kernel. This uses the HPET in
      LegacyReplacement mode (so that counter 0 will be tied to IRQ0,
      and counter 1 will be tied to IRQ 8). In this mode, HPET overrides
      PIT and RTC interrupt lines. The patch will enable HPET by default,
      on systems where ACPI tables reports this feature. The patch will
      have no impact on systems that do not support this feature.
      
      
      
      
      A major change from previous version is elimination of fixmap for HPET. 
      Based on Andrew Morton's suggestion, we have a new hook in init/main.c for
      late_time_init(), at which time we can use ioremap, in place of fixmap. 
      Impact on other archs: Calibrate_delay() (and hence loops_per_jiffy
      calculation) has moved down in main.c, from after time_init() to after
      kmem_cache_init().
      
      1/6 - hpet1.patch - main.c change to introduce late_time_init()
      3c732c3b
    • Andrew Morton's avatar
      [PATCH] Remove SSE2 bugs.h check · b94a6563
      Andrew Morton authored
      From: Andi Kleen <ak@muc.de>
      
      Remove some dead code.
      
      CONFIG_SSE2 hasn't been defined for some time, because everything
      SSE related is handled at runtime based on cpuid.
      b94a6563
    • Andrew Morton's avatar
      [PATCH] vmscan: zone pressure simplification and fix · d867ca5c
      Andrew Morton authored
      The zone->pressure field is supposed to record the amount of reclaim pressure
      which this zone is under.  We need this info so we know whether to unmap
      pages from pagetables right from the outset of a balance_pgdat() or
      try_to_free_pages() invokation.
      
      The problem with the current code is that the exponential average gets tugged
      around too much: as we perform the increasing-priority scan, the pressure
      metric is made artificially low by the early part of the scan.
      
      So instead what we do here is to record within the zone the scanning priority
      from the zone's previous scan.  It is defined as the priority at which the
      zone achieved the "enough pages free" state.  This prev_priority is used on
      the next scan for the do-we-need-to-be-unmapping-pages decision.
      d867ca5c
    • Andrew Morton's avatar
      [PATCH] vmscan: zone pressure calculation fix · b25bb608
      Andrew Morton authored
      Off-by-one in balance_pgdat(): `priority' can never go negative.  It causes
      the scanning priority thresholds to be quite wrong and kswapd tends to go
      berzerk when there is a lot of mapped memory around.
      b25bb608
    • Andrew Morton's avatar
      [PATCH] ipc_init() uses vmalloc too early · 322bb616
      Andrew Morton authored
      From: Andrea Arcangeli <andrea@suse.de>
      
      aka: "vmalloc allocations in ipc needs smp initialized (and vm must be
      allowed to schedule in 2.6)"
      
      In short if you change SEMMNI to 8192 the kernel will crash at boot, beause
      it tries to call vmalloc before the smp is initialized.  The reason is that
      vmalloc calls into the pte alloc code, and the fast pte alloc is tried
      first, but that reads into the pte_quicklist, that requires the cpu_data to
      be initialized (and that happens in smp_init()).
      
      the patch is obviously safe, since no piece of kernel (especially the code
      in the check_bugs and smp_init paths ;) calls into the ipc subsystem.
      
      The reason this started to trigger wasn't really that we increased SEMMNI,
      but what happend is that some IPC data structure grown, and for some reason
      the corruption due the uninitalized pte_quicklist triggers only for smp
      boxes with less than 1G (not very common anymore ;).  So it wasn't
      immediatly reproducible on all setups.
      
      2.6 doesn't suffer from the same problem, simply because 2.6 isn't using
      the quicklist anymore, but I think it would be much more correct to make
      the same change in 2.6 too, since whatever cond_resched() in the vm paths
      (and they're definitely allowed to call it), will lead to a crash since the
      init task isn't initialized and the scheduler can't be invoked yet.  (and
      2.6 already has the bigger data structures that should trigger the vmalloc
      all the time on all setups)
      322bb616
    • Andrew Morton's avatar
      [PATCH] raw driver oops fix · ab05d4ab
      Andrew Morton authored
      From: Dave Olien <dmo@osdl.org>
      
      The raw.c character device Oopses dereferencing a NULL pointer in
      bd_claim() This problem occurred after bd_claim() in block_dev.c was
      modified to "claim the whole device when a partition is claimed".
      
      raw_open() made the mistake of calling bd_claim BEFORE calling blkdev_get().
      At that time, the bdev->bd_contains field has not yet been initialized. 
      Switching the order allows blkdev_get() to initialize those fields before
      calling bd_claim().
      
      Also fixed up some error return paths:
      
      igrab() should never fail under these circumstances since the caller
      already has a reference to that inode through the bdev at that time.
      
      In the event of blkdev_get() failure or set_blocksize() failure, not all
      the work to unwind from the error was done.
      ab05d4ab
    • Andrew Morton's avatar
      [PATCH] compat ioctl_table fix · 1022068b
      Andrew Morton authored
      The arch ioctl tables are doing this:
      
      	struct foo ioctl_start[] = {
      		...
      	};
      	struct foo ioctl_end[0];
      
      and fs/compat.c expects that the table lies between &ioctl_end and
      &ioctl_start.
      
      Problem is, gcc-3.3 puts ioctl_end into bss, even if it is initialised.  It
      doesn't work.
      
      So we do away with the ioctl_end thing and add
      
      	int ioctl_table_length = ARRAY_SIZE(ioctl_start);
      
      to each architecture.
      1022068b
    • Andrew Morton's avatar
      [PATCH] mtrr cleanups · 8604173d
      Andrew Morton authored
      - Remove duplicated implementation of attrib_to_str()
      
      - Make mtrr_strings[] static to if.c
      8604173d
    • Andrew Morton's avatar
      [PATCH] make voyager work again after the cpumask_t changes · 00bd8e91
      Andrew Morton authored
      From: James Bottomley <James.Bottomley@SteelEye.com>
      
      Most is just simple fixes; however, the needless change from atomic to
      non-atomic operations in smp_invalidate_interrupt() caused me a lot of
      pain to track down since it introduced some very subtle bugs.
      
      I've also taken phys_cpu_present_map out of smp.h.  Since it
      physid_mask_t is defined in mpspec.h anyway, and contains a duplicate
      definition, I don't believe it can hurt anything.
      00bd8e91
    • Andrew Morton's avatar
      [PATCH] Fix a few declarations · 1097ca0a
      Andrew Morton authored
      extern decls in .c files are evil.  Put the send_sigio(), fcntl_setlease()
      and fcntl_getlease() into fs.h.
      1097ca0a
    • Andrew Morton's avatar
      [PATCH] Use tgid rather than pid in dnotify · 02488b12
      Andrew Morton authored
      From: Ulrich Drepper <drepper@redhat.com>
      
      I'm not entirely sure about this change.  But it seems to be necessary. 
      The dnotify code stores the PID in the file structure.  The entire process
      shares the file and any signal (is it used for that?) should be sent to the
      process (thread group), not the individual thread.  Also keep in mind that
      threads can go away while the process (and therefore file descriptor)
      remain.  And the ID of the thread can be reused.
      
      Somebody who knows this code should take a good look.
      
      (Looks right to me...)
      02488b12
    • Andrew Morton's avatar
      [PATCH] floppy driver cleanup · a19a4921
      Andrew Morton authored
      From: "Randy.Dunlap" <rddunlap@osdl.org>
      
      - use kernel.h min() and max();
      
      - C99 initializers;
      
      - Tidy up the scheule_work() callbacks (none of them take an arg)
      a19a4921
    • Andrew Morton's avatar
      [PATCH] fix arcnet printk parameter types · 77aae21d
      Andrew Morton authored
      From: "Randy.Dunlap" <rddunlap@osdl.org>
      
      fix arcnet printk parameter types
      77aae21d
    • Andrew Morton's avatar
      [PATCH] kbuild: warn if the user has old modutils · 9fff2998
      Andrew Morton authored
      From: Valdis.Kletnieks@vt.edu, Sam Ravnborg <sam@ravnborg.org>
      
      Adds an explicit check for the new modutils in the build system.
      
      Generally we should avoid these sorts of hardwired checks for the right
      versions of things, but we are still getting a significant number of problem
      reports due to people not having the new tools.  Let's help them out.
      9fff2998
    • Andrew Morton's avatar
      [PATCH] Cyclades ISA serial driver fix · 0040b222
      Andrew Morton authored
      From: "John Stoffel" <stoffel@lucent.com>
      
      Quick patch to get my 8 port Cyclades Cyclom-Y ISA card to work.
      
      (It doesn't look to be very SMP-robust, but then the 2.4 dirver probably
      isn't either).
      0040b222
    • Andrew Morton's avatar
      [PATCH] hch has moved · 6a94c0e5
      Andrew Morton authored
      From: Christoph Hellwig <hch@lst.de>
      
      I moved a while ago and I'm also not at SGI anymore.
      6a94c0e5
    • Andrew Morton's avatar
      [PATCH] AS: don't anticipate against a task's initial I/O · 66958511
      Andrew Morton authored
      From: Nick Piggin <piggin@cyberone.com.au>
      
      In the anticipatory scheduler, don't anticipate against the very first IO
      request which a process issues.
      
      This solves a very specific problem wherein a process starts, submits a
      single IO then exits.
      66958511
    • Andrew Morton's avatar
      [PATCH] evdev_ioctl does not report EV_MSC capabilities · b6117830
      Andrew Morton authored
      From: Dmitry Torokhov <dtor_core@ameritech.net>
      
      While working on my GPM patches found out that EV_MSC was forgotten...
      b6117830
    • Andrew Morton's avatar
      [PATCH] large dev_t 12/12 oops fix · 2181ea2e
      Andrew Morton authored
      From: viro@parcelfarce.linux.theplanet.co.uk
      
      On Wed, Aug 27, 2003 at 01:46:37AM -0700, Andrew Morton wrote:
      >
      > LILO seems to be oopsing in HDIO_GETGEO ioctl for some reason, in
      > generic_ide_ioctl().
      >
      > I'm not sure quite why though.  Could one of your patches affected this
      > area?
      
      The last one (fix for hd_struct handling).  The fix follows:
      2181ea2e
    • Andrew Morton's avatar
      [PATCH] remove size_t-based printk warnings · 605102e5
      Andrew Morton authored
      From: "Randy.Dunlap" <rddunlap@osdl.org>
      
      This patch removes warnings on non-matching parameter types to printk
      and incorrect function types (n_hdlc).
      605102e5
    • Andrew Morton's avatar
      [PATCH] add context switch counters · a776ac8d
      Andrew Morton authored
      From: Peter Chubb <peterc@gelato.unsw.edu.au>
      
      Currently, the context switch counters reported by getrusage() are
      always zero.  The appended patch adds fields to struct task_struct to
      count context switches, and adds code to do the counting.
      
      The patch adds 4 longs to struct task struct, and a single addition to
      the fast path in schedule().
      a776ac8d
    • Andrew Morton's avatar
      [PATCH] acpi pci_link fix · 88907397
      Andrew Morton authored
      From: Christophe Saout <christophe@saout.de>
      
      - acpi_pci_link_get_irq() returns 0 on error, not -ENODEV.
      
      - Fix mpparse.c tpyo.
      88907397
    • Andrew Morton's avatar
      [PATCH] jbd: remove uninformative printk · 5e8ab613
      Andrew Morton authored
      This printk doesn't impart any information.
      5e8ab613
    • Andrew Morton's avatar
      [PATCH] do_no_page() rss accounting fix · e0f0d9ef
      Andrew Morton authored
      From: Jaroslav Kysela <perex@suse.cz>
      
      The do_no_page() function in mm/memory.c does accounting for reserved pages
      (++mm->rss), but in zap_pte_range() we don't decrement rss if the page was
      reserved.
      
      So don't account for PageReserved pages in the rss.  (Maybe it would be
      better to fix zap_pte_range in the opposite direction..)
      e0f0d9ef
    • Andrew Morton's avatar
      [PATCH] Fix bluetooth compile warnings · 23d77265
      Andrew Morton authored
      23d77265
    • Andrew Morton's avatar
      [PATCH] knfsd nfs4 warning fixes · 371781cb
      Andrew Morton authored
      371781cb
    • Andrew Morton's avatar
      [PATCH] kill CONFIG_KCORE_AOUT · e23a1220
      Andrew Morton authored
      From: Adrian Bunk <bunk@fs.tum.de>
      
      Remove CONFIG_KCORE_AOUT: the ability to present /proc/kcore in a.out
      format.
      
      I've checked with various arch maintainers.  It won't be missed.
      e23a1220
    • Andrew Morton's avatar
      [PATCH] Fix build with CONFIG_KCORE_AOUT · 09952a58
      Andrew Morton authored
      We get a linkage error with CONFIG_KCORE_AOUT because there is no
      implementation of kclist_add() and kclist_del().
      
      Also fix a warning in the a.out version of read_kcore().
      
      Maybe we should just remove kcore a.out support.  m68knommu and h8300 are
      setting CONFIG_KCORE_AOUT in their defconfigs though.
      09952a58
    • Andrew Morton's avatar
      [PATCH] Add more bad_inode operations · 22cfa91b
      Andrew Morton authored
      From: <ffrederick@prov-liege.be>
      
      Flesh out the bad_inode file and inode operations tables with new
      additions.
      22cfa91b
    • Andrew Morton's avatar
      [PATCH] Fix typo in #ifdef for ext2 xattr support · b2d627ee
      Andrew Morton authored
      From: Stephen Smalley <sds@epoch.ncsc.mil>
      
      This patch corrects a typo in an ifdef that enables xattr operations for
      special files in the ext2 code; otherwise, extended attributes cannot be
      obtained or set on such inodes.
      b2d627ee
    • Andrew Morton's avatar
      [PATCH] Rework SELinux binprm hooks · 081bb1e6
      Andrew Morton authored
      From: Stephen Smalley <sds@epoch.ncsc.mil>
      
      This patch reworks the SELinux binprm hook functions to use a security
      structure for the linux_binprm rather than directly stuffing the security
      identifier into the void* security field.  It also performs some cleanup of
      the SELinux binprm hook functions, and one miscellaneous fix.
      081bb1e6
    • Andrew Morton's avatar
      [PATCH] Fix SELinux format specifiers · 2a1c7412
      Andrew Morton authored
      From: Stephen Smalley <sds@epoch.ncsc.mil>, James Morris <jmorris@redhat.com>
      
      This patch corrects several format specifiers in the SELinux security server
      code.
      2a1c7412
    • Andrew Morton's avatar
      [PATCH] Fix SELinux avtab · 696bce21
      Andrew Morton authored
      From: Stephen Smalley <sds@epoch.ncsc.mil>, Arnd Bergmann <arnd@arndb.de>
      
      This patch changes the SELinux avtab to use vmalloc/vfree; the table is too
      large for kmalloc on s390.
      696bce21
    • Andrew Morton's avatar
      [PATCH] Fix selinux_file_fcntl · 4218788b
      Andrew Morton authored
      From: Stephen Smalley <sds@epoch.ncsc.mil>, James Morris <jmorris@redhat.com>
      
      This patch adds the appropriate #if around the F_*64 commands in the
      selinux_file_fcntl hook function.
      4218788b
    • Andrew Morton's avatar
      [PATCH] Fix ext3 htree corruption on big-endian platforms · e2d964e6
      Andrew Morton authored
      From: Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
      
      current bk 2.6.0 corrupts my ext3 filesystems, usually in the RESYNC dir
      during a bk pull.  Checking the recent changes I noticed that the one in
      fs/ext3/namei.c misses an endian conversion.  The attached patch fixes that
      and works fine for me since 2 days now on PPC.
      e2d964e6
    • Andrew Morton's avatar
      [PATCH] visws: fix 2.6.0-test4 breakage · b6029830
      Andrew Morton authored
      From: Andrey Panin <pazke@donpac.ru>
      
      attached trivial patch fixes visws subarch kernel build.  It was broken by
      2.6.0-test4 cpumask_t changes.
      b6029830
    • Andrew Morton's avatar
      [PATCH] reiserfs writepage-versus-truncate fix · c33e05c5
      Andrew Morton authored
      From: Oleg Drokin <green@namesys.com>
      
      The conversion of reiserfs to not return errors from
      writepage-outside-i_size was incorrect.  Fix.
      c33e05c5
    • Andrew Morton's avatar
      [PATCH] parport_pc rmmod oops fix · bc6e6ea4
      Andrew Morton authored
      The `user_specified' variable is used in cleanup_module() and hence cannot be
      dropped from memory after module initialisation.
      bc6e6ea4
    • Andrew Morton's avatar
      [PATCH] do_no_page() fix · cfbb8488
      Andrew Morton authored
      From: David Mosberger <davidm@napali.hpl.hp.com>,
      	"Sharma, Arun" <arun.sharma@intel.com>
      
      The truncate race fix assumed that a non-zero vma->vm_ops->nopage implies a
      non-zero vma->vm_file.
      
      The ia64 x86 emulation code breaks this assumption, so teach do_no_page() to
      handle it.
      cfbb8488