Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3931274pxj; Mon, 21 Jun 2021 09:37:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyH8zkseQNRX2GQ7JZ4AoyfA6mDoqa0RgN8yxSe948LWUWREEwC8Un94gCOdQYuYjL8nlNC X-Received: by 2002:a17:907:9ec:: with SMTP id ce12mr24927630ejc.434.1624293451235; Mon, 21 Jun 2021 09:37:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624293451; cv=none; d=google.com; s=arc-20160816; b=NQ6EeJOjyXgInDhpiws8MXWzErNTyvQ5MXp2yD4gQoyvq8+j/CUDngJ873q0f1PYP3 Nlfw1ZAXSHth9oUQbYfNnzYaYtUuoFZ6js8J0FPjIGRdZHoC3Fs/hwkmlls6AUhYVLL4 TerOTleJSw/ZRugd8r/qTIu8w4WgioGiWp9XyfM0fw7Q3VATMlxpZzTcIUilyeiGwQK1 YqovG7z9j2QdFHuFKgRARDalBzdFQptKCg3sXCy2+P+170HhJAM16yCf+j9byGp9EL8p 7b6ccrcbmwB7/IhzXbWJsMBG+mlzbUErSP11V05QJGHqVVpnqXyqMxG50zEZm3DdcF+5 zf2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=nxfGB0xDq/d3gucCZPno6/P+osLPzdB0vRXt8QT3xSM=; b=IqdUj/1nxsG9EyD5NEKX96uTifMP93yJmPPOBf3MCqABuhcvShyWwof+7EVZ7z7B8M 4F0/5WoWdMLXRCC8KZWzr9TPRiXBn8dwPzmmV8IndGkAs0ni3z6or+BB+lGLjZ4qbr5S oueFJhhn1zf7/PRJqrMu5dRdw2vPdQvrxs8QpMQPX8eDo4KapX2DOD9idYZl9JCW3Osy s07+UQA9uCdJlow0TMv3nnHhM15Z2/6I+PP3xovMTBXhAejyzTgTDb5+J+V2FS0nIbKy 3c4J5/bxkcRQ8Gz7GuoVpDx5Jj22L8fBWalvEwjdbG5M/mU7GhayPq5bRRskBBkCF3kr fKyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=SmAAWikZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hr40si11228112ejc.41.2021.06.21.09.37.08; Mon, 21 Jun 2021 09:37:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=SmAAWikZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232456AbhFUQgT (ORCPT + 99 others); Mon, 21 Jun 2021 12:36:19 -0400 Received: from mail.kernel.org ([198.145.29.99]:55398 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232239AbhFUQcc (ORCPT ); Mon, 21 Jun 2021 12:32:32 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 83B0E613C2; Mon, 21 Jun 2021 16:26:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1624292765; bh=fU13to9nu0aO8QZO1mX+8wtj7oG7zYJNoYFpZBMBe8w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=SmAAWikZ1SE1IWFY8XvLhkr4agUKenFjg//h+eDZjggvIJLw0UdqsGfq9ZM6zZ5vh lAIXeeJZXbHCQMnd9s+ho6pRVqBD3+/syR0C/msIN1Noi1w2fgheo5A3YM8CM3G/NI i3F5Ryeno2tLXJnNL/zymapLNI8g11UTuTAlsLwQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sergio Paracuellos , Linus Walleij , Sasha Levin Subject: [PATCH 5.10 088/146] pinctrl: ralink: rt2880: avoid to error in calls is pin is already enabled Date: Mon, 21 Jun 2021 18:15:18 +0200 Message-Id: <20210621154916.667453687@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210621154911.244649123@linuxfoundation.org> References: <20210621154911.244649123@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sergio Paracuellos [ Upstream commit eb367d875f94a228c17c8538e3f2efcf2eb07ead ] In 'rt2880_pmx_group_enable' driver is printing an error and returning -EBUSY if a pin has been already enabled. This begets anoying messages in the caller when this happens like the following: rt2880-pinmux pinctrl: pcie is already enabled mt7621-pci 1e140000.pcie: Error applying setting, reverse things back To avoid this just print the already enabled message in the pinctrl driver and return 0 instead to not confuse the user with a real bad problem. Signed-off-by: Sergio Paracuellos Link: https://lore.kernel.org/r/20210604055337.20407-1-sergio.paracuellos@gmail.com Signed-off-by: Linus Walleij Signed-off-by: Sasha Levin --- drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c index caaf9e34f1ee..09b0b8a16e99 100644 --- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c +++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c @@ -127,7 +127,7 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev *pctrldev, if (p->groups[group].enabled) { dev_err(p->dev, "%s is already enabled\n", p->groups[group].name); - return -EBUSY; + return 0; } p->groups[group].enabled = 1; -- 2.30.2