]> git.baikalelectronics.ru Git - kernel.git/commitdiff
ALSA: cmipci: Drop stale variable assignment
authorTakashi Iwai <tiwai@suse.de>
Fri, 12 Nov 2021 10:31:37 +0000 (11:31 +0100)
committerTakashi Iwai <tiwai@suse.de>
Sun, 14 Nov 2021 08:28:59 +0000 (09:28 +0100)
Since the recent code refactoring using devres, the variable cm in
snd_cmipci_probe() is no longer referred.

Fixes: 9678d2d45b18 ("ALSA: cmipci: Allocate resources with device-managed APIs")
Reported-by: kernel test robot <lkp@intel.com>
Link: https://lore.kernel.org/r/cc6383a2-cafb-ffe7-0b4f-27a310a1005c@intel.com
Link: https://lore.kernel.org/r/20211112103137.9504-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/cmipci.c

index ea20236f35dbc210b2042897bf19319f26f93c7b..9a678b5cf2855fabf163cbf4d69821fe3f08f098 100644 (file)
@@ -3218,7 +3218,6 @@ static int snd_cmipci_probe(struct pci_dev *pci,
 {
        static int dev;
        struct snd_card *card;
-       struct cmipci *cm;
        int err;
 
        if (dev >= SNDRV_CARDS)
@@ -3229,10 +3228,9 @@ static int snd_cmipci_probe(struct pci_dev *pci,
        }
 
        err = snd_devm_card_new(&pci->dev, index[dev], id[dev], THIS_MODULE,
-                               sizeof(*cm), &card);
+                               sizeof(struct cmipci), &card);
        if (err < 0)
                return err;
-       cm = card->private_data;
        
        switch (pci->device) {
        case PCI_DEVICE_ID_CMEDIA_CM8738: