提交 11b4a1cc 编写于 作者: J Joerg Roedel

x86, irq: Move irq_remapped() check into free_remapped_irq

The function is called unconditionally now in IO-APIC code
removing another irq_remapped() check from x86 core code.
Signed-off-by: NJoerg Roedel <joro@8bytes.org>
Acked-by: NSebastian Andrzej Siewior <sebastian@breakpoint.cc>
Reviewed-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
上级 9f9d39e4
...@@ -3003,8 +3003,8 @@ void destroy_irq(unsigned int irq) ...@@ -3003,8 +3003,8 @@ void destroy_irq(unsigned int irq)
irq_set_status_flags(irq, IRQ_NOREQUEST|IRQ_NOPROBE); irq_set_status_flags(irq, IRQ_NOREQUEST|IRQ_NOPROBE);
if (irq_remapped(cfg))
free_remapped_irq(irq); free_remapped_irq(irq);
raw_spin_lock_irqsave(&vector_lock, flags); raw_spin_lock_irqsave(&vector_lock, flags);
__clear_irq_vector(irq, cfg); __clear_irq_vector(irq, cfg);
raw_spin_unlock_irqrestore(&vector_lock, flags); raw_spin_unlock_irqrestore(&vector_lock, flags);
......
...@@ -282,9 +282,12 @@ int set_remapped_irq_affinity(struct irq_data *data, const struct cpumask *mask, ...@@ -282,9 +282,12 @@ int set_remapped_irq_affinity(struct irq_data *data, const struct cpumask *mask,
void free_remapped_irq(int irq) void free_remapped_irq(int irq)
{ {
struct irq_cfg *cfg = irq_get_chip_data(irq);
if (!remap_ops || !remap_ops->free_irq) if (!remap_ops || !remap_ops->free_irq)
return; return;
if (irq_remapped(cfg))
remap_ops->free_irq(irq); remap_ops->free_irq(irq);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册