From: Takashi Iwai <tiwai@suse.de>
To: Arnd Bergmann <arnd@kernel.org>
Cc: James Schulman <james.schulman@cirrus.com>,
David Rhodes <david.rhodes@cirrus.com>,
Richard Fitzgerald <rf@opensource.cirrus.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
Stefan Binding <sbinding@opensource.cirrus.com>,
Arnd Bergmann <arnd@arndb.de>,
Dorian Cruveiller <doriancruveiller@gmail.com>,
Yang Yingliang <yangyingliang@huawei.com>,
alsa-devel@alsa-project.org, patches@opensource.cirrus.com,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ALSA: hda: cs35l41: fix building without CONFIG_SPI
Date: Wed, 03 Jan 2024 11:50:17 +0100 [thread overview]
Message-ID: <87bka2bsie.wl-tiwai@suse.de> (raw)
In-Reply-To: <20240103102606.3742476-1-arnd@kernel.org>
On Wed, 03 Jan 2024 11:25:59 +0100,
Arnd Bergmann wrote:
>
> From: Arnd Bergmann <arnd@arndb.de>
>
> When CONFIG_SPI is disabled, the driver produces unused-variable warning:
>
> sound/pci/hda/cs35l41_hda_property.c: In function 'generic_dsd_config':
> sound/pci/hda/cs35l41_hda_property.c:181:28: error: unused variable 'spi' [-Werror=unused-variable]
> 181 | struct spi_device *spi;
> | ^~~
> sound/pci/hda/cs35l41_hda_property.c:180:27: error: unused variable 'cs_gpiod' [-Werror=unused-variable]
> 180 | struct gpio_desc *cs_gpiod;
> | ^~~~~~~~
>
> Avoid these by turning the preprocessor contionals into equivalent C code,
> which also helps readability.
>
> Fixes: 916d051730ae ("ALSA: hda: cs35l41: Only add SPI CS GPIO if SPI is enabled in kernel")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Applied now. Thanks.
Takashi
prev parent reply other threads:[~2024-01-03 10:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-03 10:25 [PATCH] ALSA: hda: cs35l41: fix building without CONFIG_SPI Arnd Bergmann
2024-01-03 10:50 ` Takashi Iwai [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bka2bsie.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=arnd@arndb.de \
--cc=arnd@kernel.org \
--cc=david.rhodes@cirrus.com \
--cc=doriancruveiller@gmail.com \
--cc=james.schulman@cirrus.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=patches@opensource.cirrus.com \
--cc=perex@perex.cz \
--cc=rf@opensource.cirrus.com \
--cc=sbinding@opensource.cirrus.com \
--cc=tiwai@suse.com \
--cc=yangyingliang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox