aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci
diff options
context:
space:
mode:
authorEliot Blennerhassett <eliot@blennerhassett.gen.nz>2014-11-19 22:22:55 -0500
committerTakashi Iwai <tiwai@suse.de>2014-11-22 16:33:37 -0500
commit12eb0898741870882ca474708e811983d5a5d768 (patch)
tree3e959c435daab7337c5684b0bd02d3c19e466649 /sound/pci
parent5bc91f5b3c732bdb3b9e7cc8bd27969d25015bcd (diff)
ALSA: asihpi: Use standard printk helpers
Signed-off-by: Eliot Blennerhassett <eliot@blennerhassett.gen.nz> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r--sound/pci/asihpi/asihpi.c32
1 files changed, 13 insertions, 19 deletions
diff --git a/sound/pci/asihpi/asihpi.c b/sound/pci/asihpi/asihpi.c
index ae29f30547cc..e9273fb2a505 100644
--- a/sound/pci/asihpi/asihpi.c
+++ b/sound/pci/asihpi/asihpi.c
@@ -380,7 +380,7 @@ static void snd_card_asihpi_pcm_samplerates(struct snd_card_asihpi *asihpi,
380 HPI_SOURCENODE_CLOCK_SOURCE, 0, 0, 0, 380 HPI_SOURCENODE_CLOCK_SOURCE, 0, 0, 0,
381 HPI_CONTROL_SAMPLECLOCK, &h_control); 381 HPI_CONTROL_SAMPLECLOCK, &h_control);
382 if (err) { 382 if (err) {
383 snd_printk(KERN_ERR 383 dev_err(&asihpi->pci->dev,
384 "No local sampleclock, err %d\n", err); 384 "No local sampleclock, err %d\n", err);
385 } 385 }
386 386
@@ -1438,7 +1438,7 @@ static inline int ctl_add(struct snd_card *card, struct snd_kcontrol_new *ctl,
1438 if (err < 0) 1438 if (err < 0)
1439 return err; 1439 return err;
1440 else if (mixer_dump) 1440 else if (mixer_dump)
1441 snd_printk(KERN_INFO "added %s(%d)\n", ctl->name, ctl->index); 1441 dev_info(&asihpi->pci->dev, "added %s(%d)\n", ctl->name, ctl->index);
1442 1442
1443 return 0; 1443 return 0;
1444} 1444}
@@ -2652,7 +2652,7 @@ static int snd_card_asihpi_mixer_new(struct snd_card_asihpi *asihpi)
2652 if (err) { 2652 if (err) {
2653 if (err == HPI_ERROR_CONTROL_DISABLED) { 2653 if (err == HPI_ERROR_CONTROL_DISABLED) {
2654 if (mixer_dump) 2654 if (mixer_dump)
2655 snd_printk(KERN_INFO 2655 dev_info(&asihpi->pci->dev,
2656 "Disabled HPI Control(%d)\n", 2656 "Disabled HPI Control(%d)\n",
2657 idx); 2657 idx);
2658 continue; 2658 continue;
@@ -2717,9 +2717,8 @@ static int snd_card_asihpi_mixer_new(struct snd_card_asihpi *asihpi)
2717 case HPI_CONTROL_COMPANDER: 2717 case HPI_CONTROL_COMPANDER:
2718 default: 2718 default:
2719 if (mixer_dump) 2719 if (mixer_dump)
2720 snd_printk(KERN_INFO 2720 dev_info(&asihpi->pci->dev,
2721 "Untranslated HPI Control" 2721 "Untranslated HPI Control (%d) %d %d %d %d %d\n",
2722 "(%d) %d %d %d %d %d\n",
2723 idx, 2722 idx,
2724 hpi_ctl.control_type, 2723 hpi_ctl.control_type,
2725 hpi_ctl.src_node_type, 2724 hpi_ctl.src_node_type,
@@ -2734,7 +2733,7 @@ static int snd_card_asihpi_mixer_new(struct snd_card_asihpi *asihpi)
2734 if (HPI_ERROR_INVALID_OBJ_INDEX != err) 2733 if (HPI_ERROR_INVALID_OBJ_INDEX != err)
2735 hpi_handle_error(err); 2734 hpi_handle_error(err);
2736 2735
2737 snd_printk(KERN_INFO "%d mixer controls found\n", idx); 2736 dev_info(&asihpi->pci->dev, "%d mixer controls found\n", idx);
2738 2737
2739 return 0; 2738 return 0;
2740} 2739}
@@ -2897,8 +2896,7 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev,
2897 &card); 2896 &card);
2898 if (err < 0) 2897 if (err < 0)
2899 return err; 2898 return err;
2900 snd_printk(KERN_WARNING 2899 dev_warn(&pci_dev->dev, "Adapter index %d->ALSA index %d\n",
2901 "**** WARNING **** Adapter index %d->ALSA index %d\n",
2902 adapter_index, card->number); 2900 adapter_index, card->number);
2903 } 2901 }
2904 2902
@@ -2908,9 +2906,6 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev,
2908 asihpi->hpi = hpi; 2906 asihpi->hpi = hpi;
2909 hpi->snd_card = card; 2907 hpi->snd_card = card;
2910 2908
2911 snd_printk(KERN_INFO "adapter ID=%4X index=%d\n",
2912 asihpi->hpi->adapter->type, adapter_index);
2913
2914 err = hpi_adapter_get_property(adapter_index, 2909 err = hpi_adapter_get_property(adapter_index,
2915 HPI_ADAPTER_PROPERTY_CAPS1, 2910 HPI_ADAPTER_PROPERTY_CAPS1,
2916 NULL, &asihpi->support_grouping); 2911 NULL, &asihpi->support_grouping);
@@ -2968,22 +2963,21 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev,
2968 asihpi->in_min_chans = 1; 2963 asihpi->in_min_chans = 1;
2969 } 2964 }
2970 2965
2971 snd_printk(KERN_INFO "update_interval_frames: %d", 2966 dev_info(&pci_dev->dev, "Has dma:%d, grouping:%d, mrx:%d, uif:%d\n",
2972 asihpi->update_interval_frames);
2973 snd_printk(KERN_INFO "Has dma:%d, grouping:%d, mrx:%d\n",
2974 asihpi->can_dma, 2967 asihpi->can_dma,
2975 asihpi->support_grouping, 2968 asihpi->support_grouping,
2976 asihpi->support_mrx 2969 asihpi->support_mrx,
2970 asihpi->update_interval_frames
2977 ); 2971 );
2978 2972
2979 err = snd_card_asihpi_pcm_new(asihpi, 0); 2973 err = snd_card_asihpi_pcm_new(asihpi, 0);
2980 if (err < 0) { 2974 if (err < 0) {
2981 snd_printk(KERN_ERR "pcm_new failed\n"); 2975 dev_err(&pci_dev->dev, "pcm_new failed\n");
2982 goto __nodev; 2976 goto __nodev;
2983 } 2977 }
2984 err = snd_card_asihpi_mixer_new(asihpi); 2978 err = snd_card_asihpi_mixer_new(asihpi);
2985 if (err < 0) { 2979 if (err < 0) {
2986 snd_printk(KERN_ERR "mixer_new failed\n"); 2980 dev_err(&pci_dev->dev, "mixer_new failed\n");
2987 goto __nodev; 2981 goto __nodev;
2988 } 2982 }
2989 2983
@@ -3015,7 +3009,7 @@ static int snd_asihpi_probe(struct pci_dev *pci_dev,
3015 } 3009 }
3016__nodev: 3010__nodev:
3017 snd_card_free(card); 3011 snd_card_free(card);
3018 snd_printk(KERN_ERR "snd_asihpi_probe error %d\n", err); 3012 dev_err(&pci_dev->dev, "snd_asihpi_probe error %d\n", err);
3019 return err; 3013 return err;
3020 3014
3021} 3015}