From: Klaus Kudielka <klaus.kudielka@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Florian Fainelli <f.fainelli@gmail.com>,
Vladimir Oltean <olteanv@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Richard Cochran <richardcochran@gmail.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
Klaus Kudielka <klaus.kudielka@gmail.com>
Subject: [PATCH net-next v3 4/4] net: dsa: mv88e6xxx: mask apparently non-existing phys during probing
Date: Tue, 14 Mar 2023 19:26:59 +0100 [thread overview]
Message-ID: <20230314182659.63686-5-klaus.kudielka@gmail.com> (raw)
In-Reply-To: <20230314182659.63686-1-klaus.kudielka@gmail.com>
To avoid excessive mdio bus transactions during probing, mask all phy
addresses that do not exist (there is a 1:1 mapping between switch port
number and phy address).
Suggested-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Klaus Kudielka <klaus.kudielka@gmail.com>
---
v2: Patch is new
v3: No change
drivers/net/dsa/mv88e6xxx/chip.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
index 29b0f3bb1c..c52798d9ce 100644
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
@@ -3797,6 +3797,7 @@ static int mv88e6xxx_mdio_register(struct mv88e6xxx_chip *chip,
bus->read_c45 = mv88e6xxx_mdio_read_c45;
bus->write_c45 = mv88e6xxx_mdio_write_c45;
bus->parent = chip->dev;
+ bus->phy_mask = GENMASK(31, mv88e6xxx_num_ports(chip));
if (!external) {
err = mv88e6xxx_g2_irq_mdio_setup(chip, bus);
--
2.39.2
next prev parent reply other threads:[~2023-03-14 18:28 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-14 18:26 [PATCH net-next v3 0/4] net: dsa: mv88e6xxx: accelerate C45 scan Klaus Kudielka
2023-03-14 18:26 ` [PATCH] net: dsa: mv88e6xxx: don't dispose of Global2 IRQ mappings from mdiobus code Klaus Kudielka
2023-03-14 19:35 ` Klaus Kudielka
2023-03-14 20:01 ` Vladimir Oltean
2023-03-15 6:07 ` Klaus Kudielka
2023-03-15 9:53 ` Vladimir Oltean
2023-03-15 14:41 ` Andrew Lunn
2023-03-14 18:26 ` [PATCH net-next v3 2/4] net: dsa: mv88e6xxx: re-order functions Klaus Kudielka
2023-03-14 18:26 ` [PATCH net-next v3 3/4] net: dsa: mv88e6xxx: move call to mv88e6xxx_mdios_register() Klaus Kudielka
2023-03-14 19:15 ` Andrew Lunn
2023-03-14 18:26 ` Klaus Kudielka [this message]
2023-03-14 19:23 ` [PATCH net-next v3 4/4] net: dsa: mv88e6xxx: mask apparently non-existing phys during probing 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=20230314182659.63686-5-klaus.kudielka@gmail.com \
--to=klaus.kudielka@gmail.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=olteanv@gmail.com \
--cc=pabeni@redhat.com \
--cc=richardcochran@gmail.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