qca8k: enable port flow control
Subsystems (4)
PATCH 1/1 qca8k: enable port flow control
Set phy device advertising to enable MAC flow control.
--- drivers/net/dsa/qca8k.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/net/dsa/qca8k.c +3 -1
@@ -1,7 +1,7 @@/* * Copyright (C) 2009 Felix Fietkau <[email protected]> * Copyright (C) 2011-2012 Gabor Juhos <[email protected]> -* Copyright (c) 2015, The Linux Foundation. All rights reserved. +* Copyright (c) 2015, 2019, The Linux Foundation. All rights reserved. * Copyright (c) 2016 John Crispin <[email protected]> * * This program is free software; you can redistribute it and/or modify
@@ -800,6 +800,8 @@qca8k_port_set_status (priv, port,1 ); priv->port_sts[port].enabled =1 ; + phy->advertising |= (ADVERTISED_Pause | ADVERTISED_Asym_Pause); +return 0 ; }
Signature · 1 line
1.9.1
Quoted 1 line · xiaofeis
Set phy device advertising to enable MAC flow control.
How about:
to Pause for enabling MAC flow control
Quoted 2 lines
Change-Id: Ibf0f554b072fc73136ec9f7ffb90c20b25a4faae
Please remove this
Quoted 29 lines
Signed-off-by Xiaofei Shen <[email protected]>--- drivers/net/dsa/qca8k.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)drivers/net/dsa/qca8k.c +3
-1@@ -1,7 +1,7 @@/* * Copyright (C) 2009 Felix Fietkau <[email protected]> * Copyright (C) 2011-2012 Gabor Juhos <[email protected]> -* Copyright (c) 2015, The Linux Foundation. All rights reserved. +* Copyright (c) 2015, 2019, The Linux Foundation. All rights reserved. * Copyright (c) 2016 John Crispin <[email protected]> * * This program is free software; you can redistribute it and/or modify @@ -800,6 +800,8 @@qca8k_port_set_status (priv, port,1 ); priv->port_sts[port].enabled =1 ; + phy->advertising |= (ADVERTISED_Pause | ADVERTISED_Asym_Pause); +return 0 ; }Signature · 1 line
1.9.1
Signature · 1 line
~Vinod
Quoted 22 lines · xiaofeis
Set phy device advertising to enable MAC flow control.
Change-Id Ibf0f554b072fc73136ec9f7ffb90c20b25a4faaeSigned-off-by Xiaofei Shen <[email protected]>--- drivers/net/dsa/qca8k.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)drivers/net/dsa/qca8k.c +1
-1@@ -1,7 +1,7 @@/* * Copyright (C) 2009 Felix Fietkau <[email protected]> * Copyright (C) 2011-2012 Gabor Juhos <[email protected]> -* Copyright (c) 2015, The Linux Foundation. All rights reserved. +* Copyright (c) 2015, 2019, The Linux Foundation. All rights reserved. * Copyright (c) 2016 John Crispin <[email protected]> * * This program is free software; you can redistribute it and/or modify
drivers/net/dsa/qca8k.c line 803
Quoted 4 lines
drivers/net/dsa/qca8k.c +1
-0@@ -800,6 +800,8 @@qca8k_port_set_status (priv, port,1 ); priv->port_sts[port].enabled =1 ; + phy->advertising |= (ADVERTISED_Pause | ADVERTISED_Asym_Pause);
Drop the unnecessary parentheses.
Question for DSA maintainers: shouldn't this be implemented in the dsa_switch_ops phylink_validate callback, like it's done for other dsa drivers?
Kind regards,
Niklas
Quoted 7 lines
drivers/net/dsa/qca8k.c +1
-0+return 0 ; }Signature · 1 line
1.9.1
Andrew Lunn
maintainerQuoted 4 lines · xiaofeis
Set phy device advertising to enable MAC flow control.
Change-Id Ibf0f554b072fc73136ec9f7ffb90c20b25a4faaeSigned-off-by Xiaofei Shen <[email protected]>
Hi Xiaofei
What tree is this patch against? I don't think it is net-next. It actually looks to be an old tree. Please rebase to David Millers net-next. Patches to that tree are closed at the moment, due to the merge window. You can post an RFC, or wait until it opens again.
Thanks
Andrew
Andrew Lunn
maintainerQuoted 3 lines
Question for DSA maintainers: shouldn't this be implemented in the
dsa_switch_opsphylink_validatecallback, like it's done for other dsa drivers?
Hi Niklas
qca8K is still using phylib, not phylink. So the validate callback cannot be used.
Andrew
Hi Andrew
Thanks for your comments. I have sent a new patch based on net-next tree.
Thanks
Xiaofeis
Quoted 15 lines · Andrew Lunn
Quoted 4 lines · xiaofeis
Set phy device advertising to enable MAC flow control.
Change-Id Ibf0f554b072fc73136ec9f7ffb90c20b25a4faaeSigned-off-by Xiaofei Shen <[email protected]>Hi Xiaofei
What tree is this patch against? I don't think it is net-next. It actually looks to be an old tree. Please rebase to David Millers net-next. Patches to that tree are closed at the moment, due to the merge window. You can post an RFC, or wait until it opens again.
Thanks
Andrew