]> Git Repo - J-linux.git/blobdiff - drivers/net/dsa/dsa_loop.c
Merge tag 'trace-v5.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt...
[J-linux.git] / drivers / net / dsa / dsa_loop.c
index 5f69216376fe23260b285d3337cb24efe57f9412..bfdf3324aac3a24172b096ef48c05d656a633a38 100644 (file)
@@ -190,7 +190,8 @@ static void dsa_loop_port_stp_state_set(struct dsa_switch *ds, int port,
 }
 
 static int dsa_loop_port_vlan_filtering(struct dsa_switch *ds, int port,
-                                       bool vlan_filtering)
+                                       bool vlan_filtering,
+                                       struct netlink_ext_ack *extack)
 {
        dev_dbg(ds->dev, "%s: port: %d, vlan_filtering: %d\n",
                __func__, port, vlan_filtering);
@@ -199,7 +200,8 @@ static int dsa_loop_port_vlan_filtering(struct dsa_switch *ds, int port,
 }
 
 static int dsa_loop_port_vlan_add(struct dsa_switch *ds, int port,
-                                 const struct switchdev_obj_port_vlan *vlan)
+                                 const struct switchdev_obj_port_vlan *vlan,
+                                 struct netlink_ext_ack *extack)
 {
        bool untagged = vlan->flags & BRIDGE_VLAN_INFO_UNTAGGED;
        bool pvid = vlan->flags & BRIDGE_VLAN_INFO_PVID;
@@ -207,7 +209,7 @@ static int dsa_loop_port_vlan_add(struct dsa_switch *ds, int port,
        struct mii_bus *bus = ps->bus;
        struct dsa_loop_vlan *vl;
 
-       if (vlan->vid > ARRAY_SIZE(ps->vlans))
+       if (vlan->vid >= ARRAY_SIZE(ps->vlans))
                return -ERANGE;
 
        /* Just do a sleeping operation to make lockdep checks effective */
This page took 0.029811 seconds and 4 git commands to generate.