From: Rasmus Villemoes <linux@rasmusvillemoes.dk> To: Daniel Vetter <daniel.vetter@intel.com>, Jani Nikula <jani.nikula@linux.intel.com>, David Airlie <airlied@linux.ie> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk>, intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/5] drm/i915: fix error path in intel_setup_gmbus() Date: Tue, 9 Feb 2016 21:11:13 +0100 [thread overview] Message-ID: <1455048677-19882-3-git-send-email-linux@rasmusvillemoes.dk> (raw) In-Reply-To: <1455048677-19882-1-git-send-email-linux@rasmusvillemoes.dk> This fails to undo the setup for pin==0; moreover, something interesting happens if the setup failed already at pin==0. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> --- drivers/gpu/drm/i915/intel_i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/intel_i2c.c b/drivers/gpu/drm/i915/intel_i2c.c index 25254b5c1ac5..deb8282c26d8 100644 --- a/drivers/gpu/drm/i915/intel_i2c.c +++ b/drivers/gpu/drm/i915/intel_i2c.c @@ -683,7 +683,7 @@ int intel_setup_gmbus(struct drm_device *dev) return 0; err: - while (--pin) { + while (pin--) { if (!intel_gmbus_is_valid_pin(dev_priv, pin)) continue; -- 2.1.4
WARNING: multiple messages have this Message-ID (diff)
From: Rasmus Villemoes <linux@rasmusvillemoes.dk> To: Daniel Vetter <daniel.vetter@intel.com>, Jani Nikula <jani.nikula@linux.intel.com>, David Airlie <airlied@linux.ie> Cc: intel-gfx@lists.freedesktop.org, Rasmus Villemoes <linux@rasmusvillemoes.dk>, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 2/5] drm/i915: fix error path in intel_setup_gmbus() Date: Tue, 9 Feb 2016 21:11:13 +0100 [thread overview] Message-ID: <1455048677-19882-3-git-send-email-linux@rasmusvillemoes.dk> (raw) In-Reply-To: <1455048677-19882-1-git-send-email-linux@rasmusvillemoes.dk> This fails to undo the setup for pin==0; moreover, something interesting happens if the setup failed already at pin==0. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> --- drivers/gpu/drm/i915/intel_i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/intel_i2c.c b/drivers/gpu/drm/i915/intel_i2c.c index 25254b5c1ac5..deb8282c26d8 100644 --- a/drivers/gpu/drm/i915/intel_i2c.c +++ b/drivers/gpu/drm/i915/intel_i2c.c @@ -683,7 +683,7 @@ int intel_setup_gmbus(struct drm_device *dev) return 0; err: - while (--pin) { + while (pin--) { if (!intel_gmbus_is_valid_pin(dev_priv, pin)) continue; -- 2.1.4 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-02-09 20:11 UTC|newest] Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-02-09 20:11 [PATCH 0/5] pre-decrement in error paths considered harmful Rasmus Villemoes 2016-02-09 20:11 ` Rasmus Villemoes 2016-02-09 20:11 ` [PATCH 1/5] drm/gma500: fix error path in gma_intel_setup_gmbus() Rasmus Villemoes 2016-02-10 6:41 ` Andy Shevchenko 2016-02-10 6:41 ` Andy Shevchenko 2016-02-10 7:26 ` Daniel Vetter 2016-02-10 7:26 ` Daniel Vetter 2016-02-09 20:11 ` Rasmus Villemoes [this message] 2016-02-09 20:11 ` [PATCH 2/5] drm/i915: fix error path in intel_setup_gmbus() Rasmus Villemoes 2016-02-09 20:27 ` Jani Nikula 2016-02-09 20:27 ` Jani Nikula 2016-02-10 8:56 ` Jani Nikula 2016-02-10 8:56 ` Jani Nikula 2016-02-09 20:11 ` [PATCH 3/5] net/mlx4: fix some error handling in mlx4_multi_func_init() Rasmus Villemoes 2016-02-10 9:40 ` Yishai Hadas 2016-02-10 18:15 ` Rasmus Villemoes 2016-02-10 18:15 ` Rasmus Villemoes 2016-02-11 9:29 ` Jack Morgenstein 2016-02-11 9:29 ` Jack Morgenstein 2016-02-11 10:20 ` Jack Morgenstein 2016-02-11 16:02 ` Doug Ledford 2016-02-09 20:11 ` [PATCH 4/5] net: sxgbe: fix error paths in sxgbe_platform_probe() Rasmus Villemoes 2016-03-08 20:44 ` Rasmus Villemoes 2016-03-22 19:47 ` Rasmus Villemoes 2016-03-26 21:24 ` [PATCH] " Rasmus Villemoes 2016-03-27 8:22 ` Francois Romieu 2016-03-27 21:40 ` Rasmus Villemoes 2016-03-28 2:39 ` David Miller 2016-03-28 2:40 ` David Miller 2016-02-09 20:11 ` [PATCH 5/5] mm/backing-dev.c: fix error path in wb_init() Rasmus Villemoes 2016-02-09 20:11 ` Rasmus Villemoes
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=1455048677-19882-3-git-send-email-linux@rasmusvillemoes.dk \ --to=linux@rasmusvillemoes.dk \ --cc=airlied@linux.ie \ --cc=daniel.vetter@intel.com \ --cc=dri-devel@lists.freedesktop.org \ --cc=intel-gfx@lists.freedesktop.org \ --cc=jani.nikula@linux.intel.com \ --cc=linux-kernel@vger.kernel.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: linkBe 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.