linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/7] staging: media: Remove unnecessary typecast of c90 int constant
@ 2017-03-02 19:51 simran singhal
  2017-03-02 19:51 ` [PATCH 2/7] staging: media: Add blank line after a declaration simran singhal
                   ` (7 more replies)
  0 siblings, 8 replies; 11+ messages in thread
From: simran singhal @ 2017-03-02 19:51 UTC (permalink / raw)
  To: mchehab; +Cc: gregkh, linux-media, devel, linux-kernel, outreachy-kernel

This patch removes unnecessary typecast of c90 int constant.

WARNING: Unnecessary typecast of c90 int constant

Signed-off-by: simran singhal <singhalsimran0@gmail.com>
---
 drivers/staging/media/atomisp/i2c/gc2235.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/media/atomisp/i2c/gc2235.c b/drivers/staging/media/atomisp/i2c/gc2235.c
index 3dd5e7f..3f2b11ec 100644
--- a/drivers/staging/media/atomisp/i2c/gc2235.c
+++ b/drivers/staging/media/atomisp/i2c/gc2235.c
@@ -706,10 +706,10 @@ static int distance(struct gc2235_resolution *res, u32 w, u32 h)
 	h_ratio = ((res->height << 13) / h);
 	if (h_ratio == 0)
 		return -1;
-	match   = abs(((w_ratio << 13) / h_ratio) - ((int)8192));
+	match   = abs(((w_ratio << 13) / h_ratio) - 8192);
 
-	if ((w_ratio < (int)8192) || (h_ratio < (int)8192)  ||
-		(match > LARGEST_ALLOWED_RATIO_MISMATCH))
+	if ((w_ratio < 8192) || (h_ratio < 8192)  ||
+	    (match > LARGEST_ALLOWED_RATIO_MISMATCH))
 		return -1;
 
 	return w_ratio + h_ratio;
-- 
2.7.4

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

end of thread, other threads:[~2017-03-09 17:11 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-02 19:51 [PATCH 1/7] staging: media: Remove unnecessary typecast of c90 int constant simran singhal
2017-03-02 19:51 ` [PATCH 2/7] staging: media: Add blank line after a declaration simran singhal
2017-03-02 19:51 ` [PATCH 3/7] staging: media: Replace NULL with "!" simran singhal
2017-03-02 19:51 ` [PATCH 4/7] staging: media: Remove blank line before '}' and after '{' braces simran singhal
2017-03-02 19:52 ` [PATCH 5/7] staging: media: Remove multiple assignments simran singhal
2017-03-02 19:52 ` [PATCH 6/7] staging: media: Use x instead of x != NULL simran singhal
2017-03-02 19:52 ` [PATCH 7/7] staging: media: Do not use multiple blank lines simran singhal
2017-03-03 17:45 ` [PATCH 1/7] staging: media: Remove unnecessary typecast of c90 int constant Sakari Ailus
2017-03-03 18:23   ` SIMRAN SINGHAL
2017-03-03 18:37     ` [Outreachy kernel] " Julia Lawall
2017-03-09 16:45 ` Greg KH

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).