Skip to content

Commit

Permalink
ALSA: hda/tegra check correct return value from ioremap_resource
Browse files Browse the repository at this point in the history
Signed-off-by: Eliot Blennerhassett <eliot@blennerhassett.gen.nz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Eliot Blennerhassett authored and Takashi Iwai committed Feb 14, 2015
1 parent f0153c3 commit 93ceaa3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sound/pci/hda/hda_tegra.c
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ static int hda_tegra_init_chip(struct azx *chip, struct platform_device *pdev)

res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
hda->regs = devm_ioremap_resource(dev, res);
if (IS_ERR(chip->remap_addr))
return PTR_ERR(chip->remap_addr);
if (IS_ERR(hda->regs))
return PTR_ERR(hda->regs);

chip->remap_addr = hda->regs + HDA_BAR0;
chip->addr = res->start + HDA_BAR0;
Expand Down

0 comments on commit 93ceaa3

Please sign in to comment.