Skip to content

Commit

Permalink
Update Sleepy -> Session in context of active/idle intervals
Browse files Browse the repository at this point in the history
  • Loading branch information
samadDotDev committed Feb 14, 2024
1 parent faffa65 commit 047e31f
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions src/app/tests/suites/TestDiscovery.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ tests:
- name: "productId"
value: productId

- label: "Optional TXT key for MRP Sleepy Idle Interval (SII)"
- label: "Optional TXT key for MRP Session Idle Interval (SII)"
PICS: MCORE.SC.SII_COMM_DISCOVERY_KEY
cluster: "DiscoveryCommands"
command: "FindCommissionable"
Expand All @@ -214,7 +214,7 @@ tests:
minValue: 0
maxValue: 3600000

- label: "Optional TXT key for MRP Sleepy Active Interval (SAI)"
- label: "Optional TXT key for MRP Session Active Interval (SAI)"
PICS: MCORE.SC.SAI_COMM_DISCOVERY_KEY
cluster: "DiscoveryCommands"
command: "FindCommissionable"
Expand Down
4 changes: 2 additions & 2 deletions src/app/tests/suites/certification/Test_TC_SC_3_3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ tests:
responderSessionID is of uint16
sigma2ResumeMIC is of Octet String maximum of length 16 bytes
responderSEDParams is from any one of the following:
SLEEPY_IDLE_INTERVAL - Verify that it is of uint32
SLEEPY_ACTIVE_INTERVAL - Verify that it is of uint32
SESSION_IDLE_INTERVAL - Verify that it is of uint32
SESSION_ACTIVE_INTERVAL - Verify that it is of uint32
[1683973658.044236][21637:21637] CHIP:EM: Rxd Ack; Removing MessageCounter:113416101 from Retrans Table on exchange 32995r
Expand Down
2 changes: 1 addition & 1 deletion src/app/tests/suites/certification/Test_TC_SC_4_10.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ tests:
verification: |
avahi-browse -rt _matter._tcp
On the TH(Chip-tool) Log: Verify the DUT is advertising for:
- SII key is higher than the SLEEPY_IDLE_INTERVAL default value (> 500 milliseconds)
- SII key is higher than the SESSION_IDLE_INTERVAL default value (> 500 milliseconds)
- SII key and SAI key is less than 3600000 (1hour in milliseconds)
+ eth0 IPv6 3A235FF3FA2DAC10-0000000000000055 _matter._tcp local
Expand Down
2 changes: 1 addition & 1 deletion src/lib/dnssd/Types.h
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ struct CommonResolutionData

bool IsDeviceTreatedAsSleepy(const ReliableMessageProtocolConfig * defaultMRPConfig) const
{
// If either sleepy interval (Idle - SII, Active - SAI) has a value and that value is greater
// If either session interval (Idle - SII, Active - SAI) has a value and that value is greater
// than the value passed to this function, then the peer device will be treated as if it is
// a Sleepy End Device (SED)
return (mrpRetryIntervalIdle.HasValue() && (mrpRetryIntervalIdle.Value() > defaultMRPConfig->mIdleRetransTimeout)) ||
Expand Down
6 changes: 3 additions & 3 deletions src/lib/dnssd/tests/TestIncrementalResolve.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ void TestParseOperational(nlTestSuite * inSuite, void * inContext)
{
const char * entries[] = {
"foo=bar", // unused data
"SII=23" // sleepy idle interval
"SII=23" // session idle interval
};

CallOnRecord(inSuite, resolver, TxtResourceRecord(kTestOperationalName.Full(), entries));
Expand Down Expand Up @@ -369,7 +369,7 @@ void TestParseCommissionable(nlTestSuite * inSuite, void * inContext)
{
const char * entries[] = {
"some", "foo=bar", "x=y=z", "a=", // unused data
"SII=123" // Sleepy idle interval
"SII=123" // session idle interval
};

CallOnRecord(inSuite, resolver, TxtResourceRecord(kTestHostName.Full(), entries));
Expand All @@ -381,7 +381,7 @@ void TestParseCommissionable(nlTestSuite * inSuite, void * inContext)
{
const char * entries[] = {
"foo=bar", // unused data
"SAI=321", // sleepy active interval
"SAI=321", // session active interval
"D=22345", // Long discriminator
"VP=321+654", // VendorProduct
"DN=mytest" // Device name
Expand Down
2 changes: 1 addition & 1 deletion src/messaging/ReliableMessageProtocolConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ namespace chip {
* timeout when it sends a message to the present node and the present node is
* perceived by the peer as active.
*
* This value is announced to the peer using SAI (Sleepy Active Interval) key
* This value is announced to the peer using SAI (Session Active Interval) key
* in the advertised DNS Service Discovery TXT records. Additionally, it is
* exchanged in the initial phase of the PASE/CASE session establishment.
*
Expand Down
4 changes: 2 additions & 2 deletions src/protocols/secure_channel/RendezvousParameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ namespace chip {
// The largest supported value for Rendezvous discriminators
const uint16_t kMaxRendezvousDiscriminatorValue = 0xFFF;

// The largest supported value for sleepy idle interval and sleepy active interval
inline constexpr uint32_t kMaxSleepyInterval = 3600000;
// The largest supported value for session idle interval and session active interval
inline constexpr uint32_t kMaxSessionIdleInterval = 3600000;

class RendezvousParameters
{
Expand Down

0 comments on commit 047e31f

Please sign in to comment.