From patchwork Tue Oct 2 13:25:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kleber Sacilotto de Souza X-Patchwork-Id: 977849 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42PfzC4Cbjz9sj1; Tue, 2 Oct 2018 23:25:27 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1g7Kft-00088d-Gs; Tue, 02 Oct 2018 13:25:17 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.86_2) (envelope-from ) id 1g7Kfs-00088Q-8x for kernel-team@lists.ubuntu.com; Tue, 02 Oct 2018 13:25:16 +0000 Received: from mail-wr1-f71.google.com ([209.85.221.71]) by youngberry.canonical.com with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1g7Kfs-0006ET-1f for kernel-team@lists.ubuntu.com; Tue, 02 Oct 2018 13:25:16 +0000 Received: by mail-wr1-f71.google.com with SMTP id 93-v6so1737528wrb.2 for ; Tue, 02 Oct 2018 06:25:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=X2jSyiqsaz9g75QPq9qm0dDxpB+o8VUnc3HMD+hPNRw=; b=fqxvIJ6ebWsbeoCrYlu0UO1Iao9EkBALVemUwzfpa9ZtdRRlDfaijslYxF+5h3M94X 8GiChwFeGt96SIZplmcsdEzDQ2CiUZJMqeE+I+FVPDD0MFVZr7iWJD2QOK8JsXAPIA8b rh9w2TDqVgP/rrRYBZb58c7NihPoL3JttKuNxO8M16+2Ngoj1YQK0ctFU5DlyWm/Exwu kCVUxw3W3XxrGFP6Ovs5N0mBw2468tv0RBOJJghirufvPMad8l9cETslAtBMFZl/Yb07 3XFsYX3DXj6UPJESO51nnCq00fSYxhztLOIBOt0v0HuZ3zvUYdG7q9jnYFze8uSZHYXY piAw== X-Gm-Message-State: ABuFfohMJT7SutV/ZBoTx0WuCE6hH+MFN3pxIBWA/mj2O0HN8mI4m72Q q4TxRlTV8XxYV0/JR9NlGAk+iOZyPQ1pSCMdeq5jssKocwiTRFwzeqvgMVNQjnzjGGjCHMM8V5v u+chWd29NLVl+sLSiZ6IH8nSsQKJaOTjv+ytSJqHJAg== X-Received: by 2002:a7b:c151:: with SMTP id z17-v6mr1974285wmi.39.1538486715394; Tue, 02 Oct 2018 06:25:15 -0700 (PDT) X-Google-Smtp-Source: ACcGV60KlWCHJIRSfEbuh+R4UPfmKpVVtm3dviP3tgcYZ9TeDAWMEJORzzIiuAmw7P/XyT3/DUxETw== X-Received: by 2002:a7b:c151:: with SMTP id z17-v6mr1974266wmi.39.1538486715077; Tue, 02 Oct 2018 06:25:15 -0700 (PDT) Received: from localhost ([2a02:8109:98c0:1604:3540:adf5:d839:581a]) by smtp.gmail.com with ESMTPSA id u4-v6sm11060155wro.47.2018.10.02.06.25.13 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 02 Oct 2018 06:25:14 -0700 (PDT) From: Kleber Sacilotto de Souza To: kernel-team@lists.ubuntu.com Subject: [SRU][Xenial] UBUNTU: SAUCE: powerpc/fadump: fix wrong function return in the backport Date: Tue, 2 Oct 2018 15:25:12 +0200 Message-Id: <20181002132512.31330-1-kleber.souza@canonical.com> X-Mailer: git-send-email 2.17.1 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/1792419 The 4.4.y stable backport c9fadf27006b for upstream commit 1bd6a1c4b80a ("powerpc/fadump: handle crash memory ranges array index overflow") introduces a build failure on ppc by returning a int in a void function. In 4.4.y register_fadump() returns void because 98b8cd7f7564 ("powerpc/fadump: Return error when fadump registration fails") hasn't been backported for this stable release. Fixes: c9fadf27006b ("powerpc/fadump: handle crash memory ranges array index overflow") Signed-off-by: Kleber Sacilotto de Souza --- arch/powerpc/kernel/fadump.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/powerpc/kernel/fadump.c b/arch/powerpc/kernel/fadump.c index 4e71df4048a9..69c8090e5399 100644 --- a/arch/powerpc/kernel/fadump.c +++ b/arch/powerpc/kernel/fadump.c @@ -1001,7 +1001,6 @@ static void register_fadump(void) { unsigned long addr; void *vaddr; - int ret; /* * If no memory is reserved then we can not register for firmware- @@ -1010,9 +1009,8 @@ static void register_fadump(void) if (!fw_dump.reserve_dump_area_size) return; - ret = fadump_setup_crash_memory_ranges(); - if (ret) - return ret; + if (fadump_setup_crash_memory_ranges()) + return; addr = be64_to_cpu(fdm.rmr_region.destination_address) + be64_to_cpu(fdm.rmr_region.source_len); /* Initialize fadump crash info header. */