mirror of
git://projects.qi-hardware.com/ben-blinkenlights.git
synced 2024-12-26 21:00:48 +02:00
ubb-patgen/ubb-patgen.c (send_buffer): use physmem_flush instead of cacheflush
This commit is contained in:
parent
a8f905a85f
commit
ff38f1c249
@ -11,7 +11,7 @@
|
||||
#
|
||||
|
||||
CC = mipsel-openwrt-linux-gcc
|
||||
CFLAGS = -g -Wall -O9 -march=mips32 -I../libubb/include
|
||||
CFLAGS = -g -Wall -O9 -I../libubb/include
|
||||
LDFLAGS =
|
||||
LDLIBS = -L../libubb -lubb -lm
|
||||
|
||||
|
@ -20,7 +20,6 @@
|
||||
#include <time.h>
|
||||
#include <assert.h>
|
||||
#include <sys/mman.h>
|
||||
#include <asm/cachectl.h>
|
||||
|
||||
#include <ubb/ubb.h>
|
||||
#include <ubb/regs4740.h>
|
||||
@ -31,9 +30,6 @@
|
||||
#define DMA 5
|
||||
|
||||
|
||||
extern int cacheflush(char *addr, int nbytes, int cache);
|
||||
|
||||
|
||||
/* ----- List available bus clock frequencies ------------------------------ */
|
||||
|
||||
|
||||
@ -390,13 +386,11 @@ static void send_buffer(const struct mmcclk *clk,
|
||||
{
|
||||
unsigned long phys;
|
||||
|
||||
if (cacheflush((void *) buf, nibbles >> 1, DCACHE)) {
|
||||
perror("cacheflush");
|
||||
if (physmem_flush(buf, nibbles)) {
|
||||
perror("physmem_flush");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
asm("sync"); /* flush the write buffer */
|
||||
|
||||
phys = physmem_xlat((void *) buf);
|
||||
mmc_buffer(clk, buf[0] >> 4, phys, nibbles, mask, trigger);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user