Skip to contentSkip to conversation

FPGA DFL Changes for 5.12

PATCH In review Moritz Fischer 3 participants 27 messages Jan 7, 2021 – Jan 14, 2021

Subsystems (6)
lore
Share & tools
lore

Moritz Fischer

author maintainer
#0 lore raw

cover FPGA DFL Changes for 5.12

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

This contains Matthew's changes to allow for more flexible discovery of DFLs.

Xu's changeset adds support for DFL device drivers. Two of the first users are part of the patchset: dfl-emif a memory controller, as well as support for the NIOS N3000.

Thanks,
Moritz

Matthew Gerlach (2):
fpga: dfl: refactor cci_enumerate_feature_devs()
fpga: dfl-pci: locate DFLs by PCIe vendor specific capability

Xu Yilun (6):
fpga: dfl: fix the definitions of type & feature_id for dfl devices
fpga: dfl: move dfl_device_id to mod_devicetable.h
fpga: dfl: add dfl bus support to MODULE_DEVICE_TABLE()
fpga: dfl: move dfl bus related APIs to include/linux/dfl.h
fpga: dfl: add support for N3000 Nios private feature
memory: dfl-emif: add the DFL EMIF private feature driver

 .../ABI/testing/sysfs-bus-dfl-devices-emif    |  25 +
 .../testing/sysfs-bus-dfl-devices-n3000-nios  |  47 ++
 Documentation/fpga/dfl.rst                    |  27 +
 MAINTAINERS                                   |   3 +-
 drivers/fpga/Kconfig                          |  11 +
 drivers/fpga/Makefile                         |   2 +
 drivers/fpga/dfl-n3000-nios.c                 | 588 ++++++++++++++++++
 drivers/fpga/dfl-pci.c                        | 165 +++--
 drivers/fpga/dfl.c                            |   4 +-
 drivers/fpga/dfl.h                            |  85 +--
 drivers/memory/Kconfig                        |   9 +
 drivers/memory/Makefile                       |   2 +
 drivers/memory/dfl-emif.c                     | 207 ++++++
 include/linux/dfl.h                           |  86 +++
 include/linux/mod_devicetable.h               |  24 +
 scripts/mod/devicetable-offsets.c             |   4 +
 scripts/mod/file2alias.c                      |  13 +
 17 files changed, 1180 insertions(+), 122 deletions(-)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-dfl-devices-emif
 create mode 100644 Documentation/ABI/testing/sysfs-bus-dfl-devices-n3000-nios
 create mode 100644 drivers/fpga/dfl-n3000-nios.c
 create mode 100644 drivers/memory/dfl-emif.c
 create mode 100644 include/linux/dfl.h
Signature · 1 line
2.30.0
author maintainer
#1 lore raw

PATCH 1/8 fpga: dfl: refactor cci_enumerate_feature_devs()

From: Matthew Gerlach <[email protected]>

In preparation of looking for dfls based on a vendor specific pci capability, move the code for the default method of finding the first dfl at offset 0 of Bar 0 to its own function.

---
 drivers/fpga/dfl-pci.c | 84 +++++++++++++++++++++++-------------------
 1 file changed, 47 insertions(+), 37 deletions(-)
drivers/fpga/dfl-pci.c +47 -37
index a2203d03c9e2..5100695e27cd 100644
@@ -119,49 +119,20 @@ static int *cci_pci_create_irq_table(struct pci_dev *pcidev, unsigned int nvec)
 	return table;
 }
 
