Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp753246lqo; Wed, 8 May 2024 13:55:14 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCW73s7qRpVUt7FZKF3nnxgfcKOSTolm8bWxZxKyybZVEf718O8qxRjvm5h2kFj1abGgRoJKxWzKAWk5crj1+0cn+5BtdmnkKENn4P/7sw== X-Google-Smtp-Source: AGHT+IGC6t5o8Z6FHnW40AcFjB30Fp0VKILpZ+ujY0McLgw4TZS6gGgR2IWExDRM757CCsgW1lbo X-Received: by 2002:aca:1709:0:b0:3c8:5664:dd1a with SMTP id 5614622812f47-3c9852fb1acmr3727316b6e.42.1715201714405; Wed, 08 May 2024 13:55:14 -0700 (PDT) Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id a11-20020a05620a066b00b0079294dbf5f6si7772657qkh.261.2024.05.08.13.55.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 13:55:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-173819-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@chromium.org header.s=google header.b=GRvkP+YH; arc=fail (body hash mismatch); spf=pass (google.com: domain of linux-kernel+bounces-173819-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173819-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (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 ny.mirrors.kernel.org (Postfix) with ESMTPS id E53B41C21D5F for ; Wed, 8 May 2024 20:55:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 504B0134409; Wed, 8 May 2024 20:53:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="GRvkP+YH" Received: from mail-pf1-f175.google.com (mail-pf1-f175.google.com [209.85.210.175]) (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 8875C1332B1 for ; Wed, 8 May 2024 20:53:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.175 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715201615; cv=none; b=pt087HjVcuytudeQdVirz13zj4hHg+wunYGV1bqJNVnDU1p8yy5J2ts30JLn8DF5rNHxTcuwS8Hm7II3bJ3YXXN/9PuBe0W30Letx4hqRtlEnjkYi5UhAOVZRj3WssHQA8bUgf7o7Q3N4UG99DoxqK9fM6JEbINRqCuKFnvMziE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715201615; c=relaxed/simple; bh=tsa6AYuf40jHiTJukh+6TV9aFnwKy1NsbiB5LC+CvyE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=bm4d1Xq595cVXal2N7a+BEYykw2CaR7mvrfhlmpbexuSYdIHsn1NLS7lbDHIQEaIbePSheyjLLRwW/2Fbu98IR6qssXZhGYE1kCXIuWo7jQrjTdmZnZpgOHDvMRwdWLhj8PtkYy+dMG/uMdJUGGOp1+npN8bLe9q8wYupXvrj4s= 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=GRvkP+YH; arc=none smtp.client-ip=209.85.210.175 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-pf1-f175.google.com with SMTP id d2e1a72fcca58-6ed3cafd766so251495b3a.0 for ; Wed, 08 May 2024 13:53:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1715201610; x=1715806410; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=vLidwqUpHr187hGFcEiCCAyDeHC6n0W/LwS7hTKYWys=; b=GRvkP+YH71Zbm7SxxaiSTYQtomyeJXp+CcQd5Mi9T8+fzlxQWxxbRTqVsXSEpsuCqn Rg67twSnUGycAxcSQWveh7SLIlu4SIhvXjEMUbkdYfgKc4U1MnQfCItylIXynm2kc6EU P4kre1P5nxWhL0fp35QbeIUhmzNXWW7a4lG0M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715201610; x=1715806410; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vLidwqUpHr187hGFcEiCCAyDeHC6n0W/LwS7hTKYWys=; b=cTNhlS5AIBxVLf5U/76Oab7dYfpkmKgMUknSsawWYQv0lFQyck68+X4BU6cNbHuCYL mAJb6ss1jmGloikgh+RTJCkllPcKJaXePr6DeHRGOaGh9WpRgQ+TdEEb+/sjxsJJAzlS U5dKr/O/wsBdTRmUbjeAUx3Zso6ubXcPhS81eTK2oESbu6MSnb/KVwUIUivCYroazThC uG+VZMG87eGIWn51ppqb5CwgsFN7y/kjKPtjoV9c9afmxlSlNTm2W8V/e0GCSR0Ly7xM pqELzGiJjvraPEQy7k5eR7/S6DCoqJaasmrliK1lQ5EMQQo4FzxRycJgyl/3GYTPg7xL 3ewg== X-Forwarded-Encrypted: i=1; AJvYcCUgMLbw6IYhQ+LBe3GEETvWjv2soovUlKsu0oTUWJvtqbVhQU2U5UHzTL5vjcEkcLTRkNG80kGG5s5D7MqdftRIWUgAriVe1n+oxNTz X-Gm-Message-State: AOJu0Yy/gs0N3wYrqFrWoo/yCW7tQASL47QI9YoAqv+neKlhjATecGe+ Y5OWAg/rLeJJU5sguc+g9juBXcg5cnOP4C9KARUnEQnWKTb1W6LLLpoNFTi8Dw== X-Received: by 2002:a05:6a20:564e:b0:1af:8104:46e0 with SMTP id adf61e73a8af0-1afc8dea254mr3378322637.49.1715201609337; Wed, 08 May 2024 13:53:29 -0700 (PDT) Received: from dianders.sjc.corp.google.com ([2620:15c:9d:2:40f4:feca:59e0:d3ca]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2b67126ad51sm6887a91.25.2024.05.08.13.53.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 13:53:28 -0700 (PDT) From: Douglas Anderson To: dri-devel@lists.freedesktop.org Cc: lvzhaoxiong@huaqin.corp-partner.google.com, Jani Nikula , Hsin-Yi Wang , Linus Walleij , Javier Martinez Canillas , Neil Armstrong , Cong Yang , Sam Ravnborg , Dmitry Baryshkov , Joel Selvaraj , Brian Norris , Douglas Anderson , Daniel Vetter , David Airlie , Jessica Zhang , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , linux-kernel@vger.kernel.org Subject: [PATCH v4 7/9] drm/panel: boe-tv101wum-nl6: Don't use a table for initting panels Date: Wed, 8 May 2024 13:51:49 -0700 Message-ID: <20240508135148.v4.7.Ib5030ab5cd41b4e08b1958bd7e51571725723008@changeid> X-Mailer: git-send-email 2.45.0.rc1.225.g2a3ae87e7f-goog In-Reply-To: <20240508205222.2251854-1-dianders@chromium.org> References: <20240508205222.2251854-1-dianders@chromium.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Consensus on the mailing lists is that panels shouldn't use a table of init commands but should instead use init functions. With the recently introduced mipi_dsi_dcs_write_seq_multi() this is not only clean/easy but also saves space. Measuring before/after this change: $ scripts/bloat-o-meter \ .../before/panel-boe-tv101wum-nl6.ko \ .../after/panel-boe-tv101wum-nl6.ko add/remove: 14/8 grow/shrink: 0/1 up/down: 27062/-31433 (-4371) Function old new delta inx_hj110iz_init - 7040 +7040 boe_tv110c9m_init - 6440 +6440 boe_init - 5916 +5916 starry_qfh032011_53g_init - 1944 +1944 starry_himax83102_j02_init - 1228 +1228 inx_hj110iz_init.d - 1040 +1040 boe_tv110c9m_init.d - 982 +982 auo_b101uan08_3_init - 944 +944 boe_init.d - 580 +580 starry_himax83102_j02_init.d - 512 +512 starry_qfh032011_53g_init.d - 180 +180 auo_kd101n80_45na_init - 172 +172 auo_b101uan08_3_init.d - 82 +82 auo_kd101n80_45na_init.d - 2 +2 auo_kd101n80_45na_init_cmd 144 - -144 boe_panel_prepare 592 440 -152 auo_b101uan08_3_init_cmd 1056 - -1056 starry_himax83102_j02_init_cmd 1392 - -1392 starry_qfh032011_53g_init_cmd 2256 - -2256 compoundliteral 3393 - -3393 boe_init_cmd 7008 - -7008 boe_tv110c9m_init_cmd 7656 - -7656 inx_hj110iz_init_cmd 8376 - -8376 Total: Before=37297, After=32926, chg -11.72% Let's do the conversion. Since we're touching all the tables, let's also convert hex numbers to lower case as per kernel conventions. Reviewed-by: Linus Walleij Signed-off-by: Douglas Anderson --- (no changes since v3) Changes in v3: - Fix spacing of init function. - Remove an unneeded error print. - Squash boe-tv101wum-nl6 lowercase patch into main patch Changes in v2: - New .../gpu/drm/panel/panel-boe-tv101wum-nl6.c | 2792 +++++++++-------- 1 file changed, 1442 insertions(+), 1350 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c index 0ffe8f8c01de..aab60cec0603 100644 --- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c +++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c @@ -17,6 +17,8 @@ #include