Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754546AbdCBRzc (ORCPT ); Thu, 2 Mar 2017 12:55:32 -0500 Received: from mx1.redhat.com ([209.132.183.28]:57294 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752916AbdCBRz1 (ORCPT ); Thu, 2 Mar 2017 12:55:27 -0500 From: Vitaly Kuznetsov To: xen-devel@lists.xenproject.org Cc: x86@kernel.org, linux-kernel@vger.kernel.org, Boris Ostrovsky , Juergen Gross , Andrew Jones Subject: [PATCH v2 21/21] x86/xen: rename some PV-only functions in smp_pv.c Date: Thu, 2 Mar 2017 18:53:57 +0100 Message-Id: <20170302175357.8222-22-vkuznets@redhat.com> In-Reply-To: <20170302175357.8222-1-vkuznets@redhat.com> References: <20170302175357.8222-1-vkuznets@redhat.com> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Thu, 02 Mar 2017 17:54:38 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3275 Lines: 110 After code split between PV and HVM some functions in xen_smp_ops have xen_pv_ prefix and some only xen_ which makes them look like they're common for both PV and HVM while they're not. Rename all the rest to have xen_pv_ prefix. Signed-off-by: Vitaly Kuznetsov --- - This patch is rather a matter of taste and it makes code archeology slightly harder, we may consider dropping it from the series. --- arch/x86/xen/smp_pv.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/arch/x86/xen/smp_pv.c b/arch/x86/xen/smp_pv.c index e20718a..0110429 100644 --- a/arch/x86/xen/smp_pv.c +++ b/arch/x86/xen/smp_pv.c @@ -220,7 +220,7 @@ static void __init xen_pv_smp_prepare_boot_cpu(void) xen_init_spinlocks(); } -static void __init xen_smp_prepare_cpus(unsigned int max_cpus) +static void __init xen_pv_smp_prepare_cpus(unsigned int max_cpus) { unsigned cpu; unsigned int i; @@ -336,7 +336,7 @@ cpu_initialize_context(unsigned int cpu, struct task_struct *idle) return 0; } -static int xen_cpu_up(unsigned int cpu, struct task_struct *idle) +static int xen_pv_cpu_up(unsigned int cpu, struct task_struct *idle) { int rc; @@ -370,12 +370,12 @@ static int xen_cpu_up(unsigned int cpu, struct task_struct *idle) return 0; } -static void xen_smp_cpus_done(unsigned int max_cpus) +static void xen_pv_smp_cpus_done(unsigned int max_cpus) { } #ifdef CONFIG_HOTPLUG_CPU -static int xen_cpu_disable(void) +static int xen_pv_cpu_disable(void) { unsigned int cpu = smp_processor_id(); if (cpu == 0) @@ -403,7 +403,7 @@ static void xen_pv_cpu_die(unsigned int cpu) } } -static void xen_play_dead(void) /* used only with HOTPLUG_CPU */ +static void xen_pv_play_dead(void) /* used only with HOTPLUG_CPU */ { play_dead_common(); HYPERVISOR_vcpu_op(VCPUOP_down, xen_vcpu_nr(smp_processor_id()), NULL); @@ -420,7 +420,7 @@ static void xen_play_dead(void) /* used only with HOTPLUG_CPU */ } #else /* !CONFIG_HOTPLUG_CPU */ -static int xen_cpu_disable(void) +static int xen_pv_cpu_disable(void) { return -ENOSYS; } @@ -430,7 +430,7 @@ static void xen_pv_cpu_die(unsigned int cpu) BUG(); } -static void xen_play_dead(void) +static void xen_pv_play_dead(void) { BUG(); } @@ -450,7 +450,7 @@ static void stop_self(void *v) BUG(); } -static void xen_stop_other_cpus(int wait) +static void xen_pv_stop_other_cpus(int wait) { smp_call_function(stop_self, NULL, wait); } @@ -477,15 +477,15 @@ static irqreturn_t xen_irq_work_interrupt(int irq, void *dev_id) static const struct smp_ops xen_smp_ops __initconst = { .smp_prepare_boot_cpu = xen_pv_smp_prepare_boot_cpu, - .smp_prepare_cpus = xen_smp_prepare_cpus, - .smp_cpus_done = xen_smp_cpus_done, + .smp_prepare_cpus = xen_pv_smp_prepare_cpus, + .smp_cpus_done = xen_pv_smp_cpus_done, - .cpu_up = xen_cpu_up, + .cpu_up = xen_pv_cpu_up, .cpu_die = xen_pv_cpu_die, - .cpu_disable = xen_cpu_disable, - .play_dead = xen_play_dead, + .cpu_disable = xen_pv_cpu_disable, + .play_dead = xen_pv_play_dead, - .stop_other_cpus = xen_stop_other_cpus, + .stop_other_cpus = xen_pv_stop_other_cpus, .smp_send_reschedule = xen_smp_send_reschedule, .send_call_func_ipi = xen_smp_send_call_function_ipi, -- 2.9.3