All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Santos <daniel.santos@pobox.com>
To: Felix Fietkau <nbd@nbd.name>,
	openwrt-devel <openwrt-devel@lists.openwrt.org>
Cc: netdev@vger.kernel.org, Vitaly Chekryzhev <13hakta@gmail.com>
Subject: Using ethtool or swconfig to change link settings for mt7620a?
Date: Sat, 8 Jun 2019 04:06:54 -0500	[thread overview]
Message-ID: <5316c6da-1966-4896-6f4d-8120d9f1ff6e@pobox.com> (raw)

Hello,

I need to change auto-negotiate, speed and duplex for a port on my
mt7620a-based device, but I'm not quite certain that I understand the
structure here.  When using ethtool on eth0 I always get ENODEV,
apparently because priv->phy_dev is always NULL in fe_get_link_ksettings
of drivers/net/ethernet/mtk/ethtool.c.  But I'm being told that eth0 is
only an internal device between the µC and the switch hardware, so it
isn't even the one I need to change.

If this is true, then it looks like I will need to implement a
get_port_link function for struct switch_dev_ops?  Can anybody confirm
this to be the case?  Also, are there any examples aside from the
Broadcom drivers?  I have the mt7620 programmer's guide and it specifies
the registers I need to change.

Thanks,
Daniel

             reply	other threads:[~2019-06-08  9:15 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-08  9:06 Daniel Santos [this message]
2019-06-08 11:51 ` [OpenWrt-Devel] Using ethtool or swconfig to change link settings for mt7620a? Daniel Golle
2019-06-09  0:12   ` Daniel Santos
2019-06-08 19:04 ` Andrew Lunn

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=5316c6da-1966-4896-6f4d-8120d9f1ff6e@pobox.com \
    --to=daniel.santos@pobox.com \
    --cc=13hakta@gmail.com \
    --cc=nbd@nbd.name \
    --cc=netdev@vger.kernel.org \
    --cc=openwrt-devel@lists.openwrt.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.