From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752834AbcHQKWq (ORCPT ); Wed, 17 Aug 2016 06:22:46 -0400 Received: from mail-wm0-f52.google.com ([74.125.82.52]:36264 "EHLO mail-wm0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752325AbcHQKWc (ORCPT ); Wed, 17 Aug 2016 06:22:32 -0400 From: Daniel Lezcano To: mingo@kernel.org Cc: tglx@linutronix.de, linux-kernel@vger.kernel.org, Paul Gortmaker , linux-mips@linux-mips.org Subject: [PATCH 3/3] clocksource/drivers/mips-gic-timer: Make gic_clocksource_of_init return int Date: Wed, 17 Aug 2016 12:21:35 +0200 Message-Id: <1471429296-9053-3-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1471429296-9053-1-git-send-email-daniel.lezcano@linaro.org> References: <57B439B0.8010901@linaro.org> <1471429296-9053-1-git-send-email-daniel.lezcano@linaro.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Paul Gortmaker In commit d8152bf85d2c057fc39c3e20a4d623f524d9f09c: ("clocksource/drivers/mips-gic-timer: Convert init function to return error") several return values were added to a void function resulting in: clocksource/mips-gic-timer.c: In function 'gic_clocksource_of_init': clocksource/mips-gic-timer.c:175:3: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c:183:4: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c:190:3: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c:195:3: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c:200:3: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c:211:2: warning: 'return' with a value, in function returning void [enabled by default] clocksource/mips-gic-timer.c: At top level: clocksource/mips-gic-timer.c:213:1: warning: comparison of distinct pointer types lacks a cast [enabled by default] clocksource/mips-gic-timer.c: In function 'gic_clocksource_of_init': clocksource/mips-gic-timer.c:183:18: warning: ignoring return value of 'PTR_ERR', declared with attribute warn_unused_result [-Wunused-result] Given that the addition of the return values was intentional, it seems that the conversion of the containing function from void to int was simply overlooked. Fixes: d8152bf85d2c ("clocksource/drivers/mips-gic-timer: Convert init function to return error") Cc: Daniel Lezcano Cc: linux-mips@linux-mips.org Signed-off-by: Paul Gortmaker Signed-off-by: Daniel Lezcano --- drivers/clocksource/mips-gic-timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clocksource/mips-gic-timer.c b/drivers/clocksource/mips-gic-timer.c index 1572c7a..2577a2f 100644 --- a/drivers/clocksource/mips-gic-timer.c +++ b/drivers/clocksource/mips-gic-timer.c @@ -176,7 +176,7 @@ void __init gic_clocksource_init(unsigned int frequency) gic_start_count(); } -static void __init gic_clocksource_of_init(struct device_node *node) +static int __init gic_clocksource_of_init(struct device_node *node) { struct clk *clk; int ret; -- 1.9.1