Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Matter{{clusterName}}PluginServerInitCallback instead of the per endpoint init callback for diagnostics related cluster AttributeAccessInterface instance #10938

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions src/app/clusters/descriptor/descriptor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,12 +142,6 @@ CHIP_ERROR DescriptorAttrAccess::Read(const ConcreteAttributePath & aPath, Attri
void MatterDescriptorPluginServerInitCallback(void)
{
#if CHIP_CLUSTER_CONFIG_ENABLE_COMPLEX_ATTRIBUTE_READ
static bool attrAccessRegistered = false;

if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
#endif
}
Original file line number Diff line number Diff line change
Expand Up @@ -144,12 +144,7 @@ bool emberAfEthernetNetworkDiagnosticsClusterResetCountsCallback(app::CommandHan
return true;
}

void emberAfEthernetNetworkDiagnosticsClusterServerInitCallback(EndpointId endpoint)
void MatterEthernetNetworkDiagnosticsClusterServerInitCallback()
{
static bool attrAccessRegistered = false;
if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
}
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,7 @@ CHIP_ERROR GeneralDiagosticsAttrAccess::Read(const ConcreteAttributePath & aPath
}
} // anonymous namespace

void emberAfGeneralDiagnosticsClusterServerInitCallback(EndpointId endpoint)
void MatterGeneralDiagnosticsPluginServerInitCallback()
{
static bool attrAccessRegistered = false;
if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
}
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,7 @@ bool emberAfSoftwareDiagnosticsClusterResetWatermarksCallback(app::CommandHandle
return true;
}

void emberAfSoftwareDiagnosticsClusterServerInitCallback(EndpointId endpoint)
void MatterSoftwareDiagnosticsPluginServerInitCallback()
{
static bool attrAccessRegistered = false;
if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
}
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,7 @@ bool emberAfThreadNetworkDiagnosticsClusterResetCountsCallback(app::CommandHandl
return true;
}

void emberAfThreadNetworkDiagnosticsClusterServerInitCallback(EndpointId endpoint)
void MatterThreadNetworkDiagnosticsPluginServerInitCallback()
{
static bool attrAccessRegistered = false;
if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
}
Original file line number Diff line number Diff line change
Expand Up @@ -160,12 +160,7 @@ bool emberAfWiFiNetworkDiagnosticsClusterResetCountsCallback(app::CommandHandler
return true;
}

void emberAfWiFiNetworkDiagnosticsClusterServerInitCallback(EndpointId endpoint)
void MatterWiFiNetworkDiagnosticsPluginServerInitCallback()
{
static bool attrAccessRegistered = false;
if (!attrAccessRegistered)
{
registerAttributeAccessOverride(&gAttrAccess);
attrAccessRegistered = true;
}
registerAttributeAccessOverride(&gAttrAccess);
}
5 changes: 0 additions & 5 deletions src/app/zap-templates/templates/app/helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,6 @@ var endpointClusterWithInit = [
'Color Control',
'IAS Zone',
'Pump Configuration and Control',
'Ethernet Network Diagnostics',
'Software Diagnostics',
'Thread Network Diagnostics',
'General Diagnostics',
'WiFi Network Diagnostics',
];
var endpointClusterWithAttributeChanged = [ 'Identify', 'Door Lock', 'Pump Configuration and Control' ];
var endpointClusterWithPreAttribute = [ 'IAS Zone' ];
Expand Down
60 changes: 15 additions & 45 deletions zzz_generated/all-clusters-app/zap-generated/endpoint_config.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading