1. 14 Jun, 2002 1 commit
  2. 12 Jun, 2002 1 commit
    • Ingo Molnar's avatar
      · 873cbfcf
      Ingo Molnar authored
      - i've extended the scheduler context-switch mechanism with the following
        per-arch defines:
      
              prepare_arch_schedule(prev_task);
              finish_arch_schedule(prev_task);
              prepare_arch_switch(rq);
              finish_arch_switch(rq);
      
      - plus switch_to() takes 3 parameters again:
      
              switch_to(prev, next, last);
      
      - schedule_tail() has the 'prev' task parameter again, it must be passed
        over in switch_to() and passed in to the fork() startup path.
      
      architectures that need to unlock the runqueue before doing the switch can
      do the following:
      
       #define prepare_arch_schedule(prev)             task_lock(prev)
       #define finish_arch_schedule(prev)              task_unlock(prev)
       #define prepare_arch_switch(rq)                 spin_unlock(&(rq)->lock)
       #define finish_arch_switch(rq)                  __sti()
      
      this way the task-lock makes sure that a task is not scheduled on some
      other CPU before the switch-out finishes, but the runqueue lock is
      dropped. (Local interrupts are kept disabled in this variant, just to
      exclude things like TLB flushes - if that matters.)
      
      architectures that can hold the runqueue lock during context-switch can do
      the following simplification:
      
       #define prepare_arch_schedule(prev)             do { } while(0)
       #define finish_arch_schedule(prev)              do { } while(0)
       #define prepare_arch_switch(rq)                 do { } while(0)
       #define finish_arch_switch(rq)                  spin_unlock_irq(&(rq)->lock)
      
      further optimizations possible in the 'simple' variant:
      
      - an architecture does not have to handle the 'last' parameter in
        switch_to() if the 'prev' parameter is unused in finish_arch_schedule().
        This way the inlined return value of context_switch() too gets optimized
        away at compile-time.
      
      - an architecture does not have to pass the 'prev' pointer to
        schedule_tail(), if the 'prev' parameter is unused in
        finish_arch_schedule().
      
      the x86 architecture makes use of these optimizations.
      
      Via this solution we have a reasonably flexible context-switch setup which
      falls back to the current (faster) code on x86, but on other platforms the
      runqueue lock can be dropped before doing the context-switch as well.
      
              Ingo
      
      NOTE: i have coded and tested the 'complex' variant on x86 as well to make
            sure it works for you on Sparc64 - but since x86's switch_mm() is
            not too subtle it can use the simpler variant. [ The following
            things had to be done to make x86 arch use the complex variant: the
            4 complex macros have to be used in system.h, entry.S has to
            'pushl %ebx' and 'addl $4, %esp' around the call to schedule_tail(),
            and switch_to() had to be reverted to the 3-parameter variant
            present in the 2.4 kernels.
      
      NOTE2: prepare_to_switch() functionality has been moved into the
             prepare_arch_switch() macro.
      
      NOTE3: please use macros for prepare|finish_arch_switch() so that we can
             keep the scheduler data structures internal to sched.c.
      873cbfcf
  3. 11 Jun, 2002 38 commits
    • Peter Chubb's avatar
      [PATCH] yenta_socket driver PCI irq routing fix · b533e812
      Peter Chubb authored
      	This patch  fixes the Compaq WL210 problems I've been having.
      
      The symptoms were that no interupts were ever received from the card;
      the BIOS reported it had assigned INTA to IRQ 10; but the yenta
      driver reported IRQ 17.
      
      The fix is not to rely on the BIOS's initialisation of interrupt
      routing in the TI1410, but to do it explicitly.
      
      This may break laptops that actually use the parallel ISA IRQ
      mechanism.
      b533e812
    • Linus Torvalds's avatar
      Fix various sound compiler warnings (and outright bugs · 66b8206b
      Linus Torvalds authored
      on non-x86 architectures)
      66b8206b
    • Linus Torvalds's avatar
      Add infrastructure to easily make _correct_ bitmap members · 6406b41a
      Linus Torvalds authored
      in structures and unions (and why not other variables too..)
      6406b41a
    • Linus Torvalds's avatar
      6ff5815e
    • Linus Torvalds's avatar
      53a22115
    • Linus Torvalds's avatar
      Automerge · 5c1f5beb
      Linus Torvalds authored
      5c1f5beb
    • Andi Kleen's avatar
      [PATCH] CONFIG_ISA for several driver dirs · 8f73c6a8
      Andi Kleen authored
      Many old ISA drivers are not 64bit clean. To avoid dealing with them on
      x86-64 I guarded them with CONFIG_ISA. This is also helpful for other
      archs (including modern x86) that do not have ISA slots anymore.
      The patch has been reviewed by Linux-Kernel, with some additional
      cleanups by me. It misses some directories like ISDN or sound drivers.
      8f73c6a8
    • Andi Kleen's avatar
      [PATCH] i386 stack frame security fix · bc404e79
      Andi Kleen authored
      This fixes a potential security issue on i386. FXRSTOR raises an #GP
      when the MXCSR field in the FXSAVE frame contains illegal values. By
      putting an signal frame just at a border to an unmapped page a malicious
      user could potentially cause an exception in the context switch using this.
      When the EFAULT occurs in the last bytes of the signal frame the MXCSR
      check would be skipped in the old code, but the rogue value would be already
      in task_struct, causing problems later.
      
      Here is the minimal fix for this.
      
      Originally discovered by Andrea while doing x86-64 work. It was fixed in
      a different way a bit more intrusive way on x86-64 - all FXRSTOR in the
      kernel are guarded by exception handlers.
      bc404e79
    • Andi Kleen's avatar
      [PATCH] i386 mptable cpu name decoding cleanup · 9edd824d
      Andi Kleen authored
      It's nearly impossible to get the correct CPU names for AMD CPUs in
      the MP table (would need BIOS calls etc.). The decoding of CPU names form
      the mptable doesn't look too useful anyways, because the correct CPU name
      from CPUID is printed only a few lines later. This patch just removes
      the name table and replaces it with a printout of the hex value.
      This mirrors a change in x86-64
      9edd824d
    • Andi Kleen's avatar
      [PATCH] network maintainer · 041aee51
      Andi Kleen authored
      Remove myself as networking maintainer. I haven't done much for networking
      for a long time and it doesn't look likely it'll change anytime soon.
      Also David/Alexey are doing a fine job without me.
      041aee51
    • Andi Kleen's avatar
      [PATCH] 2.5.21 x86-64 jumbo patch - arch specific changes · e4b9e2aa
      Andi Kleen authored
      Here is the big 2.5.21 x86-64 sync patch. It only touches arch/x86_64
      and include/asm-x86_64. It requires a few other changes that I'm sending
      in separate mail.
      
      Changes:
      - merge wit 2.5.21
      - merge from 2.5.21/i386 (new PCI code, new LDT code etc.)
      - sync with 2.4-x86_64 tree.
      - minor updates to 32bit emulation
      - better early console; including serial support.
      - now set up dummy PDA for booting to avoid problems
      - Fix GS reloading in context switch one instruction race
      - Remove hardcoded names from mpparse code
      - Fix inline assembly for RAID-5 xor (similar change needed for i386)
      - Real per cpu data support based on PDA field
      - Cleanup of offset.c generation requested by Kai: it only puts structure
        offsets into offset.h now.
      - Fix i387 fxsave signal frame problems.
      - Add uname emulation via personality ("linux32")
      - New SSE optimized checksum-copy, copy*user, memcpy, clear_page, copy_page
        functions. Other tunings/cleanups in checksum and other user memory
        access function.
      - check if exception table is really sorted
      - Cleanups in page table handling in preparation of non executable pages
        support.
      - Cleanup PDA access to not require offset.h (thanks to kai for kicking me
        to this)
      - use long long for u64/s64 to avoid more warnings
      - remove CONFIG_ISA
      - fix various bugs and other cleanups
      e4b9e2aa
    • Linus Torvalds's avatar
      cc9af0c5
    • Linus Torvalds's avatar
      Merge master.kernel.org:/home/mingo/BK/linux-2.5-sched · be9af746
      Linus Torvalds authored
      into home.transmeta.com:/home/torvalds/v2.5/linux
      be9af746
    • Ingo Molnar's avatar
      f85e6275
    • Ingo Molnar's avatar
      019afe86
    • Ingo Molnar's avatar
      - wait_task_inactive() preemption-latency optimization: we should · b5734da1
      Ingo Molnar authored
        enable/disable preemption to not spend too much time with
        preemption disabled. wait_task_inactive() can take quite some
        time occasionally ...
      b5734da1
    • Ingo Molnar's avatar
      - set_cpus_allowed() optimization from Mike Kravetz: we can · 16fea1db
      Ingo Molnar authored
        set p->thread_info->cpu directly if the task is not running
        and is not on any runqueue.
      16fea1db
    • Ingo Molnar's avatar
    • Linus Torvalds's avatar
      Merge master.kernel.org:/home/davem/BK/mm-2.5 · af0d5292
      Linus Torvalds authored
      into home.transmeta.com:/home/torvalds/v2.5/linux
      af0d5292
    • Linus Torvalds's avatar
      Merge master.kernel.org:/home/davem/BK/sparc-2.5 · 030dabd5
      Linus Torvalds authored
      into home.transmeta.com:/home/torvalds/v2.5/linux
      030dabd5
    • Brad Heilbrun's avatar
      [PATCH] Compile error, ALSA Cirrus Logic driver · c50dbc33
      Brad Heilbrun authored
      Recent header cleanup broke this driver. Needs #include <linux/init.h>
      c50dbc33
    • Andy Grover's avatar
      [PATCH] ACPI [3/3] · bbdd8222
      Andy Grover authored
      ACPI interpreter update
      Change non-interpreter code to account for the interpreter changes.
      bbdd8222
    • Andy Grover's avatar
      [PATCH] ACPI [2/3] · 044aff7a
      Andy Grover authored
      This update gets things compiling again after a device model change.
      044aff7a
    • Andy Grover's avatar
      [PATCH] ACPI [1/3] · e32aa901
      Andy Grover authored
      This adds preliminary support for _TRA resource on PCI root bridges (Bjorn
      Helgaas)
      e32aa901
    • Linus Torvalds's avatar
      Merge bk://linuxusb.bkbits.net/linus-2.5 · e0a22486
      Linus Torvalds authored
      into home.transmeta.com:/home/torvalds/v2.5/linux
      e0a22486
    • Linus Torvalds's avatar
    • Linus Torvalds's avatar
      Merge Al's bdevname cleanups · 5325aa3d
      Linus Torvalds authored
      5325aa3d
    • Alexander Viro's avatar
      [PATCH] (14/14) resync · 4fe6433a
      Alexander Viro authored
      end_request(int) turned to end_request(req, int); all old callers
      are converted to end_request(CURRENT, value).  Now we can start
      killing CURRENT/QUEUE - end_request() was the last obstacle to
      that.
      4fe6433a
    • Alexander Viro's avatar
      [PATCH] (13/14) resync · 718e92c5
      Alexander Viro authored
      ditto for DEVICE_INTR/CLEAR_INTR.  do_mfm/do_acsi/do_hd/... are
      explicitly declared in the drivers that use DEVICE_INTR stuff;
      DEVICE_INTR/CLEAR_INTR is gone from blk.h.
      718e92c5
    • Alexander Viro's avatar
      [PATCH] (12/14) resync · 9437b796
      Alexander Viro authored
      #define DEVICE_NAME ... removed from the drivers that never use
      that macro.
      9437b796
    • Alexander Viro's avatar
      [PATCH] (11/14) resync · 1b4199a5
      Alexander Viro authored
      monstrous cascade of #ifdefs is gone from blk.h.  This is the first
      step of cleanup - we move #define in question into the code that
      includes blk.h (i.e. DEVICE_NR, DEVICE_NAME and DEVICE_INTR are
      explicitly set by drivers).
      1b4199a5
    • Alexander Viro's avatar
      [PATCH] (10/14) resync · b7031fe5
      Alexander Viro authored
      ->s_dev is switched to dev_t.  Everything that uses it uses it as
      a number - i.e. all instances are either minor() or kdev_t_to_nr().
      b7031fe5
    • Alexander Viro's avatar
      [PATCH] (9/14) resync · aaa44e6b
      Alexander Viro authored
      ->j_dev is gone from reiserfs journal.  All its uses had been replaced
      with use of ->j_dev_bd; it's simply not used anymore.
      aaa44e6b
    • Alexander Viro's avatar
      [PATCH] (8/14) resync · b174bf96
      Alexander Viro authored
      get_super() split in two functions - get_super(bdev) and
      user_get_super(dev_t).  Callers that used get_super() to get superblock
      by (dev_t) syscall argument switched to the latter; the rest had
      block_device in question and switched to passing it.
      b174bf96
    • Alexander Viro's avatar
      [PATCH] (7/14) resync · 334c8b07
      Alexander Viro authored
      ROOT_DEV converted to dev_t.  There's no reason for it to be kdev_t -
      it's both used as a number and set as a number.
      334c8b07
    • Alexander Viro's avatar
      [PATCH] (6/14) resync · 92ca434d
      Alexander Viro authored
      do_getattr() renamed to vfs_getattr(), exported and used by
      loop.c and nfsd - both blindly accessed ->i_dev/->i_ino of
      random inodes when they ought to be calling ->getattr() to
      get that information.
      92ca434d
    • Alexander Viro's avatar
      [PATCH] (5/14) resync · 6343913a
      Alexander Viro authored
      misc gratitious kdev_t uses fixed (janitorial stuff - e.g. quota
      patches had reintroduced kdevname(sb->s_dev) in places where we'd
      switched to sb->s_id, etc.)
      6343913a
    • Alexander Viro's avatar
      [PATCH] (4/14) resync · b83c1ac7
      Alexander Viro authored
      added bdev_read_only() - analog of is_read_only() using block_device.
      Almost all callers of is_read_only() converted.
      b83c1ac7