aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/sfxge/common/efx.h
diff options
context:
space:
mode:
authorAndrew Rybchenko <arybchik@FreeBSD.org>2016-01-14 09:19:28 +0000
committerAndrew Rybchenko <arybchik@FreeBSD.org>2016-01-14 09:19:28 +0000
commit0c848230f72ce4108cfc3fc6904fb55b8d66b614 (patch)
tree22138f121a0010e538dd71600c9e16ad6a4e0be3 /sys/dev/sfxge/common/efx.h
parentdc5427fc70618fbe5f10b2dd8a8bdbcb2ba0ce5b (diff)
downloadsrc-0c848230f72ce4108cfc3fc6904fb55b8d66b614.tar.gz
src-0c848230f72ce4108cfc3fc6904fb55b8d66b614.zip
sfxge: add accessors for license-related MCDI calls to common code
Add support for Huntington MCDI licensing interface to common code. Ported from Linux net driver IOCTL functions with restructuring for initial support for V3 licensing API. Submitted by: Richard Houldsworth <rhouldsworth at solarflare.com> Reviewed by: gnn Sponsored by: Solarflare Communications, Inc. MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D4918
Notes
Notes: svn path=/head/; revision=293901
Diffstat (limited to 'sys/dev/sfxge/common/efx.h')
-rw-r--r--sys/dev/sfxge/common/efx.h51
1 files changed, 51 insertions, 0 deletions
diff --git a/sys/dev/sfxge/common/efx.h b/sys/dev/sfxge/common/efx.h
index cf629625089f..9f6dab9266d8 100644
--- a/sys/dev/sfxge/common/efx.h
+++ b/sys/dev/sfxge/common/efx.h
@@ -2310,6 +2310,57 @@ efx_hash_bytes(
__in size_t length,
__in uint32_t init);
+#if EFSYS_OPT_LICENSING
+
+/* LICENSING */
+
+typedef struct efx_key_stats_s {
+ uint32_t eks_valid;
+ uint32_t eks_invalid;
+ uint32_t eks_blacklisted;
+ uint32_t eks_unverifiable;
+ uint32_t eks_wrong_node;
+ uint32_t eks_licensed_apps_lo;
+ uint32_t eks_licensed_apps_hi;
+ uint32_t eks_licensed_features_lo;
+ uint32_t eks_licensed_features_hi;
+} efx_key_stats_t;
+
+extern __checkReturn efx_rc_t
+efx_lic_init(
+ __in efx_nic_t *enp);
+
+extern void
+efx_lic_fini(
+ __in efx_nic_t *enp);
+
+extern __checkReturn efx_rc_t
+efx_lic_update_licenses(
+ __in efx_nic_t *enp);
+
+extern __checkReturn efx_rc_t
+efx_lic_get_key_stats(
+ __in efx_nic_t *enp,
+ __out efx_key_stats_t *ksp);
+
+extern __checkReturn efx_rc_t
+efx_lic_app_state(
+ __in efx_nic_t *enp,
+ __in uint64_t app_id,
+ __out boolean_t *licensedp);
+
+extern __checkReturn efx_rc_t
+efx_lic_get_id(
+ __in efx_nic_t *enp,
+ __in size_t buffer_size,
+ __out uint32_t *typep,
+ __out size_t *lengthp,
+ __out_opt uint8_t *bufferp);
+
+
+#endif /* EFSYS_OPT_LICENSING */
+
+
#ifdef __cplusplus
}