Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3378e7a4 authored by Vinod Koul's avatar Vinod Koul
Browse files

Merge branch 'topic/qcom' into for-linus

parents dd2b9ff8 dc7c733a
Loading
Loading
Loading
Loading
+15 −0
Original line number Original line Diff line number Diff line
@@ -865,6 +865,20 @@ static int hidma_probe(struct platform_device *pdev)
	return rc;
	return rc;
}
}


static void hidma_shutdown(struct platform_device *pdev)
{
	struct hidma_dev *dmadev = platform_get_drvdata(pdev);

	dev_info(dmadev->ddev.dev, "HI-DMA engine shutdown\n");

	pm_runtime_get_sync(dmadev->ddev.dev);
	if (hidma_ll_disable(dmadev->lldev))
		dev_warn(dmadev->ddev.dev, "channel did not stop\n");
	pm_runtime_mark_last_busy(dmadev->ddev.dev);
	pm_runtime_put_autosuspend(dmadev->ddev.dev);

}

static int hidma_remove(struct platform_device *pdev)
static int hidma_remove(struct platform_device *pdev)
{
{
	struct hidma_dev *dmadev = platform_get_drvdata(pdev);
	struct hidma_dev *dmadev = platform_get_drvdata(pdev);
@@ -908,6 +922,7 @@ MODULE_DEVICE_TABLE(of, hidma_match);
static struct platform_driver hidma_driver = {
static struct platform_driver hidma_driver = {
	.probe = hidma_probe,
	.probe = hidma_probe,
	.remove = hidma_remove,
	.remove = hidma_remove,
	.shutdown = hidma_shutdown,
	.driver = {
	.driver = {
		   .name = "hidma",
		   .name = "hidma",
		   .of_match_table = hidma_match,
		   .of_match_table = hidma_match,
+6 −0
Original line number Original line Diff line number Diff line
@@ -499,6 +499,9 @@ int hidma_ll_enable(struct hidma_lldev *lldev)
	lldev->trch_state = HIDMA_CH_ENABLED;
	lldev->trch_state = HIDMA_CH_ENABLED;
	lldev->evch_state = HIDMA_CH_ENABLED;
	lldev->evch_state = HIDMA_CH_ENABLED;


	/* enable irqs */
	writel(ENABLE_IRQS, lldev->evca + HIDMA_EVCA_IRQ_EN_REG);

	return 0;
	return 0;
}
}


@@ -596,6 +599,9 @@ int hidma_ll_disable(struct hidma_lldev *lldev)


	lldev->trch_state = HIDMA_CH_SUSPENDED;
	lldev->trch_state = HIDMA_CH_SUSPENDED;
	lldev->evch_state = HIDMA_CH_SUSPENDED;
	lldev->evch_state = HIDMA_CH_SUSPENDED;

	/* disable interrupts */
	writel(0, lldev->evca + HIDMA_EVCA_IRQ_EN_REG);
	return 0;
	return 0;
}
}