Re: [PATCH net-next v6 1/6] net: dsa: motorcomm: initialize dsa_switch based on chipid

From: Kyle Switch

Date: Wed Sep 09 2026 - 22:14:34 EST



On 9/10/26 00:18, David Yang wrote:
On Tue, Sep 8, 2026 at 4:36 PM Kyle Switch <kyle.switch@xxxxxxxxxxxxxx> wrote:
+ if (major == YT9215_MAJOR || major == YT9218_MAJOR)
+ mode = YT92XX_MODE_YT921X;
+
+ for (i = 0; i < ARRAY_SIZE(yt92xx_series_table); ++i)
+ if (yt92xx_series_table[i].mode == mode)
+ return &yt92xx_series_table[i];
Still redundant lookups here.
Ans: will be fixed in next patch.
- ds->priv = priv;
ds->priv is gone in the new register.
Ans: will be fixed in next version.
static const struct of_device_id yt921x_of_match[] = {
- { .compatible = "motorcomm,yt9215" },
- {}
+ {
+ .compatible = "motorcomm,yt9215",
+ },
+ { /* sentinel */ }
Leftovers.
Ans: will be fixed in next version