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


Groups > linux.kernel > #1463831

Re: [PATCH] clocksource: mips-gic-timer: make gic_clocksource_of_init return int

From Daniel Lezcano <daniel.lezcano@linaro.org>
Newsgroups linux.kernel
Subject Re: [PATCH] clocksource: mips-gic-timer: make gic_clocksource_of_init return int
Date 2016-08-16 16:00 +0200
Message-ID <s6N4m-3Ny-29@gated-at.bofh.it> (permalink)
References <s1cf7-Qb-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 08/01/2016 05:35 AM, Paul Gortmaker wrote:
> 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.
> 
> Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
> Cc: linux-mips@linux-mips.org
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> ---

Hi Paul,

Thomas is in vacation and I'm returning back.

So I applied this patch as a fix.

Thanks!

  -- Daniel


-- 
 <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

Re: [PATCH] clocksource: mips-gic-timer: make gic_clocksource_of_init  return int Daniel Lezcano <daniel.lezcano@linaro.org> - 2016-08-16 16:00 +0200

csiph-web