Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp310284rdh; Thu, 26 Oct 2023 02:58:20 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGznaanpE/qUpHhh9m5W0dbyIXHdawXZD1/vSSSiNm2sk1kj1Sru0zlz6rGX0WReucvu6ze X-Received: by 2002:a25:4212:0:b0:d9a:b7cd:47f5 with SMTP id p18-20020a254212000000b00d9ab7cd47f5mr16981239yba.56.1698314299935; Thu, 26 Oct 2023 02:58:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698314299; cv=none; d=google.com; s=arc-20160816; b=ikb3bHxKmdV/tx6m0g/rHjY1ewCze7UbW89eNGujp8uHsloDnnRUljaZ3qrCJbSZqD SJZFTTJjvt5cgd4uFuF+7YX83WfxQYz0xxxq6qHJmmwhC+R8MDvDS2F04d4aYdv/jI4U vIDZu7uAqcWBjbRCKNNnp5PgJ66sq/oaNx+JtRk8D0HSaBYIOhFHChnssgOqBwTNsVvY IfCDkKUHBhKZnlz8SpN6iHdPmTtREQYRihyWOki/3cgK5scgbXeMwT0i6Umy9VYuU7y0 hYk5YWk3j0Y//kIaJWNbJgwUZuYGW/oiWRLQudC7CtOITkOiVX71xGyvcRjoZ1x9yhDt jeQA== 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=9KIvM94Zo8czLYhdT3nLKb2AOCp1EA16AmR4SZgO/t4=; fh=B1Vvp0bHhNgFlEShYESroF9prv6US+gO+RZm4rcjB08=; b=DWFhXbUULsnLF3YaDvwIa4kiGbMfVLTimjHYKITPbe4s2WetZ/BiSUUVVDB11j5DLl tMlk4iy2Qp4rDCGn4BQ+aw5my1Lu5yAdEVCgbtJqftcCgHXPovEOqDe6W+AFdE0v/Z4X EKmpJxqNR7DJqIZttQ3H5hza5u2iEx9pVsSZo9pRsbacbTOhSu06B2KQBuF/b4f/MRGM Mcu1dOPfsLifcZpv8T2w1689q5+1CLrNKph63LUL8pMRrtJv8GVxMG8LgXmmgUDWRupp GblrJa8NYRusjg9KVUIVq1BIqmlamVKVUeoo5hRzNjspQSq4L1rrBWvjOD4FfoyUREOV YAfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=NEt5wwqI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 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 pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id b7-20020a253407000000b00d9ac09b7ea5si12685746yba.102.2023.10.26.02.58.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Oct 2023 02:58:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=NEt5wwqI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 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 pete.vger.email (Postfix) with ESMTP id DBE5081C0C1C; Thu, 26 Oct 2023 02:58:16 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229934AbjJZJ6L (ORCPT + 99 others); Thu, 26 Oct 2023 05:58:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229518AbjJZJ6K (ORCPT ); Thu, 26 Oct 2023 05:58:10 -0400 Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DCE7A93; Thu, 26 Oct 2023 02:58:07 -0700 (PDT) Received: by mail-ej1-x633.google.com with SMTP id a640c23a62f3a-9bf0ac97fdeso108604466b.2; Thu, 26 Oct 2023 02:58:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698314286; x=1698919086; 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=9KIvM94Zo8czLYhdT3nLKb2AOCp1EA16AmR4SZgO/t4=; b=NEt5wwqImRgDWauETNXA/+jsOSV/bAbMRs4dBNT7cfzWdx6QEOBGMXqbrgyAjDGy/7 Hr9JirvRT5DeB6wZfZ6tFtvh9+aMKdz7LKsU/V/4veYb/hrLGwTOZcYx0j/J62qKbdCI tgxAWfn0AcXuPISxqqeOb3c+A/drBmfflaVr8CIp8AsKrVmO4mKs0Qff6pZjy3qj5Ufx akde5aojA3aLHl9v2oqO/xEY24bE5/MRAyy91q4GxUv6JkMl51fQvz7Cr7LM7t0FF4Ta 4oVAXDsKgxccPbXQUYIZJ88yjf8oQb3C0qjyh3wkkYFIj6pdg97BC+vfV2BLoa3OT7Ov BGlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698314286; x=1698919086; 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=9KIvM94Zo8czLYhdT3nLKb2AOCp1EA16AmR4SZgO/t4=; b=N6vRd4e+QkIhSCtbz710e7guKNQqMixRqqstFYofbnCo5PmPLUVkSrdVmab5CD043r jVTqUZzOfniG8z6M0svhE2+9DL91aEwiF01MKwU0RV+OpS+6/jCaWDOEGssY5KYJppzd miIfeWIchzju/tbiR7AXQa/BqMbhUBP7wL8JA3tD9preyX65pTf55SwbZuNoriSDTFck jBBv358uk50rRhLvh+3F939MEMr2fFAUUY3d+KO5TOCnbGLc7xH2dxq7pSZUyRFYW76P 3tT3pucZESR8AC8LX/p8NInXjAqMcKyxSWjTgzBYiJsJnVwX5D1OIKNvz4vo6wuH+eWq 4aMQ== X-Gm-Message-State: AOJu0Yxsc9ddX5Qn72I2jkBotTlthOpTN9FGgWhvndp2QFmY6tN8Vb8b JtdHVbuPOPbBMhlA4Ml+qU8= X-Received: by 2002:a17:907:841:b0:9c7:3611:9e7c with SMTP id ww1-20020a170907084100b009c736119e7cmr13848003ejb.61.1698314286213; Thu, 26 Oct 2023 02:58:06 -0700 (PDT) Received: from skbuf ([188.26.57.160]) by smtp.gmail.com with ESMTPSA id n13-20020a170906088d00b0098ec690e6d7sm11396113eje.73.2023.10.26.02.58.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Oct 2023 02:58:05 -0700 (PDT) Date: Thu, 26 Oct 2023 12:58:03 +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 v8 1/5] net: dsa: microchip: ksz9477: Add Wake on Magic Packet support Message-ID: <20231026095803.a54uni73ugwm33sg@skbuf> References: <20231026051051.2316937-1-o.rempel@pengutronix.de> <20231026051051.2316937-1-o.rempel@pengutronix.de> <20231026051051.2316937-2-o.rempel@pengutronix.de> <20231026051051.2316937-2-o.rempel@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231026051051.2316937-2-o.rempel@pengutronix.de> <20231026051051.2316937-2-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 pete.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 (pete.vger.email [0.0.0.0]); Thu, 26 Oct 2023 02:58:17 -0700 (PDT) On Thu, Oct 26, 2023 at 07:10:47AM +0200, Oleksij Rempel wrote: > Introduce Wake on Magic Packet (WoL) functionality to the ksz9477 > driver. > > Major changes include: > > 1. Extending the `ksz9477_handle_wake_reason` function to identify Magic > Packet wake events alongside existing wake reasons. > > 2. Updating the `ksz9477_get_wol` and `ksz9477_set_wol` functions to > handle WAKE_MAGIC alongside the existing WAKE_PHY option, and to > program the switch's MAC address register accordingly when Magic > Packet wake-up is enabled. This change will prevent WAKE_MAGIC > activation if the related port has a different MAC address compared > to a MAC address already used by HSR or an already active WAKE_MAGIC > on another port. > > 3. Adding a restriction in `ksz_port_set_mac_address` to prevent MAC > address changes on ports with active Wake on Magic Packet, as the > switch's MAC address register is utilized for this feature. > > Signed-off-by: Oleksij Rempel > Reviewed-by: Florian Fainelli > --- Reviewed-by: Vladimir Oltean