[PATCH] ndfc driver

Kostas Nakos
2008-12-23T12:26:27Z

Hello list,

with respect to Sean's updated patch (
http://lists.infradead.org/pipermail/linux-mtd/2008-December/023932.html
) of the ndfc driver:

We are using an AMCC PPC440EPx based board which requires the ndfc
driver to handle the nand memory. We have encountered 2 problems with
this latest patch:

1) Kernel oops after of_iomap() of ndfc_probe(). The external nand
memory is bound to chip select 0. The respective dts "reg" line was 'reg
= <0 d0000000 2000>;'. Using chip selects greater than zero do not crash
the kernel.

2) Byte order wrong in ndfc_calculate_ecc(). ecc_code[0] and ecc_code[1]
have been exchanged in this version of the patch which lead to ecc
errors being reported during mounting (and of course, a failed mount
operation).

These problems have been solved: (1) -hackish way- by using a dts line
like this 'reg = <1 d0000000 2000>;' and calculating the chip select in
ndfc_probe() like this 'ndfc->chip_select = reg[0] - 1;'. (2) has been
fixed by returning to the previous byte order of ecc_code.

Cheers,
Kostas