--- ipw2200-1.0.12/ipw2200.c.orig 2006-02-18 16:13:18.000000000 +0100 +++ ipw2200-1.0.12/ipw2200.c 2006-02-18 16:31:53.000000000 +0100 @@ -8014,7 +8014,11 @@ /* HW decrypt will not clear the WEP bit, MIC, PN, etc. */ hdr = (struct ieee80211_hdr_4addr *)rxb->skb->data; if (priv->ieee->iw_mode != IW_MODE_MONITOR && - (is_multicast_ether_addr(hdr->addr1) ? +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) + ((is_multicast_ether_addr(hdr->addr1) || is_broadcast_ether_addr(hdr->addr1)) ? +#else + (is_multicast_ether_addr(hdr->addr1)) ? +#endif !priv->ieee->host_mc_decrypt : !priv->ieee->host_decrypt)) ipw_rebuild_decrypted_skb(priv, rxb->skb); @@ -8205,7 +8209,12 @@ return 0; /* {broad,multi}cast packets to our BSSID go through */ +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) + if ((is_multicast_ether_addr(header->addr1)) || + is_broadcast_ether_addr(header->addr1)) +#else if (is_multicast_ether_addr(header->addr1)) +#endif return !memcmp(header->addr3, priv->bssid, ETH_ALEN); /* packets to our adapter go through */ @@ -8218,7 +8227,12 @@ return 0; /* {broad,multi}cast packets to our BSS go through */ +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) + if ((is_multicast_ether_addr(header->addr1)) || + is_broadcast_ether_addr(header->addr1)) +#else if (is_multicast_ether_addr(header->addr1)) +#endif return !memcmp(header->addr2, priv->bssid, ETH_ALEN); /* packets to our adapter go through */ @@ -10229,7 +10243,12 @@ switch (priv->ieee->iw_mode) { case IW_MODE_ADHOC: hdr_len = IEEE80211_3ADDR_LEN; - unicast = !is_multicast_ether_addr(hdr->addr1); +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) + unicast = !(is_multicast_ether_addr(hdr->addr1) || + is_broadcast_ether_addr(hdr->addr1)); +#else + unicast = !(is_multicast_ether_addr(hdr->addr1)); +#endif id = ipw_find_station(priv, hdr->addr1); if (id == IPW_INVALID_STATION) { id = ipw_add_station(priv, hdr->addr1); @@ -10244,7 +10263,12 @@ case IW_MODE_INFRA: default: - unicast = !is_multicast_ether_addr(hdr->addr3); +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) + unicast = !(is_multicast_ether_addr(hdr->addr3) || + is_broadcast_ether_addr(hdr->addr3)); +#else + unicast = !(is_multicast_ether_addr(hdr->addr3)); +#endif hdr_len = IEEE80211_3ADDR_LEN; id = 0; break;