Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2029631iof; Tue, 7 Jun 2022 17:31:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwvwhjINi9iokwszHEHx9f2tTaXA1SqZLPglE/hx1xngQ3p3RXlLuAPubm8D7W1PS7u0F52 X-Received: by 2002:a17:902:d545:b0:167:6ef7:d540 with SMTP id z5-20020a170902d54500b001676ef7d540mr16407815plf.133.1654648273079; Tue, 07 Jun 2022 17:31:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654648273; cv=none; d=google.com; s=arc-20160816; b=O4s7CPI76AU9KI4KEVAbF/QJNNBwybON8g0qyAakkKxXL4I7CHWbFeJ6QYtxiKhk+G b6jGTEDPqlQ4Y0l8W+D2p/Uu8sWxggk4aVdRiuA7D0JUFMqakJrZK80md50yRynDTId8 Ic+PaFhEGKtKuhdJdBAmzpI856FXbkx94+cmLXv/tsXumeuWyyYXRL605UeM0fErmoM8 eEM9MF6K1PcCytZEBEO4Gd0S/SgiJf1NnZsk0Qu+P9KJxEiZpyMquIf5k6ab8Q+BU+pf eFbao3FXHTONJG1Tcuf7h4LpkeuNcidKK45+vPDB7jyBXJeqAVawtZFUNmfp82jb1nNV mz8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=1HCnyXhOafzmcP69v2HLalUicns4RO/ZQ4qvjS6XyGk=; b=PwJP9sl0q66+ZZ0ICK6l9RmwJz793DRDJ4pojVSTMrx06SXjzRqKZF+ViZhgptoYiP NsPP/OfFsbEa9StJvEEEJszuzsglJFHDGHnGUEkqGImkJiCTFOcuuxc62AznzjG8XS4m 3516wMpI667i5TkfBp6dRDc+rhOTlXqcliq8Cj3fz+S9hwpr4qyO9wPNsTkmPo6UBcFy lsGAuZLV/nRbjJmcOmih5ImBRp54ei7uhWahaDeR7cX+WukK0sEnLW+fB6POV2HOQmUS Eq9U00hwueasAgxL23UiY3z9FoG2rp+DvBASpCYPHQzdoXdM1nCDMyIcZLdmCPspJHBi a2rQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=ge9Jny+h; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id t186-20020a6381c3000000b003fe0ac61b9fsi3469355pgd.367.2022.06.07.17.31.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 17:31:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=ge9Jny+h; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 1B5041668B4; Tue, 7 Jun 2022 17:16:44 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238981AbiFGJGl (ORCPT + 99 others); Tue, 7 Jun 2022 05:06:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42384 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238953AbiFGJGU (ORCPT ); Tue, 7 Jun 2022 05:06:20 -0400 Received: from mail-pg1-x529.google.com (mail-pg1-x529.google.com [IPv6:2607:f8b0:4864:20::529]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 33601DFD13 for ; Tue, 7 Jun 2022 02:06:17 -0700 (PDT) Received: by mail-pg1-x529.google.com with SMTP id c18so6947864pgh.11 for ; Tue, 07 Jun 2022 02:06:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=1HCnyXhOafzmcP69v2HLalUicns4RO/ZQ4qvjS6XyGk=; b=ge9Jny+hYIej3cj9ag/91xWa81svwEBV3N/ogFXUBgG8rjD7S/momLJGj/7KfP47Wy LYvdSpbngfwMYyTZAwYAiJC5uxG+viVuvfdtirnB7O0giwIJnl+IUWu8X0LiYKRKC6/z Lb0aWIcnWIDHNQ4GOq+bVdZ8jjlqGU35La27o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=1HCnyXhOafzmcP69v2HLalUicns4RO/ZQ4qvjS6XyGk=; b=FbJRDwI7NRvSH9/47m+sACt+OIAhT6B0gF03Onm2mPKbnMBfocrPAfjFH6Y1WT27br gPFbXtpWkuYBXl/ietDk42KxCpHSaZDO0lBMLDxfbMd1mU2QIQTU/Ctsf0m73p1vZnmc plqRTPtDAZusaJlyPJfnfK4loVVnmPWA/UTi1jMN7zWEFobao/LntMCnyax+OI34FSy3 it8o5A/c/USqL1eG70qU8sEaCIKRpkRcta38xHPlGHkBNVGY/o0nWrlcpVrpriWnsPQC RBg+r7gDE+4qHTXzJFTD4I37YVx7QFlMB9oe2RDr5Gz0fSKI8WWpspsBXjMfGK4XC/cf SoXQ== X-Gm-Message-State: AOAM531bay6gXOr6ixwjoGfWortxWve+guFKRBmaS/PGIy7kRcND0zfA wmxZgxWNZVc+ivFQYHUfkLF4tw== X-Received: by 2002:a05:6a00:1a49:b0:51b:8e5d:424b with SMTP id h9-20020a056a001a4900b0051b8e5d424bmr28485080pfv.66.1654592776372; Tue, 07 Jun 2022 02:06:16 -0700 (PDT) Received: from hsinyi-z840.tpe.corp.google.com ([2401:fa00:1:10:40b7:55ce:10ee:c7a0]) by smtp.gmail.com with ESMTPSA id t27-20020aa7947b000000b0051c0fe8fb8csm4507010pfq.95.2022.06.07.02.06.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 02:06:15 -0700 (PDT) From: Hsin-Yi Wang To: Chun-Kuang Hu Cc: Hans de Goede , Thierry Reding , Sam Ravnborg , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Philipp Zabel , David Airlie , Daniel Vetter , Matthias Brugger , dri-devel@lists.freedesktop.org, linux-mediatek@lists.infradead.org, Rob Clark , Stephen Boyd , Douglas Anderson , Rob Herring , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v5 6/8] drm/panel: ili9881c: Implement .get_orientation callback Date: Tue, 7 Jun 2022 17:05:47 +0800 Message-Id: <20220607090549.2345795-7-hsinyi@chromium.org> X-Mailer: git-send-email 2.36.1.255.ge46751e96f-goog In-Reply-To: <20220607090549.2345795-1-hsinyi@chromium.org> References: <20220607090549.2345795-1-hsinyi@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org To return the orientation property to drm/kms driver. Signed-off-by: Hsin-Yi Wang Reviewed-by: Hans de Goede Reviewed-by: Douglas Anderson --- drivers/gpu/drm/panel/panel-ilitek-ili9881c.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c b/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c index ba30d11547ad..58d6798c25ed 100644 --- a/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c +++ b/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c @@ -853,17 +853,29 @@ static int ili9881c_get_modes(struct drm_panel *panel, connector->display_info.width_mm = mode->width_mm; connector->display_info.height_mm = mode->height_mm; + /* + * TODO: Remove once all drm drivers call + * drm_connector_set_orientation_from_panel() + */ drm_connector_set_panel_orientation(connector, ctx->orientation); return 1; } +static enum drm_panel_orientation ili9881c_get_orientation(struct drm_panel *panel) +{ + struct ili9881c *ctx = panel_to_ili9881c(panel); + + return ctx->orientation; +} + static const struct drm_panel_funcs ili9881c_funcs = { .prepare = ili9881c_prepare, .unprepare = ili9881c_unprepare, .enable = ili9881c_enable, .disable = ili9881c_disable, .get_modes = ili9881c_get_modes, + .get_orientation = ili9881c_get_orientation, }; static int ili9881c_dsi_probe(struct mipi_dsi_device *dsi) -- 2.36.1.255.ge46751e96f-goog