From patchwork Fri Feb 2 11:41:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 126632 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp559393ljc; Fri, 2 Feb 2018 03:44:26 -0800 (PST) X-Google-Smtp-Source: AH8x2279llzAlDe2jIkYTha2vXpjLx2nn+CbVNHJD2wtHtB3ot8+JOxZIgRwKoc8aiI0zfDpbHDR X-Received: by 10.107.169.94 with SMTP id s91mr10832759ioe.83.1517571866708; Fri, 02 Feb 2018 03:44:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517571866; cv=none; d=google.com; s=arc-20160816; b=nVs1CtneEKWrmxLOkdzTW+XMwNvycCDOGE0AkhbRJd/hQDVefI8vEVjwDuw3PycpSh x+uLZqch0EaT84fleIRJMLG1i0tFjj2oDDe4yCrpogk5Q3fyWv7OaT8YrNTcYPUiSGs+ kQ4wCTsvzcafx6AQW3KaN9tRHXeqA2nsmiwzm6TfzJtmjX8mEjy+6ZhMhU6QHcnGOs8b uF8vuGeevDlDiqJYO8aFfDQ+KepPEvb3BX/s2HgcK0t7PQliAia6TAy0mNLAsFEq0Ex8 zVxpWcgOPL6jxcv6foiCiufzh+I+5oFFj65fA20qzI+y3unlweTHuH8heaIsFakr5aE4 HAjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-unsubscribe:list-id :precedence:subject:cc:references:in-reply-to:message-id:date:to :from:dkim-signature:arc-authentication-results; bh=XoU3J4iB9rmxT/kYvSBjYr4ZFWfqGPfa06iAINjiBtQ=; b=EOisMtpFFk+L9vzAlDIx6aUp69Wtrad6GPAaN9W44bHvRBZzBsMgP9v1thli5KIExz hXBein3jsjfOratga161SUl/biWByXj2uIY14km2aQDvWdVqwFnO8PUDX1S0MXPp4ka5 fhtO2QxB033CYtPwRQnF1/uK55EUYh705Ittg/tA+EM7RJ2WQTCyvtcQdNmlfbxhDJk9 0k+i45G6vyU0VpFj3g96nxS8eRcE4NKlsd+coWGZoqgA04dwAx9Cwo1GxiZyMbs9qV/X vcObTK91be7itH1a9/6+AZAweHKRdT/xcEXlDywny2Ad6fPhcY27tKJmI81T8mDjjItn 2DqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=LdjmKZaQ; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id 7si1499491iod.195.2018.02.02.03.44.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Feb 2018 03:44:26 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=LdjmKZaQ; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ehZjB-0004IZ-9a; Fri, 02 Feb 2018 11:41:57 +0000 Received: from us1-rack-dfw2.inumbo.com ([104.130.134.6]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ehZjA-0004II-1n for xen-devel@lists.xen.org; Fri, 02 Feb 2018 11:41:56 +0000 X-Inumbo-ID: 06ce7e3b-080e-11e8-ba59-bc764e045a96 Received: from mail-wm0-x242.google.com (unknown [2a00:1450:400c:c09::242]) by us1-rack-dfw2.inumbo.com (Halon) with ESMTPS id 06ce7e3b-080e-11e8-ba59-bc764e045a96; Fri, 02 Feb 2018 12:41:37 +0100 (CET) Received: by mail-wm0-x242.google.com with SMTP id v71so11758293wmv.2 for ; Fri, 02 Feb 2018 03:41:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=nr/JDd3Gw3tslzGAE+cPlZH/6ssaNJ4BmhU0mW/oPZ8=; b=LdjmKZaQzn6EfK60Tu5+Z1UJabcImvHVRDtFZVnF3GtYgurEjKdo0f+7hrSQYv1WJJ QUVslLzO+TddvYok7qVLFiV1DpBJEZiQKKDF6yfz/tZO0wUrpxvSEV9Cr6+aca+aXnws ZpjOCJ4G1T10KLuL4tI8y51DWHwOOvSyZHfPI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=nr/JDd3Gw3tslzGAE+cPlZH/6ssaNJ4BmhU0mW/oPZ8=; b=SjHx+k1d0pILkzFRCMcEPuppFvV3eyvwsanC74oGliQ1xWUGqVSOq10RTA1Nz0d+gG M4AuNIs8A/kL/ijBfA9yj3wVixl/fngJayHi9ApnSse01W50gPxZDe21jNcstlsKbylw 0vNZ0LR6Ybjs/WDaMwTrKfW9galyhIQGlCAmRIR5u9LA+xuVGW//SnTUqcPdzUbFoYXG ZRi2I65WmSI8gesBghcoOCkraCjkNCEIX8hZ9WsavCQT7QD9jfkEJAjGan+zjriCpUes DBoyxFgitbea8X3Mvjk8IGBsat3xXGLrOr/xMW5rh8V8UXvn6+fo9BI//hZcrJhzglsY SA9Q== X-Gm-Message-State: AKwxytfUNtZZCZZNcLVqvx3Z/kJlXrupaSaY7WB6uVaPxOwPvK3vHSRe EUwQMKqIcdC5GZNwrKaGqTX3+f83iI8= X-Received: by 10.28.174.210 with SMTP id x201mr26728047wme.105.1517571713438; Fri, 02 Feb 2018 03:41:53 -0800 (PST) Received: from e108454-lin.cambridge.arm.com ([2001:41d0:1:6c23::1]) by smtp.gmail.com with ESMTPSA id f13sm764900wre.84.2018.02.02.03.41.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Feb 2018 03:41:52 -0800 (PST) From: Julien Grall To: xen-devel@lists.xen.org Date: Fri, 2 Feb 2018 11:41:48 +0000 Message-Id: <20180202114150.23817-2-julien.grall@linaro.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180202114150.23817-1-julien.grall@linaro.org> References: <20180202114150.23817-1-julien.grall@linaro.org> Cc: sstabellini@kernel.org, volodymyr_babchuk@epam.com, andre.przywara@linaro.org, Julien Grall Subject: [Xen-devel] [PATCH v2 1/3] xen/arm: vpsci: Removing dummy MIGRATE and MIGRATE_INFO_UP_CPU X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" The PSCI call MIGRATE and MIGRATE_INFO_UP_CPU are optional and implemented as just returning PSCI_NOT_SUPPORTED (aka UNKNOWN_FUNCTION for SMCCC). The new SMCCC framework is able to deal with unimplemented function and return the proper error code. So remove the implementations for both function. Signed-off-by: Julien Grall --- Changes in v2: - Remove define in psci.h - Update SSSC_SMCCC_FUNCTION_COUNT --- xen/arch/arm/vpsci.c | 10 ---------- xen/arch/arm/vsmc.c | 16 +--------------- xen/include/asm-arm/perfc_defn.h | 2 -- xen/include/asm-arm/psci.h | 4 ---- 4 files changed, 1 insertion(+), 31 deletions(-) diff --git a/xen/arch/arm/vpsci.c b/xen/arch/arm/vpsci.c index cd724904ef..979d32ed6d 100644 --- a/xen/arch/arm/vpsci.c +++ b/xen/arch/arm/vpsci.c @@ -172,21 +172,11 @@ int32_t do_psci_0_2_affinity_info(register_t target_affinity, return PSCI_0_2_AFFINITY_LEVEL_OFF; } -int32_t do_psci_0_2_migrate(uint32_t target_cpu) -{ - return PSCI_NOT_SUPPORTED; -} - uint32_t do_psci_0_2_migrate_info_type(void) { return PSCI_0_2_TOS_MP_OR_NOT_PRESENT; } -register_t do_psci_0_2_migrate_info_up_cpu(void) -{ - return PSCI_NOT_SUPPORTED; -} - void do_psci_0_2_system_off( void ) { struct domain *d = current->domain; diff --git a/xen/arch/arm/vsmc.c b/xen/arch/arm/vsmc.c index c9064de37a..997f2e0ebc 100644 --- a/xen/arch/arm/vsmc.c +++ b/xen/arch/arm/vsmc.c @@ -28,7 +28,7 @@ #define XEN_SMCCC_FUNCTION_COUNT 3 /* Number of functions currently supported by Standard Service Service Calls. */ -#define SSSC_SMCCC_FUNCTION_COUNT 13 +#define SSSC_SMCCC_FUNCTION_COUNT 11 static bool fill_uid(struct cpu_user_regs *regs, xen_uuid_t uuid) { @@ -157,11 +157,6 @@ static bool handle_sssc(struct cpu_user_regs *regs) PSCI_SET_RESULT(regs, do_psci_0_2_migrate_info_type()); return true; - case PSCI_0_2_FN_MIGRATE_INFO_UP_CPU: - perfc_incr(vpsci_migrate_info_up_cpu); - PSCI_SET_RESULT(regs, do_psci_0_2_migrate_info_up_cpu()); - return true; - case PSCI_0_2_FN_SYSTEM_OFF: perfc_incr(vpsci_system_off); do_psci_0_2_system_off(); @@ -206,15 +201,6 @@ static bool handle_sssc(struct cpu_user_regs *regs) return true; } - case PSCI_0_2_FN_MIGRATE: - { - uint32_t tcpu = PSCI_ARG32(regs, 1); - - perfc_incr(vpsci_cpu_migrate); - PSCI_SET_RESULT(regs, do_psci_0_2_migrate(tcpu)); - return true; - } - case ARM_SMCCC_FUNC_CALL_COUNT: return fill_function_call_count(regs, SSSC_SMCCC_FUNCTION_COUNT); diff --git a/xen/include/asm-arm/perfc_defn.h b/xen/include/asm-arm/perfc_defn.h index 5f957ee6ec..a7acb7d21c 100644 --- a/xen/include/asm-arm/perfc_defn.h +++ b/xen/include/asm-arm/perfc_defn.h @@ -27,12 +27,10 @@ PERFCOUNTER(vpsci_cpu_on, "vpsci: cpu_on") PERFCOUNTER(vpsci_cpu_off, "vpsci: cpu_off") PERFCOUNTER(vpsci_version, "vpsci: version") PERFCOUNTER(vpsci_migrate_info_type, "vpsci: migrate_info_type") -PERFCOUNTER(vpsci_migrate_info_up_cpu, "vpsci: migrate_info_up_cpu") PERFCOUNTER(vpsci_system_off, "vpsci: system_off") PERFCOUNTER(vpsci_system_reset, "vpsci: system_reset") PERFCOUNTER(vpsci_cpu_suspend, "vpsci: cpu_suspend") PERFCOUNTER(vpsci_cpu_affinity_info, "vpsci: cpu_affinity_info") -PERFCOUNTER(vpsci_cpu_migrate, "vpsci: cpu_migrate") PERFCOUNTER(vgicd_reads, "vgicd: read") PERFCOUNTER(vgicd_writes, "vgicd: write") diff --git a/xen/include/asm-arm/psci.h b/xen/include/asm-arm/psci.h index 635ea5dae4..32c1f81f21 100644 --- a/xen/include/asm-arm/psci.h +++ b/xen/include/asm-arm/psci.h @@ -37,9 +37,7 @@ int32_t do_psci_0_2_cpu_on(register_t target_cpu, register_t entry_point, register_t context_id); int32_t do_psci_0_2_affinity_info(register_t target_affinity, uint32_t lowest_affinity_level); -int32_t do_psci_0_2_migrate(uint32_t target_cpu); uint32_t do_psci_0_2_migrate_info_type(void); -register_t do_psci_0_2_migrate_info_up_cpu(void); void do_psci_0_2_system_off(void); void do_psci_0_2_system_reset(void); @@ -57,9 +55,7 @@ void do_psci_0_2_system_reset(void); #define PSCI_0_2_FN_CPU_OFF 2 #define PSCI_0_2_FN_CPU_ON 3 #define PSCI_0_2_FN_AFFINITY_INFO 4 -#define PSCI_0_2_FN_MIGRATE 5 #define PSCI_0_2_FN_MIGRATE_INFO_TYPE 6 -#define PSCI_0_2_FN_MIGRATE_INFO_UP_CPU 7 #define PSCI_0_2_FN_SYSTEM_OFF 8 #define PSCI_0_2_FN_SYSTEM_RESET 9