[PATCH 05/13] thermal: inline only once used function

Sascha Hauer s.hauer at pengutronix.de
Tue Apr 14 03:44:47 PDT 2015


On Mon, Apr 06, 2015 at 07:23:08PM -0700, Eduardo Valentin wrote:
> On Thu, Mar 26, 2015 at 04:53:52PM +0100, Sascha Hauer wrote:
> > Inline update_temperature into its only caller to make the code
> > more readable.
> 
> I am not sure I understand how this is improving readability, can you
> please elaborate?

It improves readability because the reader does not have to lookup the
definition of update_temperature but can instead just read through. The
function name "update_temperature" does not give new information either,
so I thought inlining the code is a good idea. Anyway, I can skip this
patch if you want.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



More information about the linux-arm-kernel mailing list