[PATCH 1/3] net: dsa: Use true instead of 1 in the set_promisc() call

Bin Meng bmeng.cn at gmail.com
Wed Sep 29 07:50:44 CEST 2021


set_promisc() call accepts the parameter of a bool type. Make it
clear by using true instead of 1.

Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
---

 net/dsa-uclass.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/dsa-uclass.c b/net/dsa-uclass.c
index 694664d81b..dcefec03f4 100644
--- a/net/dsa-uclass.c
+++ b/net/dsa-uclass.c
@@ -282,7 +282,7 @@ static int dsa_port_probe(struct udevice *pdev)
 		struct eth_ops *eth_ops = eth_get_ops(master);
 
 		if (eth_ops->set_promisc)
-			eth_ops->set_promisc(master, 1);
+			eth_ops->set_promisc(master, true);
 
 		return 0;
 	}
-- 
2.25.1



More information about the U-Boot mailing list