Received: by 2002:aa6:c429:0:b029:98:93ff:f56f with SMTP id g9csp3388245lkq; Mon, 23 Nov 2020 04:33:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJwAE1W8eaC6pF05uzKHmCEqn6ot4Jn2Ks+iNmirW3S7UPJlWAiaw+7MO6GFTy8MICZoqlmi X-Received: by 2002:a17:906:8541:: with SMTP id h1mr25176426ejy.445.1606134810292; Mon, 23 Nov 2020 04:33:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606134810; cv=none; d=google.com; s=arc-20160816; b=WuRAHwg52kWhkTCMRJpLCZZlMHQPVs51KJqLSgdGHPhRDaTkBOVCnoCoa6JwdZvyBG H5Q+nGiJ79gRmh12KxqvS6WoeiqOeMYB0ZbM4RrXlATsl5I3pcVxI6Z0Oa/YY2VkHMKC PYzB6XXPotuEGQNGqCIk0KejkV8QlfpM+kIKbr7VqZKmeSpXfSXcbebP3jmJt6L2OuIQ d1auNb6A5xdKz8zZIjHFGWHOjTZZvj1H68Hj/Wx7FBbQcfUJinTulPQJAHpFtiW1kAuv 0Bt0sj9JTZRTs/zkT9hrwQhX5ZLA9f3Dn291SnEwZ+Mm+EvoJrpo5DFDNHXqYYkimAj9 mlsw== 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=T32VPbHZLxA1re5GCoFtOKGZIDviqNVommxk+eEyMCQ=; b=Jik3XRyhuyeza2EVPVyQRwKxbgQNUjqEuocXWr6x8q5g3Pt/lUbjMryUHvK5D86wGn sZoRL0JF1elezm6ZGxV8FlRmrwn07IBtWntZ9SxM4CxLEiUCMCBDcgPkUqaaBEmiBhw7 ddfuLVdcvUUMi3yj/nfQdLismRCKqGHVdHdbIC3OzW3eH5jMqIMUKUS+P5SLayCjEpw1 7QUvbKhl6H7aq0c3ApnXvkylAzP5LXSHCqx6h9j81iTASZ7IwBiWubr+kaOxNqcOi5GT KAQF0WVXQI8G3XvrY4QTswuGJ1QQUzkZCMg9McDkRfXqS6Rh9XZvLu5DcLRkZgkj2hFz aGbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=yTvpO+w8; 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 q22si6420348ejy.29.2020.11.23.04.33.07; Mon, 23 Nov 2020 04:33:30 -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=yTvpO+w8; 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 S1730720AbgKWMaS (ORCPT + 99 others); Mon, 23 Nov 2020 07:30:18 -0500 Received: from mail.kernel.org ([198.145.29.99]:40946 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729463AbgKWMaN (ORCPT ); Mon, 23 Nov 2020 07:30:13 -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 57A4B208C3; Mon, 23 Nov 2020 12:30:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606134612; bh=oZDLj9l2yBLIC6hTfRyl2HIOnDTy2SLGywKsfrd3pNo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=yTvpO+w8KOysEnP5Th8ORgBjrerjea5VmtmLS2QcBaOGqaRynYGtNM0fEo5OK/nti mNjZMKzv44tomIT4gDmXZCNRdyD/iAgGVEn84IAKZkNlRLlC3CJzoV08AZlkV0D29X 31i8eHLVZk2kF4HrEROeNMnjDXEG1jFX+ndcWxWM= 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 4.19 03/91] bnxt_en: read EEPROM A2h address using page 0 Date: Mon, 23 Nov 2020 13:21:23 +0100 Message-Id: <20201123121809.462289617@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201123121809.285416732@linuxfoundation.org> References: <20201123121809.285416732@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 @@ -2300,7 +2300,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;