[PATCH] 8xx: fix usage of pinned 8Mbyte TLB entries

Dan Malek dan at embeddededge.com
Sat May 7 15:55:24 EST 2005


> On May 6, 2005, at 4:03 PM, Marcelo Tosatti wrote:
>
>>         /* get the PTE for the bootpage */
>>         if (!get_pteptr(&init_mm, bootpage, &pte))
>>                panic("get_pteptr failed\n");
>>
>>         /* and make it uncachable */
>>         pte_val(*pte) |= _PAGE_NO_CACHE;
>>         _tlbie(bootpage);

Can someone explain to me why this was necessary,
along with the weird hacks in the serial driver to
hostmem_alloc() if we are using the console and
dma_alloc_consistent() if we aren't?


This bootmem page stuff should not be necessary,
the cpm_reset() doesn't need to allocate the host
buffer, and it should be done the first time hostmem_alloc()
is called.

I don't have an 8xx handy.  Can someone remove all of this:

         /* get the PTE for the bootpage */
         if (!get_pteptr(&init_mm, bootpage, &pte))
                panic("get_pteptr failed\n");


         /* and make it uncachable */
         pte_val(*pte) |= _PAGE_NO_CACHE;
         _tlbie(bootpage);

         host_buffer = bootpage;
         host_end = host_buffer + PAGE_SIZE;


from arch/ppc/8xx_io/commproc.c and let me know
if the system still works?

Thanks.


	-- Dan




More information about the Linuxppc-embedded mailing list