From: Alan Tull <atull@kernel.org>
To: Moritz Fischer <moritz.fischer@ettus.com>
Cc: Alan Tull <atull@kernel.org>,
linux-kernel@vger.kernel.org, linux-fpga@vger.kernel.org
Subject: [PATCH v3 00/16] Enable upper layers using FPGA region w/o device tree
Date: Thu, 6 Jul 2017 13:47:00 -0500 [thread overview]
Message-ID: <20170706184716.3179-1-atull@kernel.org> (raw)
* Change the fpga-mgr API to have one fpga_mgr_load function
instead of three.
* Expose API functions for FPGA region
* Separate common FPGA region code from Device Tree support
* Add API functions for bridges where DT is not used.
This is needed because the current FPGA layer has a couple of problems:
* We now have 3 functions for programming a FPGA, depending on whether
the image is in a sg list, a buffer, or firmware. So upper layers
have to be written assuming where the image will be or will have to
write extra code to maintain flexibility.
* users who aren't using device tree are left to write their
own code that is essentially a rewrite of FPGA region.
Currently on the linux-fpga git repo as branch
next-20170615-fpga-region-api-v3
Patch 1 updates documentation and adds a FPGA region API doc.
Patch 2 adds non-dt support for fpga-bridges
Patch 3 changes the FPGA manager API, replacing the 3 FPGA load
functions with a single function that can handle whether the image
is a sg list, a contiguous buffer, or a firmware file.
Patch 4 separates getting a ref to a manager from locking it so
code can hang onto a ref without preventing other users from
using the manager to program a FPGA.
Patches 5 to 16 separate FPGA region common code from DT overlay
support and adds API functions. Functional code changes are separated
into a bunch of little patches. The last patch actually moves code to
of-fpga-region.c with only minor init/probe changes as this becomes
two modules.
I've tested this functionally for all patches separately.
Code changes from v3 are pretty small.
Changes in v3:
* rewrite fpga-region.txt
* fix bisect, test on each patch
* change fpga_region_program_fpga take only the region as a parameter
* update docs for fpga_region_program_fpga change
Changes in v2:
* split the final (large) patch into smaller patches for easier reviewability.
* documentation has been expanded
* reorder things, clean up
* dev_err instead of pr_err
* move functions that alloc/free image info from fpga-region.c to fpga-mgr.c
* move fpga-region.h to include/linux/fpga/
* add fpga_region_class_find to fpga-region.c
* move of_fpga_region_find to of-fpga-region.c
Alan Tull (16):
doc: fpga: update documents for the FPGA API
fpga: bridge: support getting bridge from device
fpga: mgr: API change to replace fpga load functions with single
function
fpga: mgr: separate getting/locking FPGA manager
fpga: region: use dev_err instead of pr_err
fpga: region: remove unneeded of_node_get and put
fpga: region: get mgr early on
fpga: region: check for child regions before allocing image info
fpga: region: fix slow warning with more than one overlay
fpga: region: use image info as parameter for programming region
fpga: region: separate out code that parses the overlay
fpga: region: add fpga-region.h header
fpga: region: rename some functions prior to moving
fpga: region: add register/unregister functions
fpga: region: add fpga_region_class_find
fpga: region: move device tree support to of-fpga-region.c
Documentation/fpga/fpga-mgr.txt | 133 +++++-----
Documentation/fpga/fpga-region.txt | 95 +++++++
Documentation/fpga/overview.txt | 23 ++
drivers/fpga/Kconfig | 13 +-
drivers/fpga/Makefile | 1 +
drivers/fpga/fpga-bridge.c | 110 +++++++--
drivers/fpga/fpga-mgr.c | 111 +++++++--
drivers/fpga/fpga-region.c | 463 ++++------------------------------
drivers/fpga/of-fpga-region.c | 495 +++++++++++++++++++++++++++++++++++++
include/linux/fpga/fpga-bridge.h | 7 +-
include/linux/fpga/fpga-mgr.h | 29 ++-
include/linux/fpga/fpga-region.h | 38 +++
12 files changed, 975 insertions(+), 543 deletions(-)
create mode 100644 Documentation/fpga/fpga-region.txt
create mode 100644 Documentation/fpga/overview.txt
create mode 100644 drivers/fpga/of-fpga-region.c
create mode 100644 include/linux/fpga/fpga-region.h
--
2.7.4
next reply other threads:[~2017-07-06 18:47 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-06 18:47 Alan Tull [this message]
2017-07-06 18:47 ` [PATCH v3 01/16] doc: fpga: update documents for the FPGA API Alan Tull
2017-08-17 19:42 ` Moritz Fischer
2017-08-17 19:52 ` Alan Tull
2017-07-06 18:47 ` [PATCH v3 02/16] fpga: bridge: support getting bridge from device Alan Tull
2017-07-06 18:47 ` [PATCH v3 03/16] fpga: mgr: API change to replace fpga load functions with single function Alan Tull
2017-07-10 17:36 ` Moritz Fischer
2017-07-10 18:23 ` Alan Tull
2017-07-12 16:33 ` Alan Tull
2017-07-06 18:47 ` [PATCH v3 04/16] fpga: mgr: separate getting/locking FPGA manager Alan Tull
2017-07-06 18:47 ` [PATCH v3 05/16] fpga: region: use dev_err instead of pr_err Alan Tull
2017-07-06 18:47 ` [PATCH v3 06/16] fpga: region: remove unneeded of_node_get and put Alan Tull
2017-07-06 18:47 ` [PATCH v3 07/16] fpga: region: get mgr early on Alan Tull
2017-07-06 18:47 ` [PATCH v3 08/16] fpga: region: check for child regions before allocing image info Alan Tull
2017-07-06 18:47 ` [PATCH v3 09/16] fpga: region: fix slow warning with more than one overlay Alan Tull
2017-07-06 18:47 ` [PATCH v3 10/16] fpga: region: use image info as parameter for programming region Alan Tull
2017-07-06 18:47 ` [PATCH v3 11/16] fpga: region: separate out code that parses the overlay Alan Tull
2017-07-06 18:47 ` [PATCH v3 12/16] fpga: region: add fpga-region.h header Alan Tull
2017-07-06 18:47 ` [PATCH v3 13/16] fpga: region: rename some functions prior to moving Alan Tull
2017-07-06 18:47 ` [PATCH v3 14/16] fpga: region: add register/unregister functions Alan Tull
2017-07-06 18:47 ` [PATCH v3 15/16] fpga: region: add fpga_region_class_find Alan Tull
2017-07-06 18:47 ` [PATCH v3 16/16] fpga: region: move device tree support to of-fpga-region.c Alan Tull
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=20170706184716.3179-1-atull@kernel.org \
--to=atull@kernel.org \
--cc=linux-fpga@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=moritz.fischer@ettus.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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome