From patchwork Fri Aug 30 12:37:44 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulrich Hecht X-Patchwork-Id: 2851969 Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id EA7479F313 for ; Fri, 30 Aug 2013 12:40:06 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CC1C620418 for ; Fri, 30 Aug 2013 12:40:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 97379203AD for ; Fri, 30 Aug 2013 12:40:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755590Ab3H3MkE (ORCPT ); Fri, 30 Aug 2013 08:40:04 -0400 Received: from mail-ea0-f181.google.com ([209.85.215.181]:59006 "EHLO mail-ea0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756120Ab3H3MjV (ORCPT ); Fri, 30 Aug 2013 08:39:21 -0400 Received: by mail-ea0-f181.google.com with SMTP id d10so890031eaj.40 for ; Fri, 30 Aug 2013 05:39:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VgKRxiOE+gFgXL9hCuFpa71V2cicqDbd0RfTzd5n+MI=; b=flZsTCJRmgATPbQ6bIBqwPKxfDxmpb2M7Rjac7VcGf8u8VleLzUtsqGSedMyUSvJ43 BLgVxoeHEFmxSuIWx0g4cIe0nh8+5/r8GlihGpo8PeXHtltmPma9umTM8HzHD4ZrzV3J QQ/egbkD+0NeGS7WUraXNWUiZeli2H/w6N2apxI8cfRwHYCZwro9nfzbjHw5RGJPgcrV pt6LslFvSdFGucy7NI0QGsg6TU+XO3vFVBW9mDCefsb/2F1aJTK7XKnesCFZGS72KO61 5e1fA6LzF6/HRLvp8pbYOkEg9CTJVrYZbG/h2GrIhAlq7KWRqjIZJueCjdFZawKZLnyJ Rm/A== X-Received: by 10.15.74.197 with SMTP id j45mr12283916eey.40.1377866360799; Fri, 30 Aug 2013 05:39:20 -0700 (PDT) Received: from groucho.site ([109.201.152.242]) by mx.google.com with ESMTPSA id j7sm54444384eeo.15.1969.12.31.16.00.00 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 30 Aug 2013 05:39:20 -0700 (PDT) From: Ulrich Hecht To: linux-sh@vger.kernel.org Cc: magnus.damm@gmail.com, Ulrich Hecht Subject: [RFC 10/10] ARM: shmobile: r8a7790: lager: HDMI output via DU and ADV7511 Date: Fri, 30 Aug 2013 14:37:44 +0200 Message-Id: <1377866264-21110-11-git-send-email-ulrich.hecht@gmail.com> X-Mailer: git-send-email 1.8.1.4 In-Reply-To: <1377866264-21110-1-git-send-email-ulrich.hecht@gmail.com> References: <1377866264-21110-1-git-send-email-ulrich.hecht@gmail.com> Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-8.9 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 This builds and runs but is unlikely to provide useful output as I do not have physical access to a Lager board yet. Signed-off-by: Ulrich Hecht --- arch/arm/mach-shmobile/board-lager.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/arch/arm/mach-shmobile/board-lager.c b/arch/arm/mach-shmobile/board-lager.c index c6b5f21..edd0f3e 100644 --- a/arch/arm/mach-shmobile/board-lager.c +++ b/arch/arm/mach-shmobile/board-lager.c @@ -40,12 +40,20 @@ #include #include +#include "../../../drivers/gpu/drm/i2c/adv7511.h" + +static struct i2c_client *hdmi_encoder = NULL; + /* DU */ static struct rcar_du_encoder_data lager_du_encoders[] = { { .type = RCAR_DU_ENCODER_VGA, .output = RCAR_DU_OUTPUT_DPAD0, }, { + .type = RCAR_DU_ENCODER_HDMI, + .output = RCAR_DU_OUTPUT_LVDS0, + .slave = &hdmi_encoder, + }, { .type = RCAR_DU_ENCODER_NONE, .output = RCAR_DU_OUTPUT_LVDS1, .connector.lvds.panel = { @@ -199,6 +207,21 @@ static const struct pinctrl_map lager_pinctrl_map[] = { "intc_irq0", "intc"), }; +static struct adv7511_link_config adv7511_data = { + /* random guesses */ + .input_style = ADV7511_INPUT_STYLE2, + .id = ADV7511_INPUT_ID_16_20_24BIT_YCbCr422_SEPARATE_SYNC, + .sync_pulse = ADV7511_INPUT_SYNC_PULSE_NONE, + .bit_justification = ADV7511_INPUT_BIT_JUSTIFICATION_RIGHT, + .up_conversion = ADV7511_UP_CONVERSION_ZERO_ORDER, + .timing_gen_seq = ADV7511_TIMING_GEN_SEQ_SYN_ADJ_FIRST, + .vsync_polarity = ADV7511_SYNC_POLARITY_HIGH, + .hsync_polarity = ADV7511_SYNC_POLARITY_HIGH, + .tmds_clock_inversion = true, + .clock_delay = ADV7511_INPUT_CLOCK_DELAY_NONE, + .client = &hdmi_encoder, +}; + static struct i2c_board_info i2c2_devices[] = { /* ak4643 at 0x12: no driver */ { @@ -206,6 +229,7 @@ static struct i2c_board_info i2c2_devices[] = { }, { I2C_BOARD_INFO("adv7511", 0x39), + .platform_data = &adv7511_data, }, /* adv7612 at 0x4c: no driver */ };