summaryrefslogtreecommitdiffstats
path: root/sound/ppc
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2015-01-03 16:55:54 -0500
committerTakashi Iwai <tiwai@suse.de>2015-01-04 09:13:45 -0500
commitff6defa6a8fae12205d64f55db395b1fcf35af8e (patch)
treea08b5c63a0c7e21f955e254178dc53ea0d7b6e3f /sound/ppc
parentb76c0e95ab0f535e210df588b8ac42dd75b31c75 (diff)
ALSA: Deletion of checks before the function call "iounmap"
The iounmap() function performs also input parameter validation. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/ppc')
-rw-r--r--sound/ppc/pmac.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/sound/ppc/pmac.c b/sound/ppc/pmac.c
index 5a13b22748b2..d399df473896 100644
--- a/sound/ppc/pmac.c
+++ b/sound/ppc/pmac.c
@@ -867,16 +867,11 @@ static int snd_pmac_free(struct snd_pmac *chip)
867 snd_pmac_dbdma_free(chip, &chip->capture.cmd); 867 snd_pmac_dbdma_free(chip, &chip->capture.cmd);
868 snd_pmac_dbdma_free(chip, &chip->extra_dma); 868 snd_pmac_dbdma_free(chip, &chip->extra_dma);
869 snd_pmac_dbdma_free(chip, &emergency_dbdma); 869 snd_pmac_dbdma_free(chip, &emergency_dbdma);
870 if (chip->macio_base) 870 iounmap(chip->macio_base);
871 iounmap(chip->macio_base); 871 iounmap(chip->latch_base);
872 if (chip->latch_base) 872 iounmap(chip->awacs);
873 iounmap(chip->latch_base); 873 iounmap(chip->playback.dma);
874 if (chip->awacs) 874 iounmap(chip->capture.dma);
875 iounmap(chip->awacs);
876 if (chip->playback.dma)
877 iounmap(chip->playback.dma);
878 if (chip->capture.dma)
879 iounmap(chip->capture.dma);
880 875
881 if (chip->node) { 876 if (chip->node) {
882 int i; 877 int i;