Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1396403

[PATCH] clk: samsung: exynos5420: Remove useless check for return value of samsung_clk_init

Path csiph.com!aioe.org!bofh.it!news.nic.it!robomod
From Krzysztof Kozlowski <krzk@kernel.org>
Newsgroups linux.kernel
Subject [PATCH] clk: samsung: exynos5420: Remove useless check for return value of samsung_clk_init
Date Sun, 08 May 2016 11:30:01 +0200
Message-ID <rwtcd-424-5@gated-at.bofh.it> (permalink)
X-Original-To Sylwester Nawrocki <s.nawrocki@samsung.com>, Tomasz Figa <tomasz.figa@gmail.com>, Michael Turquette <mturquette@baylibre.com>, Stephen Boyd <sboyd@codeaurora.org>, Kukjin Kim <kgene@kernel.org>, Krzysztof Kozlowski <k.kozlowski@samsung.com>, linux-samsung-soc@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org
X-Mailer git-send-email 2.5.0
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 23
Organization linux.* mail to news gateway
X-Original-Cc Krzysztof Kozlowski <krzk@kernel.org>
X-Original-Date Sun, 8 May 2016 11:24:56 +0200
X-Original-Message-ID <1462699496-16646-1-git-send-email-krzk@kernel.org>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1396403

Show key headers only | View raw


The samsung_clk_init() cannot return NULL. Either it returns allocated
memory or it panics.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 drivers/clk/samsung/clk-exynos5420.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/clk/samsung/clk-exynos5420.c b/drivers/clk/samsung/clk-exynos5420.c
index 92382cef9f90..770c0f007c6b 100644
--- a/drivers/clk/samsung/clk-exynos5420.c
+++ b/drivers/clk/samsung/clk-exynos5420.c
@@ -1356,8 +1356,6 @@ static void __init exynos5x_clk_init(struct device_node *np,
 	exynos5x_soc = soc;
 
 	ctx = samsung_clk_init(np, reg_base, CLK_NR_CLKS);
-	if (!ctx)
-		panic("%s: unable to allocate context.\n", __func__);
 
 	samsung_clk_of_register_fixed_ext(ctx, exynos5x_fixed_rate_ext_clks,
 			ARRAY_SIZE(exynos5x_fixed_rate_ext_clks),
-- 
2.5.0

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH] clk: samsung: exynos5420: Remove useless check for return value of samsung_clk_init Krzysztof Kozlowski <krzk@kernel.org> - 2016-05-08 11:30 +0200
  Re: [PATCH] clk: samsung: exynos5420: Remove useless check for return  value of samsung_clk_init Javier Martinez Canillas <javier@osg.samsung.com> - 2016-05-09 15:40 +0200
    Re: [PATCH] clk: samsung: exynos5420: Remove useless check for  return value of samsung_clk_init Krzysztof Kozlowski <krzk@kernel.org> - 2016-05-09 19:40 +0200

csiph-web