aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorShannon Nelson2020-09-17 18:13:24 -0700
committerDavid S. Miller2020-09-18 13:54:23 -0700
commit6700acc5f1fe97b5705832f2678cba9e9756a0dc (patch)
tree0604bba0ce70085f45a952571c039c89140b6e77 /include
parentf92970c694b36a4dbac2b650b173c78c0f0954cc (diff)
devlink: collect flash notify params into a struct
The dev flash status notify function parameter lists are getting rather long, so add a struct to be filled and passed rather than continuously changing the function signatures. Signed-off-by: Shannon Nelson <snelson@pensando.io> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Reviewed-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/net/devlink.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/include/net/devlink.h b/include/net/devlink.h
index be132c17fbcc..73065f07bf17 100644
--- a/include/net/devlink.h
+++ b/include/net/devlink.h
@@ -392,6 +392,25 @@ struct devlink_param_gset_ctx {
};
/**
+ * struct devlink_flash_notify - devlink dev flash notify data
+ * @status_msg: current status string
+ * @component: firmware component being updated
+ * @done: amount of work completed of total amount
+ * @total: amount of work expected to be done
+ * @timeout: expected max timeout in seconds
+ *
+ * These are values to be given to userland to be displayed in order
+ * to show current activity in a firmware update process.
+ */
+struct devlink_flash_notify {
+ const char *status_msg;
+ const char *component;
+ unsigned long done;
+ unsigned long total;
+ unsigned long timeout;
+};
+
+/**
* struct devlink_param - devlink configuration parameter data
* @name: name of the parameter
* @generic: indicates if the parameter is generic or driver specific