--- zzzz-none-000/linux-3.10.107/sound/isa/sb/sb16.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/sound/isa/sb/sb16.c 2021-02-04 17:41:59.000000000 +0000 @@ -323,13 +323,14 @@ #define is_isapnp_selected(dev) 0 #endif -static int snd_sb16_card_new(int dev, struct snd_card **cardp) +static int snd_sb16_card_new(struct device *devptr, int dev, + struct snd_card **cardp) { struct snd_card *card; int err; - err = snd_card_create(index[dev], id[dev], THIS_MODULE, - sizeof(struct snd_card_sb16), &card); + err = snd_card_new(devptr, index[dev], id[dev], THIS_MODULE, + sizeof(struct snd_card_sb16), &card); if (err < 0) return err; card->private_free = snd_sb16_free; @@ -373,7 +374,7 @@ if (! is_isapnp_selected(dev) && (err = snd_sb16dsp_configure(chip)) < 0) return err; - if ((err = snd_sb16dsp_pcm(chip, 0, &chip->pcm)) < 0) + if ((err = snd_sb16dsp_pcm(chip, 0)) < 0) return err; strcpy(card->driver, @@ -493,7 +494,7 @@ struct snd_card *card; int err; - err = snd_sb16_card_new(dev, &card); + err = snd_sb16_card_new(pdev, dev, &card); if (err < 0) return err; @@ -507,7 +508,6 @@ awe_port[dev] = port[dev] + 0x400; #endif - snd_card_set_dev(card, pdev); if ((err = snd_sb16_probe(card, dev)) < 0) { snd_card_free(card); return err; @@ -566,7 +566,6 @@ static int snd_sb16_isa_remove(struct device *pdev, unsigned int dev) { snd_card_free(dev_get_drvdata(pdev)); - dev_set_drvdata(pdev, NULL); return 0; } @@ -614,10 +613,9 @@ for ( ; dev < SNDRV_CARDS; dev++) { if (!enable[dev] || !isapnp[dev]) continue; - res = snd_sb16_card_new(dev, &card); + res = snd_sb16_card_new(&pcard->card->dev, dev, &card); if (res < 0) return res; - snd_card_set_dev(card, &pcard->card->dev); if ((res = snd_card_sb16_pnp(dev, card->private_data, pcard, pid)) < 0 || (res = snd_sb16_probe(card, dev)) < 0) { snd_card_free(card);