Commit 88fd4789 authored by Stefan Brüns's avatar Stefan Brüns Committed by Alex Deucher

drm/radeon/audio: break out of loops once we match connector

No need to continue with the loops once we've matched
the appropriate connector.
See commit 8a992ee1Signed-off-by: default avatarStefan Brüns <stefan.bruens@rwth-aachen.de>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent c748990b
...@@ -164,8 +164,10 @@ void dce6_afmt_write_speaker_allocation(struct drm_encoder *encoder) ...@@ -164,8 +164,10 @@ void dce6_afmt_write_speaker_allocation(struct drm_encoder *encoder)
offset = dig->afmt->pin->offset; offset = dig->afmt->pin->offset;
list_for_each_entry(connector, &encoder->dev->mode_config.connector_list, head) { list_for_each_entry(connector, &encoder->dev->mode_config.connector_list, head) {
if (connector->encoder == encoder) if (connector->encoder == encoder) {
radeon_connector = to_radeon_connector(connector); radeon_connector = to_radeon_connector(connector);
break;
}
} }
if (!radeon_connector) { if (!radeon_connector) {
...@@ -225,8 +227,10 @@ void dce6_afmt_write_sad_regs(struct drm_encoder *encoder) ...@@ -225,8 +227,10 @@ void dce6_afmt_write_sad_regs(struct drm_encoder *encoder)
offset = dig->afmt->pin->offset; offset = dig->afmt->pin->offset;
list_for_each_entry(connector, &encoder->dev->mode_config.connector_list, head) { list_for_each_entry(connector, &encoder->dev->mode_config.connector_list, head) {
if (connector->encoder == encoder) if (connector->encoder == encoder) {
radeon_connector = to_radeon_connector(connector); radeon_connector = to_radeon_connector(connector);
break;
}
} }
if (!radeon_connector) { if (!radeon_connector) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment