From patchwork Fri Oct 18 14:11:30 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marc-Andr=C3=A9_Lureau?= X-Patchwork-Id: 3068131 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 279F09F372 for ; Fri, 18 Oct 2013 14:54:58 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 09DDD2051C for ; Fri, 18 Oct 2013 14:54:57 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 680E72051A for ; Fri, 18 Oct 2013 14:54:52 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3F310E73A6 for ; Fri, 18 Oct 2013 07:54:52 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-ea0-f170.google.com (mail-ea0-f170.google.com [209.85.215.170]) by gabe.freedesktop.org (Postfix) with ESMTP id 9B4AAE612D for ; Fri, 18 Oct 2013 07:12:07 -0700 (PDT) Received: by mail-ea0-f170.google.com with SMTP id q10so1615771eaj.15 for ; Fri, 18 Oct 2013 07:12:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=Rx/j1ntI68Yh29AOaCohz2i43Xd2hz+nhw3NMwd6k6Q=; b=jNCm76q30U90bC6LHRoV7gFWSn7KB+H/W0pNcIPYNAFfCtddxaZONtMM3UsNmvbzLj 3TbQ2Ud2n4wz1KRGvPvS68i0SrFp6gRrQi3wpzkDk2vvQZ+963NtR68t2l1AkOEQQA7K Sx1zV+vRrJuac+OUHGM8PWQrpdW6/Wdex5Bh/Vek+/QnZCZ92y0LRBn3/79bNJfMzS7Y WYpcPjDWnR48bHWbrO1mbDqpsY97n4cs6JgA488O63V7F7ehtFvkPlxqm1jqkbih65Cm pzww+d+RIo+3R79ZqCBEeKP8NuuSM9HpmfT09C9oXSKCVdv1s0K5a8drxFnEpZarpfqE p+2Q== X-Received: by 10.15.45.8 with SMTP id a8mr4829052eew.1.1382105526672; Fri, 18 Oct 2013 07:12:06 -0700 (PDT) Received: from localhost (122.Red-83-45-5.dynamicIP.rima-tde.net. [83.45.5.122]) by mx.google.com with ESMTPSA id f49sm5003833eec.7.2013.10.18.07.12.04 for (version=TLSv1.2 cipher=AES128-GCM-SHA256 bits=128/128); Fri, 18 Oct 2013 07:12:05 -0700 (PDT) From: "=?UTF-8?q?Marc-Andr=C3=A9=20Lureau?=" To: dri-devel@lists.freedesktop.org Subject: [PATCH 4/7] drm: copy mode type in drm_mode_connector_list_update() Date: Fri, 18 Oct 2013 16:11:30 +0200 Message-Id: <1382105493-2152-4-git-send-email-marcandre.lureau@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1382105493-2152-1-git-send-email-marcandre.lureau@redhat.com> References: <1382105493-2152-1-git-send-email-marcandre.lureau@redhat.com> MIME-Version: 1.0 Cc: airlied@redhat.com, =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, 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 In commit 38d5487db7f289be1d56ac7df704ee49ed3213b9, Keith explained: This patch simply merges the two mode type bits together; that seems reasonable to me, but perhaps only a subset of the bits should be used? None of these can be user defined as they all come from looking at just the hardware. However, merging the bits means that a flag becomes sticky. It is not possible, for example to update the mode type to remove the DRM_MODE_TYPE_PREFERRED bit. After a brief discussion with Dave Airlie on irc, it was agreed to propose that change, instead of introducing another function to remove a bit from exisiting modes type. Signed-off-by: Marc-André Lureau --- drivers/gpu/drm/drm_modes.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c index a6729bf..a8dbaad 100644 --- a/drivers/gpu/drm/drm_modes.c +++ b/drivers/gpu/drm/drm_modes.c @@ -1072,7 +1072,7 @@ void drm_mode_connector_list_update(struct drm_connector *connector) /* if equal delete the probed mode */ mode->status = pmode->status; /* Merge type bits together */ - mode->type |= pmode->type; + mode->type = pmode->type; list_del(&pmode->head); drm_mode_destroy(connector->dev, pmode); break;