allocating non-cacheable memory
What is the best way to allocate some non-cacheable memory for I/O use? Right now we are going to setup a BAT table with a non-cacheable memory region and use that for all I/O, but does linux have a nice neat function to grab a page and set it up non-cacheable for us? I was reading in the archives that the #define PAGE_NOCACHE doesn't work.
thanks!
Kevin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 2 lines · Kevin Fry
What is the best way to allocate some non-cacheable memory for I/O use? Right now we are going to setup a BAT table with a non-cacheable memory
If you have a processor with BAT, why do you need non-cached memory?
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Hi
Setting up a BAT by some asembler code is good.
Or you can use io_block_mapping.
For exampleio_block_mapping(0x78000000, 0x78000000, 0x08000000, _PAGE_IO);
It maps phisical address 0x78000000 ~ 0x7FFFFFFF to effective address 0x78000000 ~ 0x7FFFFFFF, No cache.
- Sangmoon Kim -
----- Original Message -----
From: "Kevin Fry" <[email protected]>
To: <[email protected]>
Sent: Thursday, December 20, 2001 10:44 AM
Subject: allocating non-cacheable memory
Quoted 8 lines
What is the best way to allocate some non-cacheable memory for I/O use? Right now we are going to setup a BAT table with a non-cacheable memory region and use that for all I/O, but does linux have a nice neat function to grab a page and set it up non-cacheable for us? I was reading in the archives that the #define
PAGE_NOCACHEdoesn't work.
Quoted 7 lines
thanks!
Kevin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/