mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/2 V2] MMC: fix spares errors of sdhci.c
@ 2008-07-05 16:52 Tomas Winkler
  2008-07-05 16:52 ` [PATCH 2/2 V2] MMC: cleanup endianity conversions and style problems Tomas Winkler
  2008-07-05 23:30 ` [PATCH 1/2 V2] MMC: fix spares errors of sdhci.c Pierre Ossman
  0 siblings, 2 replies; 6+ messages in thread
From: Tomas Winkler @ 2008-07-05 16:52 UTC (permalink / raw)
  To: drzeus-list; +Cc: marcel, linux-kernel, Tomas Winkler

1. sdhci_prepare_data: fix shadowing of count variable
	u8 count
	int count -> sg_cnt;
2.  sdhci_add_host: assignment of integer to pointer
	dma_mask = 0 -> dma_mask = NULL;

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
 drivers/mmc/host/sdhci.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 2eabfac..59db3de 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -672,14 +672,14 @@ static void sdhci_prepare_data(struct sdhci_host *host, struct mmc_data *data)
 					host->ioaddr + SDHCI_ADMA_ADDRESS);
 			}
 		} else {
-			int count;
+			int sg_cnt;
 
-			count = dma_map_sg(mmc_dev(host->mmc),
+			sg_cnt = dma_map_sg(mmc_dev(host->mmc),
 					data->sg, data->sg_len,
 					(data->flags & MMC_DATA_READ) ?
 						DMA_FROM_DEVICE :
 						DMA_TO_DEVICE);
-			if (count == 0) {
+			if (sg_cnt == 0) {
 				/*
 				 * This only happens when someone fed
 				 * us an invalid request.
@@ -1583,7 +1583,7 @@ int sdhci_add_host(struct sdhci_host *host)
 
 	/* XXX: Hack to get MMC layer to avoid highmem */
 	if (!(host->flags & SDHCI_USE_DMA))
-		mmc_dev(host->mmc)->dma_mask = 0;
+		mmc_dev(host->mmc)->dma_mask = NULL;
 
 	host->max_clk =
 		(caps & SDHCI_CLOCK_BASE_MASK) >> SDHCI_CLOCK_BASE_SHIFT;
-- 
1.5.4.1

---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2008-07-06 18:13 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-05 16:52 [PATCH 1/2 V2] MMC: fix spares errors of sdhci.c Tomas Winkler
2008-07-05 16:52 ` [PATCH 2/2 V2] MMC: cleanup endianity conversions and style problems Tomas Winkler
2008-07-05 23:26   ` Pierre Ossman
2008-07-05 23:54     ` Winkler, Tomas
2008-07-06 18:13       ` Pierre Ossman
2008-07-05 23:30 ` [PATCH 1/2 V2] MMC: fix spares errors of sdhci.c Pierre Ossman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®