Commit 67207297 authored by Dan Carpenter's avatar Dan Carpenter Committed by Mark Brown

ASoC: hdac_hdmi: tidy up a memset()

The ARRAY_SIZE() is the number of the elements but we want to use the
number of bytes.  Fortunately, in this case the value is the same so it
doesn't affect runtime.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/20200825104623.GA278587@mwandaSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent afa86a04
...@@ -1474,7 +1474,7 @@ static int hdac_hdmi_eld_ctl_get(struct snd_kcontrol *kcontrol, ...@@ -1474,7 +1474,7 @@ static int hdac_hdmi_eld_ctl_get(struct snd_kcontrol *kcontrol,
struct hdac_hdmi_port *port; struct hdac_hdmi_port *port;
struct hdac_hdmi_eld *eld; struct hdac_hdmi_eld *eld;
memset(ucontrol->value.bytes.data, 0, ARRAY_SIZE(ucontrol->value.bytes.data)); memset(ucontrol->value.bytes.data, 0, sizeof(ucontrol->value.bytes.data));
pcm = get_hdmi_pcm_from_id(hdmi, kcontrol->id.device); pcm = get_hdmi_pcm_from_id(hdmi, kcontrol->id.device);
if (!pcm) { if (!pcm) {
......
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