rtc: m48t59: clean up m48t59_nvram_read()/m48t59_nvram_write()

The change removes redundant sysfs binary file boundary checks, since
this task is already done on caller side in fs/sysfs/file.c

Spinlock acquisition/release is moved out of the loop body to get
atomic states of NVRAM reading and writing operations.

Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
1 file changed