From patchwork Mon Oct 5 15:26:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 268123 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4F102C46466 for ; Mon, 5 Oct 2020 15:39:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 13329206DD for ; Mon, 5 Oct 2020 15:39:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601912360; bh=RuIy+oBQXSvf5mse+Z28ABsLBNoDwgE1iFj9PdPuDHE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=sycpBF2nSivOHlBun5hpLYXTvBX+UTHfEiO1NeHvJmZQYBMcmMqMnzE7K/7nDeaH6 62ud5zDOYJvgmtrJI5Yq6KHjqdkEw35AUyoirpH88IKKzeIo53HKw1Vxok6VoCOLo0 y9AFyRzbCM121lRgP4/kgFgo0lpv36/VPZJGbygs= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728651AbgJEPjT (ORCPT ); Mon, 5 Oct 2020 11:39:19 -0400 Received: from mail.kernel.org ([198.145.29.99]:56288 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727723AbgJEPaD (ORCPT ); Mon, 5 Oct 2020 11:30:03 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5AEB92085B; Mon, 5 Oct 2020 15:30:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601911801; bh=RuIy+oBQXSvf5mse+Z28ABsLBNoDwgE1iFj9PdPuDHE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=wERiVgBVelwRYjDnRpVV7EUfdtdmN+Fn6EAkEm/VgUAa51eBKwO6PCxujbh2rRutf LnziambYV0vh3jUt1NzF4WtxsDt4AaiwNkukXFEFqx8+pYsRTD7jf2cKJgHbqUkKoP pnv2WdHFK3y2tp+J43gNv+/yFZZqBMHaumv0v1UM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Tao Ren , Andrew Jeffery , Bartosz Golaszewski , Sasha Levin Subject: [PATCH 5.4 42/57] gpio: aspeed: fix ast2600 bank properties Date: Mon, 5 Oct 2020 17:26:54 +0200 Message-Id: <20201005142111.825582591@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201005142109.796046410@linuxfoundation.org> References: <20201005142109.796046410@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Tao Ren [ Upstream commit 3e640b1eec38e4c8eba160f26cba4f592e657f3d ] GPIO_U is mapped to the least significant byte of input/output mask, and the byte in "output" mask should be 0 because GPIO_U is input only. All the other bits need to be 1 because GPIO_V/W/X support both input and output modes. Similarly, GPIO_Y/Z are mapped to the 2 least significant bytes, and the according bits need to be 1 because GPIO_Y/Z support both input and output modes. Fixes: ab4a85534c3e ("gpio: aspeed: Add in ast2600 details to Aspeed driver") Signed-off-by: Tao Ren Reviewed-by: Andrew Jeffery Signed-off-by: Bartosz Golaszewski Signed-off-by: Sasha Levin --- drivers/gpio/gpio-aspeed.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/gpio-aspeed.c b/drivers/gpio/gpio-aspeed.c index 09e53c5f3b0a4..2820c59b5f071 100644 --- a/drivers/gpio/gpio-aspeed.c +++ b/drivers/gpio/gpio-aspeed.c @@ -1115,8 +1115,8 @@ static const struct aspeed_gpio_config ast2500_config = static const struct aspeed_bank_props ast2600_bank_props[] = { /* input output */ - {5, 0xffffffff, 0x0000ffff}, /* U/V/W/X */ - {6, 0xffff0000, 0x0fff0000}, /* Y/Z */ + {5, 0xffffffff, 0xffffff00}, /* U/V/W/X */ + {6, 0x0000ffff, 0x0000ffff}, /* Y/Z */ { }, };