02 Nov, 2017

1 commit

  • Many source files in the tree are missing licensing information, which
    makes it harder for compliance tools to determine the correct license.

    By default all files without license information are under the default
    license of the kernel, which is GPL version 2.

    Update the files which contain no license information with the 'GPL-2.0'
    SPDX license identifier. The SPDX identifier is a legally binding
    shorthand, which can be used instead of the full boiler plate text.

    This patch is based on work done by Thomas Gleixner and Kate Stewart and
    Philippe Ombredanne.

    How this work was done:

    Patches were generated and checked against linux-4.14-rc6 for a subset of
    the use cases:
    - file had no licensing information it it.
    - file was a */uapi/* one with no licensing information in it,
    - file was a */uapi/* one with existing licensing information,

    Further patches will be generated in subsequent months to fix up cases
    where non-standard license headers were used, and references to license
    had to be inferred by heuristics based on keywords.

    The analysis to determine which SPDX License Identifier to be applied to
    a file was done in a spreadsheet of side by side results from of the
    output of two independent scanners (ScanCode & Windriver) producing SPDX
    tag:value files created by Philippe Ombredanne. Philippe prepared the
    base worksheet, and did an initial spot review of a few 1000 files.

    The 4.13 kernel was the starting point of the analysis with 60,537 files
    assessed. Kate Stewart did a file by file comparison of the scanner
    results in the spreadsheet to determine which SPDX license identifier(s)
    to be applied to the file. She confirmed any determination that was not
    immediately clear with lawyers working with the Linux Foundation.

    Criteria used to select files for SPDX license identifier tagging was:
    - Files considered eligible had to be source code files.
    - Make and config files were included as candidates if they contained >5
    lines of source
    - File already had some variant of a license header in it (even if
    Reviewed-by: Philippe Ombredanne
    Reviewed-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

23 Jun, 2017

1 commit

  • In order to handle managed interrupts gracefully on irq_startup() so they
    won't lose their assigned affinity, it's necessary to allow startups which
    keep the interrupts in managed shutdown state, if none of the assigend CPUs
    is online. This allows drivers to request interrupts w/o the CPUs being
    online, which avoid online/offline churn in drivers.

    Add a force argument which can override that decision and let only
    request_irq() and enable_irq() allow the managed shutdown
    handling. enable_irq() is required, because the interrupt might be
    requested with IRQF_NOAUTOEN and enable_irq() invokes irq_startup() which
    would then wreckage the assignment again. All other callers force startup
    and potentially break the assigned affinity.

    No functional change as this only adds the function argument.

    Signed-off-by: Thomas Gleixner
    Cc: Jens Axboe
    Cc: Marc Zyngier
    Cc: Michael Ellerman
    Cc: Keith Busch
    Cc: Peter Zijlstra
    Cc: Christoph Hellwig
    Link: http://lkml.kernel.org/r/20170619235447.112094565@linutronix.de

    Thomas Gleixner
     

15 Feb, 2012

1 commit

  • An interrupt might be pending when irq_startup() is called, but the
    startup code does not invoke the resend logic. In some cases this
    prevents the device from issuing another interrupt which renders the
    device non functional.

    Call the resend function in irq_startup() to keep things going.

    Reported-and-tested-by: Russell King
    Cc: stable@vger.kernel.org
    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     

29 Mar, 2011

1 commit


19 Feb, 2011

6 commits


04 Oct, 2010

4 commits


15 Dec, 2009

1 commit


08 Jan, 2009

1 commit

  • Right now, most of the kernel boot is strictly synchronous, such that
    various hardware delays are done sequentially.

    In order to make the kernel boot faster, this patch introduces
    infrastructure to allow doing some of the initialization steps
    asynchronously, which will hide significant portions of the hardware delays
    in practice.

    In order to not change device order and other similar observables, this
    patch does NOT do full parallel initialization.

    Rather, it operates more in the way an out of order CPU does; the work may
    be done out of order and asynchronous, but the observable effects
    (instruction retiring for the CPU) are still done in the original sequence.

    Signed-off-by: Arjan van de Ven

    Arjan van de Ven
     

26 Dec, 2008

1 commit


08 Dec, 2008

1 commit

  • Impact: new feature

    Problem on distro kernels: irq_desc[NR_IRQS] takes megabytes of RAM with
    NR_CPUS set to large values. The goal is to be able to scale up to much
    larger NR_IRQS value without impacting the (important) common case.

    To solve this, we generalize irq_desc[NR_IRQS] to an (optional) array of
    irq_desc pointers.

    When CONFIG_SPARSE_IRQ=y is used, we use kzalloc_node to get irq_desc,
    this also makes the IRQ descriptors NUMA-local (to the site that calls
    request_irq()).

    This gets rid of the irq_cfg[] static array on x86 as well: irq_cfg now
    uses desc->chip_data for x86 to store irq_cfg.

    Signed-off-by: Yinghai Lu
    Signed-off-by: Ingo Molnar

    Yinghai Lu
     

16 Oct, 2008

5 commits

  • probe_irq_off() is disfunctional as the local nr_irqs is referenced
    instead of the global one for the for_each_irq_desc() iterator.

    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • Use for_each_irq_desc[_reverse] for all the iteration loops.

    Signed-off-by: Thomas Gleixner

    Thomas Gleixner
     
  • fix:

    [ 10.631533] calling yenta_socket_init+0x0/0x20
    [ 10.631533] Yenta: CardBus bridge found at 0000:15:00.0 [17aa:2012]
    [ 10.631533] Yenta: Using INTVAL to route CSC interrupts to PCI
    [ 10.631533] Yenta: Routing CardBus interrupts to PCI
    [ 10.631533] Yenta TI: socket 0000:15:00.0, mfunc 0x01d01002, devctl 0x64
    [ 10.731599] BUG: unable to handle kernel NULL pointer dereference at 00000040
    [ 10.731838] IP: [] _spin_lock_irq+0xf/0x20
    [ 10.732221] *pde = 00000000
    [ 10.732741] Oops: 0002 [#1] SMP
    [ 10.733453]
    [ 10.734253] Pid: 1, comm: swapper Tainted: G W (2.6.27-rc3-tip-00173-gd7eaa4f-dirty #1)
    [ 10.735188] EIP: 0060:[] EFLAGS: 00010002 CPU: 0
    [ 10.735523] EIP is at _spin_lock_irq+0xf/0x20
    [ 10.735523] EAX: 00000040 EBX: 00000000 ECX: f6e04c90 EDX: 00000100
    [ 10.735523] ESI: 000000df EDI: f6e04c90 EBP: f7867df0 ESP: f7867df0
    [ 10.735523] DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 0068
    [ 10.735523] Process swapper (pid: 1, ti=f7867000 task=f7870000 task.ti=f7867000)
    [ 10.735523] Stack: f7867e04 c0155fbd 00000000 00000000 f6e04c90 f7867e5c c0c6e319 c0f6a074
    [ 10.735523] f6e04c90 000017aa 00002012 c112b648 f791f240 c112b5e0 f7867e44 c010440b
    [ 10.735523] f791f240 f791f29c c112b8ec f791f240 00000000 f7867e5c c048f893 03c0b648
    [ 10.735523] Call Trace:
    [ 10.735523] [] ? probe_irq_on+0x3d/0x140
    [ 10.735523] [] ? yenta_probe+0x529/0x640
    [ 10.735523] [] ? mcount_call+0x5/0xa
    [ 10.735523] [] ? pci_match_device+0xa3/0xb0
    [ 10.735523] [] ? pci_device_probe+0x5e/0x80
    [ 10.735523] [] ? driver_probe_device+0x83/0x180
    [ 10.735523] [] ? __driver_attach+0x74/0x80
    [ 10.735523] [] ? bus_for_each_dev+0x49/0x70
    [ 10.735523] [] ? driver_attach+0x1e/0x20
    [ 10.735523] [] ? __driver_attach+0x0/0x80
    [ 10.735523] [] ? bus_add_driver+0x1a3/0x220
    [ 10.735523] [] ? pci_device_remove+0x0/0x40
    [ 10.735523] [] ? driver_register+0x54/0x130
    [ 10.735523] [] ? __pci_register_driver+0x4f/0x90
    [ 10.735523] [] ? yenta_socket_init+0x19/0x20
    [ 10.735523] [] ? do_one_initcall+0x35/0x160
    [ 10.735523] [] ? yenta_socket_init+0x0/0x20
    [ 10.735523] [] ? __queue_work+0x36/0x50
    [ 10.735523] [] ? queue_work_on+0x3d/0x50
    [ 10.735523] [] ? kernel_init+0x148/0x210
    [ 10.735523] [] ? kernel_init+0x0/0x210
    [ 10.735523] [] ? kernel_thread_helper+0x7/0x10
    [ 10.735523] =======================
    [ 10.735523] Code: 10 38 f2 74 06 f3 90 8a 10 eb f6 5d 89 c8 c3 8d b6 00 00 00 00 8d bc 27 00 00 00 00 55 89 e5 e8 a4 e8 46 ff fa ba 00 01 00 00 90 0f c1 10 38 f2 74 06 f3 90 8a 10 eb f6 5d c3 90 55 89 e5 53

    as auto-probing wants to iterate over existing irqs.

    Signed-off-by: Ingo Molnar

    Ingo Molnar
     
  • add CONFIG_HAVE_SPARSE_IRQ to for use condensed array.
    Get rid of irq_desc[] array assumptions.

    Preallocate 32 irq_desc, and irq_desc() will try to get more.

    ( No change in functionality is expected anywhere, except the odd build
    failure where we missed a code site or where a crossing commit itroduces
    new irq_desc[] usage. )

    v2: according to Eric, change get_irq_desc() to irq_desc()

    Signed-off-by: Yinghai Lu
    Signed-off-by: Ingo Molnar

    Yinghai Lu
     
  • at this point nr_irqs is equal NR_IRQS

    convert a few easy users from NR_IRQS to dynamic nr_irqs.

    v2: according to Eric, we need to take care of arch without generic_hardirqs

    Signed-off-by: Yinghai Lu
    Signed-off-by: Ingo Molnar

    Yinghai Lu
     

30 Jun, 2006

7 commits

  • Handle bad IRQ vectors via the irqchip mechanism.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     
  • Core genirq support: add the irq-chip and irq-flow abstractions.

    Signed-off-by: Thomas Gleixner
    Signed-off-by: Ingo Molnar
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Thomas Gleixner
     
  • Introduce IRQ_NOPROBE: enables platforms to control chip-probing.

    Signed-off-by: Thomas Gleixner
    Signed-off-by: Ingo Molnar
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Thomas Gleixner
     
  • Cleanup: remove irq_desc_t use from the generic IRQ code, and mark it
    obsolete.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     
  • Assorted code cleanups to the generic IRQ code.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     
  • Convert the irq auto-probing semaphore to a mutex. (This allows us to find
    probing API usage bugs sooner, via the mutex debugging code.)

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     
  • This patch-queue improves the generic IRQ layer to be truly generic, by adding
    various abstractions and features to it, without impacting existing
    functionality.

    While the queue can be best described as "fix and improve everything in the
    generic IRQ layer that we could think of", and thus it consists of many
    smaller features and lots of cleanups, the one feature that stands out most is
    the new 'irq chip' abstraction.

    The irq-chip abstraction is about describing and coding and IRQ controller
    driver by mapping its raw hardware capabilities [and quirks, if needed] in a
    straightforward way, without having to think about "IRQ flow"
    (level/edge/etc.) type of details.

    This stands in contrast with the current 'irq-type' model of genirq
    architectures, which 'mixes' raw hardware capabilities with 'flow' details.
    The patchset supports both types of irq controller designs at once, and
    converts i386 and x86_64 to the new irq-chip design.

    As a bonus side-effect of the irq-chip approach, chained interrupt controllers
    (master/slave PIC constructs, etc.) are now supported by design as well.

    The end result of this patchset intends to be simpler architecture-level code
    and more consolidation between architectures.

    We reused many bits of code and many concepts from Russell King's ARM IRQ
    layer, the merging of which was one of the motivations for this patchset.

    This patch:

    rename desc->handler to desc->chip.

    Originally i did not want to do this, because it's a big patch. But having
    both "desc->handler", "desc->handle_irq" and "action->handler" caused a
    large degree of confusion and made the code appear alot less clean than it
    truly is.

    I have also attempted a dual approach as well by introducing a
    desc->chip alias - but that just wasnt robust enough and broke
    frequently.

    So lets get over with this quickly. The conversion was done automatically
    via scripts and converts all the code in the kernel.

    This renaming patch is the first one amongst the patches, so that the
    remaining patches can stay flexible and can be merged and split up
    without having some big monolithic patch act as a merge barrier.

    [akpm@osdl.org: build fix]
    [akpm@osdl.org: another build fix]
    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     

29 Jun, 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