All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH] xen/gntdev: Stop abusing DT of_dma_configure API
@ 2019-09-25 21:50 ` Rob Herring
  0 siblings, 0 replies; 18+ messages in thread
From: Rob Herring @ 2019-09-25 21:50 UTC (permalink / raw)
  To: Oleksandr Andrushchenko, Boris Ostrovsky
  Cc: linux-kernel, Robin Murphy, Julien Grall, Nicolas Saenz Julienne,
	Juergen Gross, Stefano Stabellini, xen-devel

As the comment says, this isn't a DT based device. of_dma_configure()
is going to stop allowing a NULL DT node, so this needs to be fixed.

Not sure exactly what setup besides arch_setup_dma_ops is needed...

Cc: Robin Murphy <robin.murphy@arm.com>
Cc: Julien Grall <julien.grall@arm.com>
Cc: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Cc: Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: Juergen Gross <jgross@suse.com>
Cc: Stefano Stabellini <sstabellini@kernel.org>
Cc: xen-devel@lists.xenproject.org
Signed-off-by: Rob Herring <robh@kernel.org>
---
 drivers/xen/gntdev.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c
index a446a7221e13..59906f9a40e4 100644
--- a/drivers/xen/gntdev.c
+++ b/drivers/xen/gntdev.c
@@ -34,9 +34,6 @@
 #include <linux/slab.h>
 #include <linux/highmem.h>
 #include <linux/refcount.h>
-#ifdef CONFIG_XEN_GRANT_DMA_ALLOC
-#include <linux/of_device.h>
-#endif
 
 #include <xen/xen.h>
 #include <xen/grant_table.h>
@@ -625,14 +622,6 @@ static int gntdev_open(struct inode *inode, struct file *flip)
 	flip->private_data = priv;
 #ifdef CONFIG_XEN_GRANT_DMA_ALLOC
 	priv->dma_dev = gntdev_miscdev.this_device;
-
-	/*
-	 * The device is not spawn from a device tree, so arch_setup_dma_ops
-	 * is not called, thus leaving the device with dummy DMA ops.
-	 * Fix this by calling of_dma_configure() with a NULL node to set
-	 * default DMA ops.
-	 */
-	of_dma_configure(priv->dma_dev, NULL, true);
 #endif
 	pr_debug("priv %p\n", priv);
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2019-10-02  4:43 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-25 21:50 [RFC PATCH] xen/gntdev: Stop abusing DT of_dma_configure API Rob Herring
2019-09-25 21:50 ` [Xen-devel] " Rob Herring
2019-09-26  9:06 ` Nicolas Saenz Julienne
2019-09-26  9:06   ` [Xen-devel] " Nicolas Saenz Julienne
2019-09-26  9:49 ` Julien Grall
2019-09-26  9:49   ` [Xen-devel] " Julien Grall
2019-09-26 10:17   ` Oleksandr Andrushchenko
2019-09-26 10:17     ` [Xen-devel] " Oleksandr Andrushchenko
2019-09-26 10:46     ` Robin Murphy
2019-09-26 10:46       ` [Xen-devel] " Robin Murphy
2019-09-26 11:16       ` Oleksandr Andrushchenko
2019-09-26 11:16         ` [Xen-devel] " Oleksandr Andrushchenko
2019-09-26 19:27         ` Rob Herring
2019-09-26 19:27           ` [Xen-devel] " Rob Herring
2019-10-01 18:23           ` Stefano Stabellini
2019-10-01 18:23             ` [Xen-devel] " Stefano Stabellini
2019-10-02  4:42             ` Oleksandr Andrushchenko
2019-10-02  4:42               ` [Xen-devel] " Oleksandr Andrushchenko

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.