From patchwork Sun Jan 22 16:41:28 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yongjun X-Patchwork-Id: 9531201 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 3418A60431 for ; Sun, 22 Jan 2017 16:43:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1B74527D9B for ; Sun, 22 Jan 2017 16:43:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1023327F8C; Sun, 22 Jan 2017 16:43:26 +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=-1.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=no version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id AE7D527D9B for ; Sun, 22 Jan 2017 16:43:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cVLEd-0005Sl-EJ; Sun, 22 Jan 2017 16:43:19 +0000 Received: from mail-pg0-f66.google.com ([74.125.83.66]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cVLEE-0005Lw-Hv for linux-arm-kernel@lists.infradead.org; Sun, 22 Jan 2017 16:42:56 +0000 Received: by mail-pg0-f66.google.com with SMTP id 75so11498870pgf.3 for ; Sun, 22 Jan 2017 08:42:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=sLrtkmC1qhP5zFqU9xdE68A96pRLzHFTxE3MJ99bskc=; b=IdUAuCr3TrW6fb9471giCR52NrjAyhR7T9CTHOP2vncUbphoZs6EQn4kQnQptrr+sX RLlB2KUyifU9tFtSSmX8cwlMV7eeey3TKS4c6QR6QxshgEpzDOx+Fyex0IVA9pi99os3 LlcxjbeGi3sGyHHnvuhEVTYzDSpdbIa+LO9t0NMvzMlF1rUkqdZ9R0A/7FPPDqskC7Jm e/0CTw4Ra3Ici6FDUXr3+rCgkQ3GV1xZE+vqyLoj3i/Or+4fDa0kbiCPAwjitXaY+RLU sZ2tlADbLwkmPRUmcxamIJ56PDJHqBSfeleUQtAzEYEtP8n9f7aEulO/PBFCKUtICVNO PVPQ== 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:mime-version :content-transfer-encoding; bh=sLrtkmC1qhP5zFqU9xdE68A96pRLzHFTxE3MJ99bskc=; b=YrQXitvYbBxD9Tfz0ivl280kk8HIRlvyFO3v0sbjKEkcCPK/mIhmiIo7JjQDvmrE/1 dKKf1G8oOfBdUEcBhQd63HeA1TW+EKTicWvli2aTJoJihYst4D6VPfp/Nj8r1mEOZ21u k9FwyIPBUk5ExZZ1b75R6ADfGadFONXj6yTtZogPvFs/yBsAdLCbIXBvI3jQKPIzelXz sn4oWPY4bba0xNnemql9EKiFzhzsbxGdo+1SW5tlppwL2gOnk7C23WetR7oLMX3YZEBH BHDF1SVApJnRY9Zu96dpJHdArEsbvZPkJERzeAJ2BVspsPMIsFKDQ+t6zkO8bfZ5re8S sHNg== X-Gm-Message-State: AIkVDXIz9lZbY8A+gte1VZR0HReYK5LCLqZOa93G30Wo8/M4u8HkNHOZ6Ywhn+jWZB8NtA== X-Received: by 10.98.19.145 with SMTP id 17mr18772786pft.26.1485103293185; Sun, 22 Jan 2017 08:41:33 -0800 (PST) Received: from localhost.localdomain.localdomain (ec2-52-192-197-227.ap-northeast-1.compute.amazonaws.com. [52.192.197.227]) by smtp.gmail.com with ESMTPSA id c18sm19343822pfj.49.2017.01.22.08.41.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 22 Jan 2017 08:41:32 -0800 (PST) From: Wei Yongjun To: Wei Xu , Russell King Subject: [PATCH -next] ARM: 8641/1: treewide: fix error return code in hip04_smp_init() Date: Sun, 22 Jan 2017 16:41:28 +0000 Message-Id: <20170122164128.29381-1-weiyj.lk@gmail.com> X-Mailer: git-send-email 2.9.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170122_084254_655283_E65379F6 X-CRM114-Status: UNSURE ( 9.66 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Wei Yongjun , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Wei Yongjun Fix to return error code -ENODEV from the of_find_compatible_node() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun --- arch/arm/mach-hisi/platmcpm.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/mach-hisi/platmcpm.c b/arch/arm/mach-hisi/platmcpm.c index a6c1176..f0fff21 100644 --- a/arch/arm/mach-hisi/platmcpm.c +++ b/arch/arm/mach-hisi/platmcpm.c @@ -279,6 +279,8 @@ static int __init hip04_smp_init(void) &hip04_boot_method[0], 4); if (ret) goto err; + + ret = -ENODEV; np_sctl = of_find_compatible_node(NULL, NULL, "hisilicon,sysctrl"); if (!np_sctl) goto err;