Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp2332270pxb; Tue, 12 Oct 2021 04:30:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz5iqlfIN4eodU8dLNB4kqrKARO7gNtg5DclalHU9zwluAKhafT9wz8Dw7yE5Jr+In+vveg X-Received: by 2002:a17:90b:3687:: with SMTP id mj7mr5461366pjb.196.1634038247233; Tue, 12 Oct 2021 04:30:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634038247; cv=none; d=google.com; s=arc-20160816; b=n5g2Er61qyuV9YCuMR19VevJx0qlZHE7wojm2q3Gf7f2bvTJtPK2IIv2jHsid2a5Uu 7PCiaAiYkBhsBnUCOVuGiQSuNkqVUWHzO5VfuqyEequvU36JukifE53aEg40zzJzwRxQ /CVclM9ywtZnqgK+yUsfr6zXvDU4bK471wVSjfPpu/tY6IlEMa7pLT9QqYC1tSXezjF0 ynOEA82o3uhB5Dk3ZL4D3kBLn5uS+WTdq85WIl+DgUOTp3gDyWLScd46owufDTiUvLnj qnIwCrIopjrGpoB4oreTbwrxPqL/sLZS0bUIqCdwqOGCAMLsAChSMz9+7dKTwyNWtV/j ya5w== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=US79hu+z+ZmdLEx+n+35ycCt5zvqCoMc3ZuPWPCa08M=; b=BhIKPplTMn0bxpekr3rq5qMvZm9eW9ygOu8g5iQc4dvkRPbGeNINd0XVLtROAuzju0 EEMlg8H6IQl7DBk880WNJRMSuZwpdg/5hkiIUkrctkNd9F1Sq/1Cjj7ZdUD+4fKe5OU6 FjQfznUxCZEsp1sViPcN0MjTVw0VV+Qf0R8sxG8wA7DIfg2pFSsw4P95jHkJ2D7W9E6f AJnz5iUjwalzwNbrNcV9UTHQL8MoSPOYffvi7eh70fDGiWQgPiETJjBJlDwwXeMl/1c4 X8G4VPrBDui9jcUqOnwU2NIVcd59Fdci46mhLUCTIRX5tGieFQKV9iPeg0fMmxTFaXaA 0O7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=temperror (no key for signature) header.i=@pqrs.dk header.s=google header.b=bCiELY98; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p1si14086315plq.398.2021.10.12.04.30.34; Tue, 12 Oct 2021 04:30:47 -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=temperror (no key for signature) header.i=@pqrs.dk header.s=google header.b=bCiELY98; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236032AbhJLLaX (ORCPT + 99 others); Tue, 12 Oct 2021 07:30:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236163AbhJLLaU (ORCPT ); Tue, 12 Oct 2021 07:30:20 -0400 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 62E67C061570 for ; Tue, 12 Oct 2021 04:28:18 -0700 (PDT) Received: by mail-ed1-x534.google.com with SMTP id w19so19895730edd.2 for ; Tue, 12 Oct 2021 04:28:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pqrs.dk; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=US79hu+z+ZmdLEx+n+35ycCt5zvqCoMc3ZuPWPCa08M=; b=bCiELY98sLaojn9ni1TPwcJLqGrrcs3c6I73IRDj87HQ3umlmaTTrk8z8bL6gZFfRJ MiBTF8VnwMkjQ4p8Gw+txhBfpewI8btttI3iG/Err+xH0qOYjQtzK4WWlw84yBlZv1nt eb8OgeiZ0ZssVcGm0Pl8JtdZCUQO10i0se5k0= 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=US79hu+z+ZmdLEx+n+35ycCt5zvqCoMc3ZuPWPCa08M=; b=uP/WTd9q4Get26DvbMDt6PaxhIVrtNdQGfShQxysEB+yRZF9l8SMkDHqiMyHkRNCDf kSaohqJ70bvNSKfy8T0Kg34+HWLtibZ2WzMhnVJo2B10fxLCk5HdZRSfYTlKrV0GC9iI iAx0ueog+zes8CSX722kEKaEDOuzAI/hW2e+FeS8O3UebGB0E/AGm3goEdvBmJu8DAjQ lLs7AkFkwgatcO6r69OyjnbjPKWdRUv+n2nhUo8BtHXYTkd/GvmG8tq8/fhDAmzSPneW dldq6dRLcSCY18P7/ihrdsdNbLOFsQcsWV+rVPCE/4xIAUNYREg9jWAuTBWgJX4fU55b Ztuw== X-Gm-Message-State: AOAM533zZM5/zRQ9lCi3QQwUIXDmKt2b09al4jRL+mZBZ14HGMYI7lAr V9GYQ2MSqq+5tfQvrVvbO6vhAaRpFI32rFf4 X-Received: by 2002:a50:9d8e:: with SMTP id w14mr49589825ede.74.1634038096916; Tue, 12 Oct 2021 04:28:16 -0700 (PDT) Received: from capella.. (27-reverse.bang-olufsen.dk. [193.89.194.27]) by smtp.gmail.com with ESMTPSA id l5sm4637862ejx.76.2021.10.12.04.28.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Oct 2021 04:28:16 -0700 (PDT) From: =?UTF-8?q?Alvin=20=C5=A0ipraga?= To: Andrew Lunn , Vivien Didelot , Florian Fainelli , Vladimir Oltean , "David S. Miller" , Jakub Kicinski Cc: =?UTF-8?q?Alvin=20=C5=A0ipraga?= , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH net] net: dsa: fix spurious error message when unoffloaded port leaves bridge Date: Tue, 12 Oct 2021 13:27:31 +0200 Message-Id: <20211012112730.3429157-1-alvin@pqrs.dk> X-Mailer: git-send-email 2.32.0 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: Alvin Šipraga Flip the sign of a return value check, thereby suppressing the following spurious error: port 2 failed to notify DSA_NOTIFIER_BRIDGE_LEAVE: -EOPNOTSUPP ... which is emitted when removing an unoffloaded DSA switch port from a bridge. Fixes: d371b7c92d19 ("net: dsa: Unset vlan_filtering when ports leave the bridge") Signed-off-by: Alvin Šipraga --- net/dsa/switch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/dsa/switch.c b/net/dsa/switch.c index 1c797ec8e2c2..6466d0539af9 100644 --- a/net/dsa/switch.c +++ b/net/dsa/switch.c @@ -168,7 +168,7 @@ static int dsa_switch_bridge_leave(struct dsa_switch *ds, if (extack._msg) dev_err(ds->dev, "port %d: %s\n", info->port, extack._msg); - if (err && err != EOPNOTSUPP) + if (err && err != -EOPNOTSUPP) return err; } -- 2.32.0