]> git.baikalelectronics.ru Git - kernel.git/commit
x86/vector: Merge allocate_vector() into assign_vector_locked()
authorDou Liyang <douly.fnst@cn.fujitsu.com>
Fri, 11 May 2018 08:09:56 +0000 (16:09 +0800)
committerThomas Gleixner <tglx@linutronix.de>
Sat, 19 May 2018 13:09:11 +0000 (15:09 +0200)
commitff4195de085718068ee212e98e0e7c2bf6c184a2
tree34449c3a9b866cd8e8ae395eb78fd50e0f128360
parent98f9022a8ce8db53574cc3b544741804f39ebe99
x86/vector: Merge allocate_vector() into assign_vector_locked()

assign_vector_locked() calls allocate_vector() to get a real vector for an
IRQ. If the current target CPU is online and in the new requested affinity
mask, allocate_vector() will return 0 and nothing should be done. But,
assign_vector_locked() calls apic_update_irq_cfg() even in that case which
is pointless.

allocate_vector() is not called from anything else, so the functions can be
merged and in case of no change the apic_update_irq_cfg() can be avoided.

[ tglx: Massaged changelog ]

Signed-off-by: Dou Liyang <douly.fnst@cn.fujitsu.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: hpa@zytor.com
Link: https://lkml.kernel.org/r/20180511080956.6316-1-douly.fnst@cn.fujitsu.com
arch/x86/kernel/apic/vector.c