Skip to content

Commit 0704ff5

Browse files
authored
[pddf]: Adding support for FPGAPCIe in PDDF (#13476)
Why I did it Some of the platform vendors use FPGA in the HW design. This FPGA is connected to the CPU via PCIe interface. This FPGA also works as an I2C controller having other devices attached to the I2C channels emanating from it. Adding a common module, a driver and a platform specific algorithm module to be used for such FPGA in PDDF. How I did it Added 'pddf_fpgapci_module', 'pddf_fpgapci_driver' and a sample algorithm module for Xilinx device 7021. Kernel modules which takes the platform dependent data from PDDF JSON files and initialises the PCIe FPGA. The sample algorithm module can be used by the ODMs in case the communication algorithms are same for their device. Else, they need to come up with similar algo module. How to verify it Any platform having such an FPGA and brought up using PDDF would use these kernel modules. The detail representation of such a device in PDDF JSON file is covered in the HLD.
1 parent 346576b commit 0704ff5

File tree

11 files changed

+1012
-2
lines changed

11 files changed

+1012
-2
lines changed

platform/pddf/i2c/debian/rules

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ PACKAGE_PRE_NAME := sonic-platform-pddf
1818
KVERSION ?= $(shell uname -r)
1919
KERNEL_SRC := /lib/modules/$(KVERSION)
2020
MOD_SRC_DIR:= $(shell pwd)
21-
MODULE_DIRS:= client cpld cpld/driver cpldmux cpldmux/driver fpgai2c fpgai2c/driver fan fan/driver mux gpio led psu psu/driver sysstatus xcvr xcvr/driver
21+
MODULE_DIRS:= client cpld cpld/driver cpldmux cpldmux/driver fpgai2c fpgai2c/driver fpgapci fpgapci/driver fpgapci/algos fan fan/driver mux gpio led psu psu/driver sysstatus xcvr xcvr/driver
2222
MODULE_DIR:= modules
2323
UTILS_DIR := utils
2424
SERVICE_DIR := service

platform/pddf/i2c/modules/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
obj-m := client/ cpld/ cpldmux/ fpgai2c/ xcvr/ mux/ gpio/ psu/ fan/ led/ sysstatus/
1+
obj-m := client/ cpld/ cpldmux/ fpgai2c/ fpgapci/ xcvr/ mux/ gpio/ psu/ fan/ led/ sysstatus/
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
obj-m := driver/ algos/
2+
obj-m += pddf_fpgapci_module.o
3+
4+
ccflags-y:= -I$(M)/modules/include
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Sample driver for Xilinx 7021 FPGA device
2+
obj-m += pddf_xilinx_device_7021_algo.o
3+
4+
ccflags-y := -I$(M)/modules/include

0 commit comments

Comments
 (0)