summaryrefslogtreecommitdiffstats
path: root/drivers/platform/x86/toshiba_acpi.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2014-02-28 14:42:38 -0600
committerJoerg Roedel <joro@8bytes.org>2014-03-04 17:02:43 +0100
commit07a0203021149140f83e64a9ac5fe7ed09a74afc (patch)
tree274fe2bd2984aad36c941fb0d1b7988638784afd /drivers/platform/x86/toshiba_acpi.c
parentb148d5fb2ef7bd1441e95402effe22b7b34f9a73 (diff)
iommu/omap: Allocate archdata on the fly for DT-based devices
The OMAP IOMMU driver locates the IOMMU associated to a device using the IOMMU name stored in the device archdata iommu field. That field is expected to be populated by platform code and is left unset for DT-based devices. This results in a crash when the IOMMU driver attaches a domain to a device. Fix this by allocating the archdata iommu structure when devices are added and freeing when they are removed. Devices without an OF node, and devices without an iommus property in their OF node are ignored. The iommu name is initialized from the IOMMU device node name. This should be simplified when removing non-DT support completely from the IOMMU users as the IOMMU name won't be needed anymore, and the IOMMU device pointer could then be stored in the archdata iommu field directly. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> [s-anna@ti.com: updated to use device name instead of OF name] Signed-off-by: Suman Anna <s-anna@ti.com> Signed-off-by: Joerg Roedel <joro@8bytes.org>
Diffstat (limited to 'drivers/platform/x86/toshiba_acpi.c')
0 files changed, 0 insertions, 0 deletions