From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1162224AbbKEOrP (ORCPT ); Thu, 5 Nov 2015 09:47:15 -0500 Received: from terminus.zytor.com ([198.137.202.10]:34681 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1161577AbbKEOrL (ORCPT ); Thu, 5 Nov 2015 09:47:11 -0500 Date: Thu, 5 Nov 2015 06:46:31 -0800 From: tip-bot for Thomas Gleixner Message-ID: Cc: daniel@numascale.com, peterz@infradead.org, mingo@kernel.org, torvalds@linux-foundation.org, bp@alien.de, linux-kernel@vger.kernel.org, tglx@linutronix.de, travis@sgi.com, hpa@zytor.com Reply-To: daniel@numascale.com, peterz@infradead.org, mingo@kernel.org, torvalds@linux-foundation.org, bp@alien.de, travis@sgi.com, hpa@zytor.com, linux-kernel@vger.kernel.org, tglx@linutronix.de In-Reply-To: <20151104220849.631111846@linutronix.de> References: <20151104220849.631111846@linutronix.de> To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/apic] x86/apic: Provide default send single IPI wrapper Git-Commit-ID: 7e29393b20a1a863a5f9bf48dc71e5cff4035ff5 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 7e29393b20a1a863a5f9bf48dc71e5cff4035ff5 Gitweb: http://git.kernel.org/tip/7e29393b20a1a863a5f9bf48dc71e5cff4035ff5 Author: Thomas Gleixner AuthorDate: Wed, 4 Nov 2015 22:57:07 +0000 Committer: Thomas Gleixner CommitDate: Thu, 5 Nov 2015 13:07:53 +0100 x86/apic: Provide default send single IPI wrapper Instead of doing the wrapping in the smp code we can provide a default wrapper for those APICs which insist on cpumasks. Signed-off-by: Thomas Gleixner Reviewed-by: Ingo Molnar Cc: Linus Torvalds Cc: Borislav Petkov Cc: Peter Zijlstra Cc: Mike Travis Cc: Daniel J Blueman Link: http://lkml.kernel.org/r/20151104220849.631111846@linutronix.de --- arch/x86/include/asm/ipi.h | 1 + arch/x86/kernel/apic/ipi.c | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/arch/x86/include/asm/ipi.h b/arch/x86/include/asm/ipi.h index 22998a8..cfc9a0d 100644 --- a/arch/x86/include/asm/ipi.h +++ b/arch/x86/include/asm/ipi.h @@ -119,6 +119,7 @@ static inline void native_apic_mem_write(APIC_ICR, cfg); } +extern void default_send_IPI_single(int cpu, int vector); extern void default_send_IPI_single_phys(int cpu, int vector); extern void default_send_IPI_mask_sequence_phys(const struct cpumask *mask, int vector); diff --git a/arch/x86/kernel/apic/ipi.c b/arch/x86/kernel/apic/ipi.c index 4fcffbf..eb45fc9 100644 --- a/arch/x86/kernel/apic/ipi.c +++ b/arch/x86/kernel/apic/ipi.c @@ -65,6 +65,14 @@ void default_send_IPI_mask_allbutself_phys(const struct cpumask *mask, local_irq_restore(flags); } +/* + * Helper function for APICs which insist on cpumasks + */ +void default_send_IPI_single(int cpu, int vector) +{ + apic->send_IPI_mask(cpumask_of(cpu), vector); +} + #ifdef CONFIG_X86_32 void default_send_IPI_mask_sequence_logical(const struct cpumask *mask,