27 Apr, 2007

1 commit


26 Apr, 2007

1 commit


13 Apr, 2007

1 commit


15 Feb, 2007

1 commit

  • After Al Viro (finally) succeeded in removing the sched.h #include in module.h
    recently, it makes sense again to remove other superfluous sched.h includes.
    There are quite a lot of files which include it but don't actually need
    anything defined in there. Presumably these includes were once needed for
    macros that used to live in sched.h, but moved to other header files in the
    course of cleaning it up.

    To ease the pain, this time I did not fiddle with any header files and only
    removed #includes from .c-files, which tend to cause less trouble.

    Compile tested against 2.6.20-rc2 and 2.6.20-rc2-mm2 (with offsets) on alpha,
    arm, i386, ia64, mips, powerpc, and x86_64 with allnoconfig, defconfig,
    allmodconfig, and allyesconfig as well as a few randconfigs on x86_64 and all
    configs in arch/arm/configs on arm. I also checked that no new warnings were
    introduced by the patch (actually, some warnings are removed that were emitted
    by unnecessarily included header files).

    Signed-off-by: Tim Schmielau
    Acked-by: Russell King
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Tim Schmielau
     

09 Dec, 2006

1 commit

  • This is the grungy swap all the occurrences in the right places patch that
    goes with the updates. At this point we have the same functionality as
    before (except that sgttyb() returns speeds not zero) and are ready to
    begin turning new stuff on providing nobody reports lots of bugs

    If you are a tty driver author converting an out of tree driver the only
    impact should be termios->ktermios name changes for the speed/property
    setting functions from your upper layers.

    If you are implementing your own TCGETS function before then your driver
    was broken already and its about to get a whole lot more painful for you so
    please fix it 8)

    Also fill in c_ispeed/ospeed on init for most devices, although the current
    code will do this for you anyway but I'd like eventually to lose that extra
    paranoia

    [akpm@osdl.org: bluetooth fix]
    [mp3@de.ibm.com: sclp fix]
    [mp3@de.ibm.com: warning fix for tty3270]
    [hugh@veritas.com: fix tty_ioctl powerpc build]
    [jdike@addtoit.com: uml: fix ->set_termios declaration]
    Signed-off-by: Alan Cox
    Signed-off-by: Martin Peschke
    Acked-by: Peter Oberparleiter
    Cc: Cornelia Huck
    Signed-off-by: Hugh Dickins
    Signed-off-by: Jeff Dike
    Cc: Paolo 'Blaisorblade' Giarrusso
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     

22 Nov, 2006

1 commit


05 Oct, 2006

1 commit

  • Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
    of passing regs around manually through all ~1800 interrupt handlers in the
    Linux kernel.

    The regs pointer is used in few places, but it potentially costs both stack
    space and code to pass it around. On the FRV arch, removing the regs parameter
    from all the genirq function results in a 20% speed up of the IRQ exit path
    (ie: from leaving timer_interrupt() to leaving do_IRQ()).

    Where appropriate, an arch may override the generic storage facility and do
    something different with the variable. On FRV, for instance, the address is
    maintained in GR28 at all times inside the kernel as part of general exception
    handling.

    Having looked over the code, it appears that the parameter may be handed down
    through up to twenty or so layers of functions. Consider a USB character
    device attached to a USB hub, attached to a USB controller that posts its
    interrupts through a cascaded auxiliary interrupt controller. A character
    device driver may want to pass regs to the sysrq handler through the input
    layer which adds another few layers of parameter passing.

    I've build this code with allyesconfig for x86_64 and i386. I've runtested the
    main part of the code on FRV and i386, though I can't test most of the drivers.
    I've also done partial conversion for powerpc and MIPS - these at least compile
    with minimal configurations.

    This will affect all archs. Mostly the changes should be relatively easy.
    Take do_IRQ(), store the regs pointer at the beginning, saving the old one:

    struct pt_regs *old_regs = set_irq_regs(regs);

    And put the old one back at the end:

    set_irq_regs(old_regs);

    Don't pass regs through to generic_handle_irq() or __do_IRQ().

    In timer_interrupt(), this sort of change will be necessary:

    - update_process_times(user_mode(regs));
    - profile_tick(CPU_PROFILING, regs);
    + update_process_times(user_mode(get_irq_regs()));
    + profile_tick(CPU_PROFILING);

    I'd like to move update_process_times()'s use of get_irq_regs() into itself,
    except that i386, alone of the archs, uses something other than user_mode().

    Some notes on the interrupt handling in the drivers:

    (*) input_dev() is now gone entirely. The regs pointer is no longer stored in
    the input_dev struct.

    (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
    something different depending on whether it's been supplied with a regs
    pointer or not.

    (*) Various IRQ handler function pointers have been moved to type
    irq_handler_t.

    Signed-Off-By: David Howells
    (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)

    David Howells
     

02 Oct, 2006

1 commit

  • As part of an SMP cleanliness pass over UML, I consted a bunch of
    structures in order to not have to document their locking. One of these
    structures was a struct tty_operations. In order to const it in UML
    without introducing compiler complaints, the declaration of
    tty_set_operations needs to be changed, and then all of its callers need to
    be fixed.

    This patch declares all struct tty_operations in the tree as const. In all
    cases, they are static and used only as input to tty_set_operations. As an
    extra check, I ran an i386 allyesconfig build which produced no extra
    warnings.

    53 drivers are affected. I checked the history of a bunch of them, and in
    most cases, there have been only a handful of maintenance changes in the
    last six months. serial_core.c was the busiest one that I looked at.

    Signed-off-by: Jeff Dike
    Acked-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Dike
     

08 Aug, 2006

1 commit


06 Aug, 2006

2 commits

  • A set of tty line discipline cleanup patches were introduced before the
    dawn of time, in kernel version 2.4.21. This patch performs that cleanup
    for the hvsi driver.

    The hvsi driver is used only on IBM pSeries PowerPC boxes. The driver was
    originally written by Hollis Blanchard, who has delegated maintainership to
    me. So this my first and maybe only patch in this official new role,
    because this driver is otherwise bug-free :-)

    Alan: "Actually its also a bug fix, tty->ldisc should be locked by refcounting
    and the helpers do this for you."

    Signed-off-by: Linas Vepstas
    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Acked-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Linas Vepstas
     
  • Under certain rare circumstances, it appears that there can be be a
    NULL-pointer deref when a user fiddles with terminal emeulation programs while
    outpu is being sent to the console. This patch checks for and avoids a
    NULL-pointer deref.

    Signed-off-by: Hollis Blanchard
    Signed-off-by: Linas Vepstas
    Cc: Paul Fulghum
    Acked-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Linas Vepstas
     

