Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8a0ca91e authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc: (68 commits)
  sdio_uart: Fix SDIO break control to now return success or an error
  mmc: host driver for Ricoh Bay1Controllers
  sdio: sdio_io.c Fix sparse warnings
  sdio: fix the use of hard coded timeout value.
  mmc: OLPC: update vdd/powerup quirk comment
  mmc: fix spares errors of sdhci.c
  mmc: remove multiwrite capability
  wbsd: fix bad dma_addr_t conversion
  atmel-mci: Driver for Atmel on-chip MMC controllers
  mmc: fix sdio_io sparse errors
  mmc: wbsd.c fix shadowing of 'dma' variable
  MMC: S3C24XX: Refuse incorrectly aligned transfers
  MMC: S3C24XX: Add maintainer entry
  MMC: S3C24XX: Update error debugging.
  MMC: S3C24XX: Add media presence test to request handling.
  MMC: S3C24XX: Fix use of msecs where jiffies are needed
  MMC: S3C24XX: Add MODULE_ALIAS() entries for the platform devices
  MMC: S3C24XX: Fix s3c2410_dma_request() return code check.
  MMC: S3C24XX: Allow card-detect on non-IRQ capable pin
  MMC: S3C24XX: Ensure host->mrq->data is valid
  ...

Manually fixed up bogus executable bits on drivers/mmc/core/sdio_io.c
and include/linux/mmc/sdio_func.h when merging.
parents 9c1be0c4 c43d8636
Loading
Loading
Loading
Loading
+16 −1
Original line number Diff line number Diff line
@@ -348,7 +348,9 @@ W: http://www.linux-usb.org/SpeedTouch/
S:	Maintained

ALCHEMY AU1XX0 MMC DRIVER
S:	Orphan
P:	Manuel Lauss
M:	manuel.lauss@gmail.com
S:	Maintained

ALI1563 I2C DRIVER
P:	Rudolf Marek
@@ -3559,6 +3561,13 @@ L: linux-s390@vger.kernel.org
W:	http://www.ibm.com/developerworks/linux/linux390/
S:	Supported

S3C24XX SD/MMC Driver
P:	Ben Dooks
M:	ben-linux@fluff.org
L:	linux-arm-kernel@lists.arm.linux.org.uk (subscribers-only)
L:	linux-kernel@vger.kernel.org
S:	Supported

SAA7146 VIDEO4LINUX-2 DRIVER
P:	Michael Hunold
M:	michael@mihu.de
@@ -3631,6 +3640,12 @@ P: Jim Cromie
M:	jim.cromie@gmail.com
S:	Maintained

SDRICOH_CS MMC/SD HOST CONTROLLER INTERFACE DRIVER
P:	Sascha Sommer
M:	saschasommer@freenet.de
L:	sdricohcs-devel@lists.sourceforge.net (subscribers-only)
S:	Maintained

SECURITY CONTACT
P:	Security Officers
M:	security@kernel.org
+7 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@
#include <linux/leds.h>
#include <linux/spi/spi.h>

#include <asm/atmel-mci.h>
#include <asm/io.h>
#include <asm/setup.h>

@@ -51,6 +52,11 @@ static struct spi_board_info spi0_board_info[] __initdata = {
	},
};

static struct mci_platform_data __initdata mci0_data = {
	.detect_pin	= GPIO_PIN_PC(25),
	.wp_pin		= GPIO_PIN_PE(0),
};

/*
 * The next two functions should go away as the boot loader is
 * supposed to initialize the macb address registers with a valid
@@ -170,6 +176,7 @@ static int __init atngw100_init(void)
	set_hw_addr(at32_add_device_eth(1, &eth_data[1]));

	at32_add_device_spi(0, spi0_board_info, ARRAY_SIZE(spi0_board_info));
	at32_add_device_mci(0, &mci0_data);
	at32_add_device_usba(0, NULL);

	for (i = 0; i < ARRAY_SIZE(ngw_leds); i++) {
+3 −0
Original line number Diff line number Diff line
@@ -234,6 +234,9 @@ static int __init atstk1002_init(void)
#ifdef CONFIG_BOARD_ATSTK100X_SPI1
	at32_add_device_spi(1, spi1_board_info, ARRAY_SIZE(spi1_board_info));
#endif
#ifndef CONFIG_BOARD_ATSTK1002_SW2_CUSTOM
	at32_add_device_mci(0, NULL);
#endif
#ifdef CONFIG_BOARD_ATSTK1002_SW5_CUSTOM
	set_hw_addr(at32_add_device_eth(1, &eth_data[1]));
#else
+25 −5
Original line number Diff line number Diff line
@@ -14,6 +14,7 @@
#include <linux/spi/spi.h>
#include <linux/usb/atmel_usba_udc.h>

#include <asm/atmel-mci.h>
#include <asm/io.h>
#include <asm/irq.h>

@@ -1278,20 +1279,32 @@ static struct clk atmel_mci0_pclk = {
	.index		= 9,
};

struct platform_device *__init at32_add_device_mci(unsigned int id)
struct platform_device *__init
at32_add_device_mci(unsigned int id, struct mci_platform_data *data)
{
	struct mci_platform_data	_data;
	struct platform_device		*pdev;
	struct dw_dma_slave		*dws;

	if (id != 0)
		return NULL;

	pdev = platform_device_alloc("atmel_mci", id);
	if (!pdev)
		return NULL;
		goto fail;

	if (platform_device_add_resources(pdev, atmel_mci0_resource,
				ARRAY_SIZE(atmel_mci0_resource)))
		goto err_add_resources;
		goto fail;

	if (!data) {
		data = &_data;
		memset(data, 0, sizeof(struct mci_platform_data));
	}

	if (platform_device_add_data(pdev, data,
				sizeof(struct mci_platform_data)))
		goto fail;

	select_peripheral(PA(10), PERIPH_A, 0);	/* CLK	 */
	select_peripheral(PA(11), PERIPH_A, 0);	/* CMD	 */
