From: Charles Perry <charles.perry@savoirfairelinux.com> To: mdf@kernel.org Cc: avandiver@markem-imaje.com, bcody@markem-imaje.com, Charles Perry <charles.perry@savoirfairelinux.com>, Wu Hao <hao.wu@intel.com>, Xu Yilun <yilun.xu@intel.com>, Tom Rix <trix@redhat.com>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Michal Simek <michal.simek@amd.com>, linux-fpga@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v4 0/3] fpga: xilinx-selectmap: add new driver Date: Wed, 21 Feb 2024 14:50:46 -0500 [thread overview] Message-ID: <20240221195058.1281973-1-charles.perry@savoirfairelinux.com> (raw) Hello, This patchset adds a new driver for the 7 series FPGA's SelectMAP interface. The SelectMAP interface shares a common GPIO protocol with the SPI interface which is already in the kernel (drivers/fpga/xilinx-spi.c). The approach proposed in this patchset is to refactor xilinx-spi.c into xilinx-core.c which would handle the common GPIO protocol. This is then used to build two drivers, the already existing xilinx-spi.c driver and a newly added xilinx-selectmap.c driver. The SelectMAP driver proposed only supports 8 bit mode. This is because the 16 and 32 bits mode have limitations with regards to compressed bitstream support as well as introducing endianness considerations. I'm testing xilinx-selectmap.c on a custom i.MX6 board connected to an Artix 7 FPGA. Flashing a 913K bitstream takes 0.44 seconds. Changes since v3: (from Rob Herring review) * Fix an error in the DT binding example compatible. * Drop the renaming of "prog_b" to "prog" and "init-b" to "init". Patches 2 and 3 are removed. Changes since v2: * Inserted patch 2 and 3 which rename "prog_b" and "init-b" into "prog" and "init" for the SPI driver. * From Krzysztof Kozlowski review's: * Use more specific compatible names * Remove other missing occurences of the slave word missed in v2. * From Xu Yilun review's: * Fix vertical whitespace in get_done_gpio(). * Combine write() and write_one_dummy_byte() together. * Eliminate most of the xilinx_core_probe() arguments, the driver needs to populate those directly into the xilinx_fpga_core struct. Added some documentation to struct xilinx_fpga_core to clarify this. * Removed typedefs from xilinx-core.h. * Moved null checks in xilinx_core_probe() to first patch. * Move csi_b and rdwr_b out of xilinx_selectmap_conf as they are not used out of the probe function. Changes since v1: (from Krzysztof Kozlowski review's) * Use more conventional names for gpio DT bindings * fix example in DT bindings * add mc-peripheral-props.yaml to DT bindings * fix various formatting mistakes * Remove all occurences of the "slave" word. Charles Perry (3): fpga: xilinx-spi: extract a common driver core dt-bindings: fpga: xlnx,fpga-selectmap: add DT schema fpga: xilinx-selectmap: add new driver .../bindings/fpga/xlnx,fpga-selectmap.yaml | 86 +++++++ drivers/fpga/Kconfig | 12 + drivers/fpga/Makefile | 2 + drivers/fpga/xilinx-core.c | 208 +++++++++++++++++ drivers/fpga/xilinx-core.h | 28 +++ drivers/fpga/xilinx-selectmap.c | 97 ++++++++ drivers/fpga/xilinx-spi.c | 212 ++---------------- 7 files changed, 446 insertions(+), 199 deletions(-) create mode 100644 Documentation/devicetree/bindings/fpga/xlnx,fpga-selectmap.yaml create mode 100644 drivers/fpga/xilinx-core.c create mode 100644 drivers/fpga/xilinx-core.h create mode 100644 drivers/fpga/xilinx-selectmap.c -- 2.43.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
WARNING: multiple messages have this Message-ID (diff)
From: Charles Perry <charles.perry@savoirfairelinux.com> To: mdf@kernel.org Cc: avandiver@markem-imaje.com, bcody@markem-imaje.com, Charles Perry <charles.perry@savoirfairelinux.com>, Wu Hao <hao.wu@intel.com>, Xu Yilun <yilun.xu@intel.com>, Tom Rix <trix@redhat.com>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Michal Simek <michal.simek@amd.com>, linux-fpga@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v4 0/3] fpga: xilinx-selectmap: add new driver Date: Wed, 21 Feb 2024 14:50:46 -0500 [thread overview] Message-ID: <20240221195058.1281973-1-charles.perry@savoirfairelinux.com> (raw) Hello, This patchset adds a new driver for the 7 series FPGA's SelectMAP interface. The SelectMAP interface shares a common GPIO protocol with the SPI interface which is already in the kernel (drivers/fpga/xilinx-spi.c). The approach proposed in this patchset is to refactor xilinx-spi.c into xilinx-core.c which would handle the common GPIO protocol. This is then used to build two drivers, the already existing xilinx-spi.c driver and a newly added xilinx-selectmap.c driver. The SelectMAP driver proposed only supports 8 bit mode. This is because the 16 and 32 bits mode have limitations with regards to compressed bitstream support as well as introducing endianness considerations. I'm testing xilinx-selectmap.c on a custom i.MX6 board connected to an Artix 7 FPGA. Flashing a 913K bitstream takes 0.44 seconds. Changes since v3: (from Rob Herring review) * Fix an error in the DT binding example compatible. * Drop the renaming of "prog_b" to "prog" and "init-b" to "init". Patches 2 and 3 are removed. Changes since v2: * Inserted patch 2 and 3 which rename "prog_b" and "init-b" into "prog" and "init" for the SPI driver. * From Krzysztof Kozlowski review's: * Use more specific compatible names * Remove other missing occurences of the slave word missed in v2. * From Xu Yilun review's: * Fix vertical whitespace in get_done_gpio(). * Combine write() and write_one_dummy_byte() together. * Eliminate most of the xilinx_core_probe() arguments, the driver needs to populate those directly into the xilinx_fpga_core struct. Added some documentation to struct xilinx_fpga_core to clarify this. * Removed typedefs from xilinx-core.h. * Moved null checks in xilinx_core_probe() to first patch. * Move csi_b and rdwr_b out of xilinx_selectmap_conf as they are not used out of the probe function. Changes since v1: (from Krzysztof Kozlowski review's) * Use more conventional names for gpio DT bindings * fix example in DT bindings * add mc-peripheral-props.yaml to DT bindings * fix various formatting mistakes * Remove all occurences of the "slave" word. Charles Perry (3): fpga: xilinx-spi: extract a common driver core dt-bindings: fpga: xlnx,fpga-selectmap: add DT schema fpga: xilinx-selectmap: add new driver .../bindings/fpga/xlnx,fpga-selectmap.yaml | 86 +++++++ drivers/fpga/Kconfig | 12 + drivers/fpga/Makefile | 2 + drivers/fpga/xilinx-core.c | 208 +++++++++++++++++ drivers/fpga/xilinx-core.h | 28 +++ drivers/fpga/xilinx-selectmap.c | 97 ++++++++ drivers/fpga/xilinx-spi.c | 212 ++---------------- 7 files changed, 446 insertions(+), 199 deletions(-) create mode 100644 Documentation/devicetree/bindings/fpga/xlnx,fpga-selectmap.yaml create mode 100644 drivers/fpga/xilinx-core.c create mode 100644 drivers/fpga/xilinx-core.h create mode 100644 drivers/fpga/xilinx-selectmap.c -- 2.43.0
next reply other threads:[~2024-02-21 19:52 UTC|newest] Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-02-21 19:50 Charles Perry [this message] 2024-02-21 19:50 ` [PATCH v4 0/3] fpga: xilinx-selectmap: add new driver Charles Perry 2024-02-21 19:50 ` [PATCH v4 1/3] fpga: xilinx-spi: extract a common driver core Charles Perry 2024-02-21 19:50 ` Charles Perry 2024-02-26 9:19 ` Xu Yilun 2024-02-26 9:19 ` Xu Yilun 2024-03-03 17:20 ` Charles Perry 2024-03-03 17:20 ` Charles Perry 2024-03-01 5:29 ` kernel test robot 2024-03-01 5:29 ` kernel test robot 2024-02-21 19:50 ` [PATCH v4 2/3] dt-bindings: fpga: xlnx,fpga-selectmap: add DT schema Charles Perry 2024-02-21 19:50 ` Charles Perry 2024-02-27 10:10 ` Krzysztof Kozlowski 2024-02-27 10:10 ` Krzysztof Kozlowski 2024-03-03 17:21 ` Charles Perry 2024-03-03 17:21 ` Charles Perry 2024-03-04 7:30 ` Krzysztof Kozlowski 2024-03-04 7:30 ` Krzysztof Kozlowski 2024-03-04 7:31 ` Krzysztof Kozlowski 2024-03-04 7:31 ` Krzysztof Kozlowski 2024-03-05 2:27 ` Charles Perry 2024-03-05 2:27 ` Charles Perry 2024-03-05 7:27 ` Krzysztof Kozlowski 2024-03-05 7:27 ` Krzysztof Kozlowski 2024-03-06 7:10 ` Xu Yilun 2024-03-06 7:10 ` Xu Yilun 2024-03-06 14:29 ` Charles Perry 2024-03-06 14:29 ` Charles Perry 2024-02-21 19:50 ` [PATCH v4 3/3] fpga: xilinx-selectmap: add new driver Charles Perry 2024-02-21 19:50 ` Charles Perry 2024-02-26 9:50 ` Xu Yilun 2024-02-26 9:50 ` Xu Yilun 2024-03-03 17:22 ` Charles Perry 2024-03-03 17:22 ` Charles Perry 2024-03-13 22:47 ` Charles Perry 2024-03-13 22:47 ` Charles Perry
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20240221195058.1281973-1-charles.perry@savoirfairelinux.com \ --to=charles.perry@savoirfairelinux.com \ --cc=avandiver@markem-imaje.com \ --cc=bcody@markem-imaje.com \ --cc=conor+dt@kernel.org \ --cc=devicetree@vger.kernel.org \ --cc=hao.wu@intel.com \ --cc=krzysztof.kozlowski+dt@linaro.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-fpga@vger.kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=mdf@kernel.org \ --cc=michal.simek@amd.com \ --cc=robh+dt@kernel.org \ --cc=trix@redhat.com \ --cc=yilun.xu@intel.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.