Port-mips archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: mips changes for loongson2



On Aug 24, 2011, at 3:25 PM, Simon Burge wrote:

> Manuel Bouyer wrote:
> 
>> Hello,
>> my work on getting the lemote fuloong working is almost ready to
>> be commited (it'll be another evbmips sub-port: evbmips/loongson,
>> which should also work on the lebote yeloong, the gdium and probably others).
> 
> Good to see it taking shape!
> 
>> This requires a few changes to some mips-specific files as in the attached
>> patches:
>> - bonito.diff:
>>  make the 'struct bonito_config' const, so that it can be in kernel
>>  text instead of data. This needs some __UNCONST() but I guess
>>  it's no big deal.
>>  Add a bc_attach_hook to struct bonito_config, to be used as pc_attach_hook
>>  if not NULL.
>>  Add some LS2-specific register defines (LS2f uses a modified bonito64).
> 
> This looks OK.  The lemote fuloong really uses a Bonito or some
> derivative thereof?

Yes it does.


>> Index: include/vmparam.h
>> ===================================================================
>> RCS file: /cvsroot/src/sys/arch/mips/include/vmparam.h,v
>> retrieving revision 1.49
>> diff -u -p -u -r1.49 vmparam.h
>> --- include/vmparam.h        21 Jul 2011 23:03:39 -0000      1.49
>> +++ include/vmparam.h        24 Aug 2011 17:21:23 -0000
>> @@ -155,7 +155,11 @@
>>  */
>> #define VM_MIN_ADDRESS               ((vaddr_t)0x00000000)
>> #ifdef _LP64
>> +#if 0
>> #define VM_MAXUSER_ADDRESS   ((vaddr_t) 1L << (4*PGSHIFT-8))
>> +#else
>> +#define VM_MAXUSER_ADDRESS  ((vaddr_t) 1L << (40))
>> +#endif
> 
> Can the "40" be described in terms of any existing (or new) constants?
> If not, could you please add a comment on how the 40 was derived?  Also,
> I'd not leave the "#if 0" block in - cvs will keep the history.

This has been properly fixed using the mips3_tlb_probe which I added a long 
time ago to find the maximum virtual address per region (user, kernel, super).


Home | Main Index | Thread Index | Old Index