From patchwork Tue Feb 27 22:19:29 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 207475 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:a81b:b0:108:e6aa:91d0 with SMTP id bq27csp2996857dyb; Tue, 27 Feb 2024 14:20:06 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWXKoer/4RUt7OKwJjUJ8gLWlaivO/8ERxASH7cnolMVML3G11ibvbpSeV3WkCciAaY8QLisILD2Kfg5UItikq6g46MKQ== X-Google-Smtp-Source: AGHT+IHF95xf/SUvPO+vYyVCTAo53WoL6x8F0zGGomiV6Ax/r/lreOoy+v8kaljpPP2IBLHMPKfE X-Received: by 2002:a17:903:249:b0:1d7:5d88:f993 with SMTP id j9-20020a170903024900b001d75d88f993mr11885433plh.41.1709072406030; Tue, 27 Feb 2024 14:20:06 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709072406; cv=pass; d=google.com; s=arc-20160816; b=r+gNKEgOXjYB+1dPZ5jbsVnjRT7xoE3DF8sbK2w7afwJ5B0kzyuSnfa6cdzi/vkTAG XF7ns4RUtSEQIpWN8bGm74XwqyIBSSnkgHo6e4ds6jxvbBj23T7Wt1D/flhSYY/vBQCN Tvq2XVxdo7hmEcvWSTmAk69XoXZceQkmgjh8NMLKBJC5zt7/OBoeFYsJ+Bmvtt8XyRlc TjVKXmpCyZRj3TpDj+IH9Tii2QhwkZGMTmPKSptebqMxyYWAkj2E/aBlpdFt1dw4cRCp aGft9Nb9xTG1WA1YVf+B9sBI3gMg6nr+4D7zKhuKacDkphpLQCq5muUGNGIfiOF//uBi na2Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=siqoqedRmX2wPOUVHojbCwdAvexAbFGkcd6CPRaGDIY=; fh=IfprcZMLGQXeYiJivFyiG5xbUr1nTILaJGCUtAPFrTs=; b=rMgWj1o/fqDXr3Pn0pKzzWNWBfOPNDd3w0hkRVqljKEfLsgp4DG4MrsM1ml0AZQ310 hbQehcH1Mnl8UW8vO2NR2x2DRMHQoiepGa0EROdIL69oZn8hPTkdDfqHKXYrzXc5rC7/ hXma/UNO2gpGFR6pwqOvrV7cMdSBBisMKDs+c6LzOrQV3ObU7y+kzZ+sCzhTJNHaHhYK xjo51nOcVKLS3x4qNUPi+mn8NJaw5gDAiLdIrNCj1RInM0OXm1EY6suejZLBNSZeQeXo hLBjbU0tXzas448Y4Y461A82eOLmxDw4wJTM969oXTWWnzW4Ze9DQeSwmuE2n3E1/Ko8 5XQA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=FLpKLYHB; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-84119-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-84119-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q3-20020a170902eb8300b001dc07b60355si2079862plg.15.2024.02.27.14.20.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Feb 2024 14:20:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-84119-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=FLpKLYHB; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-84119-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-84119-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 55E2C284811 for ; Tue, 27 Feb 2024 22:20:05 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9B33A153BD1; Tue, 27 Feb 2024 22:19:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="FLpKLYHB" Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9C4D54CE17 for ; Tue, 27 Feb 2024 22:19:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.170 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709072394; cv=none; b=bAmlnUZem41wN6rxM2S0ooyRqXEg7BgrERpds/x2xYDOl4en0mmwn0Al81Sc/EGufu/pNFki44K3Uc8oNFkPQyVsmRr1DxC3W1zAYYDyQTr52qi+a0oN2sNyV6eAl3DTEUbEYr8lfz/Uf/pzsDlFGpfJFcz7q/ijAWKJBqvPNiw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709072394; c=relaxed/simple; bh=zz+unVt7q5p60XbIw7tQi7Q0UZeD5a+xqYylMLrjnu0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ak8nyWn7ejr88WlDOUheWCVkHqGDvk7YQyRZuvQkhYtYb1qnXQotJ8j8oFMjnjDkDPBCi6A57BzNK8ILcJcwKLUoLulZSBatcCmzXvFl/fPgBCLkkrv0bLHon9LVvAPiUGeI5sbKguQEJDn5i6XF2jF8c2RGWZoVvH7DQXwr4zk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=FLpKLYHB; arc=none smtp.client-ip=209.85.214.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Received: by mail-pl1-f170.google.com with SMTP id d9443c01a7336-1dc1e7c0e29so25475695ad.1 for ; Tue, 27 Feb 2024 14:19:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1709072392; x=1709677192; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=siqoqedRmX2wPOUVHojbCwdAvexAbFGkcd6CPRaGDIY=; b=FLpKLYHBsZ8q8icyQVUQQY93fWi7+xWrN7vFipf9htxpuiNTqYSJ/IcOe5vXoP/SXK S9MB7cJa/3n2QB2n7otH3XQ/TLL7k0lxQddrP5LIf9qt2ZXlLDP29v5lsPRn5jOaGZDR xrvkhrRtw/pYBeJK0hM02QtIKvnnPOoIPsADE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709072392; x=1709677192; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=siqoqedRmX2wPOUVHojbCwdAvexAbFGkcd6CPRaGDIY=; b=S2NQudM0/G4t6WMJvzWTF67tXIdKBXja8U1q7D/J93amEmivU9ufCPUR9bDW4XdjZW JD/CHY5fY1QSVywg4wE08G/QC/kzIxGPAScAKsL2TrnEEgMZ0KLTOSgC0URE2T/FOcEt og9D0nQmWAPae2qMRkMDpGetrcHvZ67HZSx+p9FMOXGSoEXkbLfs+++7oj6b7uYPDzMo X9aDm2TYFwK84wLYVStpW4Mbk1jGFFMP/sj4GBJJpQOZ85ngSnZu7ZleZlemO2ss62Uu LI9/5TBeF9/r1ljG8rM6vWMzgXIt/U7b0wsFHUP8LBmX0MrhaMec4dCqSHs8+0gWNyuT uKCg== X-Forwarded-Encrypted: i=1; AJvYcCUiRyU+RrS3i5tv9pY+8+82VcORBchOQ/egocsy4X9PW6SVze6rSmxJaeNeD/dR7YPQbIkdZfJmyTcd3sb6QvSzErulwF+TEzB6iUgI X-Gm-Message-State: AOJu0Yz+ltin+enYJwlj3oL4d/DborpUjj0jIOAdIuJnUftiEpvx0wd/ 66GRPqp6h3IiQqAobFAKRPExaD2YqWtsBAHPqiRlWLX2lV8m2/dmLb9pA24dFw== X-Received: by 2002:a17:902:dac6:b0:1dc:c445:b253 with SMTP id q6-20020a170902dac600b001dcc445b253mr1771550plx.36.1709072391882; Tue, 27 Feb 2024 14:19:51 -0800 (PST) Received: from dianders.sjc.corp.google.com ([2620:15c:9d:2:ff74:aba4:ea8d:f18e]) by smtp.gmail.com with ESMTPSA id f13-20020a170903104d00b001dc78455383sm2006780plc.223.2024.02.27.14.19.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Feb 2024 14:19:51 -0800 (PST) From: Douglas Anderson To: dri-devel@lists.freedesktop.org Cc: Rob Clark , Javier Martinez Canillas , Douglas Anderson , Daniel Vetter , Dave Airlie , David Airlie , Maarten Lankhorst , Maxime Ripard , =?utf-8?q?Ma=C3=ADra_Canal?= , Sean Paul , Thomas Zimmermann , =?utf-8?b?VmlsbGUgU3lyasOkbMOk?= , linux-kernel@vger.kernel.org Subject: [PATCH] drm/udl: Add ARGB8888 as a format Date: Tue, 27 Feb 2024 14:19:29 -0800 Message-ID: <20240227141928.1.I24ac8d51544e4624b7e9d438d95880c4283e611b@changeid> X-Mailer: git-send-email 2.44.0.rc1.240.g4c46232300-goog Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1792092306905115398 X-GMAIL-MSGID: 1792092306905115398 Even though the UDL driver converts to RGB565 internally (see pixel32_to_be16() in udl_transfer.c), it advertises XRGB8888 for compatibility. Let's add ARGB8888 to that list. This makes UDL devices work on ChromeOS again after commit c91acda3a380 ("drm/gem: Check for valid formats"). Prior to that commit things were "working" because we'd silently treat the ARGB8888 that ChromeOS wanted as XRGB8888. Fixes: c91acda3a380 ("drm/gem: Check for valid formats") Signed-off-by: Douglas Anderson Reviewed-by: Dmitry Baryshkov --- drivers/gpu/drm/udl/udl_modeset.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/udl/udl_modeset.c b/drivers/gpu/drm/udl/udl_modeset.c index 7702359c90c2..0f8d3678770e 100644 --- a/drivers/gpu/drm/udl/udl_modeset.c +++ b/drivers/gpu/drm/udl/udl_modeset.c @@ -253,6 +253,7 @@ static int udl_handle_damage(struct drm_framebuffer *fb, static const uint32_t udl_primary_plane_formats[] = { DRM_FORMAT_RGB565, DRM_FORMAT_XRGB8888, + DRM_FORMAT_ARGB8888, }; static const uint64_t udl_primary_plane_fmtmods[] = {