Skip to content

Commit

Permalink
[tmf] set default snoop cache entry count to 1/16 of total (openthrea…
Browse files Browse the repository at this point in the history
…d#9440)

This commit sets the default value of the configuration
`TMF_ADDRESS_CACHE_MAX_SNOOP_ENTRIES` to `1/16` of the total number
of address cache entries. This ensures that the snoop entries scale
with the total number of entries.
  • Loading branch information
abtink committed Sep 21, 2023
1 parent 93e72bc commit 85aff45
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/core/config/tmf.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,11 @@
* The maximum number of EID-to-RLOC cache entries that can be used for "snoop optimization" where an entry is created
* by inspecting a received message.
*
* By default a 1/16 fraction of `OPENTHREAD_CONFIG_TMF_ADDRESS_CACHE_ENTRIES` is used.
*
*/
#ifndef OPENTHREAD_CONFIG_TMF_ADDRESS_CACHE_MAX_SNOOP_ENTRIES
#define OPENTHREAD_CONFIG_TMF_ADDRESS_CACHE_MAX_SNOOP_ENTRIES 2
#define OPENTHREAD_CONFIG_TMF_ADDRESS_CACHE_MAX_SNOOP_ENTRIES (OPENTHREAD_CONFIG_TMF_ADDRESS_CACHE_ENTRIES / 16)
#endif

/**
Expand Down

0 comments on commit 85aff45

Please sign in to comment.