From patchwork Wed Feb 7 02:15:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?U2hhd24gU3VuZyAo5a6L5a2d6KyZKQ==?= X-Patchwork-Id: 20032 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:168b:b0:106:860b:bbdd with SMTP id ma11csp1950824dyb; Tue, 6 Feb 2024 18:15:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IHZVLVbnpE5wiRlxY4eLNbPL0nXdyxRCDXYckc8iwqUz9MYXIUiGWeSYCQAf3og9u6npkiH X-Received: by 2002:aa7:c991:0:b0:55f:adc6:47e8 with SMTP id c17-20020aa7c991000000b0055fadc647e8mr3285225edt.7.1707272146078; Tue, 06 Feb 2024 18:15:46 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707272146; cv=pass; d=google.com; s=arc-20160816; b=Mi0eO/wugfyZ12rdjmwsVLUL2/nctaJvkKTIGGcvjSC/RCY4RUGFmZr/9XUk30tjPY KFTAMcM4LqN86AhCZ2GBcr0mPNzASBYqEdFzlzd25pp7+WTnaSN3HcAoUYjrudlgP53Q 80HbY08ZWRdUSZYAmBdZfApayA3S1lwhlwVwo51Qb8WaHUb7hcq2txFKUHHVS4G6vbqX zj0AuQKbr01AC2d5nmlVaJ1Ire5HIvEPTmELhcSKoefBc8SLLgmOgSTNsNVDwkyvAecF MkrZUmSWTPhKdTA0T8vC8f9GilkHYrUnBWuw5b0yX8UWDiPLiUl9rhl0Kj59XYcewWyU zXsw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:date:subject:cc:to:from:dkim-signature; bh=/9iu+hMwKPmAX48lO9etKmHZlNn7fbipD6oy4YQb2Tg=; fh=u50XktPHSZ4GqQ4vltghJKK42ax35GdF3aBqr4Y49Wg=; b=QcAwntHKLBuuDQRNUQvv3c0wkvJZgLJwIV5pcypx91ircPTLCmdye+ckFSyYPeHaXf vQvT5HIWPAUWxKZK+v2Vt8TrAq2nwO0YDbxIhSTB8NjGS6BjNGFKqZbqBaVmU9Hz0lE0 ogP1pPKD0iHeQADcrdRveH2ZURouMb1YbkrlLBAy0S4YkxDnbjuxVIFb8JbVPitEiWSW +wrAGgE54f3qPJdJ+mWDOckBgd5CJSMFt/oRpexmuSpfmxep8SKTDwU0tG6rft7tza01 tWcX2kAkIRlPDBI7YrudyAhsXKdCbej7bnxyonL3hbjRXL/TOxaG2PEvasOQP6BKpwMh b59Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=HcW7hEqG; arc=pass (i=1 spf=pass spfdomain=mediatek.com dkim=pass dkdomain=mediatek.com dmarc=pass fromdomain=mediatek.com); spf=pass (google.com: domain of linux-kernel+bounces-55841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55841-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com X-Forwarded-Encrypted: i=2; AJvYcCUS1BRoGvyHAXFp8A1fXEwAjxerIzJsBENMUYjS+O3JLFuYFynrJVpxefWYUGGehd4Da3EUSzJoLE+eYyLAgzqi/V2tow== Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id t25-20020a508d59000000b00560c88891d9si202266edt.496.2024.02.06.18.15.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Feb 2024 18:15:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-55841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=HcW7hEqG; arc=pass (i=1 spf=pass spfdomain=mediatek.com dkim=pass dkdomain=mediatek.com dmarc=pass fromdomain=mediatek.com); spf=pass (google.com: domain of linux-kernel+bounces-55841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-55841-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com 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 am.mirrors.kernel.org (Postfix) with ESMTPS id AE5921F24412 for ; Wed, 7 Feb 2024 02:15:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8FBD0FC01; Wed, 7 Feb 2024 02:15:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="HcW7hEqG" Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DA7FA8C05 for ; Wed, 7 Feb 2024 02:15:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=210.61.82.184 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707272120; cv=none; b=H+0l8KytmVaom/G9NN2NrEGVdOQ32av3VGNqLnEaQYEaK5KWHJ5ocKqSpNQXKJOXhi+xK93AU6bTOMc/Idk5OIwsRZ4tLHNG/GchVwxnv/yriA1mO1pMI2U9gmhU1NP85dIji6TtfmlF71zxV3DSEzh2kb+j0gHtRD+M4OidRxY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707272120; c=relaxed/simple; bh=ix1cmovieKIsQ+j80BYlxnrOuJfzq5bQLPl5KyFgSMU=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=AgGUUCOtgdiA98Bis2zQIxSAz8YRb3ps9AM+EXdMcaxAIQ+JVeYpoD9K2CcNWyEs5DQ7scsen7p5JyWjbj6GNqlFc2E0Yd973Krttb7ML0WURmU7m2nMkDidTjhGcxAuNNFUdJ5MjFtDdmvzSSDmnItneo2vYZ7ZPSFOc2sRGoI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com; spf=pass smtp.mailfrom=mediatek.com; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b=HcW7hEqG; arc=none smtp.client-ip=210.61.82.184 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=mediatek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mediatek.com X-UUID: ba85e336c55e11eea2298b7352fd921d-20240207 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=/9iu+hMwKPmAX48lO9etKmHZlNn7fbipD6oy4YQb2Tg=; b=HcW7hEqGBQufACMgjZNDoelGzZvYhcNUYpjsGV2WDbpTVKMtxLgdX4QjQaJ26GMAHkXE5lA0qPo6v1baMyIFCIuiSgZAfdEDpSS9WCQkq/n1ybbfwmVMlm0HysQ5rYJ8OkIYO7hIM3L7YD+IIuVV8VeI7BTDNCItfU5fNG+yRyc=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.37,REQID:025a4cb3-c75d-41d4-948c-041318ccf651,IP:0,U RL:25,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTION :release,TS:25 X-CID-META: VersionHash:6f543d0,CLOUDID:3bc43380-4f93-4875-95e7-8c66ea833d57,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:11|1,File:nil,RT:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0,LES :1,SPR:NO,DKR:0,DKP:0,BRR:0,BRE:0 X-CID-BVR: 0 X-CID-BAS: 0,_,0,_ X-CID-FACTOR: TF_CID_SPAM_ULN,TF_CID_SPAM_SNR X-UUID: ba85e336c55e11eea2298b7352fd921d-20240207 Received: from mtkmbs14n2.mediatek.inc [(172.21.101.76)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 520137397; Wed, 07 Feb 2024 10:15:14 +0800 Received: from mtkmbs11n1.mediatek.inc (172.21.101.185) by MTKMBS14N1.mediatek.inc (172.21.101.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 7 Feb 2024 10:15:12 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs11n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Wed, 7 Feb 2024 10:15:12 +0800 From: Hsiao Chien Sung To: Chun-Kuang Hu CC: Philipp Zabel , David Airlie , Daniel Vetter , Matthias Brugger , , , , , "Hsiao Chien Sung" Subject: [PATCH v2 0/1] Filter modes according to hardware capability Date: Wed, 7 Feb 2024 10:15:09 +0800 Message-ID: <20240207021510.24035-1-shawn.sung@mediatek.com> X-Mailer: git-send-email 2.18.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-TM-AS-Product-Ver: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-AS-Result: No-10--4.759200-8.000000 X-TMASE-MatchedRID: ATi5SS6xZln8rQJMqxBG8BlckvO1m+JccuFRT+prg4ZGL0g1nVmkYcDV CJRGn8Ul9thk9nbRgmWNpw2JbH/pLNm0JHSAKf2wA9lly13c/gFKPIx+MJF9o5soi2XrUn/J8m+ hzBStansUGm4zriL0oQtuKBGekqUpnH7sbImOEBSNLjMwRubhFIJLAWlgYBj9j6bYDnm5z3RGIG Ft1pWKyYS780tUCheZS3sQQCJQ7LTHajbg+Suzu1HfVNA9wjvktgZwSK5A7V1Jmt82E/eyBQGH0 CAFIQWsmb5gmylW+PbGS+seVPx64j6Qrn3xh/cy X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--4.759200-8.000000 X-TMASE-Version: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-SNTS-SMTP: 1498373DF5AC87AD7C57785CDAB8BEF926E2F60C2A869894C2EAB08A0702ACA22000:8 X-MTK: N X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790204597841166369 X-GMAIL-MSGID: 1790204597841166369 From: Hsiao Chien Sung This series is based on mediatek-drm-next branch of kernel/git/chunkuang.hu/linux.git. Changes in v2: - Refined the filtering formula - Add the .mode_valid hook to the hardware that causes the limitation Hsiao Chien Sung (1): drm/mediatek: Filter modes according to hardware capability drivers/gpu/drm/mediatek/mtk_disp_drv.h | 4 ++ drivers/gpu/drm/mediatek/mtk_disp_merge.c | 56 +++++++++++++++++++ .../gpu/drm/mediatek/mtk_disp_ovl_adaptor.c | 17 ++++++ drivers/gpu/drm/mediatek/mtk_drm_crtc.c | 17 ++++++ drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c | 1 + drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.h | 12 ++++ 6 files changed, 107 insertions(+) --- 2.18.0