From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 67964C433F5 for ; Thu, 21 Oct 2021 04:53:14 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 4907C61130 for ; Thu, 21 Oct 2021 04:53:13 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4907C61130 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=sholland.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9E838833E4; Thu, 21 Oct 2021 06:53:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=sholland.org 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=sholland.org header.i=@sholland.org header.b="K9mPYO0Q"; dkim=pass (2048-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="Pe+Hxb/Z"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 27DC48326F; Thu, 21 Oct 2021 06:53:08 +0200 (CEST) Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 8EB6A833E3 for ; Thu, 21 Oct 2021 06:53:04 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=sholland.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=samuel@sholland.org Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id C5DC55C0069; Thu, 21 Oct 2021 00:53:03 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 21 Oct 2021 00:53:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sholland.org; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; s=fm1; bh=30+YNr3MbL8HF jNScHkw1P+KrGpQb/m54IkTS3nWxdM=; b=K9mPYO0Q7GZCOQiISbmNVlbsTmC96 nR/776bFbSKd4eG9Jg0dXEeVB+so2tVACmVecagAoXLv/XamKLdBRhd7+FasvyyG ljRWMqQdq+ZxCL4L6s9DPLqyHEwZw072N+kxE21achaIVt2ngMb+7wkZ52HRFYhv 42wqXnfih6RQCVm3WH/LkagOrl9lICwWFHiv9ingVHvpwKC9BUeR7ufxUNh0v+Vu 2JfAPEQDD5wVZThNP7iBiAnd1UldbYJfZqy4zsDXLvlYZiT2GNTJtCrr7V9CE8cl LS03JvDULb+AN8+3E6CLn7jzceEghLLZUC2xKvD9gZy8rL/fcgKNycniA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=30+YNr3MbL8HFjNScHkw1P+KrGpQb/m54IkTS3nWxdM=; b=Pe+Hxb/Z mf97Mo2KjVfZ4js7CEXiCfzvgdoedbd2x3bRXde4s5lpr8XchQEXlbt1C+beIKI3 NpQvaBtSg/U2vi0eBezVX3Ej2C/mLO83UbH2izrsQTga2DOuVlMhUqXpQbnVJScE XPkNMlTqDblmOfDINb/LsDENE4EbTqLvLTaNrQaNXZzW7gMVKFzkxrThauJ3o1jU oyzSx8wE8Cy8/QTPmulyqngbnJQW3X3lntGlDbMDFI6tm/ipeDSG2/Lxw/ah/Y4p RsFx0YgusKujyPNOtDwZBthoEkhxyrwluqmxLgCv8HQZr1rebBJpuBnWK+bgma6y Zmtof4j7tE1POw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvtddrvddvhedgkedvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkffojghfggfgsedtkeertdertddtnecuhfhrohhmpefurghmuhgv lhcujfholhhlrghnugcuoehsrghmuhgvlhesshhhohhllhgrnhgurdhorhhgqeenucggtf frrghtthgvrhhnpeduhfejfedvhffgfeehtefghfeiiefgfeehgfdvvdevfeegjeehjedv gfejheeuieenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhroh hmpehsrghmuhgvlhesshhhohhllhgrnhgurdhorhhg X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 21 Oct 2021 00:53:02 -0400 (EDT) From: Samuel Holland To: u-boot@lists.denx.de, Jagan Teki , Andre Przywara Cc: Samuel Holland , Andy Shevchenko , Icenowy Zheng , Jaehoon Chung , Jernej Skrabec , Peng Fan , Simon Glass Subject: [PATCH 1/4] sunxi: gpio: Return void from setter functions Date: Wed, 20 Oct 2021 23:52:54 -0500 Message-Id: <20211021045258.30757-2-samuel@sholland.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211021045258.30757-1-samuel@sholland.org> References: <20211021045258.30757-1-samuel@sholland.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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 The return values of these functions are always zero, and they are never checked. Since they are not needed, remove them. Signed-off-by: Samuel Holland --- arch/arm/include/asm/arch-sunxi/gpio.h | 4 ++-- arch/arm/mach-sunxi/pinmux.c | 8 ++------ 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h index f3ab1aea0e..2b72b2263b 100644 --- a/arch/arm/include/asm/arch-sunxi/gpio.h +++ b/arch/arm/include/asm/arch-sunxi/gpio.h @@ -226,8 +226,8 @@ void sunxi_gpio_set_cfgbank(struct sunxi_gpio *pio, int bank_offset, u32 val); void sunxi_gpio_set_cfgpin(u32 pin, u32 val); int sunxi_gpio_get_cfgbank(struct sunxi_gpio *pio, int bank_offset); int sunxi_gpio_get_cfgpin(u32 pin); -int sunxi_gpio_set_drv(u32 pin, u32 val); -int sunxi_gpio_set_pull(u32 pin, u32 val); +void sunxi_gpio_set_drv(u32 pin, u32 val); +void sunxi_gpio_set_pull(u32 pin, u32 val); int sunxi_name_to_gpio(const char *name); #if !defined CONFIG_SPL_BUILD && defined CONFIG_AXP_GPIO diff --git a/arch/arm/mach-sunxi/pinmux.c b/arch/arm/mach-sunxi/pinmux.c index 642483f06c..cf9d9daf7c 100644 --- a/arch/arm/mach-sunxi/pinmux.c +++ b/arch/arm/mach-sunxi/pinmux.c @@ -45,7 +45,7 @@ int sunxi_gpio_get_cfgpin(u32 pin) return sunxi_gpio_get_cfgbank(pio, pin); } -int sunxi_gpio_set_drv(u32 pin, u32 val) +void sunxi_gpio_set_drv(u32 pin, u32 val) { u32 bank = GPIO_BANK(pin); u32 index = GPIO_DRV_INDEX(pin); @@ -53,11 +53,9 @@ int sunxi_gpio_set_drv(u32 pin, u32 val) struct sunxi_gpio *pio = BANK_TO_GPIO(bank); clrsetbits_le32(&pio->drv[0] + index, 0x3 << offset, val << offset); - - return 0; } -int sunxi_gpio_set_pull(u32 pin, u32 val) +void sunxi_gpio_set_pull(u32 pin, u32 val) { u32 bank = GPIO_BANK(pin); u32 index = GPIO_PULL_INDEX(pin); @@ -65,6 +63,4 @@ int sunxi_gpio_set_pull(u32 pin, u32 val) struct sunxi_gpio *pio = BANK_TO_GPIO(bank); clrsetbits_le32(&pio->pull[0] + index, 0x3 << offset, val << offset); - - return 0; } -- 2.32.0