netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: vidya@cumulusnetworks.com
Cc: bwh@kernel.org, netdev@vger.kernel.org, roopa@cumulusnetworks.com
Subject: Re: [PATCH net-next] ethtool: Macro definition for SFF-8436/8636 Memory map max sizes
Date: Sat, 11 Jun 2016 15:51:34 -0700 (PDT)	[thread overview]
Message-ID: <20160611.155134.1474324006340328110.davem@davemloft.net> (raw)
In-Reply-To: <1465278926-10231-1-git-send-email-vidya@cumulusnetworks.com>

From: vidya@cumulusnetworks.com
Date: Mon,  6 Jun 2016 22:55:26 -0700

> From: Vidya Sagar Ravipati <vidya@cumulusnetworks.com>
> 
> This patch provides macro definitions for maximum possible
> memory map size of QSFP+/QSFP28 EEPROMs as per SFF-8436/SFF-8636
> 
> According to SFF-8436/SFF-8636 specs, the common memory map for
> managing external cable interfaces is arranged into a single
> lower page address space of 128 bytes and multiple upper address pages
> of 128 bytes each. The total size of memory map is up to 5 128 byte pages
> defined by a "pages valid" register and switched via a "page select"
> register for "optional pages". Memory of 256 bytes can be memory mapped
> at a time and QSFP+/QSFP28  drivers can export upto 5*128 bytes of
> eeprom dump.
> 
> QSFP+/QSFP28 Memory layout
>            2-Wire Serial Address: 1010000x
>            Lower Page 00h (128 bytes)
>            ======================
>            |Page Select Byte(127)|
>            ======================
>                     |
>                     V
>        ----------------------------------------
>       |             |            |             |
>       V             V            V             V
>    ----------   ----------   ---------    ------------
>   | Upper    | | Upper    | | Upper    | | Upper      |
>   | Page 00h | | Page 01h | | Page 02h | | Page 03h   |
>   |          | |(Optional)| |(Optional)| | (Optional) |
>   |    ID    | |   AST    | |  User    | |  For       |
>   |  Fields  | |  Table   | | EEPROM   | |  Cable     |
>   -----------  -----------   ----------  --------------
> 
> Signed-off-by: Vidya Sagar Ravipati <vidya@cumulusnetworks.com>

Why do we need these values in the header file at all?

The application can probe the size by repeated eeprom calls, increasing
the buffer size each time as needed until success.

  reply	other threads:[~2016-06-11 22:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-07  5:55 [PATCH net-next] ethtool: Macro definition for SFF-8436/8636 Memory map max sizes vidya
2016-06-11 22:51 ` David Miller [this message]
2016-06-11 23:22   ` Vidya Sagar Ravipati
2016-06-12  2:26     ` David Miller
2016-06-12 12:34       ` Ben Hutchings
2016-06-14 19:29         ` David Miller
2016-06-12 12:33   ` Ben Hutchings

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160611.155134.1474324006340328110.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=bwh@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=roopa@cumulusnetworks.com \
    --cc=vidya@cumulusnetworks.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).