Re: mechanism to allow a driver to bind to any device

2014-03-28 Thread Greg KH
On Wed, Mar 26, 2014 at 10:39:57PM +0100, Antonios Motakis wrote: Of note is that new_id doesn't work particularly well for platform devices. Nor should it. Platform devices suck horribly, and ids mean nothing to them, so you shouldn't even try this. Use a real bus and it should be fine.

[patch] iommu/vt-d: returning free pointer in get_domain_for_dev()

2014-03-28 Thread Dan Carpenter
If we hit this error condition then we want to return a NULL pointer and not a freed variable. Signed-off-by: Dan Carpenter dan.carpen...@oracle.com diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index 6fbce01..69fa7da 100644 --- a/drivers/iommu/intel-iommu.c +++

Re: mechanism to allow a driver to bind to any device

2014-03-28 Thread Konrad Rzeszutek Wilk
On Wed, Mar 26, 2014 at 04:09:21PM -0600, Alex Williamson wrote: On Wed, 2014-03-26 at 10:21 -0600, Alex Williamson wrote: On Wed, 2014-03-26 at 23:06 +0800, Alexander Graf wrote: Am 26.03.2014 um 22:40 schrieb Konrad Rzeszutek Wilk konrad.w...@oracle.com: On Wed, Mar 26,

Re: mechanism to allow a driver to bind to any device

2014-03-28 Thread Alex Williamson
On Fri, 2014-03-28 at 12:58 -0400, Konrad Rzeszutek Wilk wrote: On Wed, Mar 26, 2014 at 04:09:21PM -0600, Alex Williamson wrote: On Wed, 2014-03-26 at 10:21 -0600, Alex Williamson wrote: On Wed, 2014-03-26 at 23:06 +0800, Alexander Graf wrote: Am 26.03.2014 um 22:40 schrieb Konrad

Re: [patch] iommu/vt-d: returning free pointer in get_domain_for_dev()

2014-03-28 Thread David Woodhouse
On Fri, 2014-03-28 at 11:29 +0300, Dan Carpenter wrote: If we hit this error condition then we want to return a NULL pointer and not a freed variable. Signed-off-by: Dan Carpenter dan.carpen...@oracle.com diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index

[PATCH v2] iommu: Add driver for Renesas VMSA-compatible IPMMU

2014-03-28 Thread Laurent Pinchart
Signed-off-by: Laurent Pinchart laurent.pinchart+rene...@ideasonboard.com --- drivers/iommu/Kconfig| 12 + drivers/iommu/Makefile |1 + drivers/iommu/ipmmu-vmsa.c | 1070 ++

[PATCH 3/5] iommu/ipmmu-vmsa: Add device tree support

2014-03-28 Thread Laurent Pinchart
Make platform data optional when the device is instantiated from DT and look up the micro-TLB number in the bus master DT node. Signed-off-by: Laurent Pinchart laurent.pinchart+rene...@ideasonboard.com --- drivers/iommu/ipmmu-vmsa.c | 37 + 1 file changed, 29

[PATCH 0/5] Renesas VMSA-compatible IPMMU DT support

2014-03-28 Thread Laurent Pinchart
Hello, This patch set adds DT support to the Renesas VMSA-compatible IPMMU driver. The first patch refactors the driver to remove dependencies on platform data, the second patch adds the DT bindings documentation and the third patch implement them in the driver. The next two patches show

[PATCH 4/5] ARM: shmobile: r8a7791: Add IPMMU DT nodes

2014-03-28 Thread Laurent Pinchart
Signed-off-by: Laurent Pinchart laurent.pinchart+rene...@ideasonboard.com --- arch/arm/boot/dts/r8a7791.dtsi | 49 ++ 1 file changed, 49 insertions(+) diff --git a/arch/arm/boot/dts/r8a7791.dtsi b/arch/arm/boot/dts/r8a7791.dtsi index 2e22cb2..bbadf7a

[PATCH 1/5] iommu/ipmmu-vmsa: Refactor micro-TLB lookup

2014-03-28 Thread Laurent Pinchart
Cache the micro-TLB number in archdata allocated in the .add_device handler instead of looking it up when the deviced is attached and detached. This simplifies the .attach_dev and .detach_dev operations and prepares for DT support. Signed-off-by: Laurent Pinchart

[PATCH 5/5] [TEST] ARM: shmobile: r8a7791: Enable IOMMU support for the VSP1

2014-03-28 Thread Laurent Pinchart
Signed-off-by: Laurent Pinchart laurent.pinchart+rene...@ideasonboard.com --- arch/arm/boot/dts/r8a7791.dtsi | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/r8a7791.dtsi b/arch/arm/boot/dts/r8a7791.dtsi index bbadf7a..26edcbe 100644 ---

[PATCH 2/5] iommu/ipmmu-vmsa: Add device tree bindings documentation

2014-03-28 Thread Laurent Pinchart
Cc: devicet...@vger.kernel.org Cc: Will Deacon will.dea...@arm.com Signed-off-by: Laurent Pinchart laurent.pinchart+rene...@ideasonboard.com --- .../bindings/iommu/renesas,ipmmu-vmsa.txt | 35 ++ 1 file changed, 35 insertions(+) create mode 100644