Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp833098pxu; Mon, 23 Nov 2020 05:27:16 -0800 (PST) X-Google-Smtp-Source: ABdhPJyus+V6NbFJ6JA8mMquyxDXUlV/Az3ziFwlgjybyZ9BJAgNKSnv4fUWU6LkNG38C/W/CxWz X-Received: by 2002:a17:906:f8cd:: with SMTP id lh13mr38778396ejb.551.1606138036319; Mon, 23 Nov 2020 05:27:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606138036; cv=none; d=google.com; s=arc-20160816; b=ZwrlTBg7Ls0+Dh5+vV5D8Ac5FojzFB7EQDc6rHR3t5ucPb2xcvxwVPxIj01j+IM+ll zTJhYiJFVOLjkKwupw5CWFnV2UpXlGZ/h/KxKPrl80DG/f3WzGH3R45Vejfb0eTQhr3C qTCE7K05kl+SQ+FnqeZNqe8k7atxbSPaBOP7bW5aaYizTVQBPveVxnI4+mUviVNoyWAG /0Ft7aW2mhpUT4dYeRcfg1qarlR1upI5obWFRsHGdKrbTnynoJEYnDVN5dECMWuw6AGM 7QTSGsTeiRD2DZNjrgSTqAsNRi2q5U+wiL4QwAJVK6te6nAFFZyeEjHSGI9aRksh30MZ oHsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Nnomu0hGEwPbxNWzA12cQu5Z6aH6UVG6QxOY1SJlj2Q=; b=QSXzAzXLZOf/N+G8GQ7Es9/Hk8dKBdHXQyBkEyyEmKsMfOyWv7OviZaCUcFqGiU5MF 6f7bvqpAt7cbJ1Q7V+jNYTlavVbfl6omaUvcUUXb0o3WsxbsIiL3rE4mop3aW8ZXktNi Y3lM/uRBLk2ajFH24Hw44woyGYdXwXpfAjdqTNDr3cvH3rIZFm2U7HRMTszO9jqaMzGc +cMoUMQ53qFV6pAdFedzGo+1/VT0TcJn7qe0GKrI/rPofiIrozMUwdsofrjMM/hDQbnI mZrhvl5DjaIj+0YwFXlxjGT/rMpJGlG7rJ1GU0fWbxFuqn8rvnEm65WO6wDQtx9rqFhG LK2w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cBYuzGec; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p18si6526754eds.125.2020.11.23.05.26.52; Mon, 23 Nov 2020 05:27:16 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cBYuzGec; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731402AbgKWMej (ORCPT + 99 others); Mon, 23 Nov 2020 07:34:39 -0500 Received: from mail.kernel.org ([198.145.29.99]:46384 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731382AbgKWMed (ORCPT ); Mon, 23 Nov 2020 07:34:33 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (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 E117720721; Mon, 23 Nov 2020 12:34:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606134873; bh=l/knj+j0jRFR8PxDq7BeTfiWtHE/BMFogcZAejeVNmM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cBYuzGece+PQ33TwPNI4QQn/MGH9hbn/LPKdAEtfSj6cjTdLYsmwfi8kdDfdx9+br Rzqsni9uIGseAA4z/1iM69CAZ9+mrezRshJKCVNdLk60geZk7rzWdCw54Rh9l0J8we DCr63sl0R2N/S9l8YytIKyTu9QBwrZaO83o992VY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Edwin Peer , Michael Chan , Jakub Kicinski Subject: [PATCH 5.4 003/158] bnxt_en: read EEPROM A2h address using page 0 Date: Mon, 23 Nov 2020 13:20:31 +0100 Message-Id: <20201123121820.116565138@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201123121819.943135899@linuxfoundation.org> References: <20201123121819.943135899@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Edwin Peer [ Upstream commit 4260330b32b14330cfe427d568ac5f5b29b5be3d ] The module eeprom address range returned by bnxt_get_module_eeprom() should be 256 bytes of A0h address space, the lower half of the A2h address space, and page 0 for the upper half of the A2h address space. Fix the firmware call by passing page_number 0 for the A2h slave address space. Fixes: 42ee18fe4ca2 ("bnxt_en: Add Support for ETHTOOL_GMODULEINFO and ETHTOOL_GMODULEEEPRO") Signed-off-by: Edwin Peer Signed-off-by: Michael Chan Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c @@ -2584,7 +2584,7 @@ static int bnxt_get_module_eeprom(struct /* Read A2 portion of the EEPROM */ if (length) { start -= ETH_MODULE_SFF_8436_LEN; - rc = bnxt_read_sfp_module_eeprom_info(bp, I2C_DEV_ADDR_A2, 1, + rc = bnxt_read_sfp_module_eeprom_info(bp, I2C_DEV_ADDR_A2, 0, start, length, data); } return rc;