Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3486709imu; Sun, 11 Nov 2018 16:11:52 -0800 (PST) X-Google-Smtp-Source: AJdET5cEtWzhjVQiH8NLolNplWpusL82NZF8Qdd4MWZ9Tpogu5BVirvAlGLGEPgKHQj6WdNTQglQ X-Received: by 2002:a65:57cb:: with SMTP id q11mr15580878pgr.60.1541981512034; Sun, 11 Nov 2018 16:11:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541981512; cv=none; d=google.com; s=arc-20160816; b=NSSolWKh+i7wOKX7vXiNy+bg4rF8XU+RUiLvaZnbNjQ6u4W/9j81TFCXNtV8AcGIGS 00NhxGlHgWBvNkQWwUmsHSH960ramezd6HS7zQRCVGp7fUIL+tWLvbUSys4Bb/S4Kymc uEzCMTa34WoT3Lkw85CgKjgFSvIJcZ7pVtymu+owbNXvdJAGHvQLp+DOcxXk7qHUlBZS +BQ5k/k+QFT96Wt7Yo/07xj4EQSRM5aGbBuzwM6u1IEoLBwIs2JJMDipot3jwf3X+xBP Pnq79llHFQEc7nRFyLF8P8SgCJGoSJy8T2kvC7h+rRkKgmXXtuClPy0OgMX5SiSm4DSE 752Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=F+Au+yykVAy5grllJfT3pwPjBWmDX9duv1yi4ONEzQc=; b=ONa5YRRCL9ee1u7nF/xv1bG4eCE+yVKMEldIJ8SiREDg/x3IJX62L5XsRT91CeZM9E N82CNT9HClmN6EXBS5dsXMemPJrJxtI4pj3xZ05+TfED5hDm/0McxagOxgy6MTmOscXC Uh4T3okHK3Vaac7g3TeAyrsmSrcKsNjUeUfhKq5fzMwjeVEPDamBSQpnBcgtdD7hzRyD p9K77ZgMZcI5y2Qo9yekTiplFDUId08r1whypAEwC/fZVgkizG4mN8pBr07oUJVExY6S H/ifEzJNIKtnoss/LuZlVFqthcs9nM/WQrbcSHv5qg5TufAd8pOdXl/OJzRRfHF0Pll8 MfjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BCa4+HJC; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 13-v6si14603888pgv.104.2018.11.11.16.11.37; Sun, 11 Nov 2018 16:11:52 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BCa4+HJC; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731731AbeKLKAd (ORCPT + 99 others); Mon, 12 Nov 2018 05:00:33 -0500 Received: from mail.kernel.org ([198.145.29.99]:60776 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730816AbeKLIR1 (ORCPT ); Mon, 12 Nov 2018 03:17:27 -0500 Received: from localhost (unknown [206.108.79.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 86526214DB; Sun, 11 Nov 2018 22:27:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1541975251; bh=2NzYSp7Opf0nkDikGP2TgaxWzU3IPhkgsMNak2gPLdI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BCa4+HJC6YcUaUmRbiVQwAPX0/pmtMOtGrpXjQ+XtGTRjhgGYNmI8xibF2NMSvApf zSmdvaRWo28RwjvC8mHM3PWrLSHcncJicoicuhGLC+kC0HhfDfDZeqsi7bpOSjl8QF 4onh0dGmWQTQcvlpytZZ/4IHnEpHI8OUA7JNayU4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Andrew Lunn , "David S. Miller" , Sasha Levin Subject: [PATCH 4.19 117/361] net: dsa: mv88e6xxx: Fix writing to a PHY page. Date: Sun, 11 Nov 2018 14:17:44 -0800 Message-Id: <20181111221636.379196580@linuxfoundation.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181111221619.915519183@linuxfoundation.org> References: <20181111221619.915519183@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ From: Andrew Lunn [ Upstream commit c309b158090d788e96ee597444965cb79b040484 ] After changing to the needed page, actually write the value to the register! Fixes: 09cb7dfd3f14 ("net: dsa: mv88e6xxx: describe PHY page and SerDes") Signed-off-by: Andrew Lunn Signed-off-by: David S. Miller Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/net/dsa/mv88e6xxx/phy.c | 3 +++ 1 file changed, 3 insertions(+) --- a/drivers/net/dsa/mv88e6xxx/phy.c +++ b/drivers/net/dsa/mv88e6xxx/phy.c @@ -110,6 +110,9 @@ int mv88e6xxx_phy_page_write(struct mv88 err = mv88e6xxx_phy_page_get(chip, phy, page); if (!err) { err = mv88e6xxx_phy_write(chip, phy, MV88E6XXX_PHY_PAGE, page); + if (!err) + err = mv88e6xxx_phy_write(chip, phy, reg, val); + mv88e6xxx_phy_page_put(chip, phy); }