mirror of
https://github.com/espressif/openthread.git
synced 2026-10-11 10:17:35 +00:00
[dua] completely remove DUA features and configurations (#13191)
This commit removes the OPENTHREAD_CONFIG_TMF_PROXY_DUA_ENABLE feature and all associated code, tests, CLI commands, and harness references. Changes: - Removed OPENTHREAD_CONFIG_TMF_PROXY_DUA_ENABLE definition and all assert/preprocessor checks. - Completely deleted dua_manager.cpp and dua_manager.hpp. - Removed DUA registration notifying and request URI paths. - Cleaned up all references to Domain Unicast Address (DUA) across child management, notifier, time ticker, and MLE. - Removed DUA commands and logic from the CLI and Python cert tests (including packet verifier). - Verified that the entire codebase compiles clean and all tests successfully pass using the Nexus test suite.
This commit is contained in:
@@ -54,7 +54,6 @@ ot_build:
|
||||
- REST_API=0
|
||||
- OT_COMMISSIONER=1
|
||||
options:
|
||||
- "-DOTBR_DUA_ROUTING=ON"
|
||||
- "-DOT_MLR=ON"
|
||||
rcp_subpath: build/ot12/simulation
|
||||
rcp_options:
|
||||
@@ -72,7 +71,6 @@ ot_build:
|
||||
- REST_API=0
|
||||
- EXTERNAL_COMMISSIONER=1
|
||||
options:
|
||||
- "-DOTBR_DUA_ROUTING=ON"
|
||||
- "-DOT_MLR=ON"
|
||||
rcp_subpath: build/ot13/simulation
|
||||
rcp_options:
|
||||
|
||||
@@ -3086,37 +3086,6 @@ class OpenThreadTHCI(object):
|
||||
cmd = 'childip max %d' % int(num)
|
||||
self.__executeCommand(cmd)
|
||||
|
||||
@API
|
||||
def config_next_dua_status_rsp(self, mliid, status_code):
|
||||
if status_code >= 400:
|
||||
# map status_code to correct COAP response code
|
||||
a, b = divmod(status_code, 100)
|
||||
status_code = ((a & 0x7) << 5) + (b & 0x1f)
|
||||
|
||||
cmd = 'bbr mgmt dua %d' % status_code
|
||||
|
||||
if mliid is not None:
|
||||
mliid = mliid.replace(':', '')
|
||||
cmd += ' %s' % mliid
|
||||
|
||||
self.__executeCommand(cmd)
|
||||
|
||||
@API
|
||||
def getDUA(self):
|
||||
dua = self.getGUA('fd00:7d03')
|
||||
return dua
|
||||
|
||||
def __addDefaultDomainPrefix(self):
|
||||
self.configBorderRouter(P_dp=1, P_stable=1, P_on_mesh=1, P_default=1)
|
||||
|
||||
def __setDUA(self, sDua):
|
||||
"""specify the DUA before Thread Starts."""
|
||||
if isinstance(sDua, str):
|
||||
sDua = sDua.decode('utf8')
|
||||
iid = ipaddress.IPv6Address(sDua).packed[-8:]
|
||||
cmd = 'dua iid %s' % ''.join('%02x' % ord(b) for b in iid)
|
||||
return self.__executeCommand(cmd)[-1] == 'Done'
|
||||
|
||||
def __getMlIid(self):
|
||||
"""get the Mesh Local IID."""
|
||||
# getULA64() would return the full string representation
|
||||
@@ -3130,10 +3099,6 @@ class OpenThreadTHCI(object):
|
||||
cmd = 'mliid %s' % sMlIid
|
||||
self.__executeCommand(cmd)
|
||||
|
||||
@API
|
||||
def registerDUA(self, sAddr=''):
|
||||
self.__setDUA(sAddr)
|
||||
|
||||
@API
|
||||
def config_next_mlr_status_rsp(self, status_code):
|
||||
cmd = 'bbr mgmt mlr response %d' % status_code
|
||||
@@ -3185,8 +3150,7 @@ class OpenThreadTHCI(object):
|
||||
@API
|
||||
def migrateNetwork(self, channel=None, net_name=None):
|
||||
"""migrate to another Thread Partition 'net_name' (could be None)
|
||||
on specified 'channel'. Make sure same Mesh Local IID and DUA
|
||||
after migration for DUA-TC-06/06b (DEV-1923)
|
||||
on specified 'channel'.
|
||||
"""
|
||||
if channel is None:
|
||||
raise Exception('channel None')
|
||||
@@ -3197,7 +3161,6 @@ class OpenThreadTHCI(object):
|
||||
print('new partition %s on channel %d' % (net_name, channel))
|
||||
|
||||
mliid = self.__getMlIid()
|
||||
dua = self.getDUA()
|
||||
self.reset()
|
||||
deviceRole = self.deviceRole
|
||||
self.setDefaultValues()
|
||||
@@ -3205,7 +3168,6 @@ class OpenThreadTHCI(object):
|
||||
if net_name is not None:
|
||||
self.setNetworkName(net_name)
|
||||
self.__setMlIid(mliid)
|
||||
self.__setDUA(dua)
|
||||
return self.joinNetwork(deviceRole)
|
||||
|
||||
@API
|
||||
|
||||
@@ -357,14 +357,11 @@ class OpenThread_BR(OpenThreadTHCI, IThci):
|
||||
self.bash(cmd)
|
||||
|
||||
@API
|
||||
def setupHost(self, setDp=False, setDua=False):
|
||||
def setupHost(self, setDp=False):
|
||||
self.IsHost = True
|
||||
|
||||
self.bash('ip -6 addr add 910b::1 dev %s' % self.backboneNetif)
|
||||
|
||||
if setDua:
|
||||
self.bash('ip -6 addr add fd00:7d03:7d03:7d03::1 dev %s' % self.backboneNetif)
|
||||
|
||||
self.__startRadvdService(setDp)
|
||||
|
||||
def _deviceEscapeEscapable(self, string):
|
||||
|
||||
@@ -2436,14 +2436,6 @@ class OTCI(object):
|
||||
#
|
||||
|
||||
# TODO: bbr mgmt ...
|
||||
def set_bbr_dua_response_status(self, status: int, mliid: Optional[str] = None):
|
||||
"""Set Backbone Router Data Unicast Address Response status/coap-code.
|
||||
|
||||
Only for testing/reference devices
|
||||
"""
|
||||
_mliid = mliid if mliid is not None else ""
|
||||
self.execute_command(f'bbr mgmt dua {status} {_mliid}')
|
||||
|
||||
def set_bbr_mlr_response_status(self, status: int):
|
||||
"""Set Backbone Router Multicast Listener Response status."""
|
||||
self.execute_command(f'bbr mgmt mlr response {status}')
|
||||
@@ -2583,7 +2575,7 @@ class OTCI(object):
|
||||
return listeners
|
||||
|
||||
#
|
||||
# Thread 1.2 and DUA/MLR utilities
|
||||
# Thread 1.2 and MLR utilities
|
||||
#
|
||||
|
||||
def get_domain_name(self) -> str:
|
||||
|
||||
Reference in New Issue
Block a user