vm_page_startup()

Jayachandran C. c.jayachandran at gmail.com
Fri Dec 3 07:42:07 UTC 2010


On Thu, Dec 2, 2010 at 11:24 PM, Alan Cox <alc at rice.edu> wrote:
> Warner Losh wrote:
>>
>> On 11/30/2010 23:03, Alan Cox wrote:
>>>
>>> Given this bit of code in the MIPS pmap:
>>>
>>> vm_offset_t
>>> pmap_map(vm_offset_t *virt, vm_offset_t start, vm_offset_t end, int prot)
>>> {
>>>   vm_offset_t va, sva;
>>>
>>>   if (MIPS_DIRECT_MAPPABLE(end))
>>>       return (MIPS_PHYS_TO_DIRECT(start));
>>
>> All mips architectures have at least a small direct map...
>
...
> Doesn't the above test have an off-by-error, specifically, shouldn't it be
> "MIPS_DIRECT_MAPPABLE(end - 1)"?

Yes. There was another place where the same error was made.  I have
attached a patch for these (also cleans up a few comments which I had
added some time back).

If there are no objections, I will check this in later today.

JC.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mips-pmap.patch
Type: text/x-patch
Size: 2071 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-mips/attachments/20101203/2c90f4e8/mips-pmap.bin


More information about the freebsd-mips mailing list