Search Linux Wireless

Re: what dictates p2p0 address?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/21/2012 09:40 AM, George Nychis wrote:
For an ad-hoc or Wifi-Direct interface, which usually seems to be
named p2p0, I'm finding that the MAC address mirrors the Wifi card's
MAC address for octets 2-6, but it seems as though octet 1 is dynamic.
  So, for example:

Wifi: 7c:d1:c3:e0:a6:81
p2p0: 0e:d1:c3:e0:a6:81

This is true across a bunch of devices that I own, but I can't seem to
find a definitive answer to how octet 1 is mutated to choose the p2p0
address.

First dealing with your opening sentence. Not sure if you truly mean ad-hoc here. Do not use that term if you are actually talking about wifi-direct because it is a totally different beast.

The definitive, but unambiguous, answer is in the WFA spec:

"The P2P Device shall assign a P2P Interface Address, corresponding to the format as described in §7.1.3.3.1 of IEEE Std 802.11‑2007 [1], which is used to communicate with the P2P Group Owner or Clients within a P2P Group. A P2P Interface Address is not required to be globally unique and may be locally administered. A P2P Interface Address may be the same as the P2P Device Address provided the requirements for P2P Interface Address in this clause are satisfied."

Actually, the MAC address details are in 802 spec (free IEEE download) in paragraph 9.2. Your p2p0 address has locally administered bit set and fiddle some more bits.

Is this something chosen randomly, or is it a function of some other
part of the address?

Most likely, as you can see from the example, it is derived. This is done in the device (or the driver) so there is no single rule or implementation except the guidelines/requirements from the spec.

Gr. AvS

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux