Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp509306rdb; Thu, 19 Oct 2023 10:25:35 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFI7Dg3WZfG1H+NOHroN7XdvEWRYwA5h7v16OICys3tjKYcmtz8EZ0RFoLTS2UgS4Wg1Q5B X-Received: by 2002:a05:6a20:1592:b0:12f:c0c1:d70 with SMTP id h18-20020a056a20159200b0012fc0c10d70mr2600074pzj.40.1697736335339; Thu, 19 Oct 2023 10:25:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697736335; cv=none; d=google.com; s=arc-20160816; b=b1N7B4CcJZnkGAt0HwsImLXa7uQ0WearozKzr0XuRN+lGW7LL/h7keOfZ5HEz8uzPh vSrHkS1GTitNjSqvDZo6z31uZ8Ac2JAocoDCf+gRjrQ/z3Rf4hPuXytt5bHX2+Z/5aa1 pfBlHhzowKH/cvEkn+YSyKRuaqK2wpTl2VXN4d+SUK2WUugC3jXgZNMMrv6Qagd8ZaXt 4XEo3Ce0GaIf5fKRR8KZtroQenSVuOs5/Fj3xeA1+sU7w7Xb5uRMtqCJN32x9mUEliM9 2Q4EgUhn+huAXOG4klTEXIXCYmzYorKvDy1Fr3AXCZtM/VwKYcJFVVur1y8Mxxv+bWdc GqDw== 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-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=tnjx/g75TQ9FU2jTkV4DiWvBfVCxrF8QEzTIbCBryMQ=; fh=B1Vvp0bHhNgFlEShYESroF9prv6US+gO+RZm4rcjB08=; b=nWjjRFoACOJwMC/d9c68bm+GHa+SI0/GV4ZmRA9QFM7nR/xXZtM0aRg3aQeerrOeia URrKwftnEOq0SLGVJOkkGKeuZ59Aq8b2E9bHSt7jMDS/+zfOmrg6nVFbqSWMda4/2GKm ulQ6Vyfd3jdfQnWbDtNfRRcbvzK63rpEDg52leCciN9CM85NDRYy7h3P3IYNSXjdOUut ra+qZYL5RrZFxRn5M2GctT08srYwy5O6E9WgWrQkJwZq9B7cOT8afkG0ssqi/aD436Fa pTRbezBx8+S7LEQbCtVr7/sfptpEqygyKa2GJMyMwXE/pp7efY0oax/gLXg656t8LeSU z/0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=ggqdpCBS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 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 agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id j4-20020a170903028400b001ca110d482csi2772352plr.573.2023.10.19.10.25.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 10:25:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=ggqdpCBS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id DDCCD81B456C; Thu, 19 Oct 2023 10:25:32 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345827AbjJSRZW (ORCPT + 99 others); Thu, 19 Oct 2023 13:25:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57468 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235476AbjJSRZU (ORCPT ); Thu, 19 Oct 2023 13:25:20 -0400 Received: from mail-lf1-x12d.google.com (mail-lf1-x12d.google.com [IPv6:2a00:1450:4864:20::12d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF685CF; Thu, 19 Oct 2023 10:25:18 -0700 (PDT) Received: by mail-lf1-x12d.google.com with SMTP id 2adb3069b0e04-507c50b7c36so3740205e87.3; Thu, 19 Oct 2023 10:25:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1697736317; x=1698341117; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=tnjx/g75TQ9FU2jTkV4DiWvBfVCxrF8QEzTIbCBryMQ=; b=ggqdpCBS0pmk74rY44ASsOdZskI/M/PydYRYE2HvSeqBtfe1j3kkVtg1ScM5Pucbpo 8TbmeMeR8UQ7VTlmXp99WSl4d4fiOaH7xOhfNwLWFpt3nzBATYouaxggGGANIq/iZ6RI OlLcdG7FxSwEKztXYf6A11VcM0srGzht1Rd2cbT8ZeiUq3E9hiZwD9ddzU4/gd97v4RV RwcmtzPhbPENn7DWY62/HqNTCWm2lyVw1B0QgAr8MLmvCV8L6lanDD6Z/Bd8EByBeJ36 Av2c7CP1ol+sR+ZyJ+FIeSXWsdHCT3E4s03RupQ9Pqnadh2XpYN1Ou+E6WGS0V+EDNp0 McJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697736317; x=1698341117; h=in-reply-to: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=tnjx/g75TQ9FU2jTkV4DiWvBfVCxrF8QEzTIbCBryMQ=; b=iez58jUOVrof/aieTBs3RvXWXS25Zk/tnRn3vp5DIihYzHNXk2bDtJRl/96aF9TPwn IAkS4XIVSSwAE1rIthfIAxfpGuLdceQo7HIFM+nvSU827KiGeL7XjhYoqT1kmMNmc7ME qhuYBPgID6GW/U6VfmepRd/J91b5upFpGqsKLoE7s9D4neYNLEVdKJJGr4X0RRRgavNr Wlhu/mhjlC//A5Ms3Hcfg4Eu7GNO9VnAndvehWN3KDo28EPRYVqCHgaHdCgisxUHzyVm tB/TFkkR880sf9OQdh6GixtcR25Tfk1RmFwP0V2h6Klx4gUIUgLu8jw2dzg/RHM8Pzvz SpDg== X-Gm-Message-State: AOJu0Yy3NM14KmujbwB0f4YBaWgVHhOfZb9nCYRGfEsy0IYnQFB+3dpa TQmrTWVX4lRrg61WujNt80E= X-Received: by 2002:a05:6512:515:b0:504:30eb:f2ac with SMTP id o21-20020a056512051500b0050430ebf2acmr1955852lfb.68.1697736316689; Thu, 19 Oct 2023 10:25:16 -0700 (PDT) Received: from skbuf ([188.26.57.160]) by smtp.gmail.com with ESMTPSA id fj27-20020a0564022b9b00b005309eb7544fsm4752188edb.45.2023.10.19.10.25.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 10:25:16 -0700 (PDT) Date: Thu, 19 Oct 2023 20:25:13 +0300 From: Vladimir Oltean To: Oleksij Rempel Cc: "David S. Miller" , Andrew Lunn , Eric Dumazet , Florian Fainelli , Jakub Kicinski , Paolo Abeni , Woojung Huh , Arun Ramadoss , Conor Dooley , Krzysztof Kozlowski , Rob Herring , Florian Fainelli , kernel@pengutronix.de, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, UNGLinuxDriver@microchip.com, "Russell King (Oracle)" , devicetree@vger.kernel.org Subject: Re: [PATCH net-next v6 8/9] net: dsa: microchip: Refactor switch shutdown routine for WoL preparation Message-ID: <20231019172513.el67tdxnmcfc7l2g@skbuf> References: <20231019122850.1199821-1-o.rempel@pengutronix.de> <20231019122850.1199821-1-o.rempel@pengutronix.de> <20231019122850.1199821-9-o.rempel@pengutronix.de> <20231019122850.1199821-9-o.rempel@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231019122850.1199821-9-o.rempel@pengutronix.de> <20231019122850.1199821-9-o.rempel@pengutronix.de> X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Thu, 19 Oct 2023 10:25:33 -0700 (PDT) On Thu, Oct 19, 2023 at 02:28:49PM +0200, Oleksij Rempel wrote: > Centralize the switch shutdown routine in a dedicated function, > ksz_switch_shutdown(), to enhance code maintainability and reduce > redundancy. This change abstracts the common shutdown operations > previously duplicated in ksz9477_i2c_shutdown() and ksz_spi_shutdown(). > > This refactoring is a preparatory step for an upcoming patch to avoid > reset on shutdown if Wake-on-LAN (WoL) is enabled. > > Signed-off-by: Oleksij Rempel > Reviewed-by: Florian Fainelli > --- Reviewed-by: Vladimir Oltean