Commit 36ba7ca8 authored by Nathan Howard's avatar Nathan Howard Committed by Greg Kroah-Hartman

staging: bcm2835-audio: bcm2835.h: fix macro coding style issue

Fix checkpatch.pl warning of the form "CHECK: Macro argument 'vol' may be
better as '(vol)' to avoid precedence issues."
Signed-off-by: default avatarNathan Howard <adanhawthorn@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 1e26728d
......@@ -77,8 +77,11 @@ enum {
/* macros for alsa2chip and chip2alsa, instead of functions */
#define alsa2chip(vol) (uint)(-((vol << 8) / 100)) /* convert alsa to chip volume (defined as macro rather than function call) */
#define chip2alsa(vol) -((vol * 100) >> 8) /* convert chip to alsa volume */
// convert alsa to chip volume (defined as macro rather than function call)
#define alsa2chip(vol) (uint)(-(((vol) << 8) / 100))
// convert chip to alsa volume
#define chip2alsa(vol) -(((vol) * 100) >> 8)
/* Some constants for values .. */
enum snd_bcm2835_route {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment