Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp139362ybi; Tue, 2 Jul 2019 17:49:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqwsMKs23nhrtAiI7ePQqzkxlldvn2D4CclW5UJQQDXo7RCs4jYtNQpDGJZ2xNksYqC0WbPT X-Received: by 2002:a17:902:704c:: with SMTP id h12mr38892620plt.214.1562114985393; Tue, 02 Jul 2019 17:49:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562114985; cv=none; d=google.com; s=arc-20160816; b=z2OPGJgxO2huTAv/Kr8EKVuOQCVopVvIb7c5w9+lLD6B2/K5nmHtieBN+0B7YRcJVE eSnWRBXCUW5CJEt6o/4MKkkXd8J0U2Wrk2MlS4wXsY0xa0IhXSR7wzonCi++LlfOuSXD 4xQBduS1Zk0zHaHCOUpPQWA71OqjyZuw4L4eCsa7l9+/h7BaWeF+/b7LIXwO963h57g9 wzX5at6bqSOfISV4A72d9iFLljyetOdudeDRhhvGjBNlZHsT8k9AUTBPXmhLVrL/1pU9 DRIdN1v2ayEKcaXlOuXEKIbnZikIaCVIKSDl5QJf/oku8IQR1hmFH2pO6gdbZ6dXceUv cYeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=4i2YSPugXI0nrqp33kMy8Y944Y94lb5ecy4lCGMxEsQ=; b=qHut+vZhCHA3RBH5aCtimjE0gl8caUOcu7ttub4Nu9YK62zz7/hZqaDf8oWUY7bGc1 ubg4K47Jg4XBrW/TTXySh3ZL1gK24Cs7QcRi/GaH7K3Pe/GT9ipYciPDaUREoXIsA331 tFmjS/lxtAxy2x2LkdVLzMiycvsoWFh0uZJMFJQHKtOTIgtJAcqP0kZP4OI8bdWjdFNa 4renurnCY4hTQ3tcxypKXRnY+8jXUurscsh+Pr4GUVN8zQNzc6ZtImyRkYGnUNSvrUVl Clpu5znW9E6t/cbvxocwDWff29k0n5QkZh2znlQAyaKBPfJdCnTOkkw1vjw9ZCVqE012 Gr4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Io3Emwop; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c18si174470pjo.105.2019.07.02.17.49.30; Tue, 02 Jul 2019 17:49:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=Io3Emwop; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727116AbfGCAre (ORCPT + 99 others); Tue, 2 Jul 2019 20:47:34 -0400 Received: from mail-pl1-f195.google.com ([209.85.214.195]:39808 "EHLO mail-pl1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727069AbfGCAre (ORCPT ); Tue, 2 Jul 2019 20:47:34 -0400 Received: by mail-pl1-f195.google.com with SMTP id b7so210471pls.6 for ; Tue, 02 Jul 2019 17:47:33 -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=4i2YSPugXI0nrqp33kMy8Y944Y94lb5ecy4lCGMxEsQ=; b=Io3EmwopeQFUFFj8MfEzOz6LKA/W7AncRHgVvChAu8QUpuD2E3VyZqA3FencbnOFjh 2QFw9FLfiNtoaQSXDSpIrLmj9mPRkqNM1rG/RbcVTya+m+LG3+XUPQhtEIJJBTQunsuR e06bOaadoY8m6HPWLWiI4UJBNkFke7GWAqs9Y= 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=4i2YSPugXI0nrqp33kMy8Y944Y94lb5ecy4lCGMxEsQ=; b=UWVs2kNzZEWgmtDytUY2CHDdtqR6I4iubwFQS1Gn99weQtyNYFZC2T2A7T9cGgh5jp cf/gKwlObvsebTz0zlRENBlElVg9uFiNIw5GnOH9Cv0zSDdNgTM0gw4VDBBjf1TW8JyJ SUG56qX5f3t69pQe8PkZDkUZbGuz2EArhD/c9N43KbCJOmOIbv/X3Y0h6QknlboN/yDz 34tbcbDdoKf7XLAOmXhcavwVKJijwpQW+jti2ygwvRqusrAzZZP5wSzjRvKt3g/zlZIJ nRUEQ8/WhzOH/LID/CI3l3p6NBN7JivEhjgDogBVZRkWGp32WwUfecIrhZVCSQFr6zQ6 JwaQ== X-Gm-Message-State: APjAAAWVn3dkOndzoaR0RLLBP47aYzIeaARCPHsXU3VWfKpvf9sYsmZM Vorg5aNFnOZe37pr6TF+Zp+ZDd5m4Zw= X-Received: by 2002:a17:902:2bc5:: with SMTP id l63mr39458967plb.30.1562110987634; Tue, 02 Jul 2019 16:43:07 -0700 (PDT) Received: from exogeni.mtv.corp.google.com ([2620:15c:202:1:5be8:f2a6:fd7b:7459]) by smtp.gmail.com with ESMTPSA id c26sm167611pfr.172.2019.07.02.16.43.06 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Tue, 02 Jul 2019 16:43:07 -0700 (PDT) From: Derek Basehore To: linux-kernel@vger.kernel.org Cc: Maarten Lankhorst , Maxime Ripard , Sean Paul , David Airlie , Daniel Vetter , Thierry Reding , Sam Ravnborg , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , CK Hu , Philipp Zabel , Matthias Brugger , dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, Derek Basehore Subject: [PATCH v4 4/4] drm/mtk: add panel orientation property Date: Tue, 2 Jul 2019 16:42:58 -0700 Message-Id: <20190702234258.136349-5-dbasehore@chromium.org> X-Mailer: git-send-email 2.22.0.410.gd8fdbe21b5-goog In-Reply-To: <20190702234258.136349-1-dbasehore@chromium.org> References: <20190702234258.136349-1-dbasehore@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This inits the panel orientation property for the mediatek dsi driver if the panel orientation (connector.display_info.panel_orientation) is not DRM_MODE_PANEL_ORIENTATION_UNKNOWN. Signed-off-by: Derek Basehore --- drivers/gpu/drm/mediatek/mtk_dsi.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c b/drivers/gpu/drm/mediatek/mtk_dsi.c index 4a0b9150a7bb..08ffdc7526dd 100644 --- a/drivers/gpu/drm/mediatek/mtk_dsi.c +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c @@ -782,10 +782,18 @@ static int mtk_dsi_create_connector(struct drm_device *drm, struct mtk_dsi *dsi) DRM_ERROR("Failed to attach panel to drm\n"); goto err_connector_cleanup; } + + ret = drm_connector_init_panel_orientation_property(&dsi->conn); + if (ret) { + DRM_ERROR("Failed to init panel orientation\n"); + goto err_panel_detach; + } } return 0; +err_panel_detach: + drm_panel_detach(dsi->panel); err_connector_cleanup: drm_connector_cleanup(&dsi->conn); return ret; -- 2.22.0.410.gd8fdbe21b5-goog