Lines Matching refs:base

187  * struct coh_dma_channel - dma channel base
1313 struct coh901318_base *base;
1423 struct powersave *pm = &cohc->base->pm;
1434 struct powersave *pm = &cohc->base->pm;
1446 void __iomem *virtbase = cohc->base->virtbase;
1457 void __iomem *virtbase = cohc->base->virtbase;
1470 void __iomem *virtbase = cohc->base->virtbase;
1489 void __iomem *virtbase = cohc->base->virtbase;
1631 left = readl(cohc->base->virtbase +
1637 ladd = readl(cohc->base->virtbase +
1689 void __iomem *virtbase = cohc->base->virtbase;
1742 val = readl(cohc->base->virtbase + COH901318_CX_CFG +
1747 writel(val, cohc->base->virtbase + COH901318_CX_CFG +
1769 struct coh901318_base *base;
1777 if (&args->base->dma_slave == chan->device &&
1788 .base = ofdma->of_dma_data,
1805 void __iomem *virtbase = cohc->base->virtbase;
1897 coh901318_lli_free(&cohc->base->pool, &cohd_fin->lli);
1987 struct coh901318_base *base = dev_id;
1989 void __iomem *virtbase = base->virtbase;
1995 dev_warn(base->dev, "spurious DMA IRQ from no channel!\n");
2008 cohc = &base->chans[ch];
2054 cohc = &base->chans[ch];
2102 void __iomem *virtbase = cohc->base->virtbase;
2123 coh901318_lli_free(&cohc->base->pool, &cohd->lli);
2132 coh901318_lli_free(&cohc->base->pool, &cohd->lli);
2181 writel(0x00000000U, cohc->base->virtbase + COH901318_CX_CFG +
2183 writel(0x00000000U, cohc->base->virtbase + COH901318_CX_CTRL +
2239 lli = coh901318_lli_alloc(&cohc->base->pool, lli_len);
2245 &cohc->base->pool, lli, src, size, dest,
2352 lli = coh901318_lli_alloc(&cohc->base->pool, len);
2360 ret = coh901318_lli_fill_sg(&cohc->base->pool, lli, sgl, sg_len,
2590 struct coh901318_base *base)
2600 cohc = &base->chans[i];
2602 cohc->base = base;
2629 struct coh901318_base *base;
2644 base = devm_kzalloc(&pdev->dev,
2649 if (!base)
2652 base->chans = ((void *)base) + ALIGN(sizeof(struct coh901318_base), 4);
2654 base->virtbase = devm_ioremap(&pdev->dev, io->start, resource_size(io));
2655 if (!base->virtbase)
2658 base->dev = &pdev->dev;
2659 spin_lock_init(&base->pm.lock);
2660 base->pm.started_channels = 0;
2662 COH901318_DEBUGFS_ASSIGN(debugfs_dma_base, base);
2669 "coh901318", base);
2673 base->irq = irq;
2675 err = coh901318_pool_create(&base->pool, &pdev->dev,
2682 coh901318_base_init(&base->dma_slave, dma_slave_channels,
2683 base);
2685 dma_cap_zero(base->dma_slave.cap_mask);
2686 dma_cap_set(DMA_SLAVE, base->dma_slave.cap_mask);
2688 base->dma_slave.device_alloc_chan_resources = coh901318_alloc_chan_resources;
2689 base->dma_slave.device_free_chan_resources = coh901318_free_chan_resources;
2690 base->dma_slave.device_prep_slave_sg = coh901318_prep_slave_sg;
2691 base->dma_slave.device_tx_status = coh901318_tx_status;
2692 base->dma_slave.device_issue_pending = coh901318_issue_pending;
2693 base->dma_slave.device_config = coh901318_dma_slave_config;
2694 base->dma_slave.device_pause = coh901318_pause;
2695 base->dma_slave.device_resume = coh901318_resume;
2696 base->dma_slave.device_terminate_all = coh901318_terminate_all;
2697 base->dma_slave.dev = &pdev->dev;
2699 err = dma_async_device_register(&base->dma_slave);
2705 coh901318_base_init(&base->dma_memcpy, dma_memcpy_channels,
2706 base);
2708 dma_cap_zero(base->dma_memcpy.cap_mask);
2709 dma_cap_set(DMA_MEMCPY, base->dma_memcpy.cap_mask);
2711 base->dma_memcpy.device_alloc_chan_resources = coh901318_alloc_chan_resources;
2712 base->dma_memcpy.device_free_chan_resources = coh901318_free_chan_resources;
2713 base->dma_memcpy.device_prep_dma_memcpy = coh901318_prep_memcpy;
2714 base->dma_memcpy.device_tx_status = coh901318_tx_status;
2715 base->dma_memcpy.device_issue_pending = coh901318_issue_pending;
2716 base->dma_memcpy.device_config = coh901318_dma_slave_config;
2717 base->dma_memcpy.device_pause = coh901318_pause;
2718 base->dma_memcpy.device_resume = coh901318_resume;
2719 base->dma_memcpy.device_terminate_all = coh901318_terminate_all;
2720 base->dma_memcpy.dev = &pdev->dev;
2725 base->dma_memcpy.copy_align = DMAENGINE_ALIGN_4_BYTES;
2726 err = dma_async_device_register(&base->dma_memcpy);
2732 base);
2736 platform_set_drvdata(pdev, base);
2737 dev_info(&pdev->dev, "Initialized COH901318 DMA on virtual base 0x%p\n",
2738 base->virtbase);
2743 dma_async_device_unregister(&base->dma_memcpy);
2745 dma_async_device_unregister(&base->dma_slave);
2747 coh901318_pool_destroy(&base->pool);
2750 static void coh901318_base_remove(struct coh901318_base *base, const int *pick_chans)
2758 cohc = &base->chans[i];
2768 struct coh901318_base *base = platform_get_drvdata(pdev);
2770 devm_free_irq(&pdev->dev, base->irq, base);
2772 coh901318_base_remove(base, dma_slave_channels);
2773 coh901318_base_remove(base, dma_memcpy_channels);
2776 dma_async_device_unregister(&base->dma_memcpy);
2777 dma_async_device_unregister(&base->dma_slave);
2778 coh901318_pool_destroy(&base->pool);