Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F115850986
D44827.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
D44827.diff
View Options
diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c
--- a/sys/net80211/ieee80211.c
+++ b/sys/net80211/ieee80211.c
@@ -434,6 +434,28 @@
IEEE80211_LOCK_DESTROY(ic);
}
+/*
+ * Called by drivers during attach to set the supported
+ * cipher set for software encryption.
+ */
+void
+ieee80211_set_software_ciphers(struct ieee80211com *ic,
+ uint32_t cipher_suite)
+{
+ ieee80211_crypto_set_supported_software_ciphers(ic, cipher_suite);
+}
+
+/*
+ * Called by drivers during attach to set the supported
+ * cipher set for hardware encryption.
+ */
+void
+ieee80211_set_hardware_ciphers(struct ieee80211com *ic,
+ uint32_t cipher_suite)
+{
+ ieee80211_crypto_set_supported_hardware_ciphers(ic, cipher_suite);
+}
+
struct ieee80211com *
ieee80211_find_com(const char *name)
{
diff --git a/sys/net80211/ieee80211_crypto.h b/sys/net80211/ieee80211_crypto.h
--- a/sys/net80211/ieee80211_crypto.h
+++ b/sys/net80211/ieee80211_crypto.h
@@ -162,6 +162,10 @@
void ieee80211_crypto_attach(struct ieee80211com *);
void ieee80211_crypto_detach(struct ieee80211com *);
+void ieee80211_crypto_set_supported_software_ciphers(struct ieee80211com *,
+ uint32_t cipher_set);
+void ieee80211_crypto_set_supported_hardware_ciphers(struct ieee80211com *,
+ uint32_t cipher_set);
void ieee80211_crypto_vattach(struct ieee80211vap *);
void ieee80211_crypto_vdetach(struct ieee80211vap *);
int ieee80211_crypto_newkey(struct ieee80211vap *,
diff --git a/sys/net80211/ieee80211_crypto.c b/sys/net80211/ieee80211_crypto.c
--- a/sys/net80211/ieee80211_crypto.c
+++ b/sys/net80211/ieee80211_crypto.c
@@ -164,6 +164,27 @@
{
}
+/*
+ * Set the supported ciphers for software encryption.
+ */
+void
+ieee80211_crypto_set_supported_software_ciphers(struct ieee80211com *ic,
+ uint32_t cipher_set)
+{
+ ic->ic_sw_cryptocaps = cipher_set;
+}
+
+/*
+ * Set the supported ciphers for hardware encryption.
+ */
+void
+ieee80211_crypto_set_supported_hardware_ciphers(struct ieee80211com *ic,
+ uint32_t cipher_set)
+{
+ ic->ic_cryptocaps = cipher_set;
+}
+
+
/*
* Setup crypto support for a vap.
*/
diff --git a/sys/net80211/ieee80211_var.h b/sys/net80211/ieee80211_var.h
--- a/sys/net80211/ieee80211_var.h
+++ b/sys/net80211/ieee80211_var.h
@@ -751,6 +751,10 @@
int ic_printf(struct ieee80211com *, const char *, ...) __printflike(2, 3);
void ieee80211_ifattach(struct ieee80211com *);
void ieee80211_ifdetach(struct ieee80211com *);
+void ieee80211_set_software_ciphers(struct ieee80211com *,
+ uint32_t cipher_suite);
+void ieee80211_set_hardware_ciphers(struct ieee80211com *,
+ uint32_t cipher_suite);
int ieee80211_vap_setup(struct ieee80211com *, struct ieee80211vap *,
const char name[IFNAMSIZ], int unit,
enum ieee80211_opmode opmode, int flags,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Apr 30, 1:29 PM (30 m, 50 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17858756
Default Alt Text
D44827.diff (2 KB)
Attached To
Mode
D44827: net80211: add driver / crypto methods to set the hardware / software cipher suites
Attached
Detach File
Event Timeline
Log In to Comment