ASoC: Intel: fix unused-variable warning in probe_codec
authorGaosheng Cui <cuigaosheng1@huawei.com>
Mon, 22 Aug 2022 03:51:33 +0000 (11:51 +0800)
committerTakashi Iwai <tiwai@suse.de>
Tue, 13 Sep 2022 15:20:37 +0000 (17:20 +0200)
commita74bfc9eaa497951effddefbcb18f1c7ab56fb35
treefc7b822020e613f0664996a598b40d00e84b9f2e
parent4053a41282f8aae290d3fe7b8daef4c8c53a4ab8
ASoC: Intel: fix unused-variable warning in probe_codec

In configurations with CONFIG_SND_SOC_INTEL_SKYLAKE_HDAUDIO_CODEC=n,
gcc warns about an unused variable:

sound/soc/intel/skylake/skl.c: In function ‘probe_codec’:
sound/soc/intel/skylake/skl.c:729:18: error: unused variable ‘skl’ [-Werror=unused-variable]
  struct skl_dev *skl = bus_to_skl(bus);
                  ^~~
cc1: all warnings being treated as errors

Fixes: 3fd63658caed9 ("ASoC: Intel: Drop hdac_ext usage for codec device creation")
Signed-off-by: Gaosheng Cui <cuigaosheng1@huawei.com>
Acked-by: Cezary Rojewski <cezary.rojewski@intel.com>
Link: https://lore.kernel.org/r/20220822035133.2147381-1-cuigaosheng1@huawei.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/soc/intel/skylake/skl.c