io_block_mapping & ioremap question
Gutson Daniel-ADG035
daniel.gutson at motorola.com
Wed Apr 16 02:25:14 EST 2008
Hi,
I'm doing some work on 2.6.10, and got this problem:
- there are some io_block_mapping calls in the setup_io_mapping
callback, that use the BATs, and passing same va and pa each one.
Problem arises later when vmallocs gets a a pointer within the mapped
ranges. In other words, seems like the VMM is not aware of the BATs
mapping.
So what I did is: called first ioremap and then io_block_mapping in the
callback thus not hardcoding the va, something like:
va = ioremap(pa, size);
io_block_mapping(pa, va, size);
Questions:
1) Is it right?
2) Should I unmap that address sometime later? (i.e. after
mem_init_done).
Thanks!
Daniel.
Daniel F. Gutson
Software Engineer
Motorola GSG Argentina
Tel = (54)-351-420-9218
Fax = (54)-351-420-9202
iProtect Classification
[x] Public
[ ] Internal
[ ] Motorola Confidential Restricted
"we made a big mistake in coming down from the trees in the first place"
- D. Adams
More information about the Linuxppc-embedded
mailing list