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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200906011745.59793.arnd@arndb.de>
Date:	Mon, 1 Jun 2009 17:45:58 +0100
From:	Arnd Bergmann <arnd@...db.de>
To:	michal.simek@...alogix.com
Cc:	FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>,
	linux-kernel@...r.kernel.org, linux-arch@...r.kernel.org,
	lethal@...ux-sh.org, chris@...kel.net,
	John Williams <john.williams@...alogix.com>
Subject: Re: [PATCH] asm-generic: add dma-mapping-linear.h

On Monday 01 June 2009, Michal Simek wrote:

> Microblaze have it but it is not cleared(checked) and not in mainline -
> I want to look at it when mmu is in mainline.
> As I wrote before  you can use Microblaze as tested arch.

Ok. It should become really easy once the asm-generic version is there.
Do you know if all DMA capable devices on microblaze are coherent
(or if all of them are noncoherent)?

If it is indeed coherent, the below code should be enough, otherwise
you need to add some cache flushes in the functions below.

	Arnd <><

---
#ifndef _ASM_MICROBLAZE_DMA_MAPPING_H
#define _ASM_MICROBLAZE_DMA_MAPPING_H

static inline int
__dma_coherent_dev(struct device *dev)
{
	return 1;
}

static inline void
dma_cache_sync(struct device *dev, void *cpu_addr, size_t size,
	       enum dma_data_direction direction)
{
}

static inline int dma_get_cache_alignment(void)
{
	return 1 << L1_CACHE_SHIFT;
}

#include <asm-generic/dma-mapping-linear.h>

#endif _ASM_MICROBLAZE_DMA_MAPPING_H
--
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