clk: meson: fix SET_PARM macro
parameter val is not enclosed in parenthesis which is buggy when given an expression instead of a simple value Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Reviewed-by: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Michael Turquette <mturquette@baylibre.com> Link: lkml.kernel.org/r/20170309104154.28295-2-jbrunet@baylibre.com
This commit is contained in:
parent
c1ae3cfa0e
commit
1ddfe82ed8
|
@ -25,7 +25,7 @@
|
|||
#define PARM_GET(width, shift, reg) \
|
||||
(((reg) & SETPMASK(width, shift)) >> (shift))
|
||||
#define PARM_SET(width, shift, reg, val) \
|
||||
(((reg) & CLRPMASK(width, shift)) | (val << (shift)))
|
||||
(((reg) & CLRPMASK(width, shift)) | ((val) << (shift)))
|
||||
|
||||
#define MESON_PARM_APPLICABLE(p) (!!((p)->width))
|
||||
|
||||
|
|
Loading…
Reference in New Issue