From patchwork Tue Jan 21 19:47:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Fritz X-Patchwork-Id: 3519431 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 70759C02DD for ; Tue, 21 Jan 2014 19:48:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 98B2A20109 for ; Tue, 21 Jan 2014 19:48:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A5B352011E for ; Tue, 21 Jan 2014 19:48:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753604AbaAUTsV (ORCPT ); Tue, 21 Jan 2014 14:48:21 -0500 Received: from mail-la0-f53.google.com ([209.85.215.53]:43856 "EHLO mail-la0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752912AbaAUTsT (ORCPT ); Tue, 21 Jan 2014 14:48:19 -0500 Received: by mail-la0-f53.google.com with SMTP id e16so7043359lan.12 for ; Tue, 21 Jan 2014 11:48:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=mdWV1NB1rkW1LS36izjW6UcW+7/mi+gEig5/b5dnxFc=; b=hzjVxbIxtEOEGpc0orVaY4Y8cPMby0h1gs3Kj/x1BAU6rtMV9xXidE6Av8k0U/bpvR rCFDCyPigylKUkUo6FaeG7L5itQ87nxVNVV3XpRDm3xCjJSJTJ2ORiDLN81XRBm8+T9b ucNRfquliYCRczImdEsTvXt8wZBz4Rhgm/ZRP2Mqv5XUxFzhtZkLBQeTpzKYh+izs4Zx ViPLOQkNzLzSAIeZScgeddUsxD+GvEj3zFMj8X6DrS/XHL6K2shHRCHTCW4my5l/g3O7 iLCOIgSs5dtxNeIptVjebdhxdnCEpkYNuoSY15eLsWQyIU9ibx5rHcgor+K0ztIoKvLS NPiw== X-Received: by 10.152.88.103 with SMTP id bf7mr9746211lab.0.1390333697309; Tue, 21 Jan 2014 11:48:17 -0800 (PST) Received: from mars.ipredator.se (anon-35-60.vpn.ipredator.se. [46.246.35.60]) by mx.google.com with ESMTPSA id n13sm5015606lbl.17.2014.01.21.11.48.15 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 21 Jan 2014 11:48:16 -0800 (PST) From: Christoph Fritz To: Tony Lindgren , Tomi Valkeinen , Mark Rutland , Ian Campbell , , Archit Taneja , Javier Martinez Canillas , Daniel Mack , "Hans J. Koch" Cc: devicetree@vger.kernel.org, linux-omap@vger.kernel.org Subject: [PATCH 4/6] ARM: OMAP2+: add legacy display for omap3 DBB056 Date: Tue, 21 Jan 2014 20:47:38 +0100 Message-Id: <1390333660-30573-5-git-send-email-chf.fritz@googlemail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1390333660-30573-1-git-send-email-chf.fritz@googlemail.com> References: <1390333660-30573-1-git-send-email-chf.fritz@googlemail.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Full device tree support for omapdss is not yet accomplished. Until then, init display by legacy platform code. Signed-off-by: Christoph Fritz --- arch/arm/mach-omap2/dss-common.c | 49 ++++++++++++++++++++++++++++++++++++ arch/arm/mach-omap2/dss-common.h | 1 + arch/arm/mach-omap2/pdata-quirks.c | 8 +++++- 3 files changed, 57 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/dss-common.c b/arch/arm/mach-omap2/dss-common.c index dadccc9..b8b4e39 100644 --- a/arch/arm/mach-omap2/dss-common.c +++ b/arch/arm/mach-omap2/dss-common.c @@ -257,3 +257,52 @@ void __init omap3_igep2_display_init_of(void) platform_device_register(&omap3_igep2_tfp410_device); platform_device_register(&omap3_igep2_dvi_connector_device); } + +/* OMAP3 dbb056 data */ + +#define DBB056_DISPLAY_ENABLE_GPIO 156 + +static const struct display_timing dbb056_lcd_videomode = { + .pixelclock = { 0, 19200000, 0 }, + + .hactive = { 0, 640, 0 }, + .hfront_porch = { 0, 104, 0 }, + .hback_porch = { 0, 8, 0 }, + .hsync_len = { 0, 8, 0 }, + + .vactive = { 0, 480, 0 }, + .vfront_porch = { 0, 104, 0 }, + .vback_porch = { 0, 8, 0 }, + .vsync_len = { 0, 8, 0 }, + + .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW | + DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE, +}; + +static struct panel_dpi_platform_data dbb056_lcd_pdata = { + .name = "lcd", + .source = "dpi.0", + + .data_lines = 18, + + .display_timing = &dbb056_lcd_videomode, + + .enable_gpio = DBB056_DISPLAY_ENABLE_GPIO, + .backlight_gpio = -1, +}; + +static struct platform_device dbb056_lcd_device = { + .name = "panel-dpi", + .id = 0, + .dev.platform_data = &dbb056_lcd_pdata, +}; + +static struct omap_dss_board_info omap_dbb056_dss_data = { + .default_display_name = "lcd", +}; + +void __init omap3_dbb056_display_init_of(void) +{ + platform_device_register(&dbb056_lcd_device); + omap_display_init(&omap_dbb056_dss_data); +} diff --git a/arch/arm/mach-omap2/dss-common.h b/arch/arm/mach-omap2/dss-common.h index a9becf0..a125b55 100644 --- a/arch/arm/mach-omap2/dss-common.h +++ b/arch/arm/mach-omap2/dss-common.h @@ -9,5 +9,6 @@ void __init omap4_panda_display_init_of(void); void __init omap_4430sdp_display_init_of(void); void __init omap3_igep2_display_init_of(void); +void __init omap3_dbb056_display_init_of(void); #endif diff --git a/arch/arm/mach-omap2/pdata-quirks.c b/arch/arm/mach-omap2/pdata-quirks.c index 39f020c..bce8020 100644 --- a/arch/arm/mach-omap2/pdata-quirks.c +++ b/arch/arm/mach-omap2/pdata-quirks.c @@ -92,6 +92,11 @@ static void __init omap3_zoom_legacy_init(void) { legacy_init_wl12xx(WL12XX_REFCLOCK_26, 0, 162); } + +static void __init omap3_dbb056_legacy_init(void) +{ + omap3_dbb056_display_init_of(); +} #endif /* CONFIG_ARCH_OMAP3 */ #ifdef CONFIG_ARCH_OMAP4 @@ -139,10 +144,11 @@ struct of_dev_auxdata omap_auxdata_lookup[] __initdata = { static struct pdata_init pdata_quirks[] __initdata = { #ifdef CONFIG_ARCH_OMAP3 + { "incostartec,omap3-lilly-dbb056", omap3_dbb056_legacy_init, }, + { "isee,omap3-igep0020", omap3_igep0020_legacy_init, }, { "nokia,omap3-n900", hsmmc2_internal_input_clk, }, { "nokia,omap3-n9", hsmmc2_internal_input_clk, }, { "nokia,omap3-n950", hsmmc2_internal_input_clk, }, - { "isee,omap3-igep0020", omap3_igep0020_legacy_init, }, { "ti,omap3-evm-37xx", omap3_evm_legacy_init, }, { "ti,omap3-zoom3", omap3_zoom_legacy_init, }, #endif