From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) (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 3FB611494A8; Mon, 5 Jan 2026 15:40:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=156.67.10.101 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767627661; cv=none; b=UxNTQvXmoCTyMoVe2w65Dii9NnQ9GTLDMymoCpAzk53Q8PjXI8qhDMfOyLVNgbbmeJBYKXtaVr83YkLkuOnLKpYyON0mccsctC4ASc2s5JnpAkI6TwLVeG9houMOgKxKHzx+hHUVD3uXEEKo13r1e5kFFClvKFqgMpT6pes6ZJ0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767627661; c=relaxed/simple; bh=qxEPNcPyoPE7cO+7Mc1UhrG9sWlmf1lDBHfKXDZcN1s=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=BuYtwoeLEAZFTT/BJ3D4YKjGvdxWr8JJjrnlhp0K1EnDoi1rv42eS7vssB2WAJcm328zG3WcQMTE5zekfuruU7AEPiEEPrxsYXrkrC516+G/9TYH89xZKv1i3BhUQY8/E+k8F/lGmGVK8g1uzkkaTmXEHPvCNqu4UDDiblP448s= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch; spf=pass smtp.mailfrom=lunn.ch; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b=vC00onSp; arc=none smtp.client-ip=156.67.10.101 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lunn.ch Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="vC00onSp" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=Wgcj7sxBXVa2NjV+9IsdVBE6EHA3Giu1FnJKtsFPXLU=; b=vC00onSp+UsgeuZOLoJshrE+6l 3VvjhykC8zhsvTtSByXsVCWhh00Xke+DeDb5+wnj7rp+xevMacfXSxLkWVtL9AyiUW+jA7Lh1m+Gf QKvSedaYTnLkLKrsLjtTN1W4TV2uKveTuZxetqHPDL/t//4WxujcOn4PfdMYthgykyXU=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1vcmhQ-001VEL-1L; Mon, 05 Jan 2026 16:40:52 +0100 Date: Mon, 5 Jan 2026 16:40:52 +0100 From: Andrew Lunn To: Maxime Chevallier Cc: davem@davemloft.net, Jakub Kicinski , Eric Dumazet , Paolo Abeni , Russell King , Jonas Jelonek , Heiner Kallweit , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, Florian Fainelli , =?iso-8859-1?Q?K=F6ry?= Maincent , Simon Horman , Romain Gantois , Marek =?iso-8859-1?Q?Beh=FAn?= Subject: Re: [PATCH net] net: sfp: return the number of written bytes for smbus single byte access Message-ID: <040995f9-5df2-4f5f-92c4-bedb8d1cd557@lunn.ch> References: <20260105151840.144552-1-maxime.chevallier@bootlin.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-Disposition: inline In-Reply-To: <20260105151840.144552-1-maxime.chevallier@bootlin.com> On Mon, Jan 05, 2026 at 04:18:39PM +0100, Maxime Chevallier wrote: > We expect the SFP write accessors to return the number of written bytes. > We fail to do so for single-byte smbus accesses, which may cause errors > when setting a module's high-power state and for some cotsworks modules. > > Let's return the amount of written bytes, as expected. > > Fixes: 7662abf4db94 ("net: phy: sfp: Add support for SMBus module access") > Signed-off-by: Maxime Chevallier Reviewed-by: Andrew Lunn Andrew