From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 32BF9C7EE29 for ; Mon, 22 May 2023 01:19:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229994AbjEVBTz (ORCPT ); Sun, 21 May 2023 21:19:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42760 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229688AbjEVBTy (ORCPT ); Sun, 21 May 2023 21:19:54 -0400 Received: from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com [IPv6:2a00:1450:4864:20::22f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EBB6BDB for ; Sun, 21 May 2023 18:19:48 -0700 (PDT) Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2af1e290921so41789731fa.3 for ; Sun, 21 May 2023 18:19:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1684718387; x=1687310387; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=VQoC+SQvPKQcE2Jq1icKOeDMkY2wGwLUBK2zmb7MpPc=; b=Z5Kq2u0p0ju13oSnhQzioJ8S09uvVpvj+/++K3AAeNFz79Kdtelw1OFagnfM/gCtrx mrMEdDnu1riZ5Oja8P2xh0/EMdv4wmG93I2r6b+jJVVbQIsOs8uZ/Wq+cp0ztjXrGA6V q8T6rG2ZDV4yOT3TrI12K8kzDKtDW1amV4bf9/C162OlO4xXmukgS5X6vDGvRGYmW8TF KK8COO8yy5NnorJY38w1V5aDNFJcmgb92KxWJuOmtP0MXlkbbrIlQU72XHCZcIErvM2r ptzKXI7ED7o9VP1SFBlzV4cdQIOeaTgmXYIc+p3ArrKVcy6ku1LuvuJpU6fsMacYxv0Z Im6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684718387; x=1687310387; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=VQoC+SQvPKQcE2Jq1icKOeDMkY2wGwLUBK2zmb7MpPc=; b=dZbmLrmGfdafA90Sjk14m0UyL5CUe6q5QRJ0nAj4dlneucEDSzUXqIXIA8NKApfeG/ qWUcIFmxJm4Gc8N1AZ9xllN6S0ggWs0DQNDm+2aSmb8N+KPUvoa2I4P9I9YmmQDDNjyE 2qMgS0sAp8q+U52KhytgBwz090QQN+/HQyNSwmZdo1AGG0tGka6ZAzIOn9JsnEoBGotV +IuAZWVCnbuAH/SpihJJsmUkuWWAR2O9K+SOC71z5RCvNHx6+hiFGrUnJhuEJ70tH5G/ sisDSGN7WthWuQbwRILSBYoTELswTH6G8w5wjRWvVJAAqh9V3XEuWCN+aQIvcNKj/P5O yj/w== X-Gm-Message-State: AC+VfDzbvAF3qNTQhcSEapgZLMbPZS6CGVLZSLGl2zcX6KNJUHSvDxTB i4X9fMZG5oojuNII2ijeaFxK4w== X-Google-Smtp-Source: ACHHUZ4dZMB8OEoziZOinZ7PZDLRkevuuNY0g3JE0N+/ud26ft5s0bpXeoKenuwUHkX3Wa4Ho30TuQ== X-Received: by 2002:ac2:4c09:0:b0:4f2:74d3:8996 with SMTP id t9-20020ac24c09000000b004f274d38996mr3059673lfq.8.1684718387133; Sun, 21 May 2023 18:19:47 -0700 (PDT) Received: from ?IPV6:2001:14ba:a0db:1f00::8a5? (dzdqv0yyyyyyyyyyybcwt-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::8a5]) by smtp.gmail.com with ESMTPSA id u17-20020ac25191000000b004f13eca769esm782940lfi.82.2023.05.21.18.19.46 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 21 May 2023 18:19:46 -0700 (PDT) Message-ID: Date: Mon, 22 May 2023 04:19:45 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: [PATCH RFC 06/10] drm/panel/samsung-sofef01: Add panel driver for Sony Xperia 5 / 10 II Content-Language: en-GB To: Marijn Suijten , Neil Armstrong , Sam Ravnborg , David Airlie , Daniel Vetter , Caleb Connolly , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Andy Gross , Bjorn Andersson Cc: ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno , Konrad Dybcio , Martin Botka , Jami Kettunen , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, Abhinav Kumar , Kuogee Hsieh , Jessica Zhang References: <20230521-drm-panels-sony-v1-0-541c341d6bee@somainline.org> <20230521-drm-panels-sony-v1-6-541c341d6bee@somainline.org> From: Dmitry Baryshkov In-Reply-To: <20230521-drm-panels-sony-v1-6-541c341d6bee@somainline.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On 22/05/2023 00:23, Marijn Suijten wrote: > This SOFEF01-M Display-IC driver supports two modes with different > compatibles to differentiate between slightly different physical sizes > (panels) found on the Xperia 5 (6.1") and 10 II (6.0"). > > It is currently also used to hardcode significantly higher fake porches > for the Xperia 5, which are unused in transfers due to this being a > command-mode panel but do have an effect on the clock rates set by > dsi_host.c. Without higher clock rates this panel fails to achieve > 60fps and has significant tearing artifacts, while the same calculated > clock rate works perfectly fine on the Xperia 10 II. > > Signed-off-by: Marijn Suijten > --- > drivers/gpu/drm/panel/Kconfig | 12 + > drivers/gpu/drm/panel/Makefile | 1 + > drivers/gpu/drm/panel/panel-samsung-sofef01.c | 360 ++++++++++++++++++++++++++ > 3 files changed, 373 insertions(+) > > diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig > index 18bd116e78a71..3f11e9906f2cb 100644 > --- a/drivers/gpu/drm/panel/Kconfig > +++ b/drivers/gpu/drm/panel/Kconfig > @@ -618,6 +618,18 @@ config DRM_PANEL_SAMSUNG_SOFEF00 > > The panels are 2280x1080@60Hz and 2340x1080@60Hz respectively > > +config DRM_PANEL_SAMSUNG_SOFEF01 > + tristate "Samsung sofef01 Sony Xperia 5 / 10 II DSI cmd mode panels" > + depends on GPIOLIB > + depends on OF > + depends on DRM_MIPI_DSI > + depends on BACKLIGHT_CLASS_DEVICE > + help > + Say Y or M here if you want to enable support for the Samsung AMOLED > + command mode panels found in the Sony Xperia 5 / 10 II smartphones. > + > + This panel features a fixed mode of 1080x2520@60. > + > config DRM_PANEL_SEIKO_43WVF1G > tristate "Seiko 43WVF1G panel" > depends on OF > diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile > index 85133f73558f3..a4039d0fc9cfb 100644 > --- a/drivers/gpu/drm/panel/Makefile > +++ b/drivers/gpu/drm/panel/Makefile > @@ -62,6 +62,7 @@ obj-$(CONFIG_DRM_PANEL_SAMSUNG_S6E63M0_DSI) += panel-samsung-s6e63m0-dsi.o > obj-$(CONFIG_DRM_PANEL_SAMSUNG_S6E88A0_AMS452EF01) += panel-samsung-s6e88a0-ams452ef01.o > obj-$(CONFIG_DRM_PANEL_SAMSUNG_S6E8AA0) += panel-samsung-s6e8aa0.o > obj-$(CONFIG_DRM_PANEL_SAMSUNG_SOFEF00) += panel-samsung-sofef00.o > +obj-$(CONFIG_DRM_PANEL_SAMSUNG_SOFEF01) += panel-samsung-sofef01.o > obj-$(CONFIG_DRM_PANEL_SEIKO_43WVF1G) += panel-seiko-43wvf1g.o > obj-$(CONFIG_DRM_PANEL_SHARP_LQ101R1SX01) += panel-sharp-lq101r1sx01.o > obj-$(CONFIG_DRM_PANEL_SHARP_LS037V7DW01) += panel-sharp-ls037v7dw01.o > diff --git a/drivers/gpu/drm/panel/panel-samsung-sofef01.c b/drivers/gpu/drm/panel/panel-samsung-sofef01.c > new file mode 100644 > index 0000000000000..18dc67a301a7b > --- /dev/null > +++ b/drivers/gpu/drm/panel/panel-samsung-sofef01.c > @@ -0,0 +1,360 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +// Copyright (c) 2023 Marijn Suijten > + > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include