summaryrefslogtreecommitdiffstats
path: root/include/net/devlink.h
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2020-09-18 21:11:01 +0200
committerDavid S. Miller <davem@davemloft.net>2020-09-18 18:17:44 -0700
commite14e05e71d106aef973e2cf100e540d911703a6e (patch)
treeef03a9d60874edcb66724c8156289cac9d6bca99 /include/net/devlink.h
parent0db0561d13df07978bea63a19f644fc16a60f54a (diff)
downloadlinux-e14e05e71d106aef973e2cf100e540d911703a6e.tar.gz
linux-e14e05e71d106aef973e2cf100e540d911703a6e.tar.bz2
linux-e14e05e71d106aef973e2cf100e540d911703a6e.zip
net: devlink: regions: Add a priv member to the regions ops struct
The driver may have multiple regions which can be dumped using one function. However, for this to work, additional information is needed. Add a priv member to the ops structure for the driver to use however it likes. Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/devlink.h')
-rw-r--r--include/net/devlink.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/net/devlink.h b/include/net/devlink.h
index 73065f07bf17..b68e483d9267 100644
--- a/include/net/devlink.h
+++ b/include/net/devlink.h
@@ -561,12 +561,14 @@ struct devlink_info_req;
* the data variable must be updated to point to the snapshot data.
* The function will be called while the devlink instance lock is
* held.
+ * @priv: Pointer to driver private data for the region operation
*/
struct devlink_region_ops {
const char *name;
void (*destructor)(const void *data);
int (*snapshot)(struct devlink *devlink, struct netlink_ext_ack *extack,
u8 **data);
+ void *priv;
};
struct devlink_fmsg;