Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2393154imu; Thu, 24 Jan 2019 12:00:50 -0800 (PST) X-Google-Smtp-Source: ALg8bN776bEznMcUDhN31fAHbedbwEMCg7hU7qUHJ9q6tr1QwZnbf8WlLP8/Taif6He4tfYfCrZv X-Received: by 2002:a65:5bc4:: with SMTP id o4mr7272912pgr.426.1548360050037; Thu, 24 Jan 2019 12:00:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548360050; cv=none; d=google.com; s=arc-20160816; b=N3PP91qYs3olV9OrGnAtUrnL64TNH7ik6IDTKly0VHZWRBSh8nraqKtwbb7Ev/YZaQ BDbxS50K6yCvQZlu81bHblU/K4kpK+02iVtaM/sSfY1T4O6kFHimK12kiEX4YqU+NehX n7GFUifm8K7rn3aue9HHx3IcvjdE7tn7fM3grlWyY8hhrFfyjdgu0/lWqWIRPoar/kWN r87IitLmTZf86HJVbA4nQ86bCfTiL1tIhiEoQs01TaBJBL/ZxGgKiyGKKK+xPOXKir+B VhfH3XqbAT5cH/nwgImSSp4KGcat9lCORoJyfsI4bNmsdgrHdJeAo7ntk5vYVA6Ed0NJ VRSQ== 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=EkDBLnbNod31G2yEaFX2CmKKS0jTQnqrj15H3QWvn9U=; b=pSTdvGE28o0xkPDiVxhkqPvsxx3SSr/O/wlbuO+JP82qBlKQ5JRaAz7SFGWPyAC0qs V3kZ0I+Tcq2RAS010wFtVy8ZsFOiw77aUyBSB4zGkQiaVa4uImAPKI5J27ejmdcJIklO ycekSiKpJ7PW+vdVSZeYWHvTB/mLWHSJxOjvBSZsLYKIhRnK4xHIV+puUC1hhTos0vRV O+wex//9ZBiB39CNdk/ZEDODhDl69TkO+TqGqcGdD2Lj5+3V0X+B/ygmp5PYLwJtAU8F LlTLdXMgMz8W8FJJ2/tV+Qircrnm9Iq6GAy8xqA6R0G7akXAaSyFiCypOqufIJEYQ9QM +5Yw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=TCD0TRN3; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 2si23077920pfd.154.2019.01.24.12.00.34; Thu, 24 Jan 2019 12:00:50 -0800 (PST) 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=@amarulasolutions.com header.s=google header.b=TCD0TRN3; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732085AbfAXT7s (ORCPT + 99 others); Thu, 24 Jan 2019 14:59:48 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:42868 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730395AbfAXT7q (ORCPT ); Thu, 24 Jan 2019 14:59:46 -0500 Received: by mail-pl1-f196.google.com with SMTP id y1so3371356plp.9 for ; Thu, 24 Jan 2019 11:59:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=EkDBLnbNod31G2yEaFX2CmKKS0jTQnqrj15H3QWvn9U=; b=TCD0TRN38afPd8Zhe1O+pYkOUH9l5R+moib5iY6n5hpyBrxb53upzWLLGzkDYl8E+I gTUUj61LciP1lsUReMlCJjvy9FiZefnOeCTMzcBQ0IwfE1S/WNJFNnF0RLMGmBVLhm1Y /4rXYrgXjGbn0Kg6zLVn52zjLpm0bhHsidHbU= 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=EkDBLnbNod31G2yEaFX2CmKKS0jTQnqrj15H3QWvn9U=; b=CwsF7YPMd0YEqbCh/8D9dPJAYzUml4+0rU7eVpMHv3Erm0ANWbi+PhOdn7wT+qxK/c WfmS49HGNun9h6xxFSXihHIHaxwSJwZq4WoQmsni5z5LgnUmknNtdj3b6QsEqnMKY3mI Z4nhAzXfghwV0ShjfXHrFvwKh/JHtq4hVZzYA1qQ1qfhtmyCRsWLWjP0/gLXsyx4KIcN pp5TV5RMslogWoi0BpnVX85NBSFQkDnS+ZwWIMO3JzBEE554ok5EpGIlYZIcR7rD4IvS Day+FqtwFWE4fHE7FMdjI6JcPBiShcnucW8hU5nBK4bTOqIJsHF/1lDrmlXyldxdbW2P QkZw== X-Gm-Message-State: AJcUukcIjKdiLb2RKyJ69X3A+BmjwJCmqCw/ek9hrMqPhixQ8zf1dM7K TL6+tE+i+8FnuJrqKMaynengEg== X-Received: by 2002:a17:902:28aa:: with SMTP id f39mr7941512plb.297.1548359986023; Thu, 24 Jan 2019 11:59:46 -0800 (PST) Received: from localhost.localdomain ([115.97.179.75]) by smtp.gmail.com with ESMTPSA id x11sm61637003pfe.72.2019.01.24.11.59.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 24 Jan 2019 11:59:45 -0800 (PST) From: Jagan Teki To: Maxime Ripard , David Airlie , Daniel Vetter , Chen-Yu Tsai , Michael Turquette , Rob Herring , Mark Rutland Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, Michael Trimarchi , linux-amarula@amarulasolutions.com, linux-sunxi@googlegroups.com, Jagan Teki Subject: [PATCH v6 05/22] drm/sun4i: tcon: Export get tcon0 routine Date: Fri, 25 Jan 2019 01:28:43 +0530 Message-Id: <20190124195900.22620-6-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20190124195900.22620-1-jagan@amarulasolutions.com> References: <20190124195900.22620-1-jagan@amarulasolutions.com> 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 Sometimes tcon attributes like tcon divider, clock rate etc are needed in interface drivers like DSI. So for such cases interface driver must probe the respective tcon and get the attributes. Since tcon0 probe is already available, via sun4i_get_tcon0 function, export the same instead of probing tcon explicitly. Signed-off-by: Jagan Teki --- drivers/gpu/drm/sun4i/sun4i_tcon.c | 3 ++- drivers/gpu/drm/sun4i/sun4i_tcon.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c index 0420f5c978b9..3da75a0c5c5d 100644 --- a/drivers/gpu/drm/sun4i/sun4i_tcon.c +++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c @@ -221,7 +221,7 @@ EXPORT_SYMBOL(sun4i_tcon_enable_vblank); * are located in TCON0. This helper returns a pointer to TCON0's * sun4i_tcon structure, or NULL if not found. */ -static struct sun4i_tcon *sun4i_get_tcon0(struct drm_device *drm) +struct sun4i_tcon *sun4i_get_tcon0(struct drm_device *drm) { struct sun4i_drv *drv = drm->dev_private; struct sun4i_tcon *tcon; @@ -235,6 +235,7 @@ static struct sun4i_tcon *sun4i_get_tcon0(struct drm_device *drm) return NULL; } +EXPORT_SYMBOL(sun4i_get_tcon0); void sun4i_tcon_set_mux(struct sun4i_tcon *tcon, int channel, const struct drm_encoder *encoder) diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.h b/drivers/gpu/drm/sun4i/sun4i_tcon.h index b5214d71610f..a52696db14a5 100644 --- a/drivers/gpu/drm/sun4i/sun4i_tcon.h +++ b/drivers/gpu/drm/sun4i/sun4i_tcon.h @@ -274,6 +274,7 @@ struct sun4i_tcon { struct drm_bridge *sun4i_tcon_find_bridge(struct device_node *node); struct drm_panel *sun4i_tcon_find_panel(struct device_node *node); +struct sun4i_tcon *sun4i_get_tcon0(struct drm_device *drm); void sun4i_tcon_enable_vblank(struct sun4i_tcon *tcon, bool enable); void sun4i_tcon_mode_set(struct sun4i_tcon *tcon, const struct drm_encoder *encoder, -- 2.18.0.321.gffc6fa0e3