diff options
author | Miquel Raynal <miquel.raynal@bootlin.com> | 2021-10-15 11:14:46 +0300 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2021-10-21 11:15:56 +0300 |
commit | e967b60eb51116d2347093655e555aa036dd40d8 (patch) | |
tree | 5acc23ce9caa94d4e6855f237708548ff7a86a7f /include/linux/mfd | |
parent | b7cb7bf11817129c623fa921a1d6cd86b3cb727b (diff) | |
download | linux-e967b60eb51116d2347093655e555aa036dd40d8.tar.xz |
mfd: ti_am335x_tscadc: Clarify the maximum values for DT entries
Clearly define the maximum open delay and sample delay. Use these
definitions in place of a mask (which works because this is the first
field in the register) and an open-coded value. While at it reword a
little bit the error messages to make them look clearer and similar.
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Link: https://lore.kernel.org/r/20211015081506.933180-29-miquel.raynal@bootlin.com
Diffstat (limited to 'include/linux/mfd')
-rw-r--r-- | include/linux/mfd/ti_am335x_tscadc.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/mfd/ti_am335x_tscadc.h b/include/linux/mfd/ti_am335x_tscadc.h index ae694fa2d711..31cffb6e8b17 100644 --- a/include/linux/mfd/ti_am335x_tscadc.h +++ b/include/linux/mfd/ti_am335x_tscadc.h @@ -84,7 +84,9 @@ #define STEPCONFIG_OPENDLY STEPDELAY_OPEN(0x098) #define STEPDELAY_SAMPLE_MASK GENMASK(31, 24) #define STEPDELAY_SAMPLE(val) FIELD_PREP(STEPDELAY_SAMPLE_MASK, (val)) +#define STEPCONFIG_MAX_OPENDLY GENMASK(17, 0) #define STEPCONFIG_SAMPLEDLY STEPDELAY_SAMPLE(0) +#define STEPCONFIG_MAX_SAMPLE GENMASK(7, 0) /* Charge Config */ #define STEPCHARGE_RFP_MASK GENMASK(14, 12) |