linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ben Widawsky <ben@bwidawsk.net>
To: Yufeng Shen <miletus@chromium.org>
Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
	Eugeni Dodonov <eugeni.dodonov@intel.com>
Subject: Re: [PATCH] [PATCH] drm/i915: Fix race condition in accessing GMBUS
Date: Mon, 13 Feb 2012 10:04:41 +0100	[thread overview]
Message-ID: <20120213090440.GA11414@seagal.ffwll.local> (raw)
In-Reply-To: <1328896201-20909-1-git-send-email-miletus@chromium.org>

On Fri, Feb 10, 2012 at 12:50:01PM -0500, Yufeng Shen wrote:
> GMBUS has several ports and each has it's own corresponding
> I2C adpater. When multiple I2C adapters call gmbus_xfer() at
> the same time there is a race condition in using the underlying
> GMBUS controller. Fixing this by adding a mutex lock when calling
> gmbus_xfer().
> 
> Signed-off-by: Yufeng Shen <miletus@chromium.org>

I do not see the race. All the i2c transfers should be protected
correctly by the i2c core, or else I think we haven't registered our
device properly. Could you give an example of when/how this can happen?

Ben

  reply	other threads:[~2012-02-13  9:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-09 22:14 [PATCH] drm/i915: Fix race condition in accessing GMBUS Yufeng Shen
2012-02-10 17:17 ` Daniel Vetter
2012-02-10 17:50 ` [PATCH] " Yufeng Shen
2012-02-13  9:04   ` Ben Widawsky [this message]
2012-02-13 21:38     ` Yufeng Shen
2012-02-13 20:31   ` Daniel Vetter
2012-02-13 22:35 ` y
2012-02-13 22:36 ` Yufeng Shen
2012-02-14  9:47   ` 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=20120213090440.GA11414@seagal.ffwll.local \
    --to=ben@bwidawsk.net \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=eugeni.dodonov@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miletus@chromium.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 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).