soc: at91: Add Atmel SFR SN (Serial Number) support
authorKamel Bouhara <kamel.bouhara@bootlin.com>
Fri, 4 Oct 2019 15:18:02 +0000 (17:18 +0200)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Thu, 7 Nov 2019 21:33:10 +0000 (22:33 +0100)
commitc3277f8ee8cdadf011b8390dfdb4c44ecfaa1a7a
tree46e1fe3f1fd1b38e26bda7f66240a71e32d24881
parent5db3fb404af55df9d0a26bd3314bc6cd3fe9f5d6
soc: at91: Add Atmel SFR SN (Serial Number) support

Add support to read SFR's read-only registers providing the SoC
Serial Numbers (SN0+SN1) to userspace.

~ #  hexdump -n 8  -e'"%d\n"' /sys/bus/nvmem/devices/atmel-sfr0/nvmem
959527243
371539274

Signed-off-by: Kamel Bouhara <kamel.bouhara@bootlin.com>
Tested-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Reviewed-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Link: https://lore.kernel.org/r/20191004151802.21793-1-kamel.bouhara@bootlin.com
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/soc/atmel/Kconfig
drivers/soc/atmel/Makefile
drivers/soc/atmel/sfr.c [new file with mode: 0644]