aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/cs46xx/cs46xx_lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/cs46xx/cs46xx_lib.c')
-rw-r--r--sound/pci/cs46xx/cs46xx_lib.c43
1 files changed, 20 insertions, 23 deletions
diff --git a/sound/pci/cs46xx/cs46xx_lib.c b/sound/pci/cs46xx/cs46xx_lib.c
index 6e3855b8b33d..9b8af5bcbb04 100644
--- a/sound/pci/cs46xx/cs46xx_lib.c
+++ b/sound/pci/cs46xx/cs46xx_lib.c
@@ -163,7 +163,7 @@ static unsigned short snd_cs46xx_codec_read(cs46xx_t *chip,
163 goto ok1; 163 goto ok1;
164 } 164 }
165 165
166 snd_printk("AC'97 read problem (ACCTL_DCV), reg = 0x%x\n", reg); 166 snd_printk(KERN_ERR "AC'97 read problem (ACCTL_DCV), reg = 0x%x\n", reg);
167 result = 0xffff; 167 result = 0xffff;
168 goto end; 168 goto end;
169 169
@@ -182,7 +182,7 @@ static unsigned short snd_cs46xx_codec_read(cs46xx_t *chip,
182 udelay(10); 182 udelay(10);
183 } 183 }
184 184
185 snd_printk("AC'97 read problem (ACSTS_VSTS), codec_index %d, reg = 0x%x\n", codec_index, reg); 185 snd_printk(KERN_ERR "AC'97 read problem (ACSTS_VSTS), codec_index %d, reg = 0x%x\n", codec_index, reg);
186 result = 0xffff; 186 result = 0xffff;
187 goto end; 187 goto end;
188 188
@@ -281,7 +281,7 @@ static void snd_cs46xx_codec_write(cs46xx_t *chip,
281 goto end; 281 goto end;
282 } 282 }
283 } 283 }
284 snd_printk("AC'97 write problem, codec_index = %d, reg = 0x%x, val = 0x%x\n", codec_index, reg, val); 284 snd_printk(KERN_ERR "AC'97 write problem, codec_index = %d, reg = 0x%x, val = 0x%x\n", codec_index, reg, val);
285 end: 285 end:
286 chip->active_ctrl(chip, -1); 286 chip->active_ctrl(chip, -1);
287} 287}
@@ -510,7 +510,7 @@ static void snd_cs46xx_proc_start(cs46xx_t *chip)
510 } 510 }
511 511
512 if (snd_cs46xx_peek(chip, BA1_SPCR) & SPCR_RUNFR) 512 if (snd_cs46xx_peek(chip, BA1_SPCR) & SPCR_RUNFR)
513 snd_printk("SPCR_RUNFR never reset\n"); 513 snd_printk(KERN_ERR "SPCR_RUNFR never reset\n");
514} 514}
515 515
516static void snd_cs46xx_proc_stop(cs46xx_t *chip) 516static void snd_cs46xx_proc_stop(cs46xx_t *chip)
@@ -2403,7 +2403,7 @@ static void snd_cs46xx_codec_reset (ac97_t * ac97)
2403 msleep(10); 2403 msleep(10);
2404 } while (time_after_eq(end_time, jiffies)); 2404 } while (time_after_eq(end_time, jiffies));
2405 2405
2406 snd_printk("CS46xx secondary codec dont respond!\n"); 2406 snd_printk(KERN_ERR "CS46xx secondary codec doesn't respond!\n");
2407} 2407}
2408#endif 2408#endif
2409 2409
@@ -2906,10 +2906,7 @@ static int snd_cs46xx_free(cs46xx_t *chip)
2906 snd_cs46xx_region_t *region = &chip->region.idx[idx]; 2906 snd_cs46xx_region_t *region = &chip->region.idx[idx];
2907 if (region->remap_addr) 2907 if (region->remap_addr)
2908 iounmap(region->remap_addr); 2908 iounmap(region->remap_addr);
2909 if (region->resource) { 2909 release_and_free_resource(region->resource);
2910 release_resource(region->resource);
2911 kfree_nocheck(region->resource);
2912 }
2913 } 2910 }
2914 if (chip->irq >= 0) 2911 if (chip->irq >= 0)
2915 free_irq(chip->irq, (void *)chip); 2912 free_irq(chip->irq, (void *)chip);
@@ -3075,8 +3072,8 @@ static int snd_cs46xx_chip_init(cs46xx_t *chip)
3075 } 3072 }
3076 3073
3077 3074
3078 snd_printk("create - never read codec ready from AC'97\n"); 3075 snd_printk(KERN_ERR "create - never read codec ready from AC'97\n");
3079 snd_printk("it is not probably bug, try to use CS4236 driver\n"); 3076 snd_printk(KERN_ERR "it is not probably bug, try to use CS4236 driver\n");
3080 return -EIO; 3077 return -EIO;
3081 ok1: 3078 ok1:
3082#ifdef CONFIG_SND_CS46XX_NEW_DSP 3079#ifdef CONFIG_SND_CS46XX_NEW_DSP
@@ -3124,17 +3121,17 @@ static int snd_cs46xx_chip_init(cs46xx_t *chip)
3124 } 3121 }
3125 3122
3126#ifndef CONFIG_SND_CS46XX_NEW_DSP 3123#ifndef CONFIG_SND_CS46XX_NEW_DSP
3127 snd_printk("create - never read ISV3 & ISV4 from AC'97\n"); 3124 snd_printk(KERN_ERR "create - never read ISV3 & ISV4 from AC'97\n");
3128 return -EIO; 3125 return -EIO;
3129#else 3126#else
3130 /* This may happen on a cold boot with a Terratec SiXPack 5.1. 3127 /* This may happen on a cold boot with a Terratec SiXPack 5.1.
3131 Reloading the driver may help, if there's other soundcards 3128 Reloading the driver may help, if there's other soundcards
3132 with the same problem I would like to know. (Benny) */ 3129 with the same problem I would like to know. (Benny) */
3133 3130
3134 snd_printk("ERROR: snd-cs46xx: never read ISV3 & ISV4 from AC'97\n"); 3131 snd_printk(KERN_ERR "ERROR: snd-cs46xx: never read ISV3 & ISV4 from AC'97\n");
3135 snd_printk(" Try reloading the ALSA driver, if you find something\n"); 3132 snd_printk(KERN_ERR " Try reloading the ALSA driver, if you find something\n");
3136 snd_printk(" broken or not working on your soundcard upon\n"); 3133 snd_printk(KERN_ERR " broken or not working on your soundcard upon\n");
3137 snd_printk(" this message please report to alsa-devel@lists.sourceforge.net\n"); 3134 snd_printk(KERN_ERR " this message please report to alsa-devel@lists.sourceforge.net\n");
3138 3135
3139 return -EIO; 3136 return -EIO;
3140#endif 3137#endif
@@ -3215,7 +3212,7 @@ int __devinit snd_cs46xx_start_dsp(cs46xx_t *chip)
3215#else 3212#else
3216 /* old image */ 3213 /* old image */
3217 if (snd_cs46xx_download_image(chip) < 0) { 3214 if (snd_cs46xx_download_image(chip) < 0) {
3218 snd_printk("image download error\n"); 3215 snd_printk(KERN_ERR "image download error\n");
3219 return -EIO; 3216 return -EIO;
3220 } 3217 }
3221 3218
@@ -3790,7 +3787,7 @@ int __devinit snd_cs46xx_create(snd_card_t * card,
3790 chip->ba1_addr = pci_resource_start(pci, 1); 3787 chip->ba1_addr = pci_resource_start(pci, 1);
3791 if (chip->ba0_addr == 0 || chip->ba0_addr == (unsigned long)~0 || 3788 if (chip->ba0_addr == 0 || chip->ba0_addr == (unsigned long)~0 ||
3792 chip->ba1_addr == 0 || chip->ba1_addr == (unsigned long)~0) { 3789 chip->ba1_addr == 0 || chip->ba1_addr == (unsigned long)~0) {
3793 snd_printk("wrong address(es) - ba0 = 0x%lx, ba1 = 0x%lx\n", chip->ba0_addr, chip->ba1_addr); 3790 snd_printk(KERN_ERR "wrong address(es) - ba0 = 0x%lx, ba1 = 0x%lx\n", chip->ba0_addr, chip->ba1_addr);
3794 snd_cs46xx_free(chip); 3791 snd_cs46xx_free(chip);
3795 return -ENOMEM; 3792 return -ENOMEM;
3796 } 3793 }
@@ -3839,12 +3836,12 @@ int __devinit snd_cs46xx_create(snd_card_t * card,
3839 } 3836 }
3840 3837
3841 if (external_amp) { 3838 if (external_amp) {
3842 snd_printk("Crystal EAPD support forced on.\n"); 3839 snd_printk(KERN_INFO "Crystal EAPD support forced on.\n");
3843 chip->amplifier_ctrl = amp_voyetra; 3840 chip->amplifier_ctrl = amp_voyetra;
3844 } 3841 }
3845 3842
3846 if (thinkpad) { 3843 if (thinkpad) {
3847 snd_printk("Activating CLKRUN hack for Thinkpad.\n"); 3844 snd_printk(KERN_INFO "Activating CLKRUN hack for Thinkpad.\n");
3848 chip->active_ctrl = clkrun_hack; 3845 chip->active_ctrl = clkrun_hack;
3849 clkrun_init(chip); 3846 clkrun_init(chip);
3850 } 3847 }
@@ -3861,20 +3858,20 @@ int __devinit snd_cs46xx_create(snd_card_t * card,
3861 for (idx = 0; idx < 5; idx++) { 3858 for (idx = 0; idx < 5; idx++) {
3862 region = &chip->region.idx[idx]; 3859 region = &chip->region.idx[idx];
3863 if ((region->resource = request_mem_region(region->base, region->size, region->name)) == NULL) { 3860 if ((region->resource = request_mem_region(region->base, region->size, region->name)) == NULL) {
3864 snd_printk("unable to request memory region 0x%lx-0x%lx\n", region->base, region->base + region->size - 1); 3861 snd_printk(KERN_ERR "unable to request memory region 0x%lx-0x%lx\n", region->base, region->base + region->size - 1);
3865 snd_cs46xx_free(chip); 3862 snd_cs46xx_free(chip);
3866 return -EBUSY; 3863 return -EBUSY;
3867 } 3864 }
3868 region->remap_addr = ioremap_nocache(region->base, region->size); 3865 region->remap_addr = ioremap_nocache(region->base, region->size);
3869 if (region->remap_addr == NULL) { 3866 if (region->remap_addr == NULL) {
3870 snd_printk("%s ioremap problem\n", region->name); 3867 snd_printk(KERN_ERR "%s ioremap problem\n", region->name);
3871 snd_cs46xx_free(chip); 3868 snd_cs46xx_free(chip);
3872 return -ENOMEM; 3869 return -ENOMEM;
3873 } 3870 }
3874 } 3871 }
3875 3872
3876 if (request_irq(pci->irq, snd_cs46xx_interrupt, SA_INTERRUPT|SA_SHIRQ, "CS46XX", (void *) chip)) { 3873 if (request_irq(pci->irq, snd_cs46xx_interrupt, SA_INTERRUPT|SA_SHIRQ, "CS46XX", (void *) chip)) {
3877 snd_printk("unable to grab IRQ %d\n", pci->irq); 3874 snd_printk(KERN_ERR "unable to grab IRQ %d\n", pci->irq);
3878 snd_cs46xx_free(chip); 3875 snd_cs46xx_free(chip);
3879 return -EBUSY; 3876 return -EBUSY;
3880 } 3877 }