From patchwork Thu Jan 12 05:24:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Li kunyu X-Patchwork-Id: 42259 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp3708270wrt; Wed, 11 Jan 2023 21:37:33 -0800 (PST) X-Google-Smtp-Source: AMrXdXshC0ebH8/KrYwCMTqelh5HsLmAwWROQ8Wo65I+vyo2ap6MVAWpGibCOrRaGyqmWD5knT4P X-Received: by 2002:a17:906:3ac6:b0:84d:3928:66b6 with SMTP id z6-20020a1709063ac600b0084d392866b6mr14688558ejd.40.1673501853437; Wed, 11 Jan 2023 21:37:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673501853; cv=none; d=google.com; s=arc-20160816; b=lQNtqqr8lzo2hHiJ9X6tO2/6Ek7Q98E6odWC4SCi2AdigDFOus9K6bS4hWtXBwqcHT nns8u3xWzjjKsJhVdDOkBBbqVtFpoAwsgwwb6fXvtKolf7+KPVlpBs45vMUCqGySmyfa SLvryxCJAxByytSFpTFvgE0OrXz1QcJyV99HGk4hlsEWe1QeSM6OBqngnWN9/GQzYKIk oxvSkfZHNOKSYT8mYt2EKVNP+gFuYtuAKS9hRiNcszhBwxgsvMFI4LyqC9YfG6a80/Od ar1wlvJ1DdrSoujI8LApb9T1h+FXoEarx9/BYirbxXvx8gU/uTed9VFKhXwUjaE0kz6I oKhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=/MUOZwiRQEwGcEmtyAgLnelM5AvoFk6eefZdCtDaJlk=; b=FmvCkzduGmAguWD/qpf67IuATKgjQK2m+ZgqNNAExqI8m3Rby3oPbTs4qXH/uznb5H mviU6zj8Wgr/P4T3FqDYIKUwxpQAwuUNOzvHz5GAXAHonxRqBa6WNdTvMe9K5F55EYUc 1FHzzzJVq/zDtgqgKP2dQvvPNBfsYUS2H/e5WtAcEfhzes/1AKLePosNfBMjUc43+eYQ ZHIwpYi7eGpv+oyKIgB9pL+biIsdX35y/UFUZhYoNzJauXLCaVQ+UhDSiS8NsZTzNzee nzJRlGAVhxIwxy0Z88S43+TANVUM8Yr4+xt99rdBnqr9h7dSqZZ3qiuOCAIvJ4wxCoG2 myjA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id sb2-20020a1709076d8200b007ae84881ebasi17409923ejc.505.2023.01.11.21.37.09; Wed, 11 Jan 2023 21:37:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235489AbjALFZP (ORCPT + 99 others); Thu, 12 Jan 2023 00:25:15 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50508 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236520AbjALFY7 (ORCPT ); Thu, 12 Jan 2023 00:24:59 -0500 Received: from mail.nfschina.com (unknown [42.101.60.237]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1FD6A65C6; Wed, 11 Jan 2023 21:24:57 -0800 (PST) Received: from localhost (unknown [127.0.0.1]) by mail.nfschina.com (Postfix) with ESMTP id 906BF1A00A1C; Thu, 12 Jan 2023 13:25:11 +0800 (CST) X-Virus-Scanned: amavisd-new at nfschina.com Received: from mail.nfschina.com ([127.0.0.1]) by localhost (localhost.localdomain [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 38brvE-IQqH0; Thu, 12 Jan 2023 13:25:10 +0800 (CST) Received: from localhost.localdomain (unknown [219.141.250.2]) (Authenticated sender: kunyu@nfschina.com) by mail.nfschina.com (Postfix) with ESMTPA id 8B4461A00888; Thu, 12 Jan 2023 13:25:10 +0800 (CST) From: Li kunyu To: rafael@kernel.org, pavel@ucw.cz, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com Cc: x86@kernel.org, hpa@zytor.com, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Li kunyu Subject: [PATCH] power: hibernate: optimize function structure Date: Thu, 12 Jan 2023 13:24:53 +0800 Message-Id: <20230112052453.3365-1-kunyu@nfschina.com> X-Mailer: git-send-email 2.18.2 X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,RDNS_NONE, SPF_HELO_NONE,SPF_NONE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1754793879520142420?= X-GMAIL-MSGID: =?utf-8?q?1754793879520142420?= The goto statement jump is not required at the end of the if statement block, because it will be executed to the lower part of the goto statement. Signed-off-by: Li kunyu --- arch/x86/power/hibernate.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/x86/power/hibernate.c b/arch/x86/power/hibernate.c index 6f955eb1e163..936558c4e821 100644 --- a/arch/x86/power/hibernate.c +++ b/arch/x86/power/hibernate.c @@ -210,8 +210,6 @@ int arch_resume_nosmt(void) if (ret) goto out; ret = cpuhp_smt_disable(old); - if (ret) - goto out; } out: cpu_hotplug_disable();