Thread (36 messages) 36 messages, 4 authors, 2020-05-05

Re: [PATCH net-next v2 07/10] net: ethtool: Add helpers for reporting test results

From: Andrew Lunn <andrew@lunn.ch>
Date: 2020-05-05 13:22:09

quoted
+int ethnl_cable_test_fault_length(struct phy_device *phydev, u8 pair, u32 cm)
+{
+	struct nlattr *nest;
+	int ret = -EMSGSIZE;
+
+	nest = nla_nest_start(phydev->skb,
+			      ETHTOOL_A_CABLE_TEST_NTF_FAULT_LENGTH);
+	if (!nest)
+		return -EMSGSIZE;
+
+	if (nla_put_u8(phydev->skb, ETHTOOL_A_CABLE_FAULT_LENGTH_PAIR, pair))
+		goto err;
+	if (nla_put_u16(phydev->skb, ETHTOOL_A_CABLE_FAULT_LENGTH_CM, cm))
+		goto err;
This should be nla_put_u32().
Yes. I think i messed up a rebase merge conflict somewhere. I'm also
surprised user space is not complaining.

	  Andrew
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help