From owner-p4-projects@FreeBSD.ORG Wed Apr 2 20:47:02 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 96C5A1065732; Wed, 2 Apr 2008 20:47:02 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4C8CE106571C for ; Wed, 2 Apr 2008 20:47:01 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id D51AD8FC15 for ; Wed, 2 Apr 2008 20:47:01 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m32Kl1kC057450 for ; Wed, 2 Apr 2008 20:47:01 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m32Kl1lA057448 for perforce@freebsd.org; Wed, 2 Apr 2008 20:47:01 GMT (envelope-from sam@freebsd.org) Date: Wed, 2 Apr 2008 20:47:01 GMT Message-Id: <200804022047.m32Kl1lA057448@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Cc: Subject: PERFORCE change 139239 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Apr 2008 20:47:03 -0000 http://perforce.freebsd.org/chv.cgi?CH=139239 Change 139239 by sam@sam_ebb on 2008/04/02 20:46:28 remove iv_cryptocaps; crypto capabilities are a property of the driver/device so they should never be different from one vap to another Affected files ... .. //depot/projects/vap/sys/net80211/ieee80211.c#34 edit .. //depot/projects/vap/sys/net80211/ieee80211_crypto.c#13 edit .. //depot/projects/vap/sys/net80211/ieee80211_ddb.c#11 edit .. //depot/projects/vap/sys/net80211/ieee80211_var.h#37 edit Differences ... ==== //depot/projects/vap/sys/net80211/ieee80211.c#34 (text+ko) ==== @@ -324,7 +324,6 @@ vap->iv_flags_ext = ic->ic_flags_ext; vap->iv_flags_ven = ic->ic_flags_ven; vap->iv_caps = ic->ic_caps &~ IEEE80211_C_OPMODE; - vap->iv_cryptocaps = ic->ic_cryptocaps; vap->iv_htcaps = ic->ic_htcaps; vap->iv_opmode = opmode; switch (opmode) { ==== //depot/projects/vap/sys/net80211/ieee80211_crypto.c#13 (text+ko) ==== @@ -262,6 +262,7 @@ ieee80211_crypto_newkey(struct ieee80211vap *vap, int cipher, int flags, struct ieee80211_key *key) { + struct ieee80211com *ic = vap->iv_ic; const struct ieee80211_cipher *cip; ieee80211_keyix keyix, rxkeyix; void *keyctx; @@ -309,7 +310,7 @@ * If the hardware does not support the cipher then * fallback to a host-based implementation. */ - if ((vap->iv_cryptocaps & (1<ic_cryptocaps & (1<ic_name); @@ -321,7 +322,7 @@ * the cipher modules honor it. */ if (cipher == IEEE80211_CIPHER_TKIP && - (vap->iv_cryptocaps & IEEE80211_CRYPTO_TKIPMIC) == 0) { + (ic->ic_cryptocaps & IEEE80211_CRYPTO_TKIPMIC) == 0) { IEEE80211_DPRINTF(vap, IEEE80211_MSG_CRYPTO, "%s: no h/w support for TKIP MIC, falling back to s/w\n", __func__); ==== //depot/projects/vap/sys/net80211/ieee80211_ddb.c#11 (text+ko) ==== @@ -330,8 +330,6 @@ db_printf("\tflags_ext=%b\n", vap->iv_flags_ext, IEEE80211_FEXT_BITS); db_printf("\tflags_ven=%b\n", vap->iv_flags_ven, IEEE80211_FVEN_BITS); db_printf("\tcaps=%b\n", vap->iv_caps, IEEE80211_C_BITS); - db_printf("\tcryptocaps=%b\n", - vap->iv_cryptocaps, IEEE80211_C_CRYPTO_BITS); db_printf("\thtcaps=%b\n", vap->iv_htcaps, IEEE80211_C_HTCAP_BITS); _db_show_stats(&vap->iv_stats); ==== //depot/projects/vap/sys/net80211/ieee80211_var.h#37 (text+ko) ==== @@ -293,7 +293,6 @@ uint32_t iv_flags_ven; /* vendor state flags */ uint32_t iv_caps; /* capabilities */ uint32_t iv_htcaps; /* HT capabilities */ - uint32_t iv_cryptocaps; /* crypto capabilities */ enum ieee80211_opmode iv_opmode; /* operation mode */ enum ieee80211_state iv_state; /* state machine state */ void (*iv_newstate_cb)(struct ieee80211vap *,