From patchwork Thu Jul 17 15:25:18 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sean Paul X-Patchwork-Id: 4576231 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9971A9F26C for ; Thu, 17 Jul 2014 15:26:20 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E01C6201C8 for ; Thu, 17 Jul 2014 15:26:18 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 6F7DF201CD for ; Thu, 17 Jul 2014 15:26:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8F1716E691; Thu, 17 Jul 2014 08:26:16 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-qa0-f43.google.com (mail-qa0-f43.google.com [209.85.216.43]) by gabe.freedesktop.org (Postfix) with ESMTP id 6B1D96E690 for ; Thu, 17 Jul 2014 08:26:15 -0700 (PDT) Received: by mail-qa0-f43.google.com with SMTP id w8so2003707qac.16 for ; Thu, 17 Jul 2014 08:26:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id; bh=Ubk3wtMLpe1ET4gN4m6aQ+365i6dxtH1XGdOZO0Jv6A=; b=Dnkqa46YzjLjaZQgKn6PSKAhvjxeo0NFNIgEX3tZnR/sOPWwcrOgSWk81YCcDA9VLc LDDkOnQFx+XNdXU+xtJ/kSj2CBhG0sv/qpTCT/DaCx5qLgFVvuxggaFg4VbplVOl8E79 uVJImcW/hZ4Wj3hYsfkQxOuRYERR6lmULyN6w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=Ubk3wtMLpe1ET4gN4m6aQ+365i6dxtH1XGdOZO0Jv6A=; b=fQvAvPeSiNnPj21Z91S8YWsRVF7qx2j1EYZ+Y55EUXq1JYGuwN4nTPWcrHw+QDwh/X jv4T8rB+i2HJ6eqw7G//PNpD9SiO0E7KvuYPYm3Y7OmXmaK5dk1mesJf+p7Js31P2jFm UqAiKbER7rwQWt8EvL4tcVQJgWYZVpzJkPA0xXcBlS7q+Lg/3Nw7HTJ8xhSVlefmwM7w u8p06oOXLM4KROmK12F6rlUGR3Vl1xjOLxYFMkA+3ne6ukLb6H3r3Pel+5pLFLZjM15Z hOPWRpV3/kQ2yGhHHVLwtqrpiHgpPImlK1r3tkyUicWrytMQiRx8wXEUyECLoxxssEiz 5vWg== X-Gm-Message-State: ALoCoQkYSBxZlugTZbCba2ePeCBVciXoi7uVK/05RBHxL2M2XBnn7DZrK/KVXQheiTguyzhQlqzN X-Received: by 10.224.42.196 with SMTP id t4mr56947883qae.48.1405610774946; Thu, 17 Jul 2014 08:26:14 -0700 (PDT) Received: from localhost.localdomain (cpe-173-095-180-236.nc.res.rr.com. [173.95.180.236]) by mx.google.com with ESMTPSA id a60sm3074648qge.30.2014.07.17.08.26.13 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 17 Jul 2014 08:26:13 -0700 (PDT) From: Sean Paul To: dri-devel@lists.freedesktop.org, daniel.vetter@ffwll.ch Subject: [PATCH] drm: Check for connection_mutex in drm_select_eld Date: Thu, 17 Jul 2014 11:25:18 -0400 Message-Id: <1405610718-7897-1-git-send-email-seanpaul@chromium.org> X-Mailer: git-send-email 2.0.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP drm_select_eld should check for mode_config.connection_mutex as well as mode_config.mutex Signed-off-by: Sean Paul --- drivers/gpu/drm/drm_edid.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/drm_edid.c b/drivers/gpu/drm/drm_edid.c index dfa9769..087d608 100644 --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c @@ -3305,6 +3305,7 @@ struct drm_connector *drm_select_eld(struct drm_encoder *encoder, struct drm_device *dev = encoder->dev; WARN_ON(!mutex_is_locked(&dev->mode_config.mutex)); + WARN_ON(!drm_modeset_is_locked(&dev->mode_config.connection_mutex)); list_for_each_entry(connector, &dev->mode_config.connector_list, head) if (connector->encoder == encoder && connector->eld[0])