Prepare for the advent of globally available common field_get() and
field_prep() macros by undefining the symbols before defining local
variants.  This prevents redefinition warnings from the C preprocessor
when introducing the common macros later.

Signed-off-by: Mikhail Kshevetskiy <[email protected]>
---
 drivers/net/hifemac.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/hifemac.c b/drivers/net/hifemac.c
index 62182f922f8..a64665c4023 100644
--- a/drivers/net/hifemac.c
+++ b/drivers/net/hifemac.c
@@ -402,6 +402,7 @@ static void hisi_femac_get_strings(struct udevice *dev, u8 
*data)
 }
 
 /* Non-constant mask variant of FIELD_GET/FIELD_PREP */
+#undef field_get
 #define field_get(_mask, _reg) (((_reg) & (_mask)) >> (ffs(_mask) - 1))
 
 static void hisi_femac_get_stats(struct udevice *dev, u64 *data)
-- 
2.53.0

Reply via email to