---
name: "struct_irq_chip"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/struct_irq_chip"
---

# struct\_irq\_chip(9)

hardware interrupt chip descriptor

## NAME

struct\_irq\_chip - hardware interrupt chip descriptor

## SYNOPSIS

```
struct irq_chip {
  struct device * parent_device;
  const char * name;
  unsigned int	(* irq_startup) (struct irq_data *data);
  void (* irq_shutdown) (struct irq_data *data);
  void (* irq_enable) (struct irq_data *data);
  void (* irq_disable) (struct irq_data *data);
  void (* irq_ack) (struct irq_data *data);
  void (* irq_mask) (struct irq_data *data);
  void (* irq_mask_ack) (struct irq_data *data);
  void (* irq_unmask) (struct irq_data *data);
  void (* irq_eoi) (struct irq_data *data);
  int (* irq_set_affinity) (struct irq_data *data, const struct cpumask *dest, bool force);
  int (* irq_retrigger) (struct irq_data *data);
  int (* irq_set_type) (struct irq_data *data, unsigned int flow_type);
  int (* irq_set_wake) (struct irq_data *data, unsigned int on);
  void (* irq_bus_lock) (struct irq_data *data);
  void (* irq_bus_sync_unlock) (struct irq_data *data);
  void (* irq_cpu_online) (struct irq_data *data);
  void (* irq_cpu_offline) (struct irq_data *data);
  void (* irq_suspend) (struct irq_data *data);
  void (* irq_resume) (struct irq_data *data);
  void (* irq_pm_shutdown) (struct irq_data *data);
  void (* irq_calc_mask) (struct irq_data *data);
  void (* irq_print_chip) (struct irq_data *data, struct seq_file *p);
  int (* irq_request_resources) (struct irq_data *data);
  void (* irq_release_resources) (struct irq_data *data);
  void (* irq_compose_msi_msg) (struct irq_data *data, struct msi_msg *msg);
  void (* irq_write_msi_msg) (struct irq_data *data, struct msi_msg *msg);
  int (* irq_get_irqchip_state) (struct irq_data *data, enum irqchip_irq_state which, bool *state);
  int (* irq_set_irqchip_state) (struct irq_data *data, enum irqchip_irq_state which, bool state);
  int (* irq_set_vcpu_affinity) (struct irq_data *data, void *vcpu_info);
  void (* ipi_send_single) (struct irq_data *data, unsigned int cpu);
  void (* ipi_send_mask) (struct irq_data *data, const struct cpumask *dest);
  unsigned long flags;
};
```

## MEMBERS

parent\_device

pointer to parent device for irqchip

name

name for /proc/interrupts

irq\_startup

start up the interrupt (defaults to -\>enable if NULL)

irq\_shutdown

shut down the interrupt (defaults to -\>disable if NULL)

irq\_enable

enable the interrupt (defaults to chip-\>unmask if NULL)

irq\_disable

disable the interrupt

irq\_ack

start of a new interrupt

irq\_mask

mask an interrupt source

irq\_mask\_ack

ack and mask an interrupt source

irq\_unmask

unmask an interrupt source

irq\_eoi

end of interrupt

irq\_set\_affinity

set the CPU affinity on SMP machines

irq\_retrigger

resend an IRQ to the CPU

irq\_set\_type

set the flow type (IRQ\_TYPE\_LEVEL/etc.) of an IRQ

irq\_set\_wake

enable/disable power-management wake-on of an IRQ

irq\_bus\_lock

function to lock access to slow bus (i2c) chips

irq\_bus\_sync\_unlock

function to sync and unlock slow bus (i2c) chips

irq\_cpu\_online

configure an interrupt source for a secondary CPU

irq\_cpu\_offline

un-configure an interrupt source for a secondary CPU

irq\_suspend

function called from core code on suspend once per chip, when one or more interrupts are installed

irq\_resume

function called from core code on resume once per chip, when one ore more interrupts are installed

irq\_pm\_shutdown

function called from core code on shutdown once per chip

irq\_calc\_mask

Optional function to set irq\_data.mask for special cases

irq\_print\_chip

optional to print special chip info in show\_interrupts

irq\_request\_resources

optional to request resources before calling any other callback related to this irq

irq\_release\_resources

optional to release resources acquired with irq\_request\_resources

irq\_compose\_msi\_msg

optional to compose message content for MSI

irq\_write\_msi\_msg

optional to write message content for MSI

irq\_get\_irqchip\_state

return the internal state of an interrupt

irq\_set\_irqchip\_state

set the internal state of a interrupt

irq\_set\_vcpu\_affinity

optional to target a vCPU in a virtual machine

ipi\_send\_single

send a single IPI to destination cpus

ipi\_send\_mask

send an IPI to destination cpus in cpumask

flags

chip specific flags

## AUTHORS

**Thomas Gleixner** \<tglx@linutronix.de\>

Author.

**Ingo Molnar** \<mingo@elte.hu\>

Author.

## COPYRIGHT
