Received: by 2002:ab2:69cc:0:b0:1f4:be93:e15a with SMTP id n12csp1594631lqp; Mon, 15 Apr 2024 10:49:37 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW5bCLzRfdFZOV0Dhdg9rfRlntZhX/3r6R/V1dFo+yrjLL6r+8PaavrZiDiW45jFDglmW6burY+Q6Q/B+D/LA7uyH6RfJk/cbP5GNOtZg== X-Google-Smtp-Source: AGHT+IHf5Sxjmxze8Yf7VkRhhbwtjtaGUVRKV8TmEmn2bgvHCV6z+0GUVWeq6/IYOmQeXxkC08Wc X-Received: by 2002:a05:6a00:3a0e:b0:6ea:ad5e:f4b3 with SMTP id fj14-20020a056a003a0e00b006eaad5ef4b3mr15307449pfb.23.1713203376760; Mon, 15 Apr 2024 10:49:36 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713203376; cv=pass; d=google.com; s=arc-20160816; b=x1uVnb4zy1VIFbR1DWXKwvz1mdY1PYfuOqrkoT8XldLB3FNtaTIHHEoVERfhnnf+DN hT+owJ4qMVcv8mk7X/m0/GuvCoDSKEJudE0WJuHVYnIUddeVzvn9a6UrR5fYUpE1isoU ZJa0hBHbcECoP8ApZj2xcQWnzLcHxpTlROQKIVgafqSwb4XjpiUTD/SDM9KRWcr5cgqT pxHRGNR2DX3wjY7WNdyVEW/viBdSNU6L4gBQ4ahL7iUtp4423zAKI/T/+t12+oNTEMRQ VWed8MDSXDLut0jchpvWliNBSraZrwqaeUqQ+O5pzpm3YONnDpTdRJ6HM3W7jyT2Xtcc 8RJg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=gPogu4n50QI+ywls3m8mPood0GMfrSMVkUcAhgnCq6Y=; fh=pw2CDadppvKgBCm84+vsd5GwSw3c0iMRBoeKYf2wwDY=; b=O7f+xvgMgv46VU4sHlxVBacSe8odKtOsv7DC8D5HdZks1RRHz69VlHhbuP/I0hh7uf k6QM7MJl9y8sOHBHK6mRNpJPlKV7wqNQla4F/QK+bZqiMnW3vhHIdjcQen6z1pe0CU7T xmx7vINn4rc0Rq0Kikwn8pqxWenzykd5c+jP7cUFbfGJVLCkH0J8K5DcreLALFc7nsoR qs4FTPb9ihGo0iu3okbpa7Izn4ZfqnTasjb3yF1uCaRqbpPlRLeFYrVWgAuVrZhjvQNP eqJw18mVROWwprNJUXr0CgkjHfc/ejGDh8ien1CIQ5HGolO4q7w0TwpvZNp4vd5XSlmc A//w==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=oQ+aDlYJ; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-145677-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-145677-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id r20-20020a632054000000b005c220a94525si8210935pgm.90.2024.04.15.10.49.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Apr 2024 10:49:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-145677-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=oQ+aDlYJ; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-145677-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-145677-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 17103B22127 for ; Mon, 15 Apr 2024 17:48:16 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1305D139563; Mon, 15 Apr 2024 17:48:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="oQ+aDlYJ" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 235E776033; Mon, 15 Apr 2024 17:48:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713203284; cv=none; b=ktR1gCu0nn7Kj1I8z3cCHRtBf6zadHvHSfQOwF7V1YGux91pbNxFSp/GeBJVRU8VBcqgGJiUUJV2Bhkg6ladx4F5no79DDMbCuJCLocl4I55h++sn+yC2RdfHl6e1O7cBbely1u2DN6cM6LnfTrzuNoaUv0m5biSMMqi2qPnQoI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713203284; c=relaxed/simple; bh=aPShdw2DP64iiJ1YwOdHPMtTmJVIyo36jyERNxM2Bmg=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=CcsweLFYknOvxwJxDR9a5j+v0AqQReF9bGitqWxeoWET2mcpTkblZ+y92H+KQ0cEg3Gl8L72FJvz5uxyiua/VlFFgrKZHRw2JtwemqL5t0JXjPNaopn8s1lbyA7p+V3BDjsSbxAa6fCmZWOBfWe5WaBN+L9qmuUpEPWQ/sNHzrs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=oQ+aDlYJ; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6EFD6C2BD11; Mon, 15 Apr 2024 17:48:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1713203283; bh=aPShdw2DP64iiJ1YwOdHPMtTmJVIyo36jyERNxM2Bmg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=oQ+aDlYJ1RtNc+up9pT4B1jjw8AsUys3NmpGqycmvUIfKkjGlKdNvZe6dUfEu4gpn yTkctKYIR+V8pbXG/tzzvvrUpA+A2zvfHijap2aJmfjnQ8sV1GU30FRF0yJowywL8f r+lLchMCMd2Nd6U6Rno0GYqsBuOdAa+dO9iFjZvfnjC++NWzuCxAE/bN+1QLvV2eMT mG2l0QAB8wxaGyobPG7e7tl4JlOmNpitdmTugO5FuCK8ZiTi/qgZB2sNBzn5NYMqW0 dVnbh/Cdw05PVRy/jm0htwbycd+TIp1G0/P/edWhX5d2FMKQQGasMJk2laN7cDNENx 6325l6N7xrq8A== Date: Mon, 15 Apr 2024 10:48:02 -0700 From: Jakub Kicinski To: Jose Ignacio Tornos Martinez Cc: davem@davemloft.net, edumazet@google.com, jarkko.palviainen@gmail.com, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, netdev@vger.kernel.org, pabeni@redhat.com, stable@vger.kernel.org Subject: Re: [PATCH] net: usb: ax88179_178a: avoid writing the mac address before first reading Message-ID: <20240415104802.6765bcdb@kernel.org> In-Reply-To: <20240415072735.6135-1-jtornosm@redhat.com> References: <20240411195129.69ff2bac@kernel.org> <20240415072735.6135-1-jtornosm@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Mon, 15 Apr 2024 09:27:32 +0200 Jose Ignacio Tornos Martinez wrote: > The issue happened at the initialization stage. At that moment, during > normal rtnl_setlink call, the mac address is set and written in the device > registers, but since the reset was not commanded previously, the mac > address is not read from the device and without that, it always has the > random address that is pre-generated just in case. > After this, during open operation, the reset is commanded and the mac > address is read, but as the device registers were modified, it reads the > pregenerated random mac address and not the default mac address for the > device. Oh, I see, why don't we issue the reset and probe time, then?