aboutsummaryrefslogtreecommitdiffstats
path: root/sound/isa/gus
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2008-11-03 02:51:33 -0500
committerTakashi Iwai <tiwai@suse.de>2008-11-03 02:57:40 -0500
commit0418ff0c8e48aae4e5e0cbcd3e19a057bea2e55a (patch)
tree4aca380581950da39813403b05d2e2b7798ff6f1 /sound/isa/gus
parentbb072bf0980abbe4fc905df91857a8ad34ca673c (diff)
ALSA: remove direct access of dev->bus_id in sound/isa/*
Removed the direct accesses of dev->bus_id in sound/isa/* by replacement with dev_err() or dev_warn() functions. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/isa/gus')
-rw-r--r--sound/isa/gus/gusclassic.c13
-rw-r--r--sound/isa/gus/gusextreme.c19
2 files changed, 12 insertions, 20 deletions
diff --git a/sound/isa/gus/gusclassic.c b/sound/isa/gus/gusclassic.c
index 8f914b37bf89..426532a4d730 100644
--- a/sound/isa/gus/gusclassic.c
+++ b/sound/isa/gus/gusclassic.c
@@ -90,24 +90,21 @@ static int __devinit snd_gusclassic_create(struct snd_card *card,
90 if (irq[n] == SNDRV_AUTO_IRQ) { 90 if (irq[n] == SNDRV_AUTO_IRQ) {
91 irq[n] = snd_legacy_find_free_irq(possible_irqs); 91 irq[n] = snd_legacy_find_free_irq(possible_irqs);
92 if (irq[n] < 0) { 92 if (irq[n] < 0) {
93 snd_printk(KERN_ERR "%s: unable to find a free IRQ\n", 93 dev_err(dev, "unable to find a free IRQ\n");
94 dev->bus_id);
95 return -EBUSY; 94 return -EBUSY;
96 } 95 }
97 } 96 }
98 if (dma1[n] == SNDRV_AUTO_DMA) { 97 if (dma1[n] == SNDRV_AUTO_DMA) {
99 dma1[n] = snd_legacy_find_free_dma(possible_dmas); 98 dma1[n] = snd_legacy_find_free_dma(possible_dmas);
100 if (dma1[n] < 0) { 99 if (dma1[n] < 0) {
101 snd_printk(KERN_ERR "%s: unable to find a free DMA1\n", 100 dev_err(dev, "unable to find a free DMA1\n");
102 dev->bus_id);
103 return -EBUSY; 101 return -EBUSY;
104 } 102 }
105 } 103 }
106 if (dma2[n] == SNDRV_AUTO_DMA) { 104 if (dma2[n] == SNDRV_AUTO_DMA) {
107 dma2[n] = snd_legacy_find_free_dma(possible_dmas); 105 dma2[n] = snd_legacy_find_free_dma(possible_dmas);
108 if (dma2[n] < 0) { 106 if (dma2[n] < 0) {
109 snd_printk(KERN_ERR "%s: unable to find a free DMA2\n", 107 dev_err(dev, "unable to find a free DMA2\n");
110 dev->bus_id);
111 return -EBUSY; 108 return -EBUSY;
112 } 109 }
113 } 110 }
@@ -174,8 +171,8 @@ static int __devinit snd_gusclassic_probe(struct device *dev, unsigned int n)
174 171
175 error = -ENODEV; 172 error = -ENODEV;
176 if (gus->max_flag || gus->ess_flag) { 173 if (gus->max_flag || gus->ess_flag) {
177 snd_printk(KERN_ERR "%s: GUS Classic or ACE soundcard was " 174 dev_err(dev, "GUS Classic or ACE soundcard was "
178 "not detected at 0x%lx\n", dev->bus_id, gus->gf1.port); 175 "not detected at 0x%lx\n", gus->gf1.port);
179 goto out; 176 goto out;
180 } 177 }
181 178
diff --git a/sound/isa/gus/gusextreme.c b/sound/isa/gus/gusextreme.c
index da13185eb0a0..7ad4c3b41a84 100644
--- a/sound/isa/gus/gusextreme.c
+++ b/sound/isa/gus/gusextreme.c
@@ -106,16 +106,14 @@ static int __devinit snd_gusextreme_es1688_create(struct snd_card *card,
106 if (irq[n] == SNDRV_AUTO_IRQ) { 106 if (irq[n] == SNDRV_AUTO_IRQ) {
107 irq[n] = snd_legacy_find_free_irq(possible_irqs); 107 irq[n] = snd_legacy_find_free_irq(possible_irqs);
108 if (irq[n] < 0) { 108 if (irq[n] < 0) {
109 snd_printk(KERN_ERR "%s: unable to find a free IRQ " 109 dev_err(dev, "unable to find a free IRQ for ES1688\n");
110 "for ES1688\n", dev->bus_id);
111 return -EBUSY; 110 return -EBUSY;
112 } 111 }
113 } 112 }
114 if (dma8[n] == SNDRV_AUTO_DMA) { 113 if (dma8[n] == SNDRV_AUTO_DMA) {
115 dma8[n] = snd_legacy_find_free_dma(possible_dmas); 114 dma8[n] = snd_legacy_find_free_dma(possible_dmas);
116 if (dma8[n] < 0) { 115 if (dma8[n] < 0) {
117 snd_printk(KERN_ERR "%s: unable to find a free DMA " 116 dev_err(dev, "unable to find a free DMA for ES1688\n");
118 "for ES1688\n", dev->bus_id);
119 return -EBUSY; 117 return -EBUSY;
120 } 118 }
121 } 119 }
@@ -143,16 +141,14 @@ static int __devinit snd_gusextreme_gus_card_create(struct snd_card *card,
143 if (gf1_irq[n] == SNDRV_AUTO_IRQ) { 141 if (gf1_irq[n] == SNDRV_AUTO_IRQ) {
144 gf1_irq[n] = snd_legacy_find_free_irq(possible_irqs); 142 gf1_irq[n] = snd_legacy_find_free_irq(possible_irqs);
145 if (gf1_irq[n] < 0) { 143 if (gf1_irq[n] < 0) {
146 snd_printk(KERN_ERR "%s: unable to find a free IRQ " 144 dev_err(dev, "unable to find a free IRQ for GF1\n");
147 "for GF1\n", dev->bus_id);
148 return -EBUSY; 145 return -EBUSY;
149 } 146 }
150 } 147 }
151 if (dma1[n] == SNDRV_AUTO_DMA) { 148 if (dma1[n] == SNDRV_AUTO_DMA) {
152 dma1[n] = snd_legacy_find_free_dma(possible_dmas); 149 dma1[n] = snd_legacy_find_free_dma(possible_dmas);
153 if (dma1[n] < 0) { 150 if (dma1[n] < 0) {
154 snd_printk(KERN_ERR "%s: unable to find a free DMA " 151 dev_err(dev, "unable to find a free DMA for GF1\n");
155 "for GF1\n", dev->bus_id);
156 return -EBUSY; 152 return -EBUSY;
157 } 153 }
158 } 154 }
@@ -278,8 +274,8 @@ static int __devinit snd_gusextreme_probe(struct device *dev, unsigned int n)
278 274
279 error = -ENODEV; 275 error = -ENODEV;
280 if (!gus->ess_flag) { 276 if (!gus->ess_flag) {
281 snd_printk(KERN_ERR "%s: GUS Extreme soundcard was not " 277 dev_err(dev, "GUS Extreme soundcard was not "
282 "detected at 0x%lx\n", dev->bus_id, gus->gf1.port); 278 "detected at 0x%lx\n", gus->gf1.port);
283 goto out; 279 goto out;
284 } 280 }
285 gus->codec_flag = 1; 281 gus->codec_flag = 1;
@@ -310,8 +306,7 @@ static int __devinit snd_gusextreme_probe(struct device *dev, unsigned int n)
310 306
311 if (snd_opl3_create(card, es1688->port, es1688->port + 2, 307 if (snd_opl3_create(card, es1688->port, es1688->port + 2,
312 OPL3_HW_OPL3, 0, &opl3) < 0) 308 OPL3_HW_OPL3, 0, &opl3) < 0)
313 printk(KERN_ERR "%s: opl3 not detected at 0x%lx\n", 309 dev_warn(dev, "opl3 not detected at 0x%lx\n", es1688->port);
314 dev->bus_id, es1688->port);
315 else { 310 else {
316 error = snd_opl3_hwdep_new(opl3, 0, 2, NULL); 311 error = snd_opl3_hwdep_new(opl3, 0, 2, NULL);
317 if (error < 0) 312 if (error < 0)