From d22976dd5e16e8719abd5c542e17427eeece7ff6 Mon Sep 17 00:00:00 2001 From: Bernd Schmidt Date: Fri, 18 Jan 2008 13:53:10 +0000 Subject: L1 memory support for the Blackfin. A couple new syscalls to manage L1 allocations, dma_memcpy to move stuff between L1 and main memory, and a new structure to describe the global data in L1 scratchpad memory. --- libc/sysdeps/linux/bfin/bfin_sram.h | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 libc/sysdeps/linux/bfin/bfin_sram.h (limited to 'libc/sysdeps/linux/bfin/bfin_sram.h') diff --git a/libc/sysdeps/linux/bfin/bfin_sram.h b/libc/sysdeps/linux/bfin/bfin_sram.h new file mode 100644 index 000000000..eea729b05 --- /dev/null +++ b/libc/sysdeps/linux/bfin/bfin_sram.h @@ -0,0 +1,30 @@ +/* + * bfin_sram.h - userspace interface to L1 memory allocator + * + * Copyright (c) 2007 Analog Devices Inc. + * + * Licensed under the GPL-2 or later. + */ + +#ifndef __BFIN_SRAM_H__ +#define __BFIN_SRAM_H__ + +#include +#include + +__BEGIN_DECLS + +#define L1_INST_SRAM 0x00000001 +#define L1_DATA_A_SRAM 0x00000002 +#define L1_DATA_B_SRAM 0x00000004 +#define L1_DATA_SRAM 0x00000006 + +extern void *sram_alloc(size_t size, unsigned long flags) + __attribute_malloc__ __attribute_warn_unused_result__; +extern int sram_free(const void *addr); +extern void *dma_memcpy(void *dest, const void *src, size_t len) + __nonnull((1, 2)); + +__END_DECLS + +#endif -- cgit v1.2.3