summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2023-11-28 19:50:27 +0200
committerJakub Kicinski <kuba@kernel.org>2023-11-29 20:12:17 -0800
commit4b86d7c64e8f69824b9b2cc0e9b72842ac2d0e62 (patch)
tree79a966fcfbee536bd91b29dcf9cfd2b3ddb4c621
parent5de7796dffcde224eba00d05fe030e2b99d286fa (diff)
downloadlinux-stable-4b86d7c64e8f69824b9b2cc0e9b72842ac2d0e62.tar.gz
linux-stable-4b86d7c64e8f69824b9b2cc0e9b72842ac2d0e62.tar.bz2
linux-stable-4b86d7c64e8f69824b9b2cc0e9b72842ac2d0e62.zip
net: dsa: sja1105: Use units.h instead of the copy of a definition
BYTES_PER_KBIT is defined in units.h, use that definition. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com> Link: https://lore.kernel.org/r/20231128175027.394754-1-andriy.shevchenko@linux.intel.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
-rw-r--r--drivers/net/dsa/sja1105/sja1105_main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/dsa/sja1105/sja1105_main.c b/drivers/net/dsa/sja1105/sja1105_main.c
index 74cee39d73df..6646f7fb0f90 100644
--- a/drivers/net/dsa/sja1105/sja1105_main.c
+++ b/drivers/net/dsa/sja1105/sja1105_main.c
@@ -21,6 +21,8 @@
#include <linux/if_bridge.h>
#include <linux/if_ether.h>
#include <linux/dsa/8021q.h>
+#include <linux/units.h>
+
#include "sja1105.h"
#include "sja1105_tas.h"
@@ -2138,7 +2140,6 @@ static void sja1105_bridge_leave(struct dsa_switch *ds, int port,
sja1105_bridge_member(ds, port, bridge, false);
}
-#define BYTES_PER_KBIT (1000LL / 8)
/* Port 0 (the uC port) does not have CBS shapers */
#define SJA1110_FIXED_CBS(port, prio) ((((port) - 1) * SJA1105_NUM_TC) + (prio))