<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Dec 27, 2012 at 7:45 PM, Marek Szyprowski <span dir="ltr"><<a href="mailto:m.szyprowski@samsung.com" target="_blank">m.szyprowski@samsung.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hello,<div><br>
<br>
On 12/27/2012 8:14 AM, Prathyush K wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
This patch adds EXPORT_SYMBOL calls to the three arm iommu<br>
functions - arm_iommu_create_mapping, arm_iommu_free_mapping<br>
and arm_iommu_attach_device. These functions can now be called<br>
from dynamic modules.<br>
</blockquote>
<br></div>
Could You describe a bit more why those functions might be needed by dynamic modules?<div><br></div></blockquote><div>Hi Marek,</div><div><br></div><div>We are adding iommu support to exynos gsc and s5p-mfc.</div><div style>
And these two drivers need to be built as modules to improve boot time.</div><div style><br></div><div style>We're calling these three functions from inside these drivers:</div><div style><div style>e.g.</div><div>mapping = arm_iommu_create_mapping(&platform_bus_type, 0x20000000, SZ_256M, 4);</div>
<div>arm_iommu_attach_device(mdev, mapping);<br></div></div>
<div><br></div><div style> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Signed-off-by: Prathyush K <<a href="mailto:prathyush.k@samsung.com" target="_blank">prathyush.k@samsung.com</a>><br>
---<br>
  arch/arm/mm/dma-mapping.c | 3 +++<br>
  1 file changed, 3 insertions(+)<br>
<br>
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c<br>
index 6b2fb87..c0f0f43 100644<br>
--- a/arch/arm/mm/dma-mapping.c<br>
+++ b/arch/arm/mm/dma-mapping.c<br>
@@ -1797,6 +1797,7 @@ err2:<br>
  err:<br>
        return ERR_PTR(err);<br>
  }<br>
+EXPORT_SYMBOL(arm_iommu_<u></u>create_mapping);<br>
</blockquote>
<br></div>
EXPORT_SYMOBL_GPL() ?<div><br></div></blockquote><div><br></div><div style>Right, it should be EXPORT_SYMOBL_GPL().</div><div style><br></div><div style>Will update in next patch.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
  static void release_iommu_mapping(struct kref *kref)<br>
  {<br>
@@ -1813,6 +1814,7 @@ void arm_iommu_release_mapping(<u></u>struct dma_iommu_mapping *mapping)<br>
        if (mapping)<br>
                kref_put(&mapping->kref, release_iommu_mapping);<br>
  }<br>
+EXPORT_SYMBOL(arm_iommu_<u></u>release_mapping);<br>
    /**<br>
   * arm_iommu_attach_device<br>
@@ -1841,5 +1843,6 @@ int arm_iommu_attach_device(struct device *dev,<br>
        pr_debug("Attached IOMMU controller to %s device.\n", dev_name(dev));<br>
        return 0;<br>
  }<br>
+EXPORT_SYMBOL(arm_iommu_<u></u>attach_device);<br>
    #endif<br>
</blockquote>
<br></div>
Best regards<span><font color="#888888"><br>
-- <br>
Marek Szyprowski<br>
Samsung Poland R&D Center<br>
<br>
<br>
</font></span></blockquote></div>Regards,</div><div class="gmail_extra" style>Prathyush</div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div><div class="gmail_extra"><br></div></div>