From: Shubhrajyoti D Date: Mon, 27 Feb 2012 13:59:05 +0000 (+0530) Subject: spi: Trivial warning fix X-Git-Tag: v3.4-rc1~170^2~23 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8f53602be555e500cfcd957955bb40fac19f2a6b;p=platform%2Fkernel%2Flinux-stable.git spi: Trivial warning fix The loop count i traverses for ntrans which is unsigned so make the loop count i also unsigned. Fix the below warning In file included from drivers/spi/spi-omap2-mcspi.c:38: include/linux/spi/spi.h: In function 'spi_message_alloc': include/linux/spi/spi.h:556: warning: comparison between signed and unsigned integer expressions Cc: Vitaly Wool Signed-off-by: Shubhrajyoti D Signed-off-by: Grant Likely --- diff --git a/include/linux/spi/spi.h b/include/linux/spi/spi.h index f9e30a5..98679b0 100644 --- a/include/linux/spi/spi.h +++ b/include/linux/spi/spi.h @@ -600,7 +600,7 @@ static inline struct spi_message *spi_message_alloc(unsigned ntrans, gfp_t flags + ntrans * sizeof(struct spi_transfer), flags); if (m) { - int i; + unsigned i; struct spi_transfer *t = (struct spi_transfer *)(m + 1); INIT_LIST_HEAD(&m->transfers);