ALSA: ctxfi: pr_* replaced with dev_*
[firefly-linux-kernel-4.4.55.git] / sound / pci / ctxfi / cthw20k1.c
index 71d496f780e30ef30db9fc259e6394c133772b96..b425aa8ee57858fb11c43f5c1b56bfa6adc8bbca 100644 (file)
@@ -1268,7 +1268,8 @@ static int hw_trn_init(struct hw *hw, const struct trn_conf *info)
 
        /* Set up device page table */
        if ((~0UL) == info->vm_pgt_phys) {
-               pr_err("Wrong device page table page address!\n");
+               dev_err(hw->card->dev,
+                       "Wrong device page table page address!\n");
                return -1;
        }
 
@@ -1327,7 +1328,7 @@ static int hw_pll_init(struct hw *hw, unsigned int rsr)
                mdelay(40);
        }
        if (i >= 3) {
-               pr_alert("PLL initialization failed!!!\n");
+               dev_alert(hw->card->dev, "PLL initialization failed!!!\n");
                return -EBUSY;
        }
 
@@ -1351,7 +1352,7 @@ static int hw_auto_init(struct hw *hw)
                        break;
        }
        if (!get_field(gctl, GCTL_AID)) {
-               pr_alert("Card Auto-init failed!!!\n");
+               dev_alert(hw->card->dev, "Card Auto-init failed!!!\n");
                return -EBUSY;
        }
 
@@ -1802,7 +1803,7 @@ static int uaa_to_xfi(struct pci_dev *pci)
        unsigned int is_uaa;
        unsigned int data[4] = {0};
        unsigned int io_base;
-       void *mem_base;
+       void __iomem *mem_base;
        int i;
        const u32 CTLX = CTLBITS('C', 'T', 'L', 'X');
        const u32 CTL_ = CTLBITS('C', 'T', 'L', '-');
@@ -1911,8 +1912,9 @@ static int hw_card_start(struct hw *hw)
        /* Set DMA transfer mask */
        if (pci_set_dma_mask(pci, CT_XFI_DMA_MASK) < 0 ||
            pci_set_consistent_dma_mask(pci, CT_XFI_DMA_MASK) < 0) {
-               pr_err("architecture does not support PCI busmaster DMA with mask 0x%llx\n",
-                      CT_XFI_DMA_MASK);
+               dev_err(hw->card->dev,
+                       "architecture does not support PCI busmaster DMA with mask 0x%llx\n",
+                       CT_XFI_DMA_MASK);
                err = -ENXIO;
                goto error1;
        }
@@ -1941,7 +1943,8 @@ static int hw_card_start(struct hw *hw)
                err = request_irq(pci->irq, ct_20k1_interrupt, IRQF_SHARED,
                                  KBUILD_MODNAME, hw);
                if (err < 0) {
-                       pr_err("XFi: Cannot get irq %d\n", pci->irq);
+                       dev_err(hw->card->dev,
+                               "XFi: Cannot get irq %d\n", pci->irq);
                        goto error2;
                }
                hw->irq = pci->irq;
@@ -1984,9 +1987,9 @@ static int hw_card_shutdown(struct hw *hw)
        hw->irq = -1;
 
        if (hw->mem_base)
-               iounmap((void *)hw->mem_base);
+               iounmap(hw->mem_base);
 
-       hw->mem_base = (unsigned long)NULL;
+       hw->mem_base = NULL;
 
        if (hw->io_base)
                pci_release_regions(hw->pci);