Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756837Ab3HGIg0 (ORCPT ); Wed, 7 Aug 2013 04:36:26 -0400 Received: from mailout2.samsung.com ([203.254.224.25]:65232 "EHLO mailout2.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756619Ab3HGIgW (ORCPT ); Wed, 7 Aug 2013 04:36:22 -0400 X-AuditID: cbfee68e-b7f276d000002279-98-52020704d8ef From: Naveen Krishna Chatradhi To: linux-pm@vger.kernel.org, rui.zhang@intel.com, eduardo.valentin@ti.com Cc: linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org, amit.daniel@samsung.com, kgene.kim@samsung.com Subject: [PATCH] thermal: exynos_tmu: fix wrong error check for mapped memory Date: Wed, 07 Aug 2013 14:01:09 +0530 Message-id: <1375864269-9197-1-git-send-email-ch.naveen@samsung.com> X-Mailer: git-send-email 1.7.9.5 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrBLMWRmVeSWpSXmKPExsWyRsSkTpeFnSnI4NVvGYuGqyEWa/b/ZLLo XXCVzeLyrjlsFp97jzBazDi/j8niycM+Ngd2j8V7XjJ59G1Zxehx/MZ2Jo/Pm+QCWKK4bFJS czLLUov07RK4Mp68/85asIStom3hAZYGxiWsXYycHBICJhJ925YyQdhiEhfurWfrYuTiEBJY yiix8tUuRpiiCxPWs0IkpjNKLJh0nRHC6WGS2HNiDjtIFZuAmcTBRavBbBEBL4lZD6+CjWUW KJV4uPMX2DphAV+JNZ2f2UBsFgFViR0PP4PV8Aq4SKzb+hyolwNom4LEnEk2IPMlBL6zSfy4 cpERol5A4tvkQywQNbISmw4wQxwnKXFwxQ2WCYyCCxgZVjGKphYkFxQnpRcZ6RUn5haX5qXr JefnbmIEhurpf8/6djDePGB9iDEZaNxEZinR5HxgqOeVxBsamxlZmJqYGhuZW5qRJqwkzqvW Yh0oJJCeWJKanZpakFoUX1Sak1p8iJGJg1OqgTF7zdvGW3eO8zs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X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1025 Lines: 29 The error check is checking for a "base" mapped memory base instead of "base_common". Fixing the same. Signed-off-by: Naveen Krishna Chatradhi --- drivers/thermal/samsung/exynos_tmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index ec01dfe..a033dbb 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c @@ -592,7 +592,7 @@ static int exynos_map_dt_data(struct platform_device *pdev) data->base_common = devm_ioremap(&pdev->dev, res.start, resource_size(&res)); - if (!data->base) { + if (!data->base_common) { dev_err(&pdev->dev, "Failed to ioremap memory\n"); return -ENOMEM; } -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/