]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
ASoC: amd: acp: Drop superfluous assignment in acp_sof_probe()
authorCristian Ciocaltea <cristian.ciocaltea@collabora.com>
Tue, 29 Apr 2025 10:29:43 +0000 (13:29 +0300)
committerMark Brown <broonie@kernel.org>
Wed, 30 Apr 2025 00:38:22 +0000 (09:38 +0900)
The 'card' pointer is not required to be NULL initialized as it is never
accessed before the related memory allocation takes place.

Drop the redundant assignment.

Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea@collabora.com>
Link: https://patch.msgid.link/20250429-acp-sof-probe-assign-v1-1-9784f6eb7660@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/amd/acp/acp-sof-mach.c

index d7b54f12f4062481876f636e483c2922e2029a5f..6215e31eceddf8931ed55c29d8488629e23bcdd0 100644 (file)
@@ -88,7 +88,7 @@ static struct acp_card_drvdata sof_nau8821_max98388_data = {
 
 static int acp_sof_probe(struct platform_device *pdev)
 {
-       struct snd_soc_card *card = NULL;
+       struct snd_soc_card *card;
        struct device *dev = &pdev->dev;
        struct snd_soc_acpi_mach *mach = dev_get_platdata(&pdev->dev);
        const struct dmi_system_id *dmi_id;