Reading from flash in kernel

Guennadi Liakhovetski gl at dsa-ac.de
Fri Sep 5 08:11:19 EDT 2003


Hello

I need to read data from a flash partition in kernel. At the moment I do

mtd = get_mtd_device(NULL, MTD_MINOR);
ret = MTD_READ(mtd, ppos, len, &retlen, kbuf);
put_mtd_device(mtd);

MTD_READ() returns 0, but nothing is copied to the buffer. Well, I would
guess I am doing it wrong, what's the right way?

Thanks
Guennadi
---------------------------------
Guennadi Liakhovetski, Ph.D.
DSA Daten- und Systemtechnik GmbH
Pascalstr. 28
D-52076 Aachen
Germany



More information about the linux-mtd mailing list