staging: omap-thermal: refactor APIs handling threshold values
authorEduardo Valentin <eduardo.valentin@ti.com>
Fri, 15 Mar 2013 13:00:21 +0000 (09:00 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Mar 2013 16:02:23 +0000 (09:02 -0700)
commit56f132f78e9ee6c45b3197290733aed1fd6eeafc
treeed236869534c4c1cda533ccd1fcb5528c927e482
parentf47f6d31645c5020602469cafa1e6c8a228dcaab
staging: omap-thermal: refactor APIs handling threshold values

This patch improves the code that handles threshold values
by creating single functions that are usable for tcold and
thot. This way we won't have duplicated functionality just
because it is handling different bitfields. Now
the added functions are reused in several places where
it is needed to update any threshold.

This patch also removes macros that are used only inside
the _validate helper function.

In this patch there is also an addition of an extra function
section for Exposed APIs, used outside the omap-bandgap.c,
but inside the omap-thermal driver.

Signed-off-by: Eduardo Valentin <eduardo.valentin@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/omap-thermal/omap-bandgap.c