- Jul 31, 2018
-
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
A comment in the probe declares that values are assigned to ecc.size and ecc.bytes, but these values will be overwritten. This is not entirely right as they are overwritten only if mtd->writesize >= 512. Let's clarify this by moving these assignations to txx9ndfmc_nand_scan(). Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Prepare the migration to nand_scan() by moving both calls to nand_scan_ident() and nand_scan_tail() in a single spot. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
An error after nand_scan_tail() should trigger a nand_cleanup(), not a nand_release() as mtd_device_register() (or one of its variants) has not been called and there is no need to deregister any MTD device yet. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com>
-
Miquel Raynal authored
Some driver (eg. docg4) will need to handle themselves the identification phase. As part of the migration to use nand_scan() everywhere (which will unconditionnaly call nand_scan_ident()), we add a condition at the start of nand_scan_with_ids() to jump over nand_scan_ident() if the maxchips parameters is zero, meaning that the driver does not want the core to handle this phase. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
No need for an atmel_nand_register() function, let's move the code in it directly where the function was called: in atmel_nand_controller_add_nand(). To make things consistent, also rename atmel_nand_unregister() into atmel_nand_controller_remove_nand(). Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Anders Roxell authored
JZ4780_NEMC doesn't depend on OF, and if OF isn't enabled we get this error: drivers/memory/jz4780-nemc.c: In function ‘jz4780_nemc_num_banks’: drivers/memory/jz4780-nemc.c:72:10: error: implicit declaration of function ‘of_read_number’; did you mean ‘down_read_nested’? [-Werror=implicit-function-declaration] bank = of_read_number(prop, 1); ^~~~~~~~~~~~~~ down_read_nested Make JZ4780_NEMC depend on OF. Fixes: ab99e110 ("memory: jz4780-nemc: Allow selection of this driver when COMPILE_TEST=y") Reported-by:Randy Dunlap <rdunlap@infradead.org> Signed-off-by:
Anders Roxell <anders.roxell@linaro.org> Acked-by:
Randy Dunlap <rdunlap@infradead.org> Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com>
-
Arnd Bergmann authored
Some drivers need these for compile-testing. On most architectures they come from asm-generic/io.h, but not on sparc64, which has its own definitions. Since we already have ioread*_rep()/iowrite*_rep() that have the same behavior on sparc64 (i.e. all PCI I/O space is memory mapped), we can rename the existing helpers and add macros to define them to the same implementation. Signed-off-by:
Arnd Bergmann <arnd@arndb.de> Acked-by:
David S. Miller <davem@davemloft.net> Tested-by:
Boris Brezillon <boris.brezillon@bootlin> Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com>
-
Arnd Bergmann authored
asm-generic/io.h provides a generic implementation of all I/O accessors, which the architectures can override. Since ia64 does not provide readsl/writesl etc, any driver using those fails to build, and including asm-generic/io.h will provide the missing interfaces, as well as any other future interfaces that get added there. We need to #define a couple of symbols to themselves in the ia64 to ensure that we use the ia64 specific version of those rather than the generic one. There should be no other effect than adding {read,write}s{b,w,l}() as well as {in,out}s{b,w,l}_p(), which were also not provided by ia64 but are provided by the generic header for historic reasons. Signed-off-by:Arnd Bergmann <arnd@arndb.de> Tested-by:
Boris Brezillon <boris.brezillon@bootlin.com> Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan_with_ids() (alternative to nand_scan() for passing a flash IDs table) instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
nand_cleanup() should be called upon error after a successful nand_scan_tail(). Rework the error path to follow this rule . Signed-off-by:Miquel Raynal <miquel.raynal@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Reviewed-by:
Stefan Agner <stefan@agner.ch>
-
Miquel Raynal authored
As already done in the core, calling a struct nand_controller 'hw_control' is misleading. Use the same name as in nand_base.c: 'controller'. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Acked-by:
Xiaolei Li <xiaolei.li@mediatek.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Acked-by:
Harvey Hunt <harveyhuntnexus@gmail.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Notes: "pw 947037"
-
Miquel Raynal authored
Return -ENOTSUPP instead of -1 from ->chip_init_tail() before migrating this driver to use nand_scan() and transform this function to be a callback run by the core. Signed-off-by:Miquel Raynal <miquel.raynal@bootlin.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com> Acked-by:
Masahiro Yamada <yamada.masahiro@socionext.com>
-
Miquel Raynal authored
Two helpers have been added to the core to do all kind of controller side configuration/initialization between the detection phase and the final NAND scan. Implement these hooks so that we can convert the driver to just use nand_scan() instead of the nand_scan_ident() + nand_scan_tail() pair. Also change the unused "struct device *dev" parameter of the driver structure into a platform device to reuse it in the ->attach_chip() hook. Signed-off-by:
Miquel Raynal <miquel.raynal@bootlin.com> Reviewed-by:
Boris Brezillon <boris.brezillon@bootlin.com>
-