public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: "Marek Behún" <kabel@kernel.org>
To: Roman Bacik <roman.bacik@broadcom.com>
Cc: U-Boot Mailing List <u-boot@lists.denx.de>,
	Bharat Gooty <bharat.gooty@broadcom.com>,
	Joe Hershberger <joe.hershberger@ni.com>,
	Ramon Fried <rfried.dev@gmail.com>
Subject: Re: [PATCH v2 1/2] net: brcm: netXtreme driver
Date: Tue, 26 Oct 2021 00:22:33 +0200	[thread overview]
Message-ID: <20211026002233.21ac0b3a@thinkpad> (raw)
In-Reply-To: <CAGQAs7wr+eewTJftUD9cenNSFtosNCR76Zv=2a8ZOMkkb30FCw@mail.gmail.com>

On Mon, 25 Oct 2021 14:35:20 -0700
Roman Bacik <roman.bacik@broadcom.com> wrote:

> > - you are introducing custom mechanism for setting / getting PHY
> >   parameters, via custom specific env variables, for example in the
> >   set_phy_speed() and set_phy_link() functions, i.e.:
> >         sprintf(name1, "bnxt_eth%u_phy_speed", bp->cardnum);
> >         env_set(name1, name);
> >
> >   The whole point of several people in the past few years was to create
> >   generic mechanisms for such things. We have ethernet PHY DM class,
> >   you should use this. That way you won't need to introduce custom
> >   mechanisms to get the infromation, since there are mii/mdio commands.  
> 
> These are chip internal settings stored internally in NVM. They are
> not modified via mii/mdio.

Ah. Well that also shouldn't use custom commands. Unfortunately U-Boot
does not have a generic nvmem API yet, but I plan to write nvmem API
together with `nvmem` command, which would be generic.

As of now, we have the `mac` and `fuse` commands for this (although
deprecated and will be removed). If you want to write nvmem interface,
you could use the `mac` command. But it will be deprecated once we have
nvmem API, would you be willing to rewrite it then?

Marek

  reply	other threads:[~2021-10-25 22:22 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-22 23:23 [PATCH v2 1/2] net: brcm: netXtreme driver Roman Bacik
2021-10-22 23:23 ` [PATCH v2 2/2] cmd: brcm: netXtreme commands Roman Bacik
2021-10-23  8:02   ` Heinrich Schuchardt
2021-10-25 16:54     ` Roman Bacik
2021-10-25 14:01   ` Marek Behún
2021-10-25 16:34     ` Roman Bacik
2021-10-25 13:58 ` [PATCH v2 1/2] net: brcm: netXtreme driver Marek Behún
2021-10-25 21:35   ` Roman Bacik
2021-10-25 22:22     ` Marek Behún [this message]
2021-10-25 22:31       ` Roman Bacik

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=20211026002233.21ac0b3a@thinkpad \
    --to=kabel@kernel.org \
    --cc=bharat.gooty@broadcom.com \
    --cc=joe.hershberger@ni.com \
    --cc=rfried.dev@gmail.com \
    --cc=roman.bacik@broadcom.com \
    --cc=u-boot@lists.denx.de \
    /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