From patchwork Tue Aug 8 20:08:42 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Volodymyr Babchuk X-Patchwork-Id: 9889035 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0FC6960352 for ; Tue, 8 Aug 2017 20:12:03 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 01D2D287D5 for ; Tue, 8 Aug 2017 20:12:03 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EAE23288E6; Tue, 8 Aug 2017 20:12:02 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7740E287D7 for ; Tue, 8 Aug 2017 20:12:02 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dfAp0-0000nZ-Hp; Tue, 08 Aug 2017 20:09:46 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dfAoy-0000ma-VU for xen-devel@lists.xen.org; Tue, 08 Aug 2017 20:09:45 +0000 Received: from [85.158.137.68] by server-5.bemta-3.messagelabs.com id CC/28-02181-88A1A895; Tue, 08 Aug 2017 20:09:44 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA1WSa0hTYRjHfc85m0fxyHGaPk4NGuRIm2kXSEi zviSGWNQHjaCOedoGu3XOrAURCwnZoLCbzkusi6bpFBEDrbwUCTXogloZGmiapoaXDDFW2s7O NHs/ve/7+z/P///AQ+KyPxI5yVrMLGdgdAppMKHZFpCgKpbb85IHX2K7q+fvExkos+eJBzuEj km0hnyj5aRE09O+QJgebbJ0tl3GrMgFdhRMEvQlHLruuQPtKIhE9HFoabUhAcjoqxi4KhclAp DRp+DpY4dPJKV3QpPzre8eQcfAh4U+XwFOtyO407pICCCczoSydwO4HZFei80wMhwpfFN0FnQ 1L/kkQG+ET29suHAPog9C60c3LnplwZMOJxL1YfCqfMynx2mAZ9++4WLtJuj2lOOCL9C3EDj7 q/1BldDh+e4XxUHP6yq/WTZMjz0ixIL3GBQNtyDxURQIfWV2qajaCl1j1/1tJ6RQXNeEiSAV5 peWpMI4QJvgWv1FUTMggYmvs367WOhpb/BbzErA/d4lFTOdhJkVDyaC+lAY73f4vW2BUDt6Q1 KC4ivWTVuxbto7CKtHSp7lzrKcKiUpn9OqNWY9o9WpUpJ3JOlZnmfUrI7J55NOGfUtyLsKAd7 Thmrn9z9H0SSm2EC1JNryZKH5xoLzGobXnOAKdSz/HMWSpAKoh9H2PFkYx6pZy2mtzrtPqxjI EEUE1Shgijcxel6rFpEbqcipkpVFTEYYjAZWHkUVCSJaEGkKDWstVreyF8XJwynkDSULMbGcX mv+n0+hKBIpwqluoUuI1mBec5ryhsC8IXKzbUIIM/MPya2orfTuuYgHk7fJg9J92Y0N064tk9 0jzJkLV3YpJUPN46MhCXWJyyN3cyqOOtMLqvdE3x/K2X7Psfyl39qp+DxcmsG7KvroIz/iZ9L rqpUvrL+x3NriyrlfnphsR+WBvRbulbPhoTr1cNrPiAcBczdr0uasRI0ysrQ3eXmwt52qMioI XsOkJOAcz/wFitWtgJADAAA= X-Env-Sender: Volodymyr_Babchuk@epam.com X-Msg-Ref: server-6.tower-31.messagelabs.com!1502222982!70603379!1 X-Originating-IP: [104.47.0.42] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 9.4.45; banners=-,-,- X-VirusChecked: Checked Received: (qmail 12959 invoked from network); 8 Aug 2017 20:09:42 -0000 Received: from mail-he1eur01on0042.outbound.protection.outlook.com (HELO EUR01-HE1-obe.outbound.protection.outlook.com) (104.47.0.42) by server-6.tower-31.messagelabs.com with AES256-SHA256 encrypted SMTP; 8 Aug 2017 20:09:42 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=EPAM.onmicrosoft.com; s=selector1-epam-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=PDfWXTI34rLvPcCjkm5td+vvQHM/KN2h7ZFwaE16oII=; b=bXvRoAYLcqA3Ta6wQqLIU2nD7UvHeS+P9b5m4iMBB98RDE6MFf+obfRx31RUWOxWxOiLT4hz5x9Oo7h4pGPnwNJhwa35wuHIv71RhRlUTkX60xBGMjrQPyAK18d0L4R58ULfGGOpD7up+w9a7oQKhEcGetmq4iPWDeTfIdp6G0E= Received: from EPUAKYIW2556.kyiv.epam.com (85.223.209.58) by HE1PR0301MB2139.eurprd03.prod.outlook.com (2603:10a6:3:21::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.1320.16; Tue, 8 Aug 2017 20:09:39 +0000 Received: by EPUAKYIW2556.kyiv.epam.com (sSMTP sendmail emulation); Tue, 08 Aug 2017 23:09:34 +0300 From: Volodymyr Babchuk To: xen-devel@lists.xen.org Date: Tue, 8 Aug 2017 23:08:42 +0300 Message-Id: <1502222922-25821-8-git-send-email-volodymyr_babchuk@epam.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1502222922-25821-1-git-send-email-volodymyr_babchuk@epam.com> References: <1502222922-25821-1-git-send-email-volodymyr_babchuk@epam.com> MIME-Version: 1.0 X-Originating-IP: [85.223.209.58] X-ClientProxiedBy: DB6PR0202CA0013.eurprd02.prod.outlook.com (2603:10a6:4:29::23) To HE1PR0301MB2139.eurprd03.prod.outlook.com (2603:10a6:3:21::16) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 4ade7856-ce87-45b9-d906-08d4de9966fa X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:HE1PR0301MB2139; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0301MB2139; 3:9e9e9c06P4HsPNbSqaJW76cD2lGTLpXpQaV629ApGtfwQ5t5Gsoi87j+WKzzkpUj7Vs3UYZBQGBwU36ZiCExdRKISoVv8vyHCUJR7LiYrcKHWKw5V9oJX3ElTJ+zy+EjwiEM7QHkEBizR7JQbSutmpaWvlmtKNbD3OpQxNWGVrQ6iId+3XYGV2a2M47fLId4LsuE/r/2YnkhGMqpcrPa7/aXt5Y98cP0bSdl84A9H15WMiwSxDrlo0IeOyycLkOB; 25:V7pNdVo+U+MrZH0Mc49jHXBqDIh2eFnXuGkDoo7dQ6LbbA/EEWVRq9KxPhqKHYRQRBQDUc20+xkPsUhshYhFKcg8RxSyAEDb8PcNoxNCjzOwBJvbb+FPfQoE1PDkMby6/4WcQvPnH441LzTc6dNriMLZfA5o7skblf6S/4w07ZQY8QvqXRfqd4lIcPOtr4leQ/9H6Buf4x4ZEp6p+NeCQcF2Uvuli5De0JprcxQCWzQQ2Gj06I9/jqwam13Y9Ypk7bsK8hHcG7bbgVYnb3sSz/t9RdXrPlwu390F1MU0PM8NU4nAdnA3zuJzZOTlVLnTrErj1whZ7LXRW63P7r3yVg==; 31:lWEO3AFEcq63DsQ8xwM/0zgNucGgta1AE4p193CcyLyn8l8bgg3s039PxIjrkPTzfZeY4mpG+ue8TQxuB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riScan:(4114951738403); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(100000703101)(100105400095)(93006095)(93001095)(10201501046)(6041248)(20161123558100)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123564025)(20161123560025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:HE1PR0301MB2139; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:HE1PR0301MB2139; X-Forefront-PRVS: 03932714EB X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(7370300001)(6009001)(39410400002)(39850400002)(39400400002)(39840400002)(39450400003)(189002)(199003)(50986999)(72206003)(97736004)(36756003)(305945005)(50466002)(7736002)(189998001)(68736007)(50226002)(101416001)(5660300001)(76176999)(8676002)(81156014)(81166006)(2906002)(106356001)(105586002)(4326008)(7350300001)(66066001)(2361001)(8656003)(86362001)(47776003)(110136004)(38730400002)(478600001)(107886003)(3846002)(5003940100001)(2351001)(2950100002)(6916009)(48376002)(80792005)(6666003)(33646002)(53936002)(42186005)(8666007)(122856001)(6116002)(54906002); DIR:OUT; SFP:1101; SCL:1; SRVR:HE1PR0301MB2139; H:EPUAKYIW2556.kyiv.epam.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: epam.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HE1PR0301MB2139; 23:yZSTlw+Dsu1zR6mt/e871Fr0l5U7lW1oMEV6x/q?= =?us-ascii?Q?gYhl2ug20pmNZNX2F6Z0r2sbF9ZOgwduwB0f5lMU6tdG7qGYz4lbS5NDXcsn?= =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faFmxVHD7JPVhvRBKi5dc4kD1dy35+M+q+MKxZVvZFZ8IadJONZthbuOkVtEJzl6wVC8s=; 7:6XA5mV6GeUkGUbwmmSLmc7iJyUXYheFt3wxwl0EAPWkBprPjd5aY6Cc8AMtqXT+VVTG65eKdroF5ADcSTpCbwA26s2NuRXTiDxElmJpVY5d0zkAfugxnDZL7gSa8JI2qXRRnalTP+oW1gjsUzf/5q7wZbw+1HbIZSrs1Frz6VgS3r7gultvCtN+FezipSuML9ivPz72QtGxhpON9yH6/3tdPO9KDlTgp7hSlfO6/FYo= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: epam.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Aug 2017 20:09:39.7191 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0301MB2139 Cc: "Edgar E . Iglesias" , Julien Grall , Stefano Stabellini , Volodymyr Babchuk Subject: [Xen-devel] [PATCH 7/7] arm: vsmc: remove 64 bit mode check in psci handler X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP PSCI handling code had helper routine that checked calling convention. It does not needed anymore, because: - Generic handler checks that 64 bit calls can be made only by 64 bit guests. - SMCCC requires that 64-bit handler should support both 32 and 64 bit calls even if they originate from 64 bit caller. This patch removes that extra check. Also, as there are no more natural scope ( if { } ) to hold local variables, paramters to do_psci_*() are taken right from SMC arguments, without storing in intermediate local variables. Signed-off-by: Volodymyr Babchuk Reviewed-by: Stefano Stabellini --- Now this patch removes { } blocks completely. Not sure if I had to split it into two separate patches. --- xen/arch/arm/vsmc.c | 45 ++++++++++----------------------------------- 1 file changed, 10 insertions(+), 35 deletions(-) diff --git a/xen/arch/arm/vsmc.c b/xen/arch/arm/vsmc.c index ea86eea..0fd4f5a 100644 --- a/xen/arch/arm/vsmc.c +++ b/xen/arch/arm/vsmc.c @@ -84,14 +84,6 @@ static bool handle_arch(struct cpu_user_regs *regs) return false; } -/* helper function for checking arm mode 32/64 bit */ -static inline int psci_mode_check(struct domain *d, register_t fid) -{ - return !( is_64bit_domain(d)^ - ((fid & (ARM_SMCCC_SMC_64 << ARM_SMCCC_CALL_CONV_SHIFT)) >> - ARM_SMCCC_CALL_CONV_SHIFT) ); -} - /* PSCI 2.0 interface */ static bool handle_ssc(struct cpu_user_regs *regs) { @@ -113,8 +105,7 @@ static bool handle_ssc(struct cpu_user_regs *regs) return true; case PSCI_0_2_FUNC_MIGRATE_INFO_UP_CPU: perfc_incr(vpsci_migrate_info_up_cpu); - if ( psci_mode_check(current->domain, fid) ) - PSCI_SET_RESULT(regs, do_psci_0_2_migrate_info_up_cpu()); + PSCI_SET_RESULT(regs, do_psci_0_2_migrate_info_up_cpu()); return true; case PSCI_0_2_FUNC_SYSTEM_OFF: perfc_incr(vpsci_system_off); @@ -128,40 +119,24 @@ static bool handle_ssc(struct cpu_user_regs *regs) return true; case PSCI_0_2_FUNC_CPU_ON: perfc_incr(vpsci_cpu_on); - if ( psci_mode_check(current->domain, fid) ) - { - register_t vcpuid = PSCI_ARG(regs,1); - register_t epoint = PSCI_ARG(regs,2); - register_t cid = PSCI_ARG(regs,3); - PSCI_SET_RESULT(regs, do_psci_0_2_cpu_on(vcpuid, epoint, cid)); - } + PSCI_SET_RESULT(regs, do_psci_0_2_cpu_on(PSCI_ARG(regs, 1), + PSCI_ARG(regs, 2), + PSCI_ARG(regs, 3))); return true; case PSCI_0_2_FUNC_CPU_SUSPEND: perfc_incr(vpsci_cpu_suspend); - if ( psci_mode_check(current->domain, fid) ) - { - uint32_t pstate = PSCI_ARG32(regs,1); - register_t epoint = PSCI_ARG(regs,2); - register_t cid = PSCI_ARG(regs,3); - PSCI_SET_RESULT(regs, do_psci_0_2_cpu_suspend(pstate, epoint, cid)); - } + PSCI_SET_RESULT(regs, do_psci_0_2_cpu_suspend(PSCI_ARG32(regs, 1), + PSCI_ARG(regs, 2), + PSCI_ARG(regs, 3))); return true; case PSCI_0_2_FUNC_AFFINITY_INFO: perfc_incr(vpsci_cpu_affinity_info); - if ( psci_mode_check(current->domain, fid) ) - { - register_t taff = PSCI_ARG(regs,1); - uint32_t laff = PSCI_ARG32(regs,2); - PSCI_SET_RESULT(regs, do_psci_0_2_affinity_info(taff, laff)); - } + PSCI_SET_RESULT(regs, do_psci_0_2_affinity_info(PSCI_ARG(regs, 1), + PSCI_ARG32(regs,2))); return true; case PSCI_0_2_FUNC_MIGRATE: perfc_incr(vpsci_cpu_migrate); - if ( psci_mode_check(current->domain, fid) ) - { - uint32_t tcpu = PSCI_ARG32(regs,1); - PSCI_SET_RESULT(regs, do_psci_0_2_migrate(tcpu)); - } + PSCI_SET_RESULT(regs, do_psci_0_2_migrate(PSCI_ARG32(regs, 1))); return true; case ARM_SMCCC_FUNC_CALL_COUNT: set_user_reg(regs, 0, SSC_SMCCC_FUNCTION_COUNT);