linux/drivers/mmc/core
Anton Vorontsov 08f80bb519 mmc: change .get_ro() callback semantics
Now get_ro() callback must return 0/1 values for its logical states, and
negative errno values in case of error. If particular host instance doesn't
support RO/WP switch, it should return -ENOSYS.

This patch changes some hosts in two ways:

1. Now functions should be smart to not return negative values in
   "RO asserted" case (particularly gpio_ calls could return negative
   values for the outermost GPIOs).

   Also, board code usually passes get_ro() callbacks that directly return
   gpioreg & bit result, so at91_mci, imxmmc, pxamci and mmc_spi's get_ro()
   handlers need take special care when returning platform's values to the
   mmc core.

2. In case of host instance didn't implement get_ro() callback, it should
   really return -ENOSYS and let the mmc core decide what to do about it
   (mmc core thinks the same way as the hosts, so it isn't functional
   change).

Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2008-07-15 14:14:41 +02:00
..
Kconfig mmc: Use menuconfig objects 2007-05-08 22:41:55 +02:00
Makefile mmc: use sysfs groups to handle conditional attributes 2008-03-22 17:02:20 -07:00
bus.c mmc: use sysfs groups to handle conditional attributes 2008-03-22 17:02:20 -07:00
bus.h mmc: use sysfs groups to handle conditional attributes 2008-03-22 17:02:20 -07:00
core.c mmc: add support for card-detection polling 2008-07-15 14:14:41 +02:00
core.h mmc: proper prototypes for mmc_attach_*() 2008-04-18 20:05:32 +02:00
host.c mmc: set controller name early 2008-04-18 20:05:26 +02:00
host.h mmc: refactor host class handling 2007-07-09 21:28:01 +02:00
mmc.c mmc: use sysfs groups to handle conditional attributes 2008-03-22 17:02:20 -07:00
mmc_ops.c cleanup asm/scatterlist.h includes 2007-11-02 08:47:06 +01:00
mmc_ops.h MMC core learns about SPI 2007-09-23 21:51:30 +02:00
sd.c mmc: change .get_ro() callback semantics 2008-07-15 14:14:41 +02:00
sd_ops.c cleanup asm/scatterlist.h includes 2007-11-02 08:47:06 +01:00
sd_ops.h drivers/mmc/core/: make 3 functions static 2007-07-26 02:05:57 +02:00
sdio.c mmc: use sysfs groups to handle conditional attributes 2008-03-22 17:02:20 -07:00
sdio_bus.c uevent environment changes fallout 2007-10-14 08:53:33 -07:00
sdio_bus.h mmc: basic SDIO device model 2007-09-23 19:45:31 +02:00
sdio_cis.c sdio: store vendor strings 2007-09-23 21:28:01 +02:00
sdio_cis.h sdio: split up common and function CIS parsing 2007-09-23 20:44:22 +02:00
sdio_io.c sdio: add sdio_f0_readb() and sdio_f0_writeb() 2007-09-23 21:24:27 +02:00
sdio_irq.c mmc: use shorter, equivalent set_current_state() 2008-04-18 20:05:27 +02:00
sdio_ops.c mmc: sdio_ops.c should #include "sdio_ops.h" 2008-04-18 20:05:33 +02:00
sdio_ops.h sdio: extend sdio_readsb() and friends to handle any length of buffer 2007-09-23 21:21:32 +02:00