Re: [RFC PATCH 0/5] arm64: IOMMU-backed DMA mapping

2015-01-13 Thread Yingjoe Chen
On Mon, 2015-01-12 at 20:48 +, Robin Murphy wrote: > Hi all, > > Whilst it's a long way off perfect, this has reached the point of being > functional and stable enough to be useful, so here it is. The core > consists of the meat of the arch/arm implementation modified to remove > the assumptio

Re: [PATCH 1/2] iommu/io-pgtable: Add MTK 4GB mode in Short-descriptor

2016-03-10 Thread Yingjoe Chen
On Wed, 2016-03-02 at 12:31 +, Robin Murphy wrote: > Hi Yong, > > On 23/02/16 23:02, Yong Wu wrote: > > Mediatek extend bit9 in the lvl1 and lvl2 pgtable descriptor of the > > Short-descriptor as the 4GB mode in which the dram size will be > > over 4GB. > > > > We add a special quirk for this

Re: [RFC PATCH v2 2/3] arm64: add IOMMU dma_ops

2015-02-09 Thread Yingjoe Chen
On Fri, 2015-02-06 at 14:55 +, Robin Murphy wrote <...> > diff --git a/arch/arm64/include/asm/dma-mapping.h > b/arch/arm64/include/asm/dma-mapping.h > index 6932bb5..c1b271f 100644 > --- a/arch/arm64/include/asm/dma-mapping.h > +++ b/arch/arm64/include/asm/dma-mapping.h > @@ -62,13 +62,30 @@ s

Re: [PATCH 1/5] soc: mediatek: Add SMI driver

2015-03-08 Thread Yingjoe Chen
On Fri, 2015-03-06 at 18:48 +0800, yong...@mediatek.com wrote: > From: Yong Wu > > This patch add SMI(Smart Multimedia Interface) driver. This driver is > responsible to enable/disable iommu and control the clocks of each > local arbiter. > > Signed-off-by: Yong Wu > --- > drivers/soc/medi

Re: [PATCH 2/5] iommu/mediatek: Add mt8173 IOMMU driver

2015-03-09 Thread Yingjoe Chen
On Mon, 2015-03-09 at 20:11 +0900, Tomasz Figa wrote: <...> > > +/* > > + * pimudev is a global var for dma_alloc_coherent. > > + * It is not accepatable, we will delete it if "domain_alloc" is enabled > > + */ > > +static struct device *pimudev; > > This is indeed not acceptable. Could you replac

Re: [PATCH 2/5] iommu/mediatek: Add mt8173 IOMMU driver

2015-03-09 Thread Yingjoe Chen
On Tue, 2015-03-10 at 02:00 +0900, Tomasz Figa wrote: > On Mon, Mar 9, 2015 at 11:46 PM, Yingjoe Chen > wrote: > > On Mon, 2015-03-09 at 20:11 +0900, Tomasz Figa wrote: > > <...> > >> > +/* > >> > + * pimudev is a global var for dma_alloc_coh

Re: [PATCH 1/5] soc: mediatek: Add SMI driver

2015-03-09 Thread Yingjoe Chen
On Mon, 2015-03-09 at 18:59 +0100, Paul Bolle wrote: > Hi Yong, > > Yong Wu schreef op ma 09-03-2015 om 19:57 [+0800]: > > On Fri, 2015-03-06 at 12:30 +0100, Paul Bolle wrote: > > > On Fri, 2015-03-06 at 18:48 +0800, yong...@mediatek.com wrote: > > > > --- a/drivers/soc/mediatek/Kconfig > > > > ++

Re: [PATCH 1/5] soc: mediatek: Add SMI driver

2015-03-09 Thread Yingjoe Chen
On Mon, 2015-03-09 at 22:56 +0100, Arnd Bergmann wrote: > On Monday 09 March 2015 11:26:52 Yingjoe Chen wrote: > > On Fri, 2015-03-06 at 18:48 +0800, yong...@mediatek.com wrote: > > > From: Yong Wu > > > > > > This patch add SMI(Smart Multimed

Re: [PATCH 00/15] iommu: Move domain allocation into drivers

2015-03-20 Thread Yingjoe Chen
On Tue, 2015-01-27 at 00:51 +0100, Joerg Roedel wrote: > From: Joerg Roedel > > Hi, > > here is patch-set to replace the existing domain_init and > domain_destroy iommu-ops with the new domain_alloc and > domain_free callbacks > > The new callbacks move the allocation of iommu domains into > th

Re: [PATCH 00/15] iommu: Move domain allocation into drivers

2015-03-23 Thread Yingjoe Chen
On Mon, 2015-03-23 at 12:49 +0100, Joerg Roedel wrote: > Hi Yingjoe, > > On Fri, Mar 20, 2015 at 05:24:18PM +0800, Yingjoe Chen wrote: > > What's the status of this patchset? > > While porting MTK IOMMU driver[1], we need to use a global variable > > because we

Re: [PATCH 2/4] iommu: Implement common IOMMU ops for DMA mapping

2015-05-28 Thread Yingjoe Chen
Hi Robin, More info, hope this make it clearer. We are calling dma_map_sg_attrs with the following 2 sg. With IOMMU, we are expecting it got merged into 1 contiguous va range, but instead we get 2 va range. sg0 dma_address 0xfeeddc00 size 0x400, offset 0xc00 sg1 dma_address 0xfeede000 size 0x100

Re: [PATCH v6 03/10] iommu/mediatek: Use a u32 flags to describe different HW features

2020-07-03 Thread Yingjoe Chen
On Fri, 2020-07-03 at 12:41 +0800, Chao Hao wrote: > Given the fact that we are adding more and more plat_data bool values, > it would make sense to use a u32 flags register and add the appropriate > macro definitions to set and check for a flag present. > No functional change. > > Cc: Yong Wu >