From patchwork Wed May 31 01:21:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hilman X-Patchwork-Id: 9755667 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8D232602CA for ; Wed, 31 May 2017 01:21:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 808CB26E74 for ; Wed, 31 May 2017 01:21:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7396C2847F; Wed, 31 May 2017 01:21:58 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 5C82528474 for ; Wed, 31 May 2017 01:21:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=H3HNL91/nXZ25xW/TK2+B4MH7hslGQqzrk7f794aP+4=; b=uq26H29sm++XVh 0zaRU/v5uEAVmrvY/LdUzFgiKHvV5bceg63UoeIfwF3i5sXohVnvgUXACDUWDRR9vx3qx2gvjWDRx ZkG3jwwxSka1nPphWPVG6fh+ZvK3dIEdB9/aVhrHNvZkcfyBPKx4dxDXJk1Ip0LkB0/BnZQ3sIWB6 a+rZCgEb/ynqW3d6QDGjp9IHNUbLXlA30d31SEmp117sqQZCkYkG/XLTLr/km234J3HTH0UWgHwA3 f0G/m7wly6sX0D7q2tGcX2YZNlnguLkUH7zr9NWyhJa6zAQ/old/2Detlt8AlFUfObPzapINJGuqf DI7jjsnB4DHTQiecwfnw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dFsKi-00007X-7u; Wed, 31 May 2017 01:21:56 +0000 Received: from mail-pf0-x236.google.com ([2607:f8b0:400e:c00::236]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dFsKe-0008WS-51 for linux-arm-kernel@lists.infradead.org; Wed, 31 May 2017 01:21:54 +0000 Received: by mail-pf0-x236.google.com with SMTP id e193so2539479pfh.0 for ; Tue, 30 May 2017 18:21:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Xwo0x5+rvl46V4bQVYIgvpKEM0g3p5g/ZuF4IfGAj4E=; b=pZEajSh2F6QsRvqgp6nugp0wNX+edLH2uLfsBNFZGRj3tdSK3YZjzjVZ6VzNp9CPOt 4PUeA3Y2pU0oBwzd5EaQZIkGn0gjVzY/IR2yvlBbjrIBfVtEJBcZZHpuD4xOZrD7JiRg tysQ2F2Ic9z45BiY9xnc8Dw9/VsMH+AnP6n5/i9o2rn2jZeOx0e6w4u0qw52zezY4UyP Js7Jx04Of3TeSQQe0jp5tqzejx9WL0W21ClZNwzDaBsnJjIlw/hyCtZ42lO++wHWwkZ/ eWN92DuxKx1Wu438xHyecmj6LiVDYOMtrOQkqd6EutdVlv9tMbjIIp76lTQ6l/s1tT2w NPag== 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:mime-version :content-transfer-encoding; bh=Xwo0x5+rvl46V4bQVYIgvpKEM0g3p5g/ZuF4IfGAj4E=; b=T+Moqu5CBwnfuYIPEE7GkKOlSN98Doq1wGhu+lKy2e27hdGIc5MNnrlQqbTGSkg+6Y /2T7jpKgfGsptc0B5zdOel1bOYk/xeujW5Rp9vcwZ7xbBVswUhYye32FBqPR121ss07J 76uudPaIblZ1NGeU4bPaqgV9zFUlADVsJrYfwiPP8+3ZwdAJ0SO2OwDpApRrsmSTHT7T 6X3e25MLLUTjyLVl1jCDD5CVj7VGmZ83uhDxZYef8VzI80CzWjd0KD44OJuHVH82mnIt sDj1lpe8dKPBFjXcb+p+Io1oqBuPMRlfbWNuyBtTKv84/GX9P+4Aq/XHtvDR9aHv6R69 9tmA== X-Gm-Message-State: AODbwcAU/0TH3gk8oykIQjMwccm29GVrxk1278OhyxYOFTQfo5rhDXAZ cLBZTEiIzVEiL6qn X-Received: by 10.99.49.206 with SMTP id x197mr6845928pgx.181.1496193691281; Tue, 30 May 2017 18:21:31 -0700 (PDT) Received: from localhost (c-98-203-232-209.hsd1.wa.comcast.net. [98.203.232.209]) by smtp.gmail.com with ESMTPSA id 15sm22688381pfj.59.2017.05.30.18.21.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 30 May 2017 18:21:30 -0700 (PDT) From: Kevin Hilman To: Sekhar Nori Subject: [PATCH] ARM: dts: da850-evm: fix tca6416 for use with GPIO hogs Date: Tue, 30 May 2017 18:21:25 -0700 Message-Id: <20170531012125.12258-1-khilman@baylibre.com> X-Mailer: git-send-email 2.9.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170530_182152_278375_EBFA9029 X-CRM114-Status: GOOD ( 10.32 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP In order GPIOS from this controller to be used with the "gpio-hogs" property, the tca6416 node has to properly labeled as a gpio-controller, and use #gpio-cells. With that, the SEL_A, SEL_B, SEL_C lines that are used to select VPIF input can be configured using GPIO hogs. As an example, example, the configuration below selects the analog video input on the da850-evm UI board: &tca6416 { status = "okay"; sel_a { gpio-hog; gpios = <7 GPIO_ACTIVE_HIGH>; output-high; line-name = "ADC_ENn"; }; sel_b { gpio-hog; gpios = <6 GPIO_ACTIVE_HIGH>; output-high; line-name = "CAMERA_ENn"; }; sel_c { gpio-hog; gpios = <5 GPIO_ACTIVE_HIGH>; output-low; line-name = "VIDEO_IN_ENn"; }; }; Signed-off-by: Kevin Hilman --- arch/arm/boot/dts/da850-evm.dts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/boot/dts/da850-evm.dts b/arch/arm/boot/dts/da850-evm.dts index 8d244cd76c36..a423e8ebfb37 100644 --- a/arch/arm/boot/dts/da850-evm.dts +++ b/arch/arm/boot/dts/da850-evm.dts @@ -82,6 +82,8 @@ tca6416: gpio@20 { compatible = "ti,tca6416"; reg = <0x20>; + gpio-controller; + #gpio-cells = <2>; }; }; wdt: wdt@21000 {