From: Geert Uytterhoeven Date: Thu, 6 Nov 2025 13:33:53 +0000 (+0100) Subject: iio: dac: ad3530r: #undef field_prep() before local definition X-Git-Tag: v6.19-rc1~87^2~24 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=27856d2b2b0f259ba261a3e3e028cc75a70ae817;p=thirdparty%2Flinux.git iio: dac: ad3530r: #undef field_prep() before local definition Prepare for the advent of a globally available common field_prep() macro by undefining the symbol before defining a local variant. This prevents redefinition warnings from the C preprocessor when introducing the common macro later. Suggested-by: Yury Norov Signed-off-by: Geert Uytterhoeven Acked-by: Jonathan Cameron Signed-off-by: Yury Norov (NVIDIA) --- diff --git a/drivers/iio/dac/ad3530r.c b/drivers/iio/dac/ad3530r.c index 6134613777b8e..5684d11137f29 100644 --- a/drivers/iio/dac/ad3530r.c +++ b/drivers/iio/dac/ad3530r.c @@ -54,6 +54,7 @@ #define AD3531R_MAX_CHANNELS 4 /* Non-constant mask variant of FIELD_PREP() */ +#undef field_prep #define field_prep(_mask, _val) (((_val) << (ffs(_mask) - 1)) & (_mask)) enum ad3530r_mode {