1. 11 Nov, 2002 28 commits
  2. 10 Nov, 2002 12 commits
    • Linus Torvalds's avatar
      Linux v2.5.47 · 5be2bc3c
      Linus Torvalds authored
      5be2bc3c
    • Andrew Morton's avatar
      [PATCH] remove duplicated disk statistics · 36e573c7
      Andrew Morton authored
      This patch will break some userspace monitoring apps in the name of
      having sane disk statistics in 2.6.x.
      
      Patch from Rick Lindsley <ricklind@us.ibm.com>
      
      In 2.5.46, there are now disk statistics being collected twice: once
      for gendisk/hd_struct, and once for dkstat.  They are collecting the
      same thing.  This patch removes dkstat, which also had the disadvantage
      of being limited by DK_MAX_MAJOR and DK_MAX_DISK. (Those #defines are
      removed too.)
      
      In addition, this patch removes disk statistics from /proc/stat since
      they are now available via sysfs and there seems to have been a general
      preference in previous discussions to "clean up" /proc/stat.  Too many
      disks being reported in /proc/stat also caused buffer overflows when
      trying to print out the data.
      
      The code in led.c from the parisc architecture has not apparently been
      recompiled under recent versions of 2.5, since it references
      kstat.dk_drive which doesn't exist in later versions.  Accordingly,
      I've added an #ifdef 0 and a comment to that code so that it may at
      least compile, albeit without one feature -- a step up from its state
      now.  If it is preferable to keep the broken code in, that patch may
      easily be excised from below.
      36e573c7
    • Andrew Morton's avatar
      [PATCH] fix page alloc/free accounting · 3e4c5912
      Andrew Morton authored
      We're currently incrementing /proc/vmstat:pgalloc in front of the
      per-cpu page queues, and incrementing /proc/vmstat:pgfree behind the
      per-cpu queues.  So they get out of whack.
      
      Change it so that we increment the counters each time someone requests
      a page.  ie: they're both in front of the queues.
      
      Also, remove a duplicated prep_new_page() call and as a consequence,
      drop the whole additional list walk in rmqueue_bulk().
      3e4c5912
    • Andrew Morton's avatar
      [PATCH] buffer_head refcounting fixes and cleanup · d9c53386
      Andrew Morton authored
      There was some strange code in the __getblk()/__find_get_block()/
      __bread() area which was performimg multiple bh_lru_install() calls as
      well as multiple touch_buffer() calls.
      
      Fix all that up.  We only need to run bh_lru_install() and
      touch_buffer() in __find_get_block().  Because if the block wasn't
      found, __getblk() will create it and will re-run __find_get_block().
      
      Also document a few things and make a couple of internal symbols static
      to buffer.c
      
      Also, don't run __find_get_block() from within
      unmap_underlying_metadata().  We hardly expect to find that block
      inside the LRU.  And we hardly expect to use it as metadata in the near
      future so there's no point in letting it evict another buffer if we
      found it.  So just go straight into the pagecache lookup for
      unmap_underlying_metadata().
      d9c53386
    • Andrew Morton's avatar
      [PATCH] Fix math underflow in disk accounting · 79d8554f
      Andrew Morton authored
      Patch from Lev Makhlis <mlev@despammed.com>
      
      The disk accounting will overflow after 4,000,000 seconds.  Extend that
      by a factor of 1000.
      79d8554f
    • Andrew Morton's avatar
      [PATCH] hugetlb: make private functions static · becd026d
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch makes various private structures and procedures static.
      becd026d
    • Andrew Morton's avatar
      [PATCH] hugetlb: remove /proc/ intrusion · 919de8f5
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch removes hugetlb's intrusion into /proc/
      919de8f5
    • Andrew Morton's avatar
      [PATCH] hugetlb: remove sysctl.c intrusion · 20078cee
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch removes hugetlb's intrusion into kernel/sysctl.c
      20078cee
    • Andrew Morton's avatar
      [PATCH] hugetlb: internalize hugetlb init · db6005a2
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch internalizes hugetlb initialization, implementing a command-line
      option in the process.
      db6005a2
    • Andrew Morton's avatar
      [PATCH] hugetlb: remove unlink_vma() · 755643ba
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch removes the unused function unlink_vma().
      755643ba
    • Andrew Morton's avatar
      [PATCH] hugetlb: fix zap_hugetlb_resources() · 0371880f
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      This patch eliminates zap_hugetlb_resources, along with its usages.
      This actually fixes bugs, as zap_hugetlb_resources was itself buggy.
      0371880f
    • Andrew Morton's avatar
      [PATCH] SMP iowait stats · 3dd63b7d
      Andrew Morton authored
      Patch from William Lee Irwin III <wli@holomorphy.com>
      
      Idle time accounting is disturbed by the iowait statistics, for several
      reasons:
      
      (1) iowait time is not subdivided among cpus.
              The only way the distinction between idle time subtracted from
              cpus (in order to be accounted as iowait) can be made is by
              summing counters for a total and dividing the individual tick
              counters by the proportions. Any tick type resolution which is
              not properly per-cpu breaks this, meaning that cpus which are
              entirely idle, when any iowait is present on the system, will
              have all idle ticks accounted to iowait instead of true idle time.
      
      (2) kstat_read_proc() misreports iowait time
              The idle tick counter is passed twice to the sprintf(), once
              in the idle tick position, and once in the iowait tick position.
      
      (3) performance enhancement
              The O(1) scheduler was very carefully constructed to perform
              accesses only to localized cachelines whenever possible. The
              global counter violates one of its core design principles,
              and the localization of "most" accesses is in greater harmony
              with its overall design and provides (at the very least) a
              qualitative performance improvement wrt. cache.
      
      The method of correcting this is simple: embed an atomic iowait counter
      in the runqueues, find the runqueue being manipulated in io_schedule(),
      increment its atomic counter prior to schedule(), and decrement it
      after returning from schedule(), which is guaranteed to be the same one,
      as the counter incremented is tracked as a variable local to the procedure.
      Then simply sum to obtain a global iowait statistic.
      
      (Atomicity is required as the post-wait decrement may occur on a different
      cpu from the one owning the counter.)
      
      io_schedule() and io_schedule_timeout() are moved to sched.c as they must
      access the runqueues, which are private to sched.c, and nr_iowait() is
      created in order to export the sum of all runqueues' nr_iowait().
      3dd63b7d