lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 27 Jan 2014 16:35:18 +0100 (CET)
From:	Guennadi Liakhovetski <g.liakhovetski@....de>
To:	Ben Dooks <ben@...nity.fluff.org>
cc:	linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
	linux-mmc@...r.kernel.org, dmaengine@...r.kernel.org
Subject: Re: [Q] block / zynq: DMA bouncing

Hi Ben,

On Mon, 27 Jan 2014, Ben Dooks wrote:

> On Mon, Jan 27, 2014 at 04:13:56PM +0100, Guennadi Liakhovetski wrote:
> > Hi all,
> > 
> > I'm working on an MMC driver with a DMA capability. All has been working 
> > well, until at some point I've got a bus error, when the mmc driver had 
> > been handed in a buffer at 0x3000 physical RAM address. The reason is, 
> > that on Zynq arch bus masters cannot access RAM below 0x80000. Therefore 
> > my question: how shall I configure this in software?
> > 
> > The way I found was to use ARM-specific struct dmabounce_device_info and 
> > implement its .needs_bounce() method to return true for those addresses. 
> > Is this the right way or is there a better / more straight-forward one?
> > 
> > To do the above I have to enable CONFIG_DMABOUNCE, which then selects 
> > CONFIG_ZONE_DMA. Having done just that I suddenly discover, that 0x3000 
> > buffers aren't used any more, so, I cannot actually verify my 
> > implementation :) Looking at ZONE_DMA it looks like it is still covering 
> > the whole RAM range (/proc/zoneinfo shows start_pfn=0 in zone DMA), so, I 
> > don't see why 0x3000 should be excluded now.
> > 
> > So, is using the .needs_bounce() method the correct way to support DMA on 
> > this arch or is there a better one?
> 
> I have a similar issue with Renesas R8A7790 where there is a bus bridge
> that can only deal with transactions to one half of the available RAM.

Have you tried enabling CONFIG_DMABOUNCE?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