Re: [PATCH net-next v3 14/47] net: phy: aquantia: Add support for rate adaptation

From
Andrew Lunn <andrew@lunn.ch>
Date
2022-07-16 18:38:31
Also in
linux-arm-kernel, lkml
Reply to
Sean Anderson, 2022-07-15
quoted hunk ↗ jump to hunk
+#define VEND1_GLOBAL_CFG_10M			0x0310
+#define VEND1_GLOBAL_CFG_100M			0x031b
+#define VEND1_GLOBAL_CFG_1G			0x031c
+#define VEND1_GLOBAL_CFG_2_5G			0x031d
+#define VEND1_GLOBAL_CFG_5G			0x031e
+#define VEND1_GLOBAL_CFG_10G			0x031f
I completely read this wrong the first time... The common meaning of
#defines line this is

VEND1_GLOBAL_CFG_ is the register and what follows indicates some bits
in the register.

However, this is not true here, these are all registers. Maybe add
_REG to the end? It makes them different to other defines for
registers, but if i parsed it wrong, probably other will as well?
quoted hunk ↗ jump to hunk
 static int aqr107_read_rate(struct phy_device *phydev)
 {
 	int val;
+	u32 config_reg;
Revere Christmass tree. config_reg should be first.

       Andrew
Thread (123 messages) 123 messages, 7 authors, last reply 2022-07-26
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help