virtual memory issue

Ofer Rashuk OferR at
Sun Nov 4 19:42:58 EST 2001

on my custom board with PPC8240 I'm trying to run some small user space
the program tries to read a device (Galileo device) that on the PCI bus.
i configured the access to the device using mmap and got a pointer with a
virtual address.

my question is who can i translate the virtual address to a physical one.
i tried it use several functions such as virt_to_phys and virt_to_bus but i
keep getting a compilation error
target/user/include/asm-ppc/io.h:214:undefined reference to 'iopa'

what am i doing wrong, is there any lib that I'm forgetting.

my compile line is as follows:
	$(CC) $(CFLAGS) -c $*.c


# Make the program...
OBJS =  \
	task.o queue.o vqueue.o event.o memblk.o timer.o sema4.o demo2.o

PROG = demo

all:	$(PROG)

$(PROG): $(OBJS) Makefile
	$(CC) $(CFLAGS) $(OBJS) -o $(PROG) -lpthread

Ofer Rashuk-Rosenthal.
Software team leader.
mailto:oferr at

** Sent via the linuxppc-embedded mail list. See

More information about the Linuxppc-embedded mailing list