From patchwork Tue Nov 17 17:56:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 325528 Delivered-To: patch@linaro.org Received: by 2002:a17:906:d156:0:0:0:0 with SMTP id br22csp5173498ejb; Tue, 17 Nov 2020 09:56:43 -0800 (PST) X-Google-Smtp-Source: ABdhPJwreC/NOQ6rUFvWZDe8Fz64vwvoyG4eRcIW80Enfu6HrgUcqv2avIxsggIiEl8x3cskA+JS X-Received: by 2002:a17:90a:448a:: with SMTP id t10mr270376pjg.38.1605635803172; Tue, 17 Nov 2020 09:56:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605635803; cv=none; d=google.com; s=arc-20160816; b=N+n/mv3v7E74uPosuXLDgBL7LqdGGYAzUeq04Q5TeOjVUhSQBRmtZppL202uBFrY9k SjbQnlw66jTVD7i6Z39PbdW9r+QESpfaw92s5ufzigLtfSd2qdlUVGZOjWD7A77DODVY lGhErRNizKSogkcVCpB6VZNQxKHJXvlErBp459p8f/QnyGP6NA+Rtws0r8uAeR0TpC/H 1XDLSY6umWGhIjLYYZ7TT/PcA/JlpRWn8kTGvWqm8Oqnv3M8hd8wZjXSX+MJQ4hKijV9 45R/SBqPrPA9UfbHms3Xx3aATPDRrnnyMaiAjLn3OuuyO05qk5YmarC2h85vAkc5zCr4 3fDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:references:in-reply-to:message-id:date :subject:to:from:dkim-signature:delivered-to; bh=DmDzjsD2kYzn8qcFjK8bnaoRYrjk4vdASaaiMf+ISuM=; b=BS5ax8bEU4qAgg5sYDQ8GqIowHxR2InE7YFz9JvlIxRoDtSpJdLy/Aq8mbvEb7Ao+j mNvIa5JP4dotcgSrk0y8z9b2Bs62c36q4unM/ZcwIGXpeadlePW4pyf7MjxQAalyHV+W mDiFKzOCsf7neZxX0Iad+OpwQyEBwtJSVLY/pucJ2tJ4V7D4cp+NyXzdXFNfHMGClIqq KDPQlgbeYdqNZTIbvdf3ifFKhcBLicvZOR0phmajdnODD6oO6JYIp4ytS7KGPGzB2/eF Q/8A73jno9Glpr1CJ2gD+lknA91CD4ntsLAm505az6hqnUK0R1oWM3QnKLlOu0UZVsPF KKVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b="T54lFKh/"; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id s13si11954525plr.266.2020.11.17.09.56.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Nov 2020 09:56:43 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b="T54lFKh/"; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 66B9689316; Tue, 17 Nov 2020 17:56:41 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x242.google.com (mail-lj1-x242.google.com [IPv6:2a00:1450:4864:20::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4A05C89316 for ; Tue, 17 Nov 2020 17:56:39 +0000 (UTC) Received: by mail-lj1-x242.google.com with SMTP id p12so25288643ljc.9 for ; Tue, 17 Nov 2020 09:56:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=r5g1xro3gzMR8larnd5g0CHs85zOBMrU8NxGzGkTUpQ=; b=T54lFKh/HBiMQ3dcAseNVF6K75gKizraekbL3FbuvF0IyjGOEyjZDXs3qsveowGzbS efVh7Z+2ozNcccq/fmygkmUmXbbC/a/wXwDFoeTMFNCqYHGEo2utFHJVUV/axJ33xvI8 NwR2ig29KZXHTb93GrCHWOLkFrx2AviOGSDM6t3tRghuAFUoiQcFZ1bI8DwwLAbWBZ08 Djna/YdxHj0ns+cW2A2mcgPD9yXy5QJnTWmvKzGpdZLzGyfh51Ga1yphNXV288xoT/D0 EmJimopwQ44Bl74n51OplRbOtW7bio0K3M/IEGiWmbgyRxo47IojNtjd959kbv4y/3dT RxAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=r5g1xro3gzMR8larnd5g0CHs85zOBMrU8NxGzGkTUpQ=; b=My3dzHZRy50Hr0kh/JKPwUwoVuWtKXNkOK30jnhXXasLbxe7DMTBoio5BvqBNuipX0 UJgAPjm+D8nVHGm4ppF8XRVsF6S7IWFCQdaVccgxGiPAcIFiQRSry9VfOc/QGXTohrTA /Va/EYF8bv0syM2MLcWpz2R/H8cqvzeOAspVm4O+sUOcfSAwkutje6xUve4/4gu6YwA7 GgDEwnoRxv6uBZCWt9TXG8yzQcoDhXa+xsNexk6I8DdiHHDrQhp02bfsLvmyxXF5NjLU DZBRgzdexYgyBNUN7lRw9U7q76riut9YML/uTdZbBVn+BKwJKqBE2ykFsqrMJ17bpXUR FTrQ== X-Gm-Message-State: AOAM533E80BKeCORyPl8JSXSG0RFA0FKmCFY65I/WAFc+xrYWn0PMfQO v6hwudUuVld4wveROlMNVZGpRA== X-Received: by 2002:a2e:b558:: with SMTP id a24mr2210740ljn.328.1605635797758; Tue, 17 Nov 2020 09:56:37 -0800 (PST) Received: from localhost.bredbandsbolaget (c-92d7225c.014-348-6c756e10.bbcust.telenor.se. [92.34.215.146]) by smtp.gmail.com with ESMTPSA id m21sm1558631ljh.82.2020.11.17.09.56.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Nov 2020 09:56:37 -0800 (PST) From: Linus Walleij To: Thierry Reding , Sam Ravnborg , dri-devel@lists.freedesktop.org Subject: [PATCH 3/3] drm/panel: s6e63m0: Fix init sequence Date: Tue, 17 Nov 2020 18:56:21 +0100 Message-Id: <20201117175621.870085-3-linus.walleij@linaro.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201117175621.870085-1-linus.walleij@linaro.org> References: <20201117175621.870085-1-linus.walleij@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stephan Gerhold , =?utf-8?q?Pawe=C5=82_Chmiel?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The init sequence consist of a number of unknown settings for the display controller. This patch achieves two things: - Fix an error that must have happened when the driver was converted from the backlight subsystem: the 0xb8 configuration command was lost and added as a tail to the previous command. - Update some minor settings in some bytes here and there according to changes in the Samsung GT-I9070 and Samsung GT-S7710 code dumps. Since two other devices use these settings they probably reflect trimmings later found to be better for the display rather than customizations for these devices. Cc: Stephan Gerhold Cc: Paweł Chmiel Signed-off-by: Linus Walleij --- drivers/gpu/drm/panel/panel-samsung-s6e63m0.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-samsung-s6e63m0.c b/drivers/gpu/drm/panel/panel-samsung-s6e63m0.c index 0418d6f1530b..6b4e97bfd46e 100644 --- a/drivers/gpu/drm/panel/panel-samsung-s6e63m0.c +++ b/drivers/gpu/drm/panel/panel-samsung-s6e63m0.c @@ -397,7 +397,7 @@ static void s6e63m0_init(struct s6e63m0 *ctx) { s6e63m0_dcs_write_seq_static(ctx, MCS_PANELCTL, 0x01, 0x27, 0x27, 0x07, 0x07, 0x54, 0x9f, - 0x63, 0x86, 0x1a, 0x33, 0x0d, 0x00, 0x00); + 0x63, 0x8f, 0x1a, 0x33, 0x0d, 0x00, 0x00); s6e63m0_dcs_write_seq_static(ctx, MCS_DISCTL, 0x02, 0x03, 0x1c, 0x10, 0x10); @@ -413,9 +413,8 @@ static void s6e63m0_init(struct s6e63m0 *ctx) 0x01); s6e63m0_dcs_write_seq_static(ctx, MCS_SRCCTL, - 0x00, 0x8c, 0x07); - s6e63m0_dcs_write_seq_static(ctx, 0xb3, - 0xc); + 0x00, 0x8e, 0x07); + s6e63m0_dcs_write_seq_static(ctx, 0xb3, 0x6c); s6e63m0_dcs_write_seq_static(ctx, 0xb5, 0x2c, 0x12, 0x0c, 0x0a, 0x10, 0x0e, 0x17, @@ -434,9 +433,12 @@ static void s6e63m0_init(struct s6e63m0 *ctx) 0x13, 0x1f, 0x1a, 0x2a, 0x24, 0x1f, 0x1b, 0x1a, 0x17, 0x2b, 0x26, 0x22, 0x20, 0x3a, 0x34, 0x30, 0x2c, 0x29, 0x26, 0x25, 0x23, - 0x21, 0x20, 0x1e, 0x1e, 0x00, 0x00, 0x11, - 0x22, 0x33, 0x44, 0x44, 0x44, 0x55, 0x55, - 0x66, 0x66, 0x66, 0x66, 0x66, 0x66); + 0x21, 0x20, 0x1e, 0x1e); + + s6e63m0_dcs_write_seq_static(ctx, 0xb8, + 0x00, 0x00, 0x11, 0x22, 0x33, 0x44, 0x44, + 0x44, 0x55, 0x55, 0x66, 0x66, 0x66, 0x66, + 0x66, 0x66); s6e63m0_dcs_write_seq_static(ctx, 0xb9, 0x2c, 0x12, 0x0c, 0x0a, 0x10, 0x0e, 0x17, @@ -456,7 +458,7 @@ static void s6e63m0_init(struct s6e63m0 *ctx) 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x06, 0x09, 0x0d, 0x0f, 0x12, 0x15, 0x18); - s6e63m0_dcs_write_seq_static(ctx, 0xb2, + s6e63m0_dcs_write_seq_static(ctx, MCS_TEMP_SWIRE, 0x10, 0x10, 0x0b, 0x05); s6e63m0_dcs_write_seq_static(ctx, MCS_MIECTL1,