Thread (19 messages) 19 messages, 2 authors, 2026-06-02

Re: [PATCH net-next 7/9] net: dsa: microchip: implement port_hsr_join for KSZ9477 only

From: Bastien Curutchet <hidden>
Date: 2026-06-02 12:35:32
Also in: lkml

Hi Paolo,

On 6/1/26 11:03 AM, Paolo Abeni wrote:
On 5/26/26 11:47 AM, Bastien Curutchet (Schneider Electric) wrote:
quoted
@@ -1744,12 +1784,20 @@ void ksz9477_hsr_join(struct dsa_switch *ds, int port, struct net_device *hsr)
  	/* Setup HW supported features for lan HSR ports */
  	user = dsa_to_port(ds, port)->user;
  	user->features |= KSZ9477_SUPPORTED_HSR_FEATURES;
+
+	dev->hsr_dev = hsr;
+	dev->hsr_ports |= BIT(port);
+
+	return 0;
  }
  
-void ksz9477_hsr_leave(struct dsa_switch *ds, int port, struct net_device *hsr)
+static int ksz9477_hsr_leave(struct dsa_switch *ds, int port,
+			     struct net_device *hsr)
  {
  	struct ksz_device *dev = ds->priv;
  
+	WARN_ON(dev->chip_id != KSZ9477_CHIP_ID);
Since the new op is used only by the relevant switch version, I think
you could/should remove the above warning.
Ack, will do.


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