Commit a8ea8d5
net: ti: icssg-prueth: Split out common object into module
icssg_prueth.c and icssg_prueth_sr1.c drivers use multiple common .c
files. These common objects are getting added to multiple modules. As a
result when both drivers are enabled in .config, below warning is seen.
drivers/net/ethernet/ti/Makefile: icssg/icssg_common.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
drivers/net/ethernet/ti/Makefile: icssg/icssg_classifier.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
drivers/net/ethernet/ti/Makefile: icssg/icssg_config.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
drivers/net/ethernet/ti/Makefile: icssg/icssg_mii_cfg.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
drivers/net/ethernet/ti/Makefile: icssg/icssg_stats.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
drivers/net/ethernet/ti/Makefile: icssg/icssg_ethtool.o is added to multiple modules: icssg-prueth icssg-prueth-sr1
Fix this by building a new module (icssg.o) for all the common objects.
Both the driver can then depend on this common module.
Some APIs being exported have emac_ as the prefix which may result into
confusion with other existing APIs with emac_ prefix, to avoid
confusion, rename the APIs being exported with emac_ to icssg_ prefix.
This also fixes below error seen when both drivers are built.
ERROR: modpost: "icssg_queue_pop"
[drivers/net/ethernet/ti/icssg-prueth-sr1.ko] undefined!
ERROR: modpost: "icssg_queue_push"
[drivers/net/ethernet/ti/icssg-prueth-sr1.ko] undefined!
Reported-and-tested-by: Thorsten Leemhuis <linux@leemhuis.info>
Closes: https://lore.kernel.org/oe-kbuild-all/202405182038.ncf1mL7Z-lkp@intel.com/
Fixes: 487f732 ("net: ti: icssg-prueth: Add helper functions to configure FDB")
Reviewed-by: Roger Quadros <rogerq@kernel.org>
Signed-off-by: MD Danish Anwar <danishanwar@ti.com>
Reviewed-by: Sai Krishna <saikrishnag@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>1 parent f8321fa commit a8ea8d5
12 files changed
Lines changed: 122 additions & 69 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
52 | 48 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
| 300 | + | |
300 | 301 | | |
301 | 302 | | |
302 | 303 | | |
| |||
360 | 361 | | |
361 | 362 | | |
362 | 363 | | |
| 364 | + | |
363 | 365 | | |
364 | 366 | | |
365 | 367 | | |
| |||
390 | 392 | | |
391 | 393 | | |
392 | 394 | | |
| 395 | + | |
393 | 396 | | |
394 | 397 | | |
395 | 398 | | |
| |||
408 | 411 | | |
409 | 412 | | |
410 | 413 | | |
| 414 | + | |
411 | 415 | | |
412 | 416 | | |
413 | 417 | | |
| |||
449 | 453 | | |
450 | 454 | | |
451 | 455 | | |
| 456 | + | |
452 | 457 | | |
453 | 458 | | |
454 | 459 | | |
| |||
460 | 465 | | |
461 | 466 | | |
462 | 467 | | |
| 468 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
71 | 72 | | |
72 | 73 | | |
73 | 74 | | |
| 75 | + | |
74 | 76 | | |
75 | 77 | | |
76 | 78 | | |
| |||
84 | 86 | | |
85 | 87 | | |
86 | 88 | | |
| 89 | + | |
87 | 90 | | |
88 | 91 | | |
89 | 92 | | |
| |||
120 | 123 | | |
121 | 124 | | |
122 | 125 | | |
| 126 | + | |
123 | 127 | | |
124 | 128 | | |
125 | 129 | | |
| |||
264 | 268 | | |
265 | 269 | | |
266 | 270 | | |
| 271 | + | |
267 | 272 | | |
268 | 273 | | |
269 | 274 | | |
| |||
344 | 349 | | |
345 | 350 | | |
346 | 351 | | |
| 352 | + | |
347 | 353 | | |
348 | 354 | | |
349 | 355 | | |
| |||
453 | 459 | | |
454 | 460 | | |
455 | 461 | | |
| 462 | + | |
456 | 463 | | |
457 | 464 | | |
458 | 465 | | |
| |||
490 | 497 | | |
491 | 498 | | |
492 | 499 | | |
| 500 | + | |
493 | 501 | | |
494 | 502 | | |
495 | 503 | | |
| |||
505 | 513 | | |
506 | 514 | | |
507 | 515 | | |
| 516 | + | |
508 | 517 | | |
509 | 518 | | |
510 | 519 | | |
| |||
636 | 645 | | |
637 | 646 | | |
638 | 647 | | |
639 | | - | |
| 648 | + | |
640 | 649 | | |
641 | 650 | | |
642 | 651 | | |
| |||
647 | 656 | | |
648 | 657 | | |
649 | 658 | | |
650 | | - | |
| 659 | + | |
651 | 660 | | |
652 | 661 | | |
653 | 662 | | |
| |||
806 | 815 | | |
807 | 816 | | |
808 | 817 | | |
| 818 | + | |
809 | 819 | | |
810 | 820 | | |
811 | 821 | | |
| |||
831 | 841 | | |
832 | 842 | | |
833 | 843 | | |
| 844 | + | |
834 | 845 | | |
835 | 846 | | |
836 | 847 | | |
| |||
855 | 866 | | |
856 | 867 | | |
857 | 868 | | |
| 869 | + | |
858 | 870 | | |
859 | 871 | | |
860 | 872 | | |
| |||
867 | 879 | | |
868 | 880 | | |
869 | 881 | | |
| 882 | + | |
870 | 883 | | |
871 | | - | |
| 884 | + | |
872 | 885 | | |
873 | 886 | | |
874 | 887 | | |
| |||
905 | 918 | | |
906 | 919 | | |
907 | 920 | | |
| 921 | + | |
908 | 922 | | |
909 | 923 | | |
910 | 924 | | |
| |||
930 | 944 | | |
931 | 945 | | |
932 | 946 | | |
| 947 | + | |
933 | 948 | | |
934 | 949 | | |
935 | 950 | | |
| |||
944 | 959 | | |
945 | 960 | | |
946 | 961 | | |
| 962 | + | |
947 | 963 | | |
948 | 964 | | |
949 | 965 | | |
| |||
956 | 972 | | |
957 | 973 | | |
958 | 974 | | |
| 975 | + | |
959 | 976 | | |
960 | | - | |
| 977 | + | |
961 | 978 | | |
962 | 979 | | |
963 | 980 | | |
| 981 | + | |
964 | 982 | | |
965 | 983 | | |
966 | 984 | | |
| |||
1024 | 1042 | | |
1025 | 1043 | | |
1026 | 1044 | | |
1027 | | - | |
| 1045 | + | |
1028 | 1046 | | |
1029 | 1047 | | |
1030 | 1048 | | |
| |||
1037 | 1055 | | |
1038 | 1056 | | |
1039 | 1057 | | |
| 1058 | + | |
1040 | 1059 | | |
1041 | | - | |
1042 | | - | |
| 1060 | + | |
| 1061 | + | |
1043 | 1062 | | |
1044 | 1063 | | |
1045 | 1064 | | |
| |||
1058 | 1077 | | |
1059 | 1078 | | |
1060 | 1079 | | |
| 1080 | + | |
1061 | 1081 | | |
1062 | | - | |
1063 | | - | |
| 1082 | + | |
| 1083 | + | |
1064 | 1084 | | |
1065 | 1085 | | |
1066 | 1086 | | |
| |||
1071 | 1091 | | |
1072 | 1092 | | |
1073 | 1093 | | |
| 1094 | + | |
1074 | 1095 | | |
1075 | 1096 | | |
1076 | 1097 | | |
| |||
1089 | 1110 | | |
1090 | 1111 | | |
1091 | 1112 | | |
| 1113 | + | |
1092 | 1114 | | |
1093 | 1115 | | |
1094 | 1116 | | |
| |||
1107 | 1129 | | |
1108 | 1130 | | |
1109 | 1131 | | |
| 1132 | + | |
1110 | 1133 | | |
1111 | 1134 | | |
1112 | 1135 | | |
| |||
1132 | 1155 | | |
1133 | 1156 | | |
1134 | 1157 | | |
| 1158 | + | |
1135 | 1159 | | |
1136 | 1160 | | |
1137 | 1161 | | |
| |||
1182 | 1206 | | |
1183 | 1207 | | |
1184 | 1208 | | |
| 1209 | + | |
1185 | 1210 | | |
1186 | 1211 | | |
1187 | 1212 | | |
| |||
1194 | 1219 | | |
1195 | 1220 | | |
1196 | 1221 | | |
| 1222 | + | |
1197 | 1223 | | |
1198 | 1224 | | |
1199 | 1225 | | |
| |||
1250 | 1276 | | |
1251 | 1277 | | |
1252 | 1278 | | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
0 commit comments