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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6DB25C43458 for ; Wed, 1 Jul 2026 12:11:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C8EFA10ED6D; Wed, 1 Jul 2026 12:11:16 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=suse.de header.i=@suse.de header.b="sPs8m+6s"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="5gIvnfEY"; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="sPs8m+6s"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="5gIvnfEY"; dkim-atps=neutral Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8DEF610ED6D for ; Wed, 1 Jul 2026 12:11:15 +0000 (UTC) Received: from imap1.dmz-prg2.suse.org (unknown [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 2E7F97602D; Wed, 1 Jul 2026 12:11:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1782907863; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=z1sCjAIYicOWDPdP0q0DgGX3p3HEJRlW7OQTdhtqAoA=; b=sPs8m+6sfZBZygvNi9mke92mHzOVGers/uucLvnO5oBJ3Lej+aQpbqyMFpicdKUUiwX2D7 dLh2mq9Q5ShU+COzlRDgTVTKZ2ZD/DRgoZU6dt4WnA1raxcAXG48XEHGb82tG2lsKInC46 3evrOk2iqDLejC4ooVNVI9UKlspvyl0= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1782907863; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=z1sCjAIYicOWDPdP0q0DgGX3p3HEJRlW7OQTdhtqAoA=; b=5gIvnfEYN9mlsBgVwf2Gvw2UaBL2Ke06LP68BDMaidY1yPPWPEPTFdRI290Gv1c5in4RkU ntyBb42+QxfiU8BQ== Authentication-Results: smtp-out2.suse.de; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1782907863; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=z1sCjAIYicOWDPdP0q0DgGX3p3HEJRlW7OQTdhtqAoA=; b=sPs8m+6sfZBZygvNi9mke92mHzOVGers/uucLvnO5oBJ3Lej+aQpbqyMFpicdKUUiwX2D7 dLh2mq9Q5ShU+COzlRDgTVTKZ2ZD/DRgoZU6dt4WnA1raxcAXG48XEHGb82tG2lsKInC46 3evrOk2iqDLejC4ooVNVI9UKlspvyl0= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1782907863; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=z1sCjAIYicOWDPdP0q0DgGX3p3HEJRlW7OQTdhtqAoA=; b=5gIvnfEYN9mlsBgVwf2Gvw2UaBL2Ke06LP68BDMaidY1yPPWPEPTFdRI290Gv1c5in4RkU ntyBb42+QxfiU8BQ== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id ADEB0779AC; Wed, 1 Jul 2026 12:11:02 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id KOs2KdYDRWozOQAAD6G6ig (envelope-from ); Wed, 01 Jul 2026 12:11:02 +0000 From: Thomas Zimmermann To: treding@nvidia.com, javierm@redhat.com, neil.armstrong@linaro.org, jesszhan0024@gmail.com, dianders@chromium.org, megi@xff.cz, igor@reznichenko.net, mwalle@kernel.org, dario.binacchi@amarulasolutions.com, jagan@edgeble.ai, laurent.pinchart@ideasonboard.com, lujianhua000@gmail.com, agx@sigxcpu.org, kernel@puri.sm, mripard@kernel.org, maarten.lankhorst@linux.intel.com, airlied@gmail.com, simona@ffwll.ch Cc: dri-devel@lists.freedesktop.org, sashiko-reviews@lists.linux.dev Subject: [PATCH v4 3/3] drm/panel: Use drm_of_get_panel_orientation() Date: Wed, 1 Jul 2026 14:03:20 +0200 Message-ID: <20260701121055.192475-4-tzimmermann@suse.de> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260701121055.192475-1-tzimmermann@suse.de> References: <20260701121055.192475-1-tzimmermann@suse.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spamd-Result: default: False [-2.80 / 50.00]; BAYES_HAM(-3.00)[100.00%]; MID_CONTAINS_FROM(1.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; R_MISSING_CHARSET(0.50)[]; NEURAL_HAM_SHORT(-0.20)[-0.998]; MIME_GOOD(-0.10)[text/plain]; TO_MATCH_ENVRCPT_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FUZZY_RATELIMITED(0.00)[rspamd.com]; ARC_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; FROM_HAS_DN(0.00)[]; TO_DN_NONE(0.00)[]; FREEMAIL_TO(0.00)[nvidia.com,redhat.com,linaro.org,gmail.com,chromium.org,xff.cz,reznichenko.net,kernel.org,amarulasolutions.com,edgeble.ai,ideasonboard.com,sigxcpu.org,puri.sm,linux.intel.com,ffwll.ch]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; FROM_EQ_ENVFROM(0.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.de:mid,nvidia.com:email,imap1.dmz-prg2.suse.org:helo]; RCPT_COUNT_TWELVE(0.00)[20]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; FREEMAIL_ENVRCPT(0.00)[gmail.com] 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Thierry Reding The old of_drm_get_panel_orientation() function was replaced by the drm_of_get_panel_orientation() in the core DRM OF helpers. Replace all uses of the old helper and remove it. Changes in v4: - also convert anbernic, chipone and ili9488 panels Changes in v2: - include drm_of.h in all drivers to make sure the new symbol is defined Signed-off-by: Thierry Reding --- drivers/gpu/drm/drm_panel.c | 20 ------------------- drivers/gpu/drm/panel/panel-anbernic-td4310.c | 3 ++- .../drm/panel/panel-boe-th101mb31ig002-28a.c | 3 ++- .../gpu/drm/panel/panel-boe-tv101wum-nl6.c | 3 ++- .../gpu/drm/panel/panel-chipone-icna35xx.c | 3 ++- .../gpu/drm/panel/panel-chipwealth-ch13726a.c | 3 ++- drivers/gpu/drm/panel/panel-edp.c | 3 ++- drivers/gpu/drm/panel/panel-elida-kd35t133.c | 3 ++- .../gpu/drm/panel/panel-focaltech-ota7290b.c | 3 ++- drivers/gpu/drm/panel/panel-himax-hx83102.c | 3 ++- drivers/gpu/drm/panel/panel-himax-hx8394.c | 3 ++- drivers/gpu/drm/panel/panel-ilitek-ili9488.c | 3 ++- .../gpu/drm/panel/panel-ilitek-ili9806e-dsi.c | 3 ++- drivers/gpu/drm/panel/panel-ilitek-ili9881c.c | 3 ++- drivers/gpu/drm/panel/panel-ilitek-ili9882t.c | 3 ++- .../gpu/drm/panel/panel-jadard-jd9365da-h3.c | 2 +- drivers/gpu/drm/panel/panel-lvds.c | 2 +- drivers/gpu/drm/panel/panel-novatek-nt36523.c | 3 ++- drivers/gpu/drm/panel/panel-simple.c | 2 +- drivers/gpu/drm/panel/panel-sitronix-st7701.c | 3 ++- drivers/gpu/drm/panel/panel-sitronix-st7703.c | 3 ++- .../gpu/drm/panel/panel-sitronix-st7789v.c | 3 ++- include/drm/drm_panel.h | 8 -------- 23 files changed, 39 insertions(+), 49 deletions(-) diff --git a/drivers/gpu/drm/drm_panel.c b/drivers/gpu/drm/drm_panel.c index eddd13a34c03..d7c6f4824b2d 100644 --- a/drivers/gpu/drm/drm_panel.c +++ b/drivers/gpu/drm/drm_panel.c @@ -492,26 +492,6 @@ struct drm_panel *of_drm_find_panel(const struct device_node *np) return ERR_PTR(-EPROBE_DEFER); } EXPORT_SYMBOL(of_drm_find_panel); - -/** - * of_drm_get_panel_orientation - look up the orientation of the panel through - * the "rotation" binding from a device tree node - * @np: device tree node of the panel - * @orientation: orientation enum to be filled in - * - * Looks up the rotation of a panel in the device tree. The orientation of the - * panel is expressed as a property name "rotation" in the device tree. The - * rotation in the device tree is counter clockwise. - * - * Return: 0 when a valid rotation value (0, 90, 180, or 270) is read or the - * rotation property doesn't exist. Return a negative error code on failure. - */ -int of_drm_get_panel_orientation(const struct device_node *np, - enum drm_panel_orientation *orientation) -{ - return drm_of_get_panel_orientation(np, orientation); -} -EXPORT_SYMBOL(of_drm_get_panel_orientation); #endif /* Find panel by fwnode. This should be identical to of_drm_find_panel(). */ diff --git a/drivers/gpu/drm/panel/panel-anbernic-td4310.c b/drivers/gpu/drm/panel/panel-anbernic-td4310.c index 9a1b4525423c..3b6de1b2fbc6 100644 --- a/drivers/gpu/drm/panel/panel-anbernic-td4310.c +++ b/drivers/gpu/drm/panel/panel-anbernic-td4310.c @@ -12,6 +12,7 @@ #include #include +#include #include #include @@ -165,7 +166,7 @@ static int panel_anbernic_td4310_probe(struct mipi_dsi_device *dsi) if (!ctx->panel_info) return -EINVAL; - ret = of_drm_get_panel_orientation(dev->of_node, &ctx->orientation); + ret = drm_of_get_panel_orientation(dev->of_node, &ctx->orientation); if (ret < 0) return dev_err_probe(dev, ret, "Failed to get panel orientation\n"); diff --git a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c index 01b4458e55ad..a70a2e58f88c 100644 --- a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c +++ b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include @@ -380,7 +381,7 @@ static int boe_th101mb31ig002_dsi_probe(struct mipi_dsi_device *dsi) return dev_err_probe(&dsi->dev, PTR_ERR(ctx->reset), "Failed to get reset GPIO\n"); - ret = of_drm_get_panel_orientation(dsi->dev.of_node, + ret = drm_of_get_panel_orientation(dsi->dev.of_node, &ctx->orientation); if (ret) return dev_err_probe(&dsi->dev, ret, diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c index 658ce64c71eb..150dff3ab6c3 100644 --- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c +++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include