Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp2632436rwl; Fri, 6 Jan 2023 08:58:29 -0800 (PST) X-Google-Smtp-Source: AMrXdXssZ0fpD8PeAfl4T4JcEkSbUZXTzZY/2fV9vQ/4tdmVFbMEKx1UdGluKKIEmHluNk2NHOsB X-Received: by 2002:a05:6a20:b059:b0:ac:21c3:2fb7 with SMTP id dx25-20020a056a20b05900b000ac21c32fb7mr72946525pzb.6.1673024308764; Fri, 06 Jan 2023 08:58:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673024308; cv=none; d=google.com; s=arc-20160816; b=bnqqRGuYbt53anFyA3i/MmvmoNYG2pQsqD6o7h4GFsKqhxI4R7BPe5+YtPfTjuBXbo WB+EqSCjVH1EcyzMJ/mxdXjW1DXvT3ipPF6QHaxFc+sKlouTb/jOq1yzBeQjnY0Hqt1f +HaU+Oi55J2MqNPeMpB2ZQp/dLdo13hnSD7f0LEkcWz416tLvNdICzANUCUjQuPC5nWm hn5BS9N8yxhai37BZ5KXz7TIVUuRpweiazpOF8jdmD86D3pAwVWBIQxsXUua2rjZHhjK 2wGv5gjYTjbO788m7sFA9RTDmeXCxfjzfaa9m+CIZxgs2wy7QwyEdsZf+byapep+RoLM 1+4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=cVVA+wtN3OwRb/Llt+vsUs/VHbWYd94vDiApWlf28eA=; b=upn8P6CZ6f1UbyJsCU+uS6G3xymWj4O2KDHVtmwYy0V6jwi/svZwhMZoM1qmwZP3mc +o2LhRYfa3ooadPRC+8EOgx3lRdkE/uK1pt00hJjIQpo1JEwPDeR7iiUvU0lUkxdPSDb kd9GCviJ8CYcsr3WL10pN16JJN2WJUlyL2WoMqpmALVFAzyW1H9t4MiDJIkc6/k0pek0 Y9dqX+Kf/B4SN6/VHeK1x0kHbpTXp5KQTLJ/F6pIi8pOf6pGuZJmiFRw0sVHhZUcZIBT EObNTOAWrwbeu21f6IKwk8uYEuA+/iwpmAymFo5kxC+DY0/T1UtsGbmOyfPQKv2c1rzc Dfmw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=ABQKaLwP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f10-20020a636a0a000000b004779bfce4ccsi1814840pgc.452.2023.01.06.08.58.21; Fri, 06 Jan 2023 08:58:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=ABQKaLwP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235673AbjAFQig (ORCPT + 56 others); Fri, 6 Jan 2023 11:38:36 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54682 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235545AbjAFQiF (ORCPT ); Fri, 6 Jan 2023 11:38:05 -0500 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E2CE078A5C; Fri, 6 Jan 2023 08:38:03 -0800 (PST) Received: by mail-ej1-x634.google.com with SMTP id fy8so4550739ejc.13; Fri, 06 Jan 2023 08:38:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=cVVA+wtN3OwRb/Llt+vsUs/VHbWYd94vDiApWlf28eA=; b=ABQKaLwPguTKBSF04UtKiM3TJSxZzUYPYoqdOYC0irtnhPMRygdoBOKLtHXbiD8bUh gfNHXwr7rpHSdc1rf3SuXySjrRn0uIGWfMlAHDpr3xUOYtTfkXvkxk+qQtt0AHr+aJXx nw7ULMBESX5IwdWftp8lQ4qRHYWP6Anw4z4817kQZF3LB48kTdchDpgoQW2Gf3UNqOgJ S9XzK9OthCMViShxcBtwrVzMdpjYgglyOGHaeZc2a38W5AJj0HsIHnh8upsQRiDGvjpE UpP0i7YxFFCu/WMqJs+zD17riwqXvGuI6o4aEHEn9j4xr3HGqi/p7LC6xbJnbPxIlezw r/NA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=cVVA+wtN3OwRb/Llt+vsUs/VHbWYd94vDiApWlf28eA=; b=6Yp1Lzij7+dIhRpvdZ5lYBS+x+MHfCzPrY11pXlVPxc3H2I5zQ3LDmoAqJZ+YySoz3 gy+QI12YHHClSVUr+P8CYK2l6x8s528fCIMIogz+sBe+sr7OcmaYe8Q9By1k7dboLl3i cd3tOooVhvGBDTfbo/QkS2rb5CRDkfampe5bdliBe+ptllfXRaT7J66Bon+LxTcfkZTN bPoPyzSMwiiJREKcNacxasrVVyU2QKGIrK+OLDPqyuSz4mGRZWuCuLsjZSQjEfcg5ZzU 9gSnqzsE5voS68U7pXNH/faablpFQ0UBArTXtKmB+/EWpmZaGIExiv/DDCK61lucexoe hD9A== X-Gm-Message-State: AFqh2kqaDm2bnQ9phpDzVkbvfpsFduAh7PbiJVgwnMIgsJagFqUQvbAr Uh20B36rLazFvMeokDeY/d0= X-Received: by 2002:a17:907:d601:b0:7c1:2d36:d11a with SMTP id wd1-20020a170907d60100b007c12d36d11amr54637846ejc.11.1673023082381; Fri, 06 Jan 2023 08:38:02 -0800 (PST) Received: from skbuf ([188.26.184.223]) by smtp.gmail.com with ESMTPSA id k8-20020a17090632c800b00780982d77d1sm546762ejk.154.2023.01.06.08.38.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Jan 2023 08:38:02 -0800 (PST) Date: Fri, 6 Jan 2023 18:37:59 +0200 From: Vladimir Oltean To: "Hans J. Schultz" Cc: davem@davemloft.net, kuba@kernel.org, netdev@vger.kernel.org, Andrew Lunn , Florian Fainelli , Eric Dumazet , Paolo Abeni , open list Subject: Re: [PATCH v3 net-next 2/3] net: dsa: mv88e6xxx: shorten the locked section in mv88e6xxx_g1_atu_prob_irq_thread_fn() Message-ID: <20230106163759.42jrkxuyjlg3l3s5@skbuf> References: <20230106160529.1668452-1-netdev@kapio-technology.com> <20230106160529.1668452-3-netdev@kapio-technology.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230106160529.1668452-3-netdev@kapio-technology.com> 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, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 06, 2023 at 05:05:28PM +0100, Hans J. Schultz wrote: > As only the hardware access functions up til and including > mv88e6xxx_g1_atu_mac_read() called under the interrupt handler > need to take the chip lock, we release the chip lock after this call. > The follow up code that handles the violations can run without the > chip lock held. > In further patches, the violation handler function will even be > incompatible with having the chip lock held. This due to an AB/BA > ordering inversion with rtnl_lock(). > > Signed-off-by: Hans J. Schultz > --- Needs to compile without new warnings patch by patch. ../drivers/net/dsa/mv88e6xxx/global1_atu.c: In function ‘mv88e6xxx_g1_atu_prob_irq_thread_fn’: ../drivers/net/dsa/mv88e6xxx/global1_atu.c:460:1: warning: label ‘out’ defined but not used [-Wunused-label] 460 | out: | ^~~ ../drivers/net/dsa/mv88e6xxx/global1_atu.c:460:1: warning: unused label 'out'