-/* enumerate feature devices under pci device */
-static int cci_enumerate_feature_devs(struct pci_dev *pcidev)
+/* default method of finding dfls starting at offset 0 of bar 0 */
+static int find_dfls_by_default(struct pci_dev *pcidev,
+				struct dfl_fpga_enum_info *info)
 {
-	struct cci_drvdata *drvdata = pci_get_drvdata(pcidev);
-	int port_num, bar, i, nvec, ret = 0;
-	struct dfl_fpga_enum_info *info;
-	struct dfl_fpga_cdev *cdev;
+	int port_num, bar, i, ret = 0;
 	resource_size_t start, len;
 	void __iomem *base;
-	int *irq_table;
 	u32 offset;
 	u64 v;
 
-	/* allocate enumeration info via pci_dev */
-	info = dfl_fpga_enum_info_alloc(&pcidev->dev);
-	if (!info)
-		return -ENOMEM;
-
-	/* add irq info for enumeration if the device support irq */
-	nvec = cci_pci_alloc_irq(pcidev);
-	if (nvec < 0) {
-		dev_err(&pcidev->dev, "Fail to alloc irq %d.\n", nvec);
-		ret = nvec;
-		goto enum_info_free_exit;
-	} else if (nvec) {
-		irq_table = cci_pci_create_irq_table(pcidev, nvec);
-		if (!irq_table) {
-			ret = -ENOMEM;
-			goto irq_free_exit;
-		}
-
-		ret = dfl_fpga_enum_info_add_irq(info, nvec, irq_table);
-		kfree(irq_table);
-		if (ret)
-			goto irq_free_exit;
-	}
-
-	/* start to find Device Feature List in Bar 0 */
+	/* start to find Device Feature List from Bar 0 */
 	base = cci_pci_ioremap_bar0(pcidev);
-	if (!base) {
-		ret = -ENOMEM;
-		goto irq_free_exit;
-	}
+	if (!base)
+		return -ENOMEM;
 
 	/*
 	 * PF device has FME and Ports/AFUs, and VF device only has one
@@ -208,12 +179,51 @@ static int cci_enumerate_feature_devs(struct pci_dev *pcidev)
 		dfl_fpga_enum_info_add_dfl(info, start, len);
 	} else {
 		ret = -ENODEV;
-		goto irq_free_exit;
 	}
 
 	/* release I/O mappings for next step enumeration */
 	pcim_iounmap_regions(pcidev, BIT(0));
 
+	return ret;
+}
+
+/* enumerate feature devices under pci device */
+static int cci_enumerate_feature_devs(struct pci_dev *pcidev)
+{
+	struct cci_drvdata *drvdata = pci_get_drvdata(pcidev);
+	struct dfl_fpga_enum_info *info;
+	struct dfl_fpga_cdev *cdev;
+	int nvec, ret = 0;
+	int *irq_table;
+
+	/* allocate enumeration info via pci_dev */
+	info = dfl_fpga_enum_info_alloc(&pcidev->dev);
+	if (!info)
+		return -ENOMEM;
+
+	/* add irq info for enumeration if the device support irq */
+	nvec = cci_pci_alloc_irq(pcidev);
+	if (nvec < 0) {
+		dev_err(&pcidev->dev, "Fail to alloc irq %d.\n", nvec);
+		ret = nvec;
+		goto enum_info_free_exit;
+	} else if (nvec) {
+		irq_table = cci_pci_create_irq_table(pcidev, nvec);
+		if (!irq_table) {
+			ret = -ENOMEM;
+			goto irq_free_exit;
+		}
+
+		ret = dfl_fpga_enum_info_add_irq(info, nvec, irq_table);
+		kfree(irq_table);
+		if (ret)
+			goto irq_free_exit;
+	}
+
+	ret = find_dfls_by_default(pcidev, info);
+	if (ret)
+		goto irq_free_exit;
+
 	/* start enumeration with prepared enumeration information */
 	cdev = dfl_fpga_feature_devs_enumerate(info);
 	if (IS_ERR(cdev)) {
Signature · 1 line
2.30.0
author maintainer
#4 lore raw

PATCH 4/8 fpga: dfl: move dfl_device_id to mod_devicetable.h

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

In order to support MODULE_DEVICE_TABLE() for dfl device driver, this patch moves struct dfl_device_id to mod_devicetable.h

Some brief description for DFL (Device Feature List) is added to make the DFL known to the whole kernel.

---
 drivers/fpga/dfl.h              | 13 +------------
 include/linux/mod_devicetable.h | 24 ++++++++++++++++++++++++
 2 files changed, 25 insertions(+), 12 deletions(-)
drivers/fpga/dfl.h +1 -12
index ac373b1fcff9..549c7900dcfd 100644
@@ -22,6 +22,7 @@
 #include <linux/interrupt.h>
 #include <linux/iopoll.h>
 #include <linux/io-64-nonatomic-lo-hi.h>
+#include <linux/mod_devicetable.h>
 #include <linux/platform_device.h>
 #include <linux/slab.h>
 #include <linux/uuid.h>
@@ -525,18 +526,6 @@ enum dfl_id_type {
 	DFL_ID_MAX,
 };
 
-/**
- * struct dfl_device_id -  dfl device identifier
- * @type: DFL FIU type of the device. See enum dfl_id_type.
- * @feature_id: feature identifier local to its DFL FIU type.
- * @driver_data: driver specific data.
- */
-struct dfl_device_id {
-	u16 type;
-	u16 feature_id;
-	unsigned long driver_data;
-};
-
 /**
  * struct dfl_device - represent an dfl device on dfl bus
  *
include/linux/mod_devicetable.h +24 -0
index c425290b21e2..b8dae34eca10 100644
@@ -846,4 +846,28 @@ struct auxiliary_device_id {
 	kernel_ulong_t driver_data;
 };
 
+/*
+ * DFL (Device Feature List)
+ *
+ * DFL defines a linked list of feature headers within the device MMIO space to
+ * provide an extensible way of adding features. Software can walk through these
+ * predefined data structures to enumerate features. It is now used in the FPGA.
+ * See Documentation/fpga/dfl.rst for more information.
+ *
+ * The dfl bus type is introduced to match the individual feature devices (dfl
+ * devices) for specific dfl drivers.
+ */
+
+/**
+ * struct dfl_device_id -  dfl device identifier
+ * @type: DFL FIU type of the device. See enum dfl_id_type.
+ * @feature_id: feature identifier local to its DFL FIU type.
+ * @driver_data: driver specific data.
+ */
+struct dfl_device_id {
+	__u16 type;
+	__u16 feature_id;
+	kernel_ulong_t driver_data;
+};
+
 #endif /* LINUX_MOD_DEVICETABLE_H */
Signature · 1 line
2.30.0
author maintainer
#5 lore raw

PATCH 5/8 fpga: dfl: add dfl bus support to MODULE_DEVICE_TABLE()

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

Device Feature List (DFL) is a linked list of feature headers within the device MMIO space. It is used by FPGA to enumerate multiple sub features within it. Each feature can be uniquely identified by DFL type and feature id, which can be read out from feature headers.

A dfl bus helps DFL framework modularize DFL device drivers for different sub features. The dfl bus matches its devices and drivers by DFL type and feature id.

This patch adds dfl bus support to MODULE_DEVICE_TABLE() by adding info about struct dfl_device_id in devicetable-offsets.c and add a dfl entry point in file2alias.c.

---
 scripts/mod/devicetable-offsets.c |  4 ++++
 scripts/mod/file2alias.c          | 13 +++++++++++++
 2 files changed, 17 insertions(+)
scripts/mod/devicetable-offsets.c +4 -0
index e377f52dbfa3..1b14f3cde4e5 100644
@@ -246,5 +246,9 @@ int main(void)
 	DEVID(auxiliary_device_id);
 	DEVID_FIELD(auxiliary_device_id, name);
 
+	DEVID(dfl_device_id);
+	DEVID_FIELD(dfl_device_id, type);
+	DEVID_FIELD(dfl_device_id, feature_id);
+
 	return 0;
 }
scripts/mod/file2alias.c +13 -0
index fb4827027536..7ebabeb1e9c9 100644
@@ -1375,6 +1375,18 @@ static int do_auxiliary_entry(const char *filename, void *symval, char *alias)
 	return 1;
 }
 
