[PATCH 2/2] Add MIPS arch support to barebox

Antony Pavlov antonynpavlov at gmail.com
Tue Jun 28 05:03:36 EDT 2011


On 28/06/2011, Sascha Hauer <s.hauer at pengutronix.de> wrote:
> On Mon, Jun 27, 2011 at 09:13:54PM +0400, Antony Pavlov wrote:
>> Only supported board is qemu malta:
>>   * barebox works in uncached memory;
>>   * no peripherals support, but serial port.
>>
>> Signed-off-by: Antony Pavlov <antonynpavlov at gmail.com>
>
> Looks mostly good, some comments inline.

...

>>
>> diff --git a/arch/mips/boards/malta/serial.c
>> b/arch/mips/boards/malta/serial.c
>> new file mode 100644
>> index 0000000..b3ade0c
>> --- /dev/null
>> +++ b/arch/mips/boards/malta/serial.c
...
>
> The whole file is inside CONFIG_DRIVER_SERIAL_NS16550, so you can do
> a obj-$(CONFIG_DRIVER_SERIAL_NS16550) += serial.o in the Makefile
> instead.

Ok.


>> diff --git a/arch/mips/configs/malta_defconfig
>> b/arch/mips/configs/malta_defconfig
>
> Please generate your defconfig file with make savedefconfig

I have know nothing about savedefconfig. I will use it.

>> +/**
>> + * @file
>> + * @brief mips posix types
>> + *
>> + * Minimal set to make all the other header files copied from the Linxu
>> kernel happy
>
> s/Linxu/Linux/
>

I did't used spell checker, but I must do.

:)

...

>> +void reset_cpu(ulong addr)
>> +{
>> +	/** How to reset the machine? */
>
> I don't know either. We should add some printf here until we know.
>

qemu malta board has magic register to reset the machine
(see "SOFTRES Register" in qemu.git/hw/mips_malta.c).

For other board we can easily jump to start of bootrom. I think it is
possible in th future to introduce option to configure reset_cpu()'s
behavior.

-- 
Best regards,
  Antony Pavlov



More information about the barebox mailing list