When in infrastructure mode, use address 3 from the 802.11 header as the
source address when receiving frames (and keep using address 2 when in pseudo-IBSS mode). This is apparently necessary in order to obtain the true MAC address of the sending station which is needed for PPPoE. Patch supplied by: Blaz Zupan <blaz@amis.net>
This commit is contained in:
parent
2a70f2122a
commit
339dabccd7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=59328
@ -391,8 +391,13 @@ static void wi_rxeof(sc)
|
||||
|
||||
bcopy((char *)&rx_frame.wi_addr1,
|
||||
(char *)&eh->ether_dhost, ETHER_ADDR_LEN);
|
||||
bcopy((char *)&rx_frame.wi_addr2,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
if (sc->wi_ptype == WI_PORTTYPE_ADHOC) {
|
||||
bcopy((char *)&rx_frame.wi_addr2,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
} else {
|
||||
bcopy((char *)&rx_frame.wi_addr3,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
}
|
||||
bcopy((char *)&rx_frame.wi_type,
|
||||
(char *)&eh->ether_type, sizeof(u_int16_t));
|
||||
|
||||
|
@ -391,8 +391,13 @@ static void wi_rxeof(sc)
|
||||
|
||||
bcopy((char *)&rx_frame.wi_addr1,
|
||||
(char *)&eh->ether_dhost, ETHER_ADDR_LEN);
|
||||
bcopy((char *)&rx_frame.wi_addr2,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
if (sc->wi_ptype == WI_PORTTYPE_ADHOC) {
|
||||
bcopy((char *)&rx_frame.wi_addr2,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
} else {
|
||||
bcopy((char *)&rx_frame.wi_addr3,
|
||||
(char *)&eh->ether_shost, ETHER_ADDR_LEN);
|
||||
}
|
||||
bcopy((char *)&rx_frame.wi_type,
|
||||
(char *)&eh->ether_type, sizeof(u_int16_t));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user