All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shobhit Kumar <shobhit.kumar@intel.com>
To: intel-gfx <intel-gfx@lists.freedesktop.org>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Subject: [PATCH] drm/i915: Code cleanup patch to fix checkpatch errors
Date: Tue, 15 Apr 2014 13:54:07 +0530	[thread overview]
Message-ID: <1397550247-15574-1-git-send-email-shobhit.kumar@intel.com> (raw)
In-Reply-To: <20140414075927.GA1023@phenom.ffwll.local>

This cleans up the checkpatch errors for the merged commit -

commit d3b542fcfc72d7724585e3fd2c5e75351bc3df47
Author: Shobhit Kumar <shobhit.kumar@intel.com>
Date:   Mon Apr 14 11:00:34 2014 +0530

    drm/i915: Add parsing support for new MIPI blocks in VBT

Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com>
---
 drivers/gpu/drm/i915/intel_bios.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c
index 917f5bb..fba9efd 100644
--- a/drivers/gpu/drm/i915/intel_bios.c
+++ b/drivers/gpu/drm/i915/intel_bios.c
@@ -653,13 +653,15 @@ static u8 *goto_next_sequence(u8 *data, int *size)
 			 * skip by this element payload size
 			 * skip elem id, command flag and data type
 			 */
-			if ((tmp = tmp - 5) < 0)
+			tmp -= 5;
+			if (tmp < 0)
 				return NULL;
 
 			data += 3;
 			len = *((u16 *)data);
 
-			if ((tmp = tmp - len) < 0)
+			tmp -= len;
+			if (tmp < 0)
 				return NULL;
 
 			/* skip by len */
@@ -667,13 +669,15 @@ static u8 *goto_next_sequence(u8 *data, int *size)
 			break;
 		case MIPI_SEQ_ELEM_DELAY:
 			/* skip by elem id, and delay is 4 bytes */
-			if ((tmp = tmp - 5) < 0)
+			tmp -= 5;
+			if (tmp < 0)
 				return NULL;
 
 			data += 5;
 			break;
 		case MIPI_SEQ_ELEM_GPIO:
-			if ((tmp = tmp - 3) < 0)
+			tmp -= 3;
+			if (tmp < 0)
 				return NULL;
 
 			data += 3;
-- 
1.8.3.2

  parent reply	other threads:[~2014-04-15  8:24 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-20 11:16 [v2 0/2] Support for new MIPI Blocks in VBT Shobhit Kumar
2014-02-20 11:16 ` [v2 1/2] drm/i915: Update VBT data structures to have MIPI block enhancements Shobhit Kumar
2014-02-27 14:48   ` Jani Nikula
2014-02-28  5:25     ` Shobhit Kumar
2014-02-28  5:48   ` [PATCH] " Shobhit Kumar
2014-03-05 12:52     ` Daniel Vetter
2014-02-20 11:16 ` [v2 2/2] drm/i915: Add parsing support for new MIPI blocks in VBT Shobhit Kumar
2014-02-28 12:34   ` Jani Nikula
2014-04-14  5:30   ` [PATCH v3] " Shobhit Kumar
2014-04-14  7:02     ` Daniel Vetter
2014-04-14  7:54       ` Kumar, Shobhit
2014-04-14  9:05         ` Daniel Vetter
2014-04-14  9:55           ` Kumar, Shobhit
2014-04-15  8:24           ` Shobhit Kumar [this message]
2014-04-15 19:46             ` [PATCH] drm/i915: Code cleanup patch to fix checkpatch errors Daniel Vetter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1397550247-15574-1-git-send-email-shobhit.kumar@intel.com \
    --to=shobhit.kumar@intel.com \
    --cc=daniel.vetter@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.