From patchwork Tue Dec 21 12:32:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Robinson X-Patchwork-Id: 1571617 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=hsKI2K6h; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4JJG8L6JrKz9s1l for ; Tue, 21 Dec 2021 23:33:20 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 26A0A82FB4; Tue, 21 Dec 2021 13:33:06 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="hsKI2K6h"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4C1218329E; Tue, 21 Dec 2021 13:33:01 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wr1-x42e.google.com (mail-wr1-x42e.google.com [IPv6:2a00:1450:4864:20::42e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 387DB82F91 for ; Tue, 21 Dec 2021 13:32:58 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=pbrobinson@gmail.com Received: by mail-wr1-x42e.google.com with SMTP id a9so26590552wrr.8 for ; Tue, 21 Dec 2021 04:32:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Uca9mI/0xr2VvM2BOnaezGNWOCyboFwDAq5VR8yJ+PY=; b=hsKI2K6hQWUj0mwUpulP3CSiejyrV10/Ixi4LRsx5IwsuVFI+3PAYXgQBuQmmUHap0 /+KNjQPXqO+gn4qhXK+Ne5SzX+U0rGfdz0jhVmG2d3XfYKdnaXJtVRBFV2OKcLXZFokz uJmvr3VC7NN5AI7e8xVhsHd7IGMxWKAjM4RU6u1D4LlfcQmThBwVnCml1FcAFV8hMC25 IMv4qqVFZSivMLmxUvhlEMHIcUqVV2ICYNWyhR3JibNccnQLNddOYsYn0m89aFDBuKfd 7r96WT8MoV5soD42qvVeUvQtXHUzwccHZNIP5CnkqLld+l5vyiujuf4Gc0rY+koB4ChP Lgnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Uca9mI/0xr2VvM2BOnaezGNWOCyboFwDAq5VR8yJ+PY=; b=nphePesKL6iC6z7MgruvobpwUEwDSMc5b/bQgihYvlTZC+EkbV+D4fmBekkaeTOIUG w1faN6xb3PKv7c6zNb0Rm5ZFaqkIzvSbKdzyq4teVfkxwpOrlhcl8NG44dNoab8sEa1b 7wkO+3r8vaTh4FUKzJyhmQdq9W1NQxxXU5btCw8O+M1XDCCRHAKw+QIwbZDcQ93lqMvj XMbO5AgR+4uUcGdzeHwHdBYf0xBRPxIgsn9KI6ORq9+UibxviOyUkG/UjozQyWqkfrS/ 2/DE6S02pxPZn+zWRhxpBHzicUsJHN2nii9iKTSK5GtPOe3Cg7vz9TssMl09/WXHRIr0 6fxA== X-Gm-Message-State: AOAM531HGXiMIZ28y6AGyBrJMw6drmXigUr1eg6n/6e0tszL4mEytxay 2wErcn2O9r43EogXAMwf84w= X-Google-Smtp-Source: ABdhPJwhquhdyadjRnL3qTRYtjDjowp+Dy+5jWMxKEWNfUDZ92AWWJoDIMWjoohF24QAQm7wqgvfXw== X-Received: by 2002:a05:6000:108e:: with SMTP id y14mr2492718wrw.69.1640089977772; Tue, 21 Dec 2021 04:32:57 -0800 (PST) Received: from morpheus.home.roving-it.com (a.7.4.5.7.2.7.b.4.1.9.2.a.3.0.0.1.8.6.2.1.1.b.f.0.b.8.0.1.0.0.2.ip6.arpa. [2001:8b0:fb11:2681:3a:2914:b727:547a]) by smtp.googlemail.com with ESMTPSA id az11sm2168479wmb.30.2021.12.21.04.32.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Dec 2021 04:32:57 -0800 (PST) From: Peter Robinson To: Stefano Babic , Fabio Estevam , Breno Lima , Francesco Montefoschi , u-boot@lists.denx.de Cc: Peter Robinson Subject: [PATCH 1/4] udoo_neo: Call gpio_request() Date: Tue, 21 Dec 2021 12:32:46 +0000 Message-Id: <20211221123249.455347-1-pbrobinson@gmail.com> X-Mailer: git-send-email 2.33.1 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.38 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Calling gpio_request() prior to its usage is now mandatory. This fixes the following GPIO errors: gpio@20a8000: set_dir_flags: error: gpio GPIO4_16 not reserved gpio@20a8000: set_dir_flags: error: gpio GPIO4_13 not reserved gpio@20a8000: set_dir_flags: error: gpio GPIO4_0 not reserved gpio@20a8000: get_value: error: gpio GPIO4_13 not reserved gpio@20a8000: get_value: error: gpio GPIO4_0 not reserved gpio@20a0000: set_dir_flags: error: gpio GPIO2_1 not reserved gpio@20a0000: set_value: error: gpio GPIO2_1 not reserved Fixes: 191840ae99 ("ARM: imx: udoo_neo: Enable OF_CONTROL and DM gpio/pin control") Signed-off-by: Peter Robinson Reviewed-by: Fabio Estevam --- board/udoo/neo/neo.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/board/udoo/neo/neo.c b/board/udoo/neo/neo.c index ce005d31cc..61195be744 100644 --- a/board/udoo/neo/neo.c +++ b/board/udoo/neo/neo.c @@ -249,6 +249,7 @@ static int setup_fec(void) ARRAY_SIZE(phy_control_pads)); /* Reset PHY */ + gpio_request(IMX_GPIO_NR(2, 1), "enet_rst"); gpio_direction_output(IMX_GPIO_NR(2, 1) , 0); udelay(10000); gpio_set_value(IMX_GPIO_NR(2, 1), 1); @@ -280,6 +281,7 @@ int board_init(void) ARRAY_SIZE(peri_3v3_pads)); /* Active high for ncp692 */ + gpio_request(IMX_GPIO_NR(4, 16), "ncp692"); gpio_direction_output(IMX_GPIO_NR(4, 16) , 1); #ifdef CONFIG_SYS_I2C_MXC @@ -296,6 +298,8 @@ static int get_board_value(void) imx_iomux_v3_setup_multiple_pads(board_recognition_pads, ARRAY_SIZE(board_recognition_pads)); + gpio_request(IMX_GPIO_NR(4, 13), "r184"); + gpio_request(IMX_GPIO_NR(4, 0), "r185"); gpio_direction_input(IMX_GPIO_NR(4, 13)); gpio_direction_input(IMX_GPIO_NR(4, 0));