devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mmc: sdhci-s3c: Use NULL instead of 0 for pointers
@ 2012-11-20  4:11 Tushar Behera
  0 siblings, 0 replies; only message in thread
From: Tushar Behera @ 2012-11-20  4:11 UTC (permalink / raw)
  To: linux-mmc, devicetree-discuss; +Cc: cjb, thomas.abraham, patches

The third argument for of_get_property() is a pointer, hence pass
NULL instead of 0.

Fixes following sparse warning.
drivers/mmc/host/sdhci-s3c.c:452:48: warning: Using plain integer as
NULL pointer
drivers/mmc/host/sdhci-s3c.c:457:52: warning: Using plain integer as
NULL pointer

Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
---
 drivers/mmc/host/sdhci-s3c.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mmc/host/sdhci-s3c.c b/drivers/mmc/host/sdhci-s3c.c
index a54dd5d..80b10f2 100644
--- a/drivers/mmc/host/sdhci-s3c.c
+++ b/drivers/mmc/host/sdhci-s3c.c
@@ -449,12 +449,12 @@ static int __devinit sdhci_s3c_parse_dt(struct device *dev,
 		return -ENOMEM;
 
 	/* get the card detection method */
-	if (of_get_property(node, "broken-cd", 0)) {
+	if (of_get_property(node, "broken-cd", NULL)) {
 		pdata->cd_type = S3C_SDHCI_CD_NONE;
 		goto setup_bus;
 	}
 
-	if (of_get_property(node, "non-removable", 0)) {
+	if (of_get_property(node, "non-removable", NULL)) {
 		pdata->cd_type = S3C_SDHCI_CD_PERMANENT;
 		goto setup_bus;
 	}
-- 
1.7.4.1


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-11-20  4:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-20  4:11 [PATCH] mmc: sdhci-s3c: Use NULL instead of 0 for pointers Tushar Behera

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).