cregit-Linux how code gets into the kernel

Release 4.18 arch/x86/kernel/irqinit.c

Directory: arch/x86/kernel
// SPDX-License-Identifier: GPL-2.0
#include <linux/linkage.h>
#include <linux/errno.h>
#include <linux/signal.h>
#include <linux/sched.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
#include <linux/timex.h>
#include <linux/random.h>
#include <linux/kprobes.h>
#include <linux/init.h>
#include <linux/kernel_stat.h>
#include <linux/device.h>
#include <linux/bitops.h>
#include <linux/acpi.h>
#include <linux/io.h>
#include <linux/delay.h>

#include <linux/atomic.h>
#include <asm/timer.h>
#include <asm/hw_irq.h>
#include <asm/pgtable.h>
#include <asm/desc.h>
#include <asm/apic.h>
#include <asm/setup.h>
#include <asm/i8259.h>
#include <asm/traps.h>
#include <asm/prom.h>

/*
 * ISA PIC or low IO-APIC triggered (INTA-cycle or APIC) interrupts:
 * (these are usually mapped to vectors 0x30-0x3f)
 */

/*
 * The IO-APIC gives us many more interrupt sources. Most of these
 * are unused but an SMP system is supposed to have enough memory ...
 * sometimes (mostly wrt. hw bugs) we get corrupted vectors all
 * across the spectrum, so we really want to be prepared to get all
 * of these. Plus, more powerful systems might have more than 64
 * IO-APIC registers.
 *
 * (these are usually mapped into the 0x30-0xff vector range)
 */

/*
 * IRQ2 is cascade interrupt to second interrupt controller
 */

static struct irqaction irq2 = {
	.handler = no_action,
	.name = "cascade",
	.flags = IRQF_NO_THREAD,
};

DEFINE_PER_CPU(vector_irq_t, vector_irq) = {
	[0 ... NR_VECTORS - 1] = VECTOR_UNUSED,
};


void __init init_ISA_irqs(void) { struct irq_chip *chip = legacy_pic->chip; int i; /* * Try to set up the through-local-APIC virtual wire mode earlier. * * On some 32-bit UP machines, whose APIC has been disabled by BIOS * and then got re-enabled by "lapic", it hangs at boot time without this. */ init_bsp_APIC(); legacy_pic->init(0); for (i = 0; i < nr_legacy_irqs(); i++) irq_set_chip_and_handler(i, chip, handle_level_irq); }

Contributors

PersonTokensPropCommitsCommitProp
Linus Torvalds (pre-git)2546.30%19.09%
Thomas Gleixner1018.52%19.09%
Andi Kleen611.11%19.09%
Ville Syrjälä35.56%19.09%
Jacob jun Pan35.56%19.09%
Yinghai Lu23.70%218.18%
Ingo Molnar23.70%19.09%
Dou Liyang11.85%19.09%
Jiang Liu11.85%19.09%
Maciej W. Rozycki11.85%19.09%
Total54100.00%11100.00%


void __init init_IRQ(void) { int i; /* * On cpu 0, Assign ISA_IRQ_VECTOR(irq) to IRQ 0..15. * If these IRQ's are handled by legacy interrupt-controllers like PIC, * then this configuration will likely be static after the boot. If * these IRQ's are handled by more mordern controllers like IO-APIC, * then this vector space can be freed and re-used dynamically as the * irq's migrate etc. */ for (i = 0; i < nr_legacy_irqs(); i++) per_cpu(vector_irq, 0)[ISA_IRQ_VECTOR(i)] = irq_to_desc(i); x86_init.irqs.intr_init(); }

Contributors

PersonTokensPropCommitsCommitProp
Suresh B. Siddha2854.90%114.29%
Thomas Gleixner1325.49%342.86%
Glauber de Oliveira Costa59.80%114.29%
Brian Gerst47.84%114.29%
Jiang Liu11.96%114.29%
Total51100.00%7100.00%


void __init native_init_IRQ(void) { /* Execute any quirks before the call gates are initialised: */ x86_init.irqs.pre_vector_init(); idt_setup_apic_and_irq_gates(); lapic_assign_system_vectors(); if (!acpi_ioapic && !of_ioapic && nr_legacy_irqs()) setup_irq(2, &irq2); irq_ctx_init(smp_processor_id()); }

Contributors

PersonTokensPropCommitsCommitProp
Cyrill V. Gorcunov1327.66%17.69%
Thomas Gleixner919.15%323.08%
Glauber de Oliveira Costa714.89%17.69%
Andrew Morton36.38%17.69%
Andy Shevchenko36.38%17.69%
Pekka J Enberg36.38%17.69%
Sebastian Andrzej Siewior36.38%17.69%
James Bottomley24.26%17.69%
Yinghai Lu24.26%17.69%
Mikael Pettersson12.13%17.69%
Linus Torvalds (pre-git)12.13%17.69%
Total47100.00%13100.00%


Overall Contributors

PersonTokensPropCommitsCommitProp
Linus Torvalds (pre-git)6322.91%24.17%
Thomas Gleixner3813.82%918.75%
Cyrill V. Gorcunov3111.27%12.08%
Suresh B. Siddha2910.55%12.08%
Yinghai Lu228.00%48.33%
Andi Kleen145.09%12.08%
Glauber de Oliveira Costa124.36%24.17%
Jaswinder Singh Rajput93.27%24.17%
Sebastian Andrzej Siewior62.18%12.08%
Ingo Molnar62.18%36.25%
Linus Torvalds51.82%24.17%
Andrew Morton41.45%24.17%
James Bottomley41.45%24.17%
Brian Gerst41.45%12.08%
Pekka J Enberg31.09%12.08%
Andy Shevchenko31.09%12.08%
Ville Syrjälä31.09%12.08%
Jacob jun Pan31.09%12.08%
Adrian Bunk31.09%12.08%
Pavel Machek20.73%12.08%
Len Brown20.73%12.08%
Jiang Liu20.73%12.08%
Greg Kroah-Hartman10.36%12.08%
Arun Sharma10.36%12.08%
Paul Jimenez10.36%12.08%
Mikael Pettersson10.36%12.08%
Dou Liyang10.36%12.08%
Kay Sievers10.36%12.08%
Maciej W. Rozycki10.36%12.08%
Total275100.00%48100.00%
Directory: arch/x86/kernel
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.