@@ -1300,12 +1313,19 @@ struct platform_device *__init at32_add_device_mci(unsigned int id)
	select_peripheral(PA(14), PERIPH_A, 0);	/* DATA2 */
	select_peripheral(PA(15), PERIPH_A, 0);	/* DATA3 */

	if (data) {
		if (data->detect_pin != GPIO_PIN_NONE)
			at32_select_gpio(data->detect_pin, 0);
		if (data->wp_pin != GPIO_PIN_NONE)
			at32_select_gpio(data->wp_pin, 0);
	}

	atmel_mci0_pclk.dev = &pdev->dev;

	platform_device_add(pdev);
	return pdev;

err_add_resources:
fail:
	platform_device_put(pdev);
	return NULL;
}
+28 −32
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@
 * Block driver for media (i.e., flash cards)
 *
 * Copyright 2002 Hewlett-Packard Company
 * Copyright 2005-2007 Pierre Ossman
 * Copyright 2005-2008 Pierre Ossman
 *
 * Use consistent with the GNU GPL is permitted,
 * provided that this copyright notice is
@@ -237,17 +237,6 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
		if (brq.data.blocks > card->host->max_blk_count)
			brq.data.blocks = card->host->max_blk_count;

		/*
		 * If the host doesn't support multiple block writes, force
		 * block writes to single block. SD cards are excepted from
		 * this rule as they support querying the number of
		 * successfully written sectors.
		 */
		if (rq_data_dir(req) != READ &&
		    !(card->host->caps & MMC_CAP_MULTIWRITE) &&
		    !mmc_card_sd(card))
			brq.data.blocks = 1;

		if (brq.data.blocks > 1) {
			/* SPI multiblock writes terminate using a special
			 * token, not a STOP_TRANSMISSION request.
@@ -296,22 +285,24 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)

		mmc_queue_bounce_post(mq);

		/*
		 * Check for errors here, but don't jump to cmd_err
		 * until later as we need to wait for the card to leave
		 * programming mode even when things go wrong.
		 */
		if (brq.cmd.error) {
			printk(KERN_ERR "%s: error %d sending read/write command\n",
			       req->rq_disk->disk_name, brq.cmd.error);
			goto cmd_err;
		}

		if (brq.data.error) {
			printk(KERN_ERR "%s: error %d transferring data\n",
			       req->rq_disk->disk_name, brq.data.error);
			goto cmd_err;
		}

		if (brq.stop.error) {
			printk(KERN_ERR "%s: error %d sending stop command\n",
			       req->rq_disk->disk_name, brq.stop.error);
			goto cmd_err;
		}

		if (!mmc_host_is_spi(card->host) && rq_data_dir(req) != READ) {
@@ -344,6 +335,9 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
#endif
		}

		if (brq.cmd.error || brq.data.error || brq.stop.error)
			goto cmd_err;

		/*
		 * A block was successfully transferred.
		 */
@@ -362,12 +356,14 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
 	 * mark the known good sectors as ok.
 	 *
	 * If the card is not SD, we can still ok written sectors
	 * if the controller can do proper error reporting.
	 * as reported by the controller (which might be less than
	 * the real number of written sectors, but never more).
	 *
	 * For reads we just fail the entire chunk as that should
	 * be safe in all cases.
	 */
 	if (rq_data_dir(req) != READ && mmc_card_sd(card)) {
	if (rq_data_dir(req) != READ) {
		if (mmc_card_sd(card)) {
			u32 blocks;
			unsigned int bytes;

@@ -381,12 +377,12 @@ static int mmc_blk_issue_rq(struct mmc_queue *mq, struct request *req)
				ret = __blk_end_request(req, 0, bytes);
				spin_unlock_irq(&md->lock);
			}
	} else if (rq_data_dir(req) != READ &&
		   (card->host->caps & MMC_CAP_MULTIWRITE)) {
		} else {
			spin_lock_irq(&md->lock);
			ret = __blk_end_request(req, 0, brq.data.bytes_xfered);
			spin_unlock_irq(&md->lock);
		}
	}

	mmc_release_host(card->host);

Loading