fix(esp_hw_support): use one universal MAC address for esp32h2/esp32h21/esp32h4

ESP32-H2/H21/H4 only provide a single universally administered MAC
address in eFuse (MAC_FACTORY), so switch their UNIVERSAL_MAC_ADDRESSES
Kconfig from "Two" to "One" to match the hardware allocation.

This is a functional no-op for MAC generation: the BT offset is only
applied when SOC_WIFI_SUPPORTED, and these chips have no Wi-Fi, so
Bluetooth already reuses the base MAC as-is; the IEEE 802.154 EUI-64 is
derived from the base MAC and MAC_EXT regardless. The only change is
the (otherwise unused) ESP_MAC_UNIVERSAL_MAC_ADDRESSES int value going
from 2 to 1.

Co-authored-by: Cursor <cursoragent@cursor.com>
(cherry picked from commit 431983a091)
This commit is contained in:
Jack
2026-07-06 18:08:27 +08:00
parent c7434cc9d9
commit 57184eb356
3 changed files with 15 additions and 15 deletions

View File

@@ -1,18 +1,18 @@
choice ESP32H2_UNIVERSAL_MAC_ADDRESSES
bool "Number of universally administered (by IEEE) MAC address"
default ESP32H2_UNIVERSAL_MAC_ADDRESSES_TWO
default ESP32H2_UNIVERSAL_MAC_ADDRESSES_ONE
help
Configure the number of universally administered (by IEEE) MAC addresses.
During initialization, MAC addresses for each network interface are generated or derived from a
single base MAC address.
config ESP32H2_UNIVERSAL_MAC_ADDRESSES_TWO
bool "Two"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_TWO
config ESP32H2_UNIVERSAL_MAC_ADDRESSES_ONE
bool "One"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_ONE
select ESP_MAC_ADDR_UNIVERSE_IEEE802154
select ESP_MAC_ADDR_UNIVERSE_BT
endchoice
config ESP32H2_UNIVERSAL_MAC_ADDRESSES
int
default 2 if ESP32H2_UNIVERSAL_MAC_ADDRESSES_TWO
default 1 if ESP32H2_UNIVERSAL_MAC_ADDRESSES_ONE

View File

@@ -1,18 +1,18 @@
choice ESP32H21_UNIVERSAL_MAC_ADDRESSES
bool "Number of universally administered (by IEEE) MAC address"
default ESP32H21_UNIVERSAL_MAC_ADDRESSES_TWO
default ESP32H21_UNIVERSAL_MAC_ADDRESSES_ONE
help
Configure the number of universally administered (by IEEE) MAC addresses.
During initialization, MAC addresses for each network interface are generated or derived from a
single base MAC address.
config ESP32H21_UNIVERSAL_MAC_ADDRESSES_TWO
bool "Two"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_TWO
config ESP32H21_UNIVERSAL_MAC_ADDRESSES_ONE
bool "One"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_ONE
select ESP_MAC_ADDR_UNIVERSE_IEEE802154
select ESP_MAC_ADDR_UNIVERSE_BT
endchoice
config ESP32H21_UNIVERSAL_MAC_ADDRESSES
int
default 2 if ESP32H21_UNIVERSAL_MAC_ADDRESSES_TWO
default 1 if ESP32H21_UNIVERSAL_MAC_ADDRESSES_ONE

View File

@@ -1,18 +1,18 @@
choice ESP32H4_UNIVERSAL_MAC_ADDRESSES
bool "Number of universally administered (by IEEE) MAC address"
default ESP32H4_UNIVERSAL_MAC_ADDRESSES_TWO
default ESP32H4_UNIVERSAL_MAC_ADDRESSES_ONE
help
Configure the number of universally administered (by IEEE) MAC addresses.
During initialization, MAC addresses for each network interface are generated or derived from a
single base MAC address.
config ESP32H4_UNIVERSAL_MAC_ADDRESSES_TWO
bool "Two"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_TWO
config ESP32H4_UNIVERSAL_MAC_ADDRESSES_ONE
bool "One"
select ESP_MAC_UNIVERSAL_MAC_ADDRESSES_ONE
select ESP_MAC_ADDR_UNIVERSE_IEEE802154
select ESP_MAC_ADDR_UNIVERSE_BT
endchoice
config ESP32H4_UNIVERSAL_MAC_ADDRESSES
int
default 2 if ESP32H4_UNIVERSAL_MAC_ADDRESSES_TWO
default 1 if ESP32H4_UNIVERSAL_MAC_ADDRESSES_ONE