ASoC: hdac_hdmi: Rate limit logging on connection and disconnection
Mark Brown
maintainerPATCH 1/1 ASoC: hdac_hdmi: Rate limit logging on connection and disconnection
We currently log parse failures for ELD data and some disconnection events as errors without rate limiting. These log messages can be triggered very frequently in some situations, especially ELD parsing when there is nothing connected to a HDMI port which will generate:
hdmi-audio-codec hdmi-audio-codec.1.auto: HDMI: Unknown ELD version 0
While there's doubtless work that could be done on reducing the number of connection notification callbacks it's possible these may be legitimately generated by poor quality physical connections so let's use rate limiting to mitigate the log spam for the parse errors and lower the severity for disconnect logging to debug level.
--- sound/soc/codecs/hdac_hdmi.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
sound/soc/codecs/hdac_hdmi.c +6 -4
@@ -1232,7 +1232,8 @@ static int hdac_hdmi_parse_eld(struct hdac_device *hdev, >> DRM_ELD_VER_SHIFT;if (ver !=ELD_VER_CEA_861D && ver !=ELD_VER_PARTIAL ) { -dev_err (&hdev->dev,"HDMI: Unknown ELD version %d\n" , ver); +dev_err_ratelimited (&hdev->dev, +"HDMI: Unknown ELD version %d\n" , ver);return -EINVAL ; }
@@ -1240,7 +1241,8 @@ static int hdac_hdmi_parse_eld(struct hdac_device *hdev, DRM_ELD_MNL_MASK) >> DRM_ELD_MNL_SHIFT;if (mnl >ELD_MAX_MNL ) { -dev_err (&hdev->dev,"HDMI: MNL Invalid %d\n" , mnl); +dev_err_ratelimited (&hdev->dev, +"HDMI: MNL Invalid %d\n" , mnl);return -EINVAL ; }
@@ -1299,8 +1301,8 @@ static void hdac_hdmi_present_sense(struct hdac_hdmi_pin *pin,if (!port->eld.monitor_present || !port->eld.eld_valid) { -dev_err (&hdev->dev,"%s: disconnect for pin:port %d:%d\n" , - __func__, pin->nid, port->id); +dev_dbg (&hdev->dev,"%s: disconnect for pin:port %d:%d\n" , + __func__, pin->nid, port->id);/* * PCMs are not registered during device probe, so don't
---
base-commit: 19272b37aa4f83ca52bdf9c16d5d81bdd1354494
change-id: 20250613-asoc-hdmi-eld-logging-11bf756cff6d
Best regards,
Signature · 1 line
Mark Brown <[email protected]>
Mark Brown
maintainerQuoted 8 lines · Mark Brown
We currently log parse failures for ELD data and some disconnection events as errors without rate limiting. These log messages can be triggered very frequently in some situations, especially ELD parsing when there is nothing connected to a HDMI port which will generate:
hdmi-audio-codec hdmi-audio-codec.1.auto: HDMI: Unknown ELD version 0
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: hdac_hdmi: Rate limit logging on connection and disconnection
commit: c4ca928a6db1593802cd945f075a7e21dd0430c1
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark