函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\irq\manage.c Create Date:2022-07-27 11:10:13
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:quest_nmi - allocate an interrupt line for NMI delivery*@irq: Interrupt line to allocate*@handler: Function to be called when the IRQ occurs

函数原型:int request_nmi(unsigned int irq, irq_handler_t handler, unsigned long irqflags, const char *name, void *dev_id)

返回类型:int

参数:

类型参数名称
unsigned intirq
irq_handler_thandler
unsigned longirqflags
const char *name
void *dev_id
2121  如果irq恒等于If a (PCI) device interrupt is not connected we set dev->irq to* IRQ_NOTCONNECTED则返回:负ENOTCONN
2125  如果irqflags按位与These flags used only by the kernel as part of the* irq handling routines按位或IRQF_COND_SUSPEND按位或IRQF_IRQPOLL的值则返回:负EINVAL
2128  如果非irqflags按位与IRQF_PERCPU的值则返回:负EINVAL
2131  如果非handler则返回:负EINVAL
2134  desc等于中断转换为描述
2136  如果非desc中断能够被设置或非设置请求参数WARN_ON(irq_settings_is_per_cpu_devid(desc))或非irq_supports_nmi(desc)则返回:负EINVAL
2142  action等于分配内存并置零
2143  如果非action则返回:负ENOMEM
2146  中断处理函数等于handler
2147  中断动作标志等于irqflags按位或IRQF_NO_THREAD按位或IRQF_NOBALANCING
2148  设备名等于name
2149  设备标识等于dev_id
2151  retval等于q_chip_pm_get - Enable power for an IRQ chip*@data: Pointer to interrupt specific data* Enable the power to the IRQ chip referenced by the interrupt data* structure.
2152  如果retval小于0则转到:err_out
2155  retval等于注册中断
2156  如果retval则转到:err_irq_setup
2159  raw_spin_lock_irqsave( & 自旋锁, flags)
2162  istate或等于IRQS_NMI
2163  retval等于irq_nmi_setup(desc)
2164  如果retval
2165  This function must be called with desc->lock held
2166  raw_spin_unlock_irqrestore( & 自旋锁, flags)
2167  返回:负EINVAL
2170  raw_spin_unlock_irqrestore( & 自旋锁, flags)
2172  返回:0
2174  err_irq_setup :
2175  q_chip_pm_put - Disable power for an IRQ chip*@data: Pointer to interrupt specific data* Disable the power to the IRQ chip referenced by the interrupt data* structure, belongs. Note that power will only be disabled, once this
2176  err_out :
2177  释放内存
2179  返回:retval