+/* Looks like: dfl:tNfN */
+static int do_dfl_entry(const char *filename, void *symval, char *alias)
+{
+	DEF_FIELD(symval, dfl_device_id, type);
+	DEF_FIELD(symval, dfl_device_id, feature_id);
+
+	sprintf(alias, "dfl:t%04Xf%04X", type, feature_id);
+
+	add_wildcard(alias);
+	return 1;
+}
+
 /* Does namelen bytes of name exactly match the symbol? */
 static bool sym_is(const char *name, unsigned namelen, const char *symbol)
 {
@@ -1450,6 +1462,7 @@ static const struct devtable devtable[] = {
 	{"wmi", SIZE_wmi_device_id, do_wmi_entry},
 	{"mhi", SIZE_mhi_device_id, do_mhi_entry},
 	{"auxiliary", SIZE_auxiliary_device_id, do_auxiliary_entry},
+	{"dfl", SIZE_dfl_device_id, do_dfl_entry},
 };
 
 /* Create MODULE_ALIAS() statements.
Signature · 1 line
2.30.0
author maintainer
#6 lore raw

PATCH 6/8 fpga: dfl: move dfl bus related APIs to include/linux/dfl.h

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

Now the dfl drivers could be made as independent modules and put in different folders according to their functionalities. In order for scattered dfl device drivers to include dfl bus APIs, move the dfl bus APIs to a new header file in the public folder.

[[email protected]: Fixed up header guards to match filename]
---
 MAINTAINERS         |  1 +
 drivers/fpga/dfl.c  |  1 +
 drivers/fpga/dfl.h  | 72 -------------------------------------
 include/linux/dfl.h | 86 +++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 88 insertions(+), 72 deletions(-)
 create mode 100644 include/linux/dfl.h
MAINTAINERS +1 -0
index 546aa66428c9..a044b58eb9ac 100644
@@ -6957,6 +6957,7 @@ S:	Maintained
 F:	Documentation/ABI/testing/sysfs-bus-dfl
 F:	Documentation/fpga/dfl.rst
 F:	drivers/fpga/dfl*
+F:	include/linux/dfl.h
 F:	include/uapi/linux/fpga-dfl.h
 
 FPGA MANAGER FRAMEWORK
drivers/fpga/dfl.c +1 -0
index 5a6ba3b2fa05..511b20ff35a3 100644
@@ -10,6 +10,7 @@
  *   Wu Hao <[email protected]>
  *   Xiao Guangrong <[email protected]>
  */
+#include <linux/dfl.h>
 #include <linux/fpga-dfl.h>
 #include <linux/module.h>
 #include <linux/uaccess.h>
drivers/fpga/dfl.h +0 -72

76 lines not on this page · raw message

include/linux/dfl.h new file +86 -0

86 lines not on this page · raw message

Signature · 1 line
2.30.0
author maintainer
#7 lore raw

PATCH 7/8 fpga: dfl: add support for N3000 Nios private feature

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

This patch adds support for the Nios handshake private feature on Intel PAC (Programmable Acceleration Card) N3000.

The Nios is the embedded processor on the FPGA card. This private feature provides a handshake interface to FPGA Nios firmware, which receives retimer configuration command from host and executes via an internal SPI master (spi-altera). When Nios finishes the configuration, host takes over the ownership of the SPI master to control an Intel MAX10 BMC (Board Management Controller) Chip on the SPI bus.

For Nios firmware handshake part, this driver requests the retimer configuration for Nios firmware on probe, and adds some sysfs nodes for user to query the onboard retimer's working mode and Nios firmware version.

For SPI part, this driver adds a spi-altera platform device as well as the MAX10 BMC spi slave info. A spi-altera driver will be matched to handle the following SPI work.

---
 .../testing/sysfs-bus-dfl-devices-n3000-nios  |  47 ++
 MAINTAINERS                                   |   2 +-
 drivers/fpga/Kconfig                          |  11 +
 drivers/fpga/Makefile                         |   2 +
 drivers/fpga/dfl-n3000-nios.c                 | 588 ++++++++++++++++++
 5 files changed, 649 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-dfl-devices-n3000-nios
 create mode 100644 drivers/fpga/dfl-n3000-nios.c
Documentation/ABI/testing/sysfs-bus-dfl-devices-n3000-nios new file +47 -0
new file mode 100644
index 000000000000..5335d742bcaf
@@ -0,0 +1,47 @@
+What:		/sys/bus/dfl/devices/dfl_dev.X/fec_mode
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. Returns the FEC mode of the 25G links of the
+		ethernet retimers configured by Nios firmware. "rs" for Reed
+		Solomon FEC, "kr" for Fire Code FEC, "no" for NO FEC.
+		"not supported" if the FEC mode setting is not supported, this
+		happens when the Nios firmware version major < 3, or no link is
+		configured to 25G.
+		Format: string
+
+What:		/sys/bus/dfl/devices/dfl_dev.X/retimer_A_mode
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. Returns the enumeration value of the working mode of
+		the retimer A configured by the Nios firmware. The value is
+		read out from shared registers filled by the Nios firmware. Now
+		the values could be:
+
+		- "0": Reset
+		- "1": 4x10G
+		- "2": 4x25G
+		- "3": 2x25G
+		- "4": 2x25G+2x10G
+		- "5": 1x25G
+
+		If the Nios firmware is updated in future to support more
+		retimer modes, more enumeration value is expected.
+		Format: 0x%x
+
+What:		/sys/bus/dfl/devices/dfl_dev.X/retimer_B_mode
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. Returns the enumeration value of the working mode of
+		the retimer B configured by the Nios firmware. The value format
+		is the same as retimer_A_mode.
+
+What:		/sys/bus/dfl/devices/dfl_dev.X/nios_fw_version
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. Returns the version of the Nios firmware in the
+		FPGA. Its format is "major.minor.patch".
+		Format: %x.%x.%x
MAINTAINERS +1 -1
index a044b58eb9ac..aebb26a7d8f2 100644
@@ -6954,7 +6954,7 @@ M:	Wu Hao <[email protected]>
 R:	Tom Rix <[email protected]>
 L:	[email protected]
 S:	Maintained
-F:	Documentation/ABI/testing/sysfs-bus-dfl
+F:	Documentation/ABI/testing/sysfs-bus-dfl*
 F:	Documentation/fpga/dfl.rst
 F:	drivers/fpga/dfl*
 F:	include/linux/dfl.h
drivers/fpga/Kconfig +11 -0
index 5645226ca3ce..5ff9438b7b46 100644
@@ -192,6 +192,17 @@ config FPGA_DFL_AFU
 	  to the FPGA infrastructure via a Port. There may be more than one
 	  Port/AFU per DFL based FPGA device.
 
+config FPGA_DFL_NIOS_INTEL_PAC_N3000
+	tristate "FPGA DFL NIOS Driver for Intel PAC N3000"
+	depends on FPGA_DFL
+	select REGMAP
+	help
+	  This is the driver for the N3000 Nios private feature on Intel
+	  PAC (Programmable Acceleration Card) N3000. It communicates
+	  with the embedded Nios processor to configure the retimers on
+	  the card. It also instantiates the SPI master (spi-altera) for
+	  the card's BMC (Board Management Controller).
+
 config FPGA_DFL_PCI
 	tristate "FPGA DFL PCIe Device Driver"
 	depends on PCI && FPGA_DFL
drivers/fpga/Makefile +2 -0
index d8e21dfc6778..18dc9885883a 100644
@@ -44,5 +44,7 @@ dfl-fme-objs += dfl-fme-perf.o
 dfl-afu-objs := dfl-afu-main.o dfl-afu-region.o dfl-afu-dma-region.o
 dfl-afu-objs += dfl-afu-error.o
 
+obj-$(CONFIG_FPGA_DFL_NIOS_INTEL_PAC_N3000)	+= dfl-n3000-nios.o
+
 # Drivers for FPGAs which implement DFL
 obj-$(CONFIG_FPGA_DFL_PCI)		+= dfl-pci.o
drivers/fpga/dfl-n3000-nios.c new file +588 -0

588 lines not on this page · raw message

Signature · 1 line
2.30.0
author maintainer
#2 lore raw

PATCH 2/8 fpga: dfl-pci: locate DFLs by PCIe vendor specific capability

In reply to Moritz Fischer

From: Matthew Gerlach <[email protected]>

A PCIe vendor specific extended capability is introduced by Intel to specify the start of a number of DFLs.

---
 Documentation/fpga/dfl.rst | 27 ++++++++++++
 drivers/fpga/dfl-pci.c     | 87 +++++++++++++++++++++++++++++++++++++-
 2 files changed, 113 insertions(+), 1 deletion(-)
Documentation/fpga/dfl.rst +27 -0
index 0404fe6ffc74..ea8cefc18bdb 100644
@@ -501,6 +501,33 @@ Developer only needs to provide a sub feature driver with matched feature id.
 FME Partial Reconfiguration Sub Feature driver (see drivers/fpga/dfl-fme-pr.c)
 could be a reference.
 
+Location of DFLs on a PCI Device
+===========================
+The original method for finding a DFL on a PCI device assumed the start of the
+first DFL to offset 0 of bar 0.  If the first node of the DFL is an FME,
+then further DFLs in the port(s) are specified in FME header registers.
+Alternatively, a PCIe vendor specific capability structure can be used to
+specify the location of all the DFLs on the device, providing flexibility
+for the type of starting node in the DFL.  Intel has reserved the
+VSEC ID of 0x43 for this purpose.  The vendor specific
+data begins with a 4 byte vendor specific register for the number of DFLs followed 4 byte
+Offset/BIR vendor specific registers for each DFL. Bits 2:0 of Offset/BIR register
+indicates the BAR, and bits 31:3 form the 8 byte aligned offset where bits 2:0 are
+zero.
+
+        +----------------------------+
+        |31     Number of DFLS      0|
+        +----------------------------+
+        |31     Offset     3|2 BIR  0|
+        +----------------------------+
+                      . . .
+        +----------------------------+
+        |31     Offset     3|2 BIR  0|
+        +----------------------------+
+
+Being able to specify more than one DFL per BAR has been considered, but it
+was determined the use case did not provide value.  Specifying a single DFL
+per BAR simplifies the implementation and allows for extra error checking.
 
 Open discussion
 ===============
drivers/fpga/dfl-pci.c +86 -1

105 lines not on this page · raw message

Signature · 1 line
2.30.0
author maintainer
#3 lore raw

PATCH 3/8 fpga: dfl: fix the definitions of type & feature_id for dfl devices

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

The value of the field dfl_device.type comes from the 12 bits register field DFH_ID according to DFL spec. So this patch changes the definition of the type field to u16.

Also it is not necessary to illustrate the valid bits of the type field in comments. Instead we should explicitly define the possible values in the enumeration type for it, because they are shared by hardware spec. We should not let the compiler decide these values.

Similar changes are also applied to dfl_device.feature_id.

This patch also fixed the MODALIAS format according to the changes above.

---
 drivers/fpga/dfl.c |  3 +--
 drivers/fpga/dfl.h | 14 +++++++-------
 2 files changed, 8 insertions(+), 9 deletions(-)
drivers/fpga/dfl.c +1 -2
index b450870b75ed..5a6ba3b2fa05 100644
@@ -298,8 +298,7 @@ static int dfl_bus_uevent(struct device *dev, struct kobj_uevent_env *env)
 {
 	struct dfl_device *ddev = to_dfl_dev(dev);
 
-	/* The type has 4 valid bits and feature_id has 12 valid bits */
-	return add_uevent_var(env, "MODALIAS=dfl:t%01Xf%03X",
+	return add_uevent_var(env, "MODALIAS=dfl:t%04Xf%04X",
 			      ddev->type, ddev->feature_id);
 }
 
drivers/fpga/dfl.h +7 -7
index 5dc758f655b7..ac373b1fcff9 100644
@@ -520,19 +520,19 @@ long dfl_feature_ioctl_set_irq(struct platform_device *pdev,
  * enum dfl_id_type - define the DFL FIU types
  */
 enum dfl_id_type {
-	FME_ID,
-	PORT_ID,
+	FME_ID = 0,
+	PORT_ID = 1,
 	DFL_ID_MAX,
 };
 
 /**
  * struct dfl_device_id -  dfl device identifier
- * @type: contains 4 bits DFL FIU type of the device. See enum dfl_id_type.
- * @feature_id: contains 12 bits feature identifier local to its DFL FIU type.
+ * @type: DFL FIU type of the device. See enum dfl_id_type.
+ * @feature_id: feature identifier local to its DFL FIU type.
  * @driver_data: driver specific data.
  */
 struct dfl_device_id {
-	u8 type;
+	u16 type;
 	u16 feature_id;
 	unsigned long driver_data;
 };
@@ -543,7 +543,7 @@ struct dfl_device_id {
  * @dev: generic device interface.
  * @id: id of the dfl device.
  * @type: type of DFL FIU of the device. See enum dfl_id_type.
- * @feature_id: 16 bits feature identifier local to its DFL FIU type.
+ * @feature_id: feature identifier local to its DFL FIU type.
  * @mmio_res: mmio resource of this dfl device.
  * @irqs: list of Linux IRQ numbers of this dfl device.
  * @num_irqs: number of IRQs supported by this dfl device.
@@ -553,7 +553,7 @@ struct dfl_device_id {
 struct dfl_device {
 	struct device dev;
 	int id;
-	u8 type;
+	u16 type;
 	u16 feature_id;
 	struct resource mmio_res;
 	int *irqs;
Signature · 1 line
2.30.0
author maintainer
#8 lore raw

PATCH 8/8 memory: dfl-emif: add the DFL EMIF private feature driver

In reply to Moritz Fischer

From: Xu Yilun <[email protected]>

This driver is for the EMIF private feature implemented under FPGA Device Feature List (DFL) framework. It is used to expose memory interface status information as well as memory clearing control.

The purpose of memory clearing block is to zero out all private memory when FPGA is to be reprogrammed. This gives users a reliable method to prevent potential data leakage.

---
 .../ABI/testing/sysfs-bus-dfl-devices-emif    |  25 +++
 drivers/memory/Kconfig                        |   9 +
 drivers/memory/Makefile                       |   2 +
 drivers/memory/dfl-emif.c                     | 207 ++++++++++++++++++
 4 files changed, 243 insertions(+)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-dfl-devices-emif
 create mode 100644 drivers/memory/dfl-emif.c
Documentation/ABI/testing/sysfs-bus-dfl-devices-emif new file +25 -0
new file mode 100644
index 000000000000..817d14126d4d
@@ -0,0 +1,25 @@
+What:		/sys/bus/dfl/devices/dfl_dev.X/infX_cal_fail
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. It indicates if the calibration failed on this
+		memory interface. "1" for calibration failure, "0" for OK.
+		Format: %u
+
+What:		/sys/bus/dfl/devices/dfl_dev.X/infX_init_done
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Read-only. It indicates if the initialization completed on
+		this memory interface. "1" for initialization complete, "0"
+		for not yet.
+		Format: %u
+
+What:		/sys/bus/dfl/devices/dfl_dev.X/infX_clear
+Date:		Oct 2020
+KernelVersion:	5.12
+Contact:	Xu Yilun <[email protected]>
+Description:	Write-only. Writing "1" to this file will zero out all memory
+		data in this memory interface. Writing of other values is
+		invalid.
+		Format: %u
drivers/memory/Kconfig +9 -0
index 3ea6913df176..3c9a9882ef28 100644
@@ -137,6 +137,15 @@ config TI_EMIF_SRAM
 	  sequence so this driver provides several relocatable PM functions
 	  for the SoC PM code to use.
 
+config FPGA_DFL_EMIF
+	tristate "FPGA DFL EMIF Driver"
+	depends on FPGA_DFL && HAS_IOMEM
+	help
+	  This driver is for the EMIF private feature implemented under
+	  FPGA Device Feature List (DFL) framework. It is used to expose
+	  memory interface status information as well as memory clearing
+	  control.
+
 config MVEBU_DEVBUS
 	bool "Marvell EBU Device Bus Controller"
 	default y if PLAT_ORION
drivers/memory/Makefile +2 -0
index e71cf7b99641..bc7663ed1c25 100644
@@ -28,6 +28,8 @@ obj-$(CONFIG_STM32_FMC2_EBI)	+= stm32-fmc2-ebi.o
 obj-$(CONFIG_SAMSUNG_MC)	+= samsung/
 obj-$(CONFIG_TEGRA_MC)		+= tegra/
 obj-$(CONFIG_TI_EMIF_SRAM)	+= ti-emif-sram.o
+obj-$(CONFIG_FPGA_DFL_EMIF)	+= dfl-emif.o
+
 ti-emif-sram-objs		:= ti-emif-pm.o ti-emif-sram-pm.o
 
 AFLAGS_ti-emif-sram-pm.o	:=-Wa,-march=armv7-a
drivers/memory/dfl-emif.c new file +207 -0

207 lines not on this page · raw message

Signature · 1 line
2.30.0
reviewer
#9 lore raw
In reply to Moritz Fischer
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

2. an in-flight dev branch for the outstanding patches

Tom

#10 lore raw
Quoted 6 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

This is all now merged in my tree, so there's not much left to do here :)

thanks,

greg k-h

reviewer
#11 lore raw
Quoted 7 lines · Greg KH
Quoted 4 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

This is all now merged in my tree, so there's not much left to do here :)

Yes this patchset is done now.

I am offering to help in an ongoing manner, something like 10hr/week would be easy as i already spend about 30hr/week doing stuff in the kernel in addition to reviewing linux-fpga.

Tom

Quoted 4 lines

thanks,

greg k-h

reviewer
#12 lore raw
In reply to Tom Rix
Quoted 5 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

Quoted 7 lines

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

2. an in-flight dev branch for the outstanding patches

I have setup these branches based on Greg's char-misc-next

fpga-next, which is char-misc-next base for fpga-testing

fpga-testing, all the in-flight patches that would apply with automatic merge conflict resolution

These are respectively

https://github.com/trixirt/linux-fpga/tree/fpga-next

https://github.com/trixirt/linux-fpga/tree/fpga-testing

There are two trivial changes, that could go to 5.12 now.

fpga: dfl: fme: Constify static attribute_group structs

fpga: Use DEFINE_SPINLOCK() for spinlock

respectively

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

There are a couple of patchsets that conflict

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

Which I will follow up on.

And the xilinx patchset

https://lore.kernel.org/linux-fpga/[email protected]/

Which is being split/worked on offline.

If I have missed any patchset, poke me.

Tom

Quoted 4 lines

Tom

author maintainer
#13 lore raw

Tom,

Quoted 5 lines · Tom Rix
Quoted 3 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Quoted 7 lines
Quoted 7 lines

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

Quoted 7 lines
Quoted 2 lines

2. an in-flight dev branch for the outstanding patches

I have setup these branches based on Greg's char-misc-next

fpga-next, which is char-misc-next base for fpga-testing

Quoted 7 lines

fpga-testing, all the in-flight patches that would apply with automatic merge conflict resolution

These are respectively

https://github.com/trixirt/linux-fpga/tree/fpga-next

https://github.com/trixirt/linux-fpga/tree/fpga-testing

Feel free to have your own repos/branches etc, but I'd like to keep the offical trees on kernel.org.

Tbh I'd much rather see the patchwork instance be cleaned up if you want to do stuff.

Quoted 6 lines

There are two trivial changes, that could go to 5.12 now.

fpga: dfl: fme: Constify static attribute_group structs

Quoted 7 lines

fpga: Use DEFINE_SPINLOCK() for spinlock

respectively

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

I was going to pick them up monday ...

Quoted 7 lines

There are a couple of patchsets that conflict

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

Conflict between what and what?

Quoted 5 lines

And the xilinx patchset

https://lore.kernel.org/linux-fpga/[email protected]/

Which is being split/worked on offline.

I'm not sure what that means.

Quoted 5 lines

If I have missed any patchset, poke me.

Tom

- Moritz

reviewer
#14 lore raw
Quoted 9 lines · Moritz Fischer

Tom,

Quoted 6 lines · Tom Rix
Quoted 5 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

Quoted 7 lines
Quoted 5 lines
Quoted 5 lines

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

There are no outstanding fixes so all changes would go to -next.

Quoted 7 lines
Quoted 7 lines
Quoted 1 line

2. an in-flight dev branch for the outstanding patches

I have setup these branches based on Greg's char-misc-next

fpga-next, which is char-misc-next base for fpga-testing

fpga-testing, all the in-flight patches that would apply with automatic merge conflict resolution

Quoted 7 lines
Quoted 5 lines

These are respectively

https://github.com/trixirt/linux-fpga/tree/fpga-next

https://github.com/trixirt/linux-fpga/tree/fpga-testing

Feel free to have your own repos/branches etc, but I'd like to keep the offical trees on kernel.org.

Is there a way for me to move these to kernel.org ?

Quoted 3 lines

Tbh I'd much rather see the patchwork instance be cleaned up if you want to do stuff.

Please point me at the wreckage and I will clean it up.

Quoted 12 lines
Quoted 5 lines

There are two trivial changes, that could go to 5.12 now.

fpga: dfl: fme: Constify static attribute_group structs

Quoted 7 lines

fpga: Use DEFINE_SPINLOCK() for spinlock

respectively

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

Quoted 8 lines

I was going to pick them up monday ...

Quoted 6 lines

There are a couple of patchsets that conflict

https://lore.kernel.org/linux-fpga/[email protected]/

https://lore.kernel.org/linux-fpga/[email protected]/

Conflict between what and what?

There are basic git am ... applying problems.

By having a -testing branch it is easier to see where the conficts with all the outstanding patchsets.

Quoted 7 lines
Quoted 6 lines

And the xilinx patchset

https://lore.kernel.org/linux-fpga/[email protected]/

Which is being split/worked on offline.

I'm not sure what that means.

Don't worry about this until a new patchset lands.

Tom

Quoted 6 lines
Quoted 4 lines

If I have missed any patchset, poke me.

Tom

- Moritz

#15 lore raw
Quoted 16 lines · Tom Rix
Quoted 14 lines · Moritz Fischer

Tom,

Quoted 11 lines · Tom Rix
Quoted 10 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Quoted 8 lines
Quoted 2 lines

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

thanks,

greg k-h

reviewer
#16 lore raw
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

Tom

Quoted 5 lines

thanks,

greg k-h

#17 lore raw
Quoted 31 lines · Tom Rix
Quoted 29 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Quoted 6 lines
Quoted 4 lines

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

thanks,

greg k-h

reviewer
#18 lore raw
Quoted 39 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 6 lines
Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

What can I do to help make your merges as easy as possible ?

Does the patchwork infra Moritz was speaking of earlier need fixing help?

Any other things ?

Tom

Quoted 5 lines

thanks,

greg k-h

#19 lore raw
Quoted 41 lines · Tom Rix
Quoted 39 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 8 lines
Quoted 6 lines
Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

What can I do to help make your merges as easy as possible ?

I have not had any problems with merges, I've only had "problems" rejecting patches for their content.

Try helping out with patch reviews if you want, finding and fixing things before I review them is usually a good idea :)

Quoted 1 line

Does the patchwork infra Moritz was speaking of earlier need fixing help?

No idea, I don't use it.

Quoted 1 line

Any other things ?

What problems are you trying to solve here? What's wrong with how this subsystem is working that you are feeling needs to be addressed?

confused,

greg k-h

reviewer
#20 lore raw
Quoted 47 lines · Greg KH
Quoted 46 lines · Tom Rix
Quoted 45 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

Quoted 6 lines
Quoted 1 line

What can I do to help make your merges as easy as possible ?

I have not had any problems with merges, I've only had "problems" rejecting patches for their content.

Try helping out with patch reviews if you want, finding and fixing things before I review them is usually a good idea :)

ok.

Quoted 7 lines
Quoted 2 lines

Does the patchwork infra Moritz was speaking of earlier need fixing help?

No idea, I don't use it.

Quoted 1 line

Any other things ?

What problems are you trying to solve here? What's wrong with how this subsystem is working that you are feeling needs to be addressed?

I do not believe the issue I raised in 5.10 has made any progress.

If you look at the content in 5.11 we have actually regressed.

https://lore.kernel.org/linux-fpga/[email protected]/

Over the last two releases, I have shown i have the time and interest to maintain this subsystem.

So I am asking for

MAINTAINERS +0 -0
index 11b38acb4c08..269cd08f4969 100644
@@ -6951,7 +6951,7 @@ F:        drivers/net/ethernet/nvidia/*


 FPGA DFL DRIVERS
 M:     Wu Hao <[email protected]>
-R:     Tom Rix <[email protected]>
+M:     Tom Rix <[email protected]>
 L:     [email protected]
 S:     Maintained
 F:     Documentation/ABI/testing/sysfs-bus-dfl*
@@ -6962,7 +6962,7 @@ F:        include/uapi/linux/fpga-dfl.h
 FPGA MANAGER FRAMEWORK
 M:     Moritz Fischer <[email protected]>
-R:     Tom Rix <[email protected]>
+M:     Tom Rix <[email protected]>
 L:     [email protected]
 S:     Maintained
 W:     http://www.rocketboards.org

And to use/maintain my fpga-next and fpga-testing as official kernel.org branches.

Tom

Quoted 5 lines

confused,

greg k-h

#21 lore raw
Quoted 57 lines · Tom Rix
Quoted 47 lines · Greg KH
Quoted 46 lines · Tom Rix
Quoted 45 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

Quoted 6 lines
Quoted 1 line

What can I do to help make your merges as easy as possible ?

I have not had any problems with merges, I've only had "problems" rejecting patches for their content.

Try helping out with patch reviews if you want, finding and fixing things before I review them is usually a good idea :)

ok.

Quoted 1 line
Quoted 8 lines
Quoted 6 lines
Quoted 1 line

Does the patchwork infra Moritz was speaking of earlier need fixing help?

No idea, I don't use it.

Quoted 1 line

Any other things ?

What problems are you trying to solve here? What's wrong with how this subsystem is working that you are feeling needs to be addressed?

I do not believe the issue I raised in 5.10 has made any progress.

What issue?

Quoted 1 line

If you look at the content in 5.11 we have actually regressed.

What bugs regressed?

Quoted 1 line

https://lore.kernel.org/linux-fpga/[email protected]/

I don't see the problem here, other than a low-quality of patches that need reworking for some patchsets, and others are just fine. Just like all kernel subsystems, I don't see anything odd here.

Quoted 1 line

Over the last two releases, I have shown i have the time and interest to maintain this subsystem.

That's not how any of this works :)

MAINTAINERS

Quoted 12 lines

So I am asking for

MAINTAINERS +0 -0
index 11b38acb4c08..269cd08f4969 100644
@@ -6951,7 +6951,7 @@ F:        drivers/net/ethernet/nvidia/*


 FPGA DFL DRIVERS
 M:     Wu Hao <[email protected]>

MAINTAINERS +1 -1
-R:     Tom Rix <[email protected]>
+M:     Tom Rix <[email protected]>

That's generous, but how about doing review first, the maintainership of this subsystem does not feel like any sort of bottleneck to me. I personally have no problems with Moritz's interactions with the community, his reviewing of patches, and forwarding on to me.

Of course we all have delays as we have other work to do than just this, that's just part of normal development. I don't see anything stalled at the moment, nor anything that having another maintainer would have helped out with at all, so this feels like it is not needed from my end.

Again, it feels like the developers need more reviews, and good ones, so please continue to help out with that, as that's the best thing I can see to do here.

thanks,

greg k-h

reviewer
#22 lore raw
Quoted 93 lines · Greg KH
Quoted 54 lines · Tom Rix
Quoted 47 lines · Greg KH
Quoted 46 lines · Tom Rix
Quoted 45 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

Quoted 6 lines
Quoted 1 line

What can I do to help make your merges as easy as possible ?

I have not had any problems with merges, I've only had "problems" rejecting patches for their content.

Try helping out with patch reviews if you want, finding and fixing things before I review them is usually a good idea :)

Quoted 8 lines

ok.

Quoted 6 lines
Quoted 1 line

Does the patchwork infra Moritz was speaking of earlier need fixing help?

No idea, I don't use it.

Quoted 1 line

Any other things ?

What problems are you trying to solve here? What's wrong with how this subsystem is working that you are feeling needs to be addressed?

I do not believe the issue I raised in 5.10 has made any progress.

What issue?

Quoted 1 line

If you look at the content in 5.11 we have actually regressed.

What bugs regressed?

Quoted 1 line

https://lore.kernel.org/linux-fpga/[email protected]/

I don't see the problem here, other than a low-quality of patches that need reworking for some patchsets, and others are just fine. Just like all kernel subsystems, I don't see anything odd here.

Quoted 1 line

Over the last two releases, I have shown i have the time and interest to maintain this subsystem.

That's not how any of this works :)

MAINTAINERS

Quoted 12 lines

So I am asking for

MAINTAINERS +0 -0
index 11b38acb4c08..269cd08f4969 100644
@@ -6951,7 +6951,7 @@ F:        drivers/net/ethernet/nvidia/*


 FPGA DFL DRIVERS
 M:     Wu Hao <[email protected]>

MAINTAINERS +1 -1
-R:     Tom Rix <[email protected]>
+M:     Tom Rix <[email protected]>

That's generous, but how about doing review first, the maintainership of this subsystem does not feel like any sort of bottleneck to me. I personally have no problems with Moritz's interactions with the community, his reviewing of patches, and forwarding on to me.

Quoted 8 lines

Of course we all have delays as we have other work to do than just this, that's just part of normal development. I don't see anything stalled at the moment, nor anything that having another maintainer would have helped out with at all, so this feels like it is not needed from my end.

Again, it feels like the developers need more reviews, and good ones, so please continue to help out with that, as that's the best thing I can see to do here.

I have been doing the first review in a couple of days after every patch landing.

I see some pretty good response from the developers to fix the issues raised.

But I do not see Moritz picking up the review until weeks later.

This consistent delay in timely reviews is a bottleneck.

It would be good if the big first reviews could be done in parallel.

Tom

Quoted 5 lines

thanks,

greg k-h

#23 lore raw
Quoted 104 lines · Tom Rix
Quoted 93 lines · Greg KH
Quoted 54 lines · Tom Rix
Quoted 47 lines · Greg KH
Quoted 46 lines · Tom Rix
Quoted 45 lines · Greg KH
Quoted 27 lines · Tom Rix
Quoted 26 lines · Greg KH
Quoted 14 lines · Tom Rix
Quoted 13 lines · Moritz Fischer

Tom,

Quoted 10 lines · Tom Rix
Quoted 9 lines · Tom Rix
Quoted 2 lines · Moritz Fischer

This is a resend of the previous (unfortunately late) patchset of
changes for FPGA DFL.

Is there something I can do to help ?

I am paid to look after linux-fpga, so i have plenty of time.

Some ideas of what i am doing now privately i can do publicly.

Quoted 8 lines
Quoted 3 lines
Quoted 1 line
Quoted 1 line

1. keep linux-fpga sync-ed to greg's branch so linux-fpga is normally in a pullable state.

Is it not? It currently points to v5.11-rc1. If I start applying patches that require the changes that went into Greg's branch I can merge.

I mean the window between when we have staged patches and when they go into Greg's branch.

We don't have any now, maybe those two trival ones.

Since Greg's branch moves much faster than ours, our staging branch needs to be rebased regularly until its merge.

Ick, no! NEVER rebase a public branch. Why does it matter the speed of my branch vs. anyone elses? Git handles merges very well.

Quoted 8 lines
Quoted 7 lines

Just like Linus's branches move much faster than mine, and I don't rebase my branches, you shouldn't rebase yours.

Becides, I'm only taking _PATCHES_ for fpga changes at the moment, no git pulls, so why does it matter at all for any of this?

What is the problem you are trying to solve here?

This 5.12 fpga patchset not making it into 5.11.

Ok, but isn't it the responsibility of the submitter to make sure they apply properly when sending them out?

Quoted 3 lines

At some point before the 5.11 window, I tried it on next and it failed to merge.

This points to needing some c/i so it does not happen again.

"again"? Merges and the like are a totally normal thing and happen all the time, I still fail to understand what you are trying to "solve" for here...

Quoted 6 lines
Quoted 1 line

What can I do to help make your merges as easy as possible ?

I have not had any problems with merges, I've only had "problems" rejecting patches for their content.

Try helping out with patch reviews if you want, finding and fixing things before I review them is usually a good idea :)

Quoted 8 lines

ok.

Quoted 6 lines
Quoted 1 line

Does the patchwork infra Moritz was speaking of earlier need fixing help?

No idea, I don't use it.

Quoted 1 line

Any other things ?

What problems are you trying to solve here? What's wrong with how this subsystem is working that you are feeling needs to be addressed?

I do not believe the issue I raised in 5.10 has made any progress.

What issue?

Quoted 1 line

If you look at the content in 5.11 we have actually regressed.

What bugs regressed?

Quoted 1 line

https://lore.kernel.org/linux-fpga/[email protected]/

I don't see the problem here, other than a low-quality of patches that need reworking for some patchsets, and others are just fine. Just like all kernel subsystems, I don't see anything odd here.

Quoted 1 line

Over the last two releases, I have shown i have the time and interest to maintain this subsystem.

That's not how any of this works :)

MAINTAINERS

Quoted 12 lines

So I am asking for

MAINTAINERS +0 -0
index 11b38acb4c08..269cd08f4969 100644
@@ -6951,7 +6951,7 @@ F:        drivers/net/ethernet/nvidia/*


 FPGA DFL DRIVERS
 M:     Wu Hao <[email protected]>

MAINTAINERS +1 -1
-R:     Tom Rix <[email protected]>
+M:     Tom Rix <[email protected]>

That's generous, but how about doing review first, the maintainership of this subsystem does not feel like any sort of bottleneck to me. I personally have no problems with Moritz's interactions with the community, his reviewing of patches, and forwarding on to me.

Quoted 8 lines

Of course we all have delays as we have other work to do than just this, that's just part of normal development. I don't see anything stalled at the moment, nor anything that having another maintainer would have helped out with at all, so this feels like it is not needed from my end.

Again, it feels like the developers need more reviews, and good ones, so please continue to help out with that, as that's the best thing I can see to do here.

Quoted 7 lines

I have been doing the first review in a couple of days after every patch landing.

I see some pretty good response from the developers to fix the issues raised.

But I do not see Moritz picking up the review until weeks later.

This consistent delay in timely reviews is a bottleneck.

What is being prevented from merging at this moment because of this?

There is always ebbs and flows with patch reviews, what do you consider "manditory" time to review a patch from a maintainer?

Remember, we are almost all doing this not as our paid job, but as part of what we do.

And to be frank, I personally have been putting the fpga patchset at the _end_ of my reviews because of the quality of them in the past. While it is slowly getting better, you all have a big hole to dig out from, and maybe you need to step up your reviews to raise that bar so I don't dread seeing them in my review queue :)

Quoted 1 line

It would be good if the big first reviews could be done in parallel.

parallel with what?

All I'm getting here is "I wish patches were accepted faster!" from you. When personally, I think they are being accepted at a very nice rate for such a tiny subsystem.

Good luck with your reviews,

greg k-h

author maintainer
#24 lore raw
In reply to Tom Rix

Tom,

On Mon, Jan 11, 2021 at 11:46:03AM -0800, Tom Rix wrote:

[..]

Quoted 1 line

I have been doing the first review in a couple of days after every patch landing.

I appreciate your help with doing reviews.

Quoted 1 line

I see some pretty good response from the developers to fix the issues raised.

... yet patches have been rejected. So it doesn't seem purely a matter of throughput?

Quoted 1 line

But I do not see Moritz picking up the review until weeks later.

I'll admit there are delays that happen, I have a dayjob as I pointed out in earlier conversations. Furthermore, just because I do not immediately send out an email does not mean I don't look at stuff.

If people show up with 100kLOC patchsets that don't pass checkpatch, it'll take a while for me to even read up and understand what they're doing / trying to do.

Quoted 1 line

This consistent delay in timely reviews is a bottleneck.

As Greg pointed out even ones that were reviewed got rejected, so clearly the issue is with the quality and not the speed at which we send them on.

Quoted 1 line

It would be good if the big first reviews could be done in parallel.

Again depending how the patchsets are structured it will take me a while to process. Having them re-use existing infrastructure, following coding and submission guidelines will speed up the process.

On a personal level, being told I'm too slow and not doing my job as maintainer doesn't exactly increase my motivation to get to it ...

- Moritz

reviewer
#25 lore raw
Quoted 26 lines · Moritz Fischer

Tom,

On Mon, Jan 11, 2021 at 11:46:03AM -0800, Tom Rix wrote:

[..]

Quoted 1 line

I have been doing the first review in a couple of days after every patch landing.

I appreciate your help with doing reviews.

Quoted 1 line

I see some pretty good response from the developers to fix the issues raised.ÂÂ

... yet patches have been rejected. So it doesn't seem purely a matter of throughput?

Quoted 1 line

But I do not see Moritz picking up the review until weeks later.

I'll admit there are delays that happen, I have a dayjob as I pointed out in earlier conversations. Furthermore, just because I do not immediately send out an email does not mean I don't look at stuff.

If people show up with 100kLOC patchsets that don't pass checkpatch, it'll take a while for me to even read up and understand what they're doing / trying to do.

Quoted 1 line

This consistent delay in timely reviews is a bottleneck.

As Greg pointed out even ones that were reviewed got rejected, so clearly the issue is with the quality and not the speed at which we send them on.

Quoted 7 lines
Quoted 1 line

It would be good if the big first reviews could be done in parallel.

Again depending how the patchsets are structured it will take me a while to process. Having them re-use existing infrastructure, following coding and submission guidelines will speed up the process.

On a personal level, being told I'm too slow and not doing my job as maintainer doesn't exactly increase my motivation to get to it ...

Sorry about that.

I really do want to help out, earlier you mentioned patchwork problems.

If you can point me at the wreckage, I'll take a look.

Tom

Quoted 3 lines

- Moritz

author maintainer
#26 lore raw
Quoted 33 lines · Tom Rix
Quoted 31 lines · Moritz Fischer

Tom,

On Mon, Jan 11, 2021 at 11:46:03AM -0800, Tom Rix wrote:

[..]

Quoted 1 line

I have been doing the first review in a couple of days after every patch landing.

I appreciate your help with doing reviews.

Quoted 1 line

I see some pretty good response from the developers to fix the issues raised.ÂÂ

... yet patches have been rejected. So it doesn't seem purely a matter of throughput?

Quoted 1 line

But I do not see Moritz picking up the review until weeks later.

I'll admit there are delays that happen, I have a dayjob as I pointed out in earlier conversations. Furthermore, just because I do not immediately send out an email does not mean I don't look at stuff.

If people show up with 100kLOC patchsets that don't pass checkpatch, it'll take a while for me to even read up and understand what they're doing / trying to do.

Quoted 1 line

This consistent delay in timely reviews is a bottleneck.

As Greg pointed out even ones that were reviewed got rejected, so clearly the issue is with the quality and not the speed at which we send them on.

Quoted 1 line

It would be good if the big first reviews could be done in parallel.

Again depending how the patchsets are structured it will take me a while to process. Having them re-use existing infrastructure, following coding and submission guidelines will speed up the process.

Quoted 8 lines
Quoted 2 lines

On a personal level, being told I'm too slow and not doing my job as maintainer doesn't exactly increase my motivation to get to it ...

Sorry about that.

I really do want to help out, earlier you mentioned patchwork problems.

If you can point me at the wreckage, I'll take a look.

I need to add you as reviewer there. Mostly needs triaging which of the open patches are still relevant.

I think you could ping kernel.org helpdesk.

- Moritz