Small issue at init with spi_mpc8xxx.c with CPM1
Dear Kumar,
I have a small issue in the init of spi_mpc8xxx.c with MPC866 (CPM1)
Unlike cpm_uart that maps the parameter ram directly using of_iomap(np,1), spi_mpc8xxx.c uses cpm_muram_alloc_fixed().
This has two impacts in the .dts file:
* The driver must be declared with pram at 1d80 instead of 3d80 whereas it is not a child of muram@2000 but a child of cpm@9c0
* muram@2000/data@0 must be declared with reg = <0x0 0x2000> whereas is should be reg=<0x0 0x1c00> to avoid cpm_muram_alloc() to allocate space from parameters ram.
Maybe I misunderstood something ?
Regards
Christophe Leroy
Quoted 8 lines · On Tue, 7 Sep 2010 11:17:17 +0200 LEROY Christophe <[email protected]>…
Dear Kumar,
I have a small issue in the init of
spi_mpc8xxx.cwith MPC866 (CPM1)Unlike
cpm_uartthat maps the parameter ram directly usingof_iomap(np,1),spi_mpc8xxx.cusescpm_muram_alloc_fixed().
Quoted 8 lines
This has two impacts in the .dts file:
* The driver must be declared with pram at 1d80 instead of 3d80 whereas it is not a child of muram@2000 but a child of cpm@9c0
* muram@2000/data@0 must be declared with reg = <0x00x2000> whereas
is should be reg=<0x00x1c00> to avoidcpm_muram_alloc()to allocate space from parameters ram.Maybe I misunderstood something ?
Don't make the device tree lie, fix the driver instead.
The allocator should not be given any chunks of muram that are dedicated to a fixed purpose -- it might hand it out to something else before you reserve it. I don't think that cpm_muram_alloc_fixed() has any legitimate use at all.
-Scott