dm: sf: Add a uclass for SPI flash
authorSimon Glass <sjg@chromium.org>
Tue, 14 Oct 2014 05:42:06 +0000 (23:42 -0600)
committerSimon Glass <sjg@chromium.org>
Wed, 22 Oct 2014 16:36:50 +0000 (10:36 -0600)
commit4c2dbefde58917205af51a2c20b3069e01e55cf4
treee144692e3657ecd26f77c19dab4f90312b75d3e1
parentae242cbfd0fc2b9e791688b3d9d6a19900ff3d31
dm: sf: Add a uclass for SPI flash

Add a driver model uclass for SPI flash which supports the common
operations (read, write, erase). Since we must keep support for the
non-dm interface, some modification of the spi_flash header is required.

CONFIG_DM_SPI_FLASH is used to enable driver model for SPI flash.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>
drivers/mtd/spi/Makefile
drivers/mtd/spi/sf-uclass.c [new file with mode: 0644]
include/dm/uclass-id.h
include/spi_flash.h