@@ -820,6 +820,9 @@ attribute-sets:
-
name: region-direct
type: flag
+ -
+ name: info-function-uid
+ type: string
-
name: dl-dev-stats
@@ -1869,6 +1872,7 @@ operations:
- info-version-running
- info-version-stored
- info-board-serial-number
+ - info-function-uid
dump:
reply: *info-get-reply
@@ -50,6 +50,11 @@ versions is generally discouraged - here, and via any other Linux API.
This is usually the serial number of the board, often available in
PCI *Vital Product Data*.
+ * - ``function.uid``
+ - Function uniqueue identifier.
+
+ Vendor defined uniqueue identifier of a function.
+
* - ``fixed``
- Group for hardware identifiers, and versions of components
which are not field-updatable.
@@ -1846,6 +1846,8 @@ int devlink_info_serial_number_put(struct devlink_info_req *req,
const char *sn);
int devlink_info_board_serial_number_put(struct devlink_info_req *req,
const char *bsn);
+int devlink_info_function_uid_put(struct devlink_info_req *req,
+ const char *fuid);
enum devlink_info_version_type {
DEVLINK_INFO_VERSION_TYPE_NONE,
@@ -614,6 +614,8 @@ enum devlink_attr {
DEVLINK_ATTR_REGION_DIRECT, /* flag */
+ DEVLINK_ATTR_INFO_FUNCTION_UID, /* string */
+
/* Add new attributes above here, update the spec in
* Documentation/netlink/specs/devlink.yaml and re-generate
* net/devlink/netlink_gen.c.
@@ -763,6 +763,15 @@ int devlink_info_board_serial_number_put(struct devlink_info_req *req,
}
EXPORT_SYMBOL_GPL(devlink_info_board_serial_number_put);
+int devlink_info_function_uid_put(struct devlink_info_req *req,
+ const char *fuid)
+{
+ if (!req->msg)
+ return 0;
+ return nla_put_string(req->msg, DEVLINK_ATTR_INFO_FUNCTION_UID, fuid);
+}
+EXPORT_SYMBOL_GPL(devlink_info_function_uid_put);
+
static int devlink_info_version_put(struct devlink_info_req *req, int attr,
const char *version_name,
const char *version_value,