32ad7444f9
Adding platform support for centec v682-48y8c_d. Why I did it Adding platform support for centec v682-48y8c_d. This switch has 48 SFP+ (1G/10G/25G) ports, 8 QSFP28 (40G/100G) ports on CENTEC TsingMa.MX. CPU used in v682-48y8c_d is Intel(R) Xeon(R) CPU D-1527. How I did it Modify related code in platform and device directory. Upgrade sai to v1.8. fix bug for parallel compile centec platform modules. How to verify it Build centec amd64 sonic image, verify platform functions (port, sfp, led etc) on centec v682-48y8c_d board. Co-authored-by: Shi Lei <shil@centecnetworks.com>
43 lines
1.3 KiB
Makefile
Executable File
43 lines
1.3 KiB
Makefile
Executable File
#!/usr/bin/make -f
|
|
|
|
export INSTALL_MOD_DIR:=extra
|
|
|
|
KVERSION ?= $(shell uname -r)
|
|
KERNEL_SRC := /lib/modules/$(KVERSION)
|
|
MOD_SRC_DIR:= $(shell pwd)
|
|
MODULE_DIRS:= 48x6q 48x2q4z
|
|
|
|
%:
|
|
dh $@
|
|
|
|
override_dh_auto_build:
|
|
(for mod in $(MODULE_DIRS); do \
|
|
make -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/$${mod}/modules; \
|
|
done)
|
|
rm $(MOD_SRC_DIR)/centec-dal -rf
|
|
cp $(MOD_SRC_DIR)/../centec-dal $(MOD_SRC_DIR)/centec-dal -rf
|
|
make -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/centec-dal
|
|
|
|
override_dh_auto_install:
|
|
(for mod in $(MODULE_DIRS); do \
|
|
dh_installdirs -pplatform-modules-e582-$${mod} \
|
|
$(KERNEL_SRC)/$(INSTALL_MOD_DIR); \
|
|
cp -f $(MOD_SRC_DIR)/$${mod}/modules/*.ko \
|
|
debian/platform-modules-e582-$${mod}/$(KERNEL_SRC)/$(INSTALL_MOD_DIR); \
|
|
cp -f $(MOD_SRC_DIR)/centec-dal/*.ko debian/platform-modules-e582-$${mod}/$(KERNEL_SRC)/$(INSTALL_MOD_DIR); \
|
|
done)
|
|
|
|
override_dh_usrlocal:
|
|
|
|
override_dh_clean:
|
|
dh_clean
|
|
(for mod in $(MODULE_DIRS); do \
|
|
make -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/$${mod}/modules clean; \
|
|
rm -rf $(MOD_SRC_DIR)/$${mod}/modules/*.ko; \
|
|
rm -rf debian/platform-modules-e582-$${mod}/$(KERNEL_SRC)/$(INSTALL_MOD_DIR)/*.ko; \
|
|
done)
|
|
make -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/centec-dal clean; \
|
|
rm -rf $(MOD_SRC_DIR)/centec-dal/*.ko; \
|
|
rm $(MOD_SRC_DIR)/centec-dal -rf
|
|
|