[PATCH] mtd: phram: error handling

From: Saurabh Sengar
Date: Thu Nov 12 2015 - 01:24:07 EST



> More importantly, it's good to test these cases too:

> * phram is built-in (not a module), with and without a phram= line on
> the commandline
> * writing to /sys/module/phram/parameters/phram (for both the module
> and built-in cases)

Hi Brian,

1) I have tried phram as built-in, with and without phram= line in cmdline
but both the time there was no phram directory found in /sys/modules, neither /dev/mtd0
(do I need to enablesome config options ?)

2) There was no 'parameters' directory inside /sys/module/phram when I used phram as module,
though /dev/mtd0 and /dev/mtd0ro were present


I tried searching phram in kernel/Documentation but couldn't found anything.
I have few queries related to phram driver, please answer if your time permits.
(Feel free to ignore if I am taking too much your time, I know these are too many :) )

Q1) Phram driver is used for accessing memory which are there but not currently mapped in system? am I correct?

Q2) When I register device with junk names like phram=saurabh,0x1f7000000,0x400, it registers fine with name 'saurabh', isn't it wrong ?

Q3) If I access some memory which does not even exist, driver still registers and even read operation is successfull to it.
eg: phram=ram,8Gi,1ki (My laptop have 4GB ram but accessing 8GB address of ram)


Regards,
Saurabh

-------------------------------------------
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/