linux-fpga.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Xu Yilun <yilun.xu@intel.com>
To: mdf@kernel.org, linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: trix@redhat.com, lgoncalv@redhat.com, yilun.xu@intel.com,
	hao.wu@intel.com,
	Matthew Gerlach <matthew.gerlach@linux.intel.com>,
	Russ Weight <russell.h.weight@intel.com>
Subject: [PATCH v3 3/5] fpga: dfl: move fpga_dfl_device_id to mod_devicetable.h
Date: Fri, 25 Sep 2020 00:59:59 +0800	[thread overview]
Message-ID: <1600966801-30586-4-git-send-email-yilun.xu@intel.com> (raw)
In-Reply-To: <1600966801-30586-1-git-send-email-yilun.xu@intel.com>

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

Signed-off-by: Xu Yilun <yilun.xu@intel.com>
Signed-off-by: Wu Hao <hao.wu@intel.com>
Signed-off-by: Matthew Gerlach <matthew.gerlach@linux.intel.com>
Signed-off-by: Russ Weight <russell.h.weight@intel.com>
Reviewed-by: Tom Rix <trix@redhat.com>
Acked-by: Wu Hao <hao.wu@intel.com>
Signed-off-by: Moritz Fischer <mdf@kernel.org>
---
v2: fix the order for the header file
v3: rebase the patch for dfl bus name change
---
 drivers/fpga/dfl.h              | 13 +------------
 include/linux/mod_devicetable.h | 12 ++++++++++++
 2 files changed, 13 insertions(+), 12 deletions(-)

diff --git a/drivers/fpga/dfl.h b/drivers/fpga/dfl.h
index 78f7c6f..4a42d26 100644
--- a/drivers/fpga/dfl.h
+++ b/drivers/fpga/dfl.h
@@ -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>
@@ -526,18 +527,6 @@ enum fpga_dfl_id_type {
 };
 
 /**
- * struct fpga_dfl_device_id - fpga dfl device identifier
- * @type: FPGA DFL FIU type of the device, see enum fpga_dfl_id_type.
- * @feature_id: feature identifier local to its FPGA DFL FIU type.
- * @driver_data: driver specific data.
- */
-struct fpga_dfl_device_id {
-	u16 type;
-	u16 feature_id;
-	unsigned long driver_data;
-};
-
-/**
  * struct fpga_dfl_device - represent an fpga dfl device on fpga dfl bus
  *
  * @dev: generic device interface.
diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetable.h
index 5b08a47..ca24a4b 100644
--- a/include/linux/mod_devicetable.h
+++ b/include/linux/mod_devicetable.h
@@ -838,4 +838,16 @@ struct mhi_device_id {
 	kernel_ulong_t driver_data;
 };
 
+/**
+ * struct fpga_dfl_device_id - fpga dfl device identifier
+ * @type: FPGA DFL FIU type of the device, see enum fpga_dfl_id_type.
+ * @feature_id: feature identifier local to its FPGA DFL FIU type.
+ * @driver_data: driver specific data.
+ */
+struct fpga_dfl_device_id {
+	__u16 type;
+	__u16 feature_id;
+	unsigned long driver_data;
+};
+
 #endif /* LINUX_MOD_DEVICETABLE_H */
-- 
2.7.4


  parent reply	other threads:[~2020-09-24 17:07 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-24 16:59 [PATCH v3 0/5] add DFL bus support to MODULE_DEVICE_TABLE() Xu Yilun
2020-09-24 16:59 ` [PATCH v3 1/5] fpga: dfl: rename the bus type "dfl" to "fpga-dfl" Xu Yilun
2020-09-24 17:27   ` Moritz Fischer
     [not found]     ` <20200926022346.GA5623@yilunxu-OptiPlex-7050>
2020-09-26  6:09       ` Greg KH
2020-09-26 19:22         ` Moritz Fischer
2020-09-27  5:51           ` Greg KH
2020-09-27  7:37             ` Xu Yilun
2020-09-27  7:54               ` Greg KH
     [not found]                 ` <20200927083647.GC16433@yilunxu-OptiPlex-7050>
2020-09-29  1:23                   ` Xu Yilun
2020-09-29  4:19                     ` Moritz Fischer
2020-09-29  7:19                       ` Xu Yilun
2020-10-09  6:20                       ` Xu Yilun
2020-10-09  6:41                         ` Greg KH
2020-10-09  7:34                           ` Xu Yilun
2020-10-09 21:28                             ` Moritz Fischer
2020-10-10  7:03                               ` Greg KH
2020-09-24 19:01   ` Tom Rix
2020-09-25  2:41     ` Moritz Fischer
2020-09-25  3:15     ` Xu Yilun
2020-09-24 16:59 ` [PATCH v3 2/5] fpga: dfl: fix the definitions of type & feature_id for dfl devices Xu Yilun
2020-09-24 16:59 ` Xu Yilun [this message]
2020-09-24 17:00 ` [PATCH v3 4/5] fpga: dfl: add fpga dfl bus support to MODULE_DEVICE_TABLE() Xu Yilun
2020-09-24 17:00 ` [PATCH v3 5/5] fpga: dfl: move fpga dfl bus related APIs to include/linux/fpga/dfl.h Xu Yilun

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=1600966801-30586-4-git-send-email-yilun.xu@intel.com \
    --to=yilun.xu@intel.com \
    --cc=hao.wu@intel.com \
    --cc=lgoncalv@redhat.com \
    --cc=linux-fpga@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matthew.gerlach@linux.intel.com \
    --cc=mdf@kernel.org \
    --cc=russell.h.weight@intel.com \
    --cc=trix@redhat.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;
as well as URLs for NNTP newsgroup(s).