01 Aug, 2006

1 commit


31 Jul, 2006

1 commit


11 Jul, 2006

1 commit

  • This patch slightly reworks the new irq code to fix a small design error. I
    removed the passing of the trigger to the map() calls entirely, it was not a
    good idea to have one call do two different things. It also fixes a couple of
    corner cases.

    Mapping a linux virtual irq to a physical irq now does only that. Setting the
    trigger is a different action which has a different call.

    The main changes are:

    - I no longer call host->ops->map() for an already mapped irq, I just return
    the virtual number that was already mapped. It was called before to give an
    opportunity to change the trigger, but that was causing issues as that could
    happen while the interrupt was in use by a device, and because of the
    trigger change, map would potentially muck around with things in a racy way.
    That was causing much burden on a given's controller implementation of
    map() to get it right. This is much simpler now. map() is only called on
    the initial mapping of an irq, meaning that you know that this irq is _not_
    being used. You can initialize the hardware if you want (though you don't
    have to).

    - Controllers that can handle different type of triggers (level/edge/etc...)
    now implement the standard irq_chip->set_type() call as defined by the
    generic code. That means that you can use the standard set_irq_type() to
    configure an irq line manually if you wish or (though I don't like that
    interface), pass explicit trigger flags to request_irq() as defined by the
    generic kernel interfaces. Also, using those interfaces guarantees that
    your controller set_type callback is called with the descriptor lock held,
    thus providing locking against activity on the same interrupt (including
    mask/unmask/etc...) automatically. A result is that, for example, MPIC's
    own map() implementation calls irq_set_type(NONE) to configure the hardware
    to the default triggers.

    - To allow the above, the irq_map array entry for the new mapped interrupt
    is now set before map() callback is called for the controller.

    - The irq_create_of_mapping() (also used by irq_of_parse_and_map()) function
    for mapping interrupts from the device-tree now also call the separate
    set_irq_type(), and only does so if there is a change in the trigger type.

    - While I was at it, I changed pci_read_irq_line() (which is the helper I
    would expect most archs to use in their pcibios_fixup() to get the PCI
    interrupt routing from the device tree) to also handle a fallback when the
    DT mapping fails consisting of reading the PCI_INTERRUPT_PIN to know wether
    the device has an interrupt at all, and the the PCI_INTERRUPT_LINE to get an
    interrupt number from the device. That number is then mapped using the
    default controller, and the trigger is set to level low. That default
    behaviour works for several platforms that don't have a proper interrupt
    tree like Pegasos. If it doesn't work for your platform, then either
    provide a proper interrupt tree from the firmware so that fallback isn't
    needed, or don't call pci_read_irq_line()

    - Add back a bit that got dropped by my main rework patch for properly
    clearing pending IPIs on pSeries when using a kexec

    Signed-off-by: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Benjamin Herrenschmidt
     

03 Jul, 2006

2 commits

  • This adds the new irq remapper core and removes the old one. Because
    there are some fundamental conflicts with the old code, like the value
    of NO_IRQ which I'm now setting to 0 (as per discussions with Linus),
    etc..., this commit also changes the relevant platform and driver code
    over to use the new remapper (so as not to cause difficulties later
    in bisecting).

    This patch removes the old pre-parsing of the open firmware interrupt
    tree along with all the bogus assumptions it made to try to renumber
    interrupts according to the platform. This is all to be handled by the
    new code now.

    For the pSeries XICS interrupt controller, a single remapper host is
    created for the whole machine regardless of how many interrupt
    presentation and source controllers are found, and it's set to match
    any device node that isn't a 8259. That works fine on pSeries and
    avoids having to deal with some of the complexities of split source
    controllers vs. presentation controllers in the pSeries device trees.

    The powerpc i8259 PIC driver now always requests the legacy interrupt
    range. It also has the feature of being able to match any device node
    (including NULL) if passed no device node as an input. That will help
    porting over platforms with broken device-trees like Pegasos who don't
    have a proper interrupt tree.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • Signed-off-by: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: "David S. Miller"
    Cc: Benjamin Herrenschmidt
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Thomas Gleixner
     

27 Jun, 2006

1 commit


22 Apr, 2006

1 commit


11 Jan, 2006

1 commit


08 Jul, 2005

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds