From nobody Mon Jun 20 14:29:16 2022 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 966F2862BCC; Mon, 20 Jun 2022 14:29:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LRX8Y1chbz4cFH; Mon, 20 Jun 2022 14:29:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655735357; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tQ4NZBVl6UjLVJ/lRjtvFVUWWd75b0ZsnHv48pqu+/s=; b=tHIOy3AKgK4w1e6hho9z8rfZWCptAC1XY46O+uMPKTXHKS7FB2vzOBELXZJYdg9uOoi1VD ByT46UMSGpW8o4YIfUAynLTqNxY52o/TqXcsG8J+8iykZNyX6VcWp24Rk5MqCX3GfiFQGR x8YrtRcS/yLRrSha5vdFsZ2hZGdSkJPtKrayLN0kWKH8kIFk83CY1FIpK98X1kaDDNHRWI An382dy/bEjvVWOX8A6MbRE/VHvooS4QVk7OUNzc7AyWJAwK87jA34gIEPP9aRbhjtJFFV YIW4RLnErSLe0P2dZXEeXh9Lsc7aQZAUdkhEIzgOQSJqvriaQyKA8beOWc6dWw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0F31A1EB69; Mon, 20 Jun 2022 14:29:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 25KETGAI036421; Mon, 20 Jun 2022 14:29:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 25KETGxM036420; Mon, 20 Jun 2022 14:29:16 GMT (envelope-from git) Date: Mon, 20 Jun 2022 14:29:16 GMT Message-Id: <202206201429.25KETGxM036420@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Cy Schubert Subject: git: 05a849eec9d9 - main - */*: Restore a missing wpa BSD driver patch List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: cy X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 05a849eec9d949b3de32e464570cefbabcd64702 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655735357; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tQ4NZBVl6UjLVJ/lRjtvFVUWWd75b0ZsnHv48pqu+/s=; b=xBux6QYfmC4QtIEC1HTH2W3eD8e9mcuElYrfPgVvL8NqYvk/BASzVLsG9elXMr88cJZ1cr 9SN2+WgzJXd/mz9KQbWQnd0W+79WkOWuNW6GFrI3aH7JH41YGsNtduNhmo+05yhAz4bFhL 5MjXPmIc9kQKArxmnkaeddxD7fPsrgT7594EOGTbKKEAn/GThrlm64oUaxAa1zbSEq4gdP Odw6gp9gvg0Gs0cAxz0MG5fQRXXTWDtWAVF1D8Mey/rWJ1svTTz9k55Hk/aAPmBEdiJ7ha VTn6pWnjUFg1I64hGQ5Q662gG9QX2IWs1Wd0LaIER4mz0mWyhT8zANIZZyR8HA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1655735357; a=rsa-sha256; cv=none; b=cDhwi7jNcmjMhVDqJ/fsdo4sMK0hyy7Dy7StU8axyRX3J9X/NPPiZZTfOeqoTHOwGVnJ0o ZE5+1s5QQB6ssy81U8+dokFdDu9AOqc1oXdD4QlZ9lHYtaXnKlmsQ0Ok8f6TVouZx0OU64 uYnEja6HdZUXLSe18x03JH0oEyRZEETKM8GPFZf4/bvVvg4kFZJX5YWfoLnWbFf7SaVqYV SOlSyja0U19c5hl9NUT5ae/mQHxHmx/XSjf2eLZTXSkw8hyQKvSUj49+3qiWAecmkmEaq/ Q5A/pTy3dTKAwOpCSWcVaQbNh1BdKw/jqnAJgN4RKkvZDxvb1D49bDeNIL6aaQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by cy: URL: https://cgit.FreeBSD.org/ports/commit/?id=05a849eec9d949b3de32e464570cefbabcd64702 commit 05a849eec9d949b3de32e464570cefbabcd64702 Author: Cy Schubert AuthorDate: 2022-06-20 14:25:42 +0000 Commit: Cy Schubert CommitDate: 2022-06-20 14:29:09 +0000 */*: Restore a missing wpa BSD driver patch These patches were removed to sync with base where in fact base was missing these patches and base should have been synced with the ports. PR: 264238 Fixes: b8477825c2dc42f6c595697a36f593c71f39fbad c86f32d652eb9dd023049122d8ca37cb13ed07b6 MFH: 2022Q2 --- net/hostapd-devel/Makefile | 2 +- .../files/patch-src_drivers_driver__bsd.c | 65 +++++++++++++++++++++- net/hostapd/Makefile | 2 +- net/hostapd/files/patch-src_drivers_driver__bsd.c | 65 +++++++++++++++++++++- security/wpa_supplicant-devel/Makefile | 2 +- .../files/patch-src_drivers_driver__bsd.c | 65 +++++++++++++++++++++- security/wpa_supplicant/Makefile | 2 +- .../files/patch-src_drivers_driver__bsd.c | 65 +++++++++++++++++++++- 8 files changed, 256 insertions(+), 12 deletions(-) diff --git a/net/hostapd-devel/Makefile b/net/hostapd-devel/Makefile index e3e48c5dc457..907873af49a0 100644 --- a/net/hostapd-devel/Makefile +++ b/net/hostapd-devel/Makefile @@ -2,7 +2,7 @@ PORTNAME= hostapd PORTVERSION= ${COMMIT_DATE} -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= net PKGNAMESUFFIX= -devel diff --git a/net/hostapd-devel/files/patch-src_drivers_driver__bsd.c b/net/hostapd-devel/files/patch-src_drivers_driver__bsd.c index f56c30c30ad3..dda055f26664 100644 --- a/net/hostapd-devel/files/patch-src_drivers_driver__bsd.c +++ b/net/hostapd-devel/files/patch-src_drivers_driver__bsd.c @@ -1,5 +1,5 @@ ---- src/drivers/driver_bsd.c.orig 2021-06-02 14:11:18.000000000 -0700 -+++ src/drivers/driver_bsd.c 2021-06-13 23:11:15.089256000 -0700 +--- src/drivers/driver_bsd.c.orig 2022-05-24 13:30:39.000000000 -0700 ++++ src/drivers/driver_bsd.c 2022-06-20 07:18:14.191871000 -0700 @@ -853,14 +853,18 @@ drv = bsd_get_drvindex(global, ifm->ifm_index); if (drv == NULL) @@ -21,3 +21,64 @@ + (drv->flags & IFF_RUNNING) == 0)) { wpa_printf(MSG_DEBUG, "RTM_IFINFO: Interface '%s' UP", drv->ifname); + wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, +@@ -1220,7 +1224,10 @@ + mode = 0 /* STA */; + break; + case IEEE80211_MODE_IBSS: ++#if 0 + mode = IFM_IEEE80211_IBSS; ++#endif ++ mode = IFM_IEEE80211_ADHOC; + break; + case IEEE80211_MODE_AP: + mode = IFM_IEEE80211_HOSTAP; +@@ -1267,6 +1274,13 @@ + params->wpa_ie[0] == WLAN_EID_RSN ? 2 : 1) < 0) + return -1; + ++ /* ++ * NB: interface must be marked UP for association ++ * or scanning (ap_scan=2) ++ */ ++ if (bsd_get_iface_flags(drv) < 0) ++ return -1; ++ + os_memset(&mlme, 0, sizeof(mlme)); + mlme.im_op = IEEE80211_MLME_ASSOC; + if (params->ssid != NULL) +@@ -1485,6 +1499,17 @@ + if (devcaps.dc_drivercaps & IEEE80211_C_WPA2) + drv->capa.key_mgmt = WPA_DRIVER_CAPA_KEY_MGMT_WPA2 | + WPA_DRIVER_CAPA_KEY_MGMT_WPA2_PSK; ++#ifdef __FreeBSD__ ++ drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | ++ WPA_DRIVER_CAPA_ENC_WEP104 | ++ WPA_DRIVER_CAPA_ENC_TKIP | ++ WPA_DRIVER_CAPA_ENC_CCMP; ++#else ++ /* ++ * XXX ++ * FreeBSD exports hardware cryptocaps. These have no meaning for wpa ++ * since net80211 performs software crypto. ++ */ + + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_WEP) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | +@@ -1493,6 +1518,7 @@ + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_TKIP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_CCM) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_CCMP; ++#endif + + if (devcaps.dc_drivercaps & IEEE80211_C_HOSTAP) + drv->capa.flags |= WPA_DRIVER_FLAGS_AP; +@@ -1545,6 +1571,8 @@ + } + if (ifmr.ifm_current & IFM_IEEE80211_HOSTAP) + return IEEE80211_M_HOSTAP; ++ if (ifmr.ifm_current & IFM_IEEE80211_IBSS) ++ return IEEE80211_M_IBSS; + if (ifmr.ifm_current & IFM_IEEE80211_MONITOR) + return IEEE80211_M_MONITOR; + #ifdef IEEE80211_M_MBSS diff --git a/net/hostapd/Makefile b/net/hostapd/Makefile index 5cd5d4fea22f..114041a960bb 100644 --- a/net/hostapd/Makefile +++ b/net/hostapd/Makefile @@ -2,7 +2,7 @@ PORTNAME= hostapd PORTVERSION= 2.10 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= net MASTER_SITES= https://w1.fi/releases/ diff --git a/net/hostapd/files/patch-src_drivers_driver__bsd.c b/net/hostapd/files/patch-src_drivers_driver__bsd.c index f56c30c30ad3..2c49538712af 100644 --- a/net/hostapd/files/patch-src_drivers_driver__bsd.c +++ b/net/hostapd/files/patch-src_drivers_driver__bsd.c @@ -1,5 +1,5 @@ ---- src/drivers/driver_bsd.c.orig 2021-06-02 14:11:18.000000000 -0700 -+++ src/drivers/driver_bsd.c 2021-06-13 23:11:15.089256000 -0700 +--- src/drivers/driver_bsd.c.orig 2022-01-16 12:51:29.000000000 -0800 ++++ src/drivers/driver_bsd.c 2022-06-20 07:14:50.617305000 -0700 @@ -853,14 +853,18 @@ drv = bsd_get_drvindex(global, ifm->ifm_index); if (drv == NULL) @@ -21,3 +21,64 @@ + (drv->flags & IFF_RUNNING) == 0)) { wpa_printf(MSG_DEBUG, "RTM_IFINFO: Interface '%s' UP", drv->ifname); + wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, +@@ -1220,7 +1224,10 @@ + mode = 0 /* STA */; + break; + case IEEE80211_MODE_IBSS: ++#if 0 + mode = IFM_IEEE80211_IBSS; ++#endif ++ mode = IFM_IEEE80211_ADHOC; + break; + case IEEE80211_MODE_AP: + mode = IFM_IEEE80211_HOSTAP; +@@ -1267,6 +1274,13 @@ + params->wpa_ie[0] == WLAN_EID_RSN ? 2 : 1) < 0) + return -1; + ++ /* ++ * NB: interface must be marked UP for association ++ * or scanning (ap_scan=2) ++ */ ++ if (bsd_get_iface_flags(drv) < 0) ++ return -1; ++ + os_memset(&mlme, 0, sizeof(mlme)); + mlme.im_op = IEEE80211_MLME_ASSOC; + if (params->ssid != NULL) +@@ -1485,6 +1499,17 @@ + if (devcaps.dc_drivercaps & IEEE80211_C_WPA2) + drv->capa.key_mgmt = WPA_DRIVER_CAPA_KEY_MGMT_WPA2 | + WPA_DRIVER_CAPA_KEY_MGMT_WPA2_PSK; ++#ifdef __FreeBSD__ ++ drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | ++ WPA_DRIVER_CAPA_ENC_WEP104 | ++ WPA_DRIVER_CAPA_ENC_TKIP | ++ WPA_DRIVER_CAPA_ENC_CCMP; ++#else ++ /* ++ * XXX ++ * FreeBSD exports hardware cryptocaps. These have no meaning for wpa ++ * since net80211 performs software crypto. ++ */ + + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_WEP) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | +@@ -1493,6 +1518,7 @@ + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_TKIP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_CCM) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_CCMP; ++#endif + + if (devcaps.dc_drivercaps & IEEE80211_C_HOSTAP) + drv->capa.flags |= WPA_DRIVER_FLAGS_AP; +@@ -1545,6 +1571,8 @@ + } + if (ifmr.ifm_current & IFM_IEEE80211_HOSTAP) + return IEEE80211_M_HOSTAP; ++ if (ifmr.ifm_current & IFM_IEEE80211_IBSS) ++ return IEEE80211_M_IBSS; + if (ifmr.ifm_current & IFM_IEEE80211_MONITOR) + return IEEE80211_M_MONITOR; + #ifdef IEEE80211_M_MBSS diff --git a/security/wpa_supplicant-devel/Makefile b/security/wpa_supplicant-devel/Makefile index 6d83310e50da..d972b2c5c512 100644 --- a/security/wpa_supplicant-devel/Makefile +++ b/security/wpa_supplicant-devel/Makefile @@ -1,6 +1,6 @@ PORTNAME= wpa_supplicant PORTVERSION= ${COMMIT_DATE} -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= security net PKGNAMESUFFIX= -devel diff --git a/security/wpa_supplicant-devel/files/patch-src_drivers_driver__bsd.c b/security/wpa_supplicant-devel/files/patch-src_drivers_driver__bsd.c index decf9a3aebdc..6a400fd174c2 100644 --- a/security/wpa_supplicant-devel/files/patch-src_drivers_driver__bsd.c +++ b/security/wpa_supplicant-devel/files/patch-src_drivers_driver__bsd.c @@ -1,5 +1,5 @@ ---- src/drivers/driver_bsd.c.orig 2021-06-02 14:11:18.000000000 -0700 -+++ src/drivers/driver_bsd.c 2021-06-13 23:08:54.275496000 -0700 +--- src/drivers/driver_bsd.c.orig 2022-05-24 13:30:39.000000000 -0700 ++++ src/drivers/driver_bsd.c 2022-06-20 07:13:36.571991000 -0700 @@ -853,14 +853,18 @@ drv = bsd_get_drvindex(global, ifm->ifm_index); if (drv == NULL) @@ -21,3 +21,64 @@ + (drv->flags & IFF_RUNNING) == 0)) { wpa_printf(MSG_DEBUG, "RTM_IFINFO: Interface '%s' UP", drv->ifname); + wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, +@@ -1220,7 +1224,10 @@ + mode = 0 /* STA */; + break; + case IEEE80211_MODE_IBSS: ++#if 0 + mode = IFM_IEEE80211_IBSS; ++#endif ++ mode = IFM_IEEE80211_ADHOC; + break; + case IEEE80211_MODE_AP: + mode = IFM_IEEE80211_HOSTAP; +@@ -1267,6 +1274,13 @@ + params->wpa_ie[0] == WLAN_EID_RSN ? 2 : 1) < 0) + return -1; + ++ /* ++ * NB: interface must be marked UP for association ++ * or scanning (ap_scan=2) ++ */ ++ if (bsd_get_iface_flags(drv) < 0) ++ return -1; ++ + os_memset(&mlme, 0, sizeof(mlme)); + mlme.im_op = IEEE80211_MLME_ASSOC; + if (params->ssid != NULL) +@@ -1485,6 +1499,17 @@ + if (devcaps.dc_drivercaps & IEEE80211_C_WPA2) + drv->capa.key_mgmt = WPA_DRIVER_CAPA_KEY_MGMT_WPA2 | + WPA_DRIVER_CAPA_KEY_MGMT_WPA2_PSK; ++#ifdef __FreeBSD__ ++ drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | ++ WPA_DRIVER_CAPA_ENC_WEP104 | ++ WPA_DRIVER_CAPA_ENC_TKIP | ++ WPA_DRIVER_CAPA_ENC_CCMP; ++#else ++ /* ++ * XXX ++ * FreeBSD exports hardware cryptocaps. These have no meaning for wpa ++ * since net80211 performs software crypto. ++ */ + + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_WEP) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | +@@ -1493,6 +1518,7 @@ + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_TKIP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_CCM) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_CCMP; ++#endif + + if (devcaps.dc_drivercaps & IEEE80211_C_HOSTAP) + drv->capa.flags |= WPA_DRIVER_FLAGS_AP; +@@ -1545,6 +1571,8 @@ + } + if (ifmr.ifm_current & IFM_IEEE80211_HOSTAP) + return IEEE80211_M_HOSTAP; ++ if (ifmr.ifm_current & IFM_IEEE80211_IBSS) ++ return IEEE80211_M_IBSS; + if (ifmr.ifm_current & IFM_IEEE80211_MONITOR) + return IEEE80211_M_MONITOR; + #ifdef IEEE80211_M_MBSS diff --git a/security/wpa_supplicant/Makefile b/security/wpa_supplicant/Makefile index 0248141d32b2..1b3e5889d2c6 100644 --- a/security/wpa_supplicant/Makefile +++ b/security/wpa_supplicant/Makefile @@ -1,6 +1,6 @@ PORTNAME= wpa_supplicant PORTVERSION= 2.10 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= security net MASTER_SITES= https://w1.fi/releases/ diff --git a/security/wpa_supplicant/files/patch-src_drivers_driver__bsd.c b/security/wpa_supplicant/files/patch-src_drivers_driver__bsd.c index decf9a3aebdc..440233164126 100644 --- a/security/wpa_supplicant/files/patch-src_drivers_driver__bsd.c +++ b/security/wpa_supplicant/files/patch-src_drivers_driver__bsd.c @@ -1,5 +1,5 @@ ---- src/drivers/driver_bsd.c.orig 2021-06-02 14:11:18.000000000 -0700 -+++ src/drivers/driver_bsd.c 2021-06-13 23:08:54.275496000 -0700 +--- src/drivers/driver_bsd.c.orig 2022-01-16 12:51:29.000000000 -0800 ++++ src/drivers/driver_bsd.c 2022-06-20 07:11:44.629814000 -0700 @@ -853,14 +853,18 @@ drv = bsd_get_drvindex(global, ifm->ifm_index); if (drv == NULL) @@ -21,3 +21,64 @@ + (drv->flags & IFF_RUNNING) == 0)) { wpa_printf(MSG_DEBUG, "RTM_IFINFO: Interface '%s' UP", drv->ifname); + wpa_supplicant_event(drv->ctx, EVENT_INTERFACE_ENABLED, +@@ -1220,7 +1224,10 @@ + mode = 0 /* STA */; + break; + case IEEE80211_MODE_IBSS: ++#if 0 + mode = IFM_IEEE80211_IBSS; ++#endif ++ mode = IFM_IEEE80211_ADHOC; + break; + case IEEE80211_MODE_AP: + mode = IFM_IEEE80211_HOSTAP; +@@ -1267,6 +1274,13 @@ + params->wpa_ie[0] == WLAN_EID_RSN ? 2 : 1) < 0) + return -1; + ++ /* ++ * NB: interface must be marked UP for association ++ * or scanning (ap_scan=2) ++ */ ++ if (bsd_get_iface_flags(drv) < 0) ++ return -1; ++ + os_memset(&mlme, 0, sizeof(mlme)); + mlme.im_op = IEEE80211_MLME_ASSOC; + if (params->ssid != NULL) +@@ -1485,6 +1499,17 @@ + if (devcaps.dc_drivercaps & IEEE80211_C_WPA2) + drv->capa.key_mgmt = WPA_DRIVER_CAPA_KEY_MGMT_WPA2 | + WPA_DRIVER_CAPA_KEY_MGMT_WPA2_PSK; ++#ifdef __FreeBSD__ ++ drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | ++ WPA_DRIVER_CAPA_ENC_WEP104 | ++ WPA_DRIVER_CAPA_ENC_TKIP | ++ WPA_DRIVER_CAPA_ENC_CCMP; ++#else ++ /* ++ * XXX ++ * FreeBSD exports hardware cryptocaps. These have no meaning for wpa ++ * since net80211 performs software crypto. ++ */ + + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_WEP) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_WEP40 | +@@ -1493,6 +1518,7 @@ + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_TKIP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_CCM) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_CCMP; ++#endif + + if (devcaps.dc_drivercaps & IEEE80211_C_HOSTAP) + drv->capa.flags |= WPA_DRIVER_FLAGS_AP; +@@ -1545,6 +1571,8 @@ + } + if (ifmr.ifm_current & IFM_IEEE80211_HOSTAP) + return IEEE80211_M_HOSTAP; ++ if (ifmr.ifm_current & IFM_IEEE80211_IBSS) ++ return IEEE80211_M_IBSS; + if (ifmr.ifm_current & IFM_IEEE80211_MONITOR) + return IEEE80211_M_MONITOR; + #ifdef IEEE80211_M_MBSS