]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
realtek: dsa: rename rtl838x_port to rtldsa_port
authorMarkus Stockhausen <markus.stockhausen@gmx.de>
Tue, 3 Mar 2026 18:38:21 +0000 (19:38 +0100)
committerRobert Marko <robimarko@gmail.com>
Thu, 5 Mar 2026 09:39:34 +0000 (10:39 +0100)
Adapt the prefix of the port structure.

Signed-off-by: Markus Stockhausen <markus.stockhausen@gmx.de>
Link: https://github.com/openwrt/openwrt/pull/22255
Signed-off-by: Robert Marko <robimarko@gmail.com>
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/debugfs.c
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/dsa.c
target/linux/realtek/files-6.12/drivers/net/dsa/rtl83xx/rtl838x.h

index 9807050edf9f57119394d2113225b784e20a5122..4b560f61928451ec01b90160d1cff4e9222e61bc 100644 (file)
@@ -160,7 +160,7 @@ static ssize_t rtl838x_common_write(const char __user *buffer, size_t count,
 static ssize_t stp_state_read(struct file *filp, char __user *buffer, size_t count,
                              loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        struct dsa_switch *ds = p->dp->ds;
        int state = rtldsa_port_get_stp_state(ds->priv, p->dp->index);
 
@@ -173,7 +173,7 @@ static ssize_t stp_state_read(struct file *filp, char __user *buffer, size_t cou
 static ssize_t stp_state_write(struct file *filp, const char __user *buffer,
                               size_t count, loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        u32 value;
        size_t res = rtl838x_common_write(buffer, count, ppos, &value);
 
@@ -586,7 +586,7 @@ static const struct file_operations rtldsa_vlan_table_fops = {
 static ssize_t age_out_read(struct file *filp, char __user *buffer, size_t count,
                            loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        struct dsa_switch *ds = p->dp->ds;
        struct rtl838x_switch_priv *priv = ds->priv;
        int value = sw_r32(priv->r->l2_port_aging_out);
@@ -600,7 +600,7 @@ static ssize_t age_out_read(struct file *filp, char __user *buffer, size_t count
 static ssize_t age_out_write(struct file *filp, const char __user *buffer,
                             size_t count, loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        u32 value;
        size_t res = rtl838x_common_write(buffer, count, ppos, &value);
 
@@ -622,7 +622,7 @@ static const struct file_operations age_out_fops = {
 static ssize_t port_egress_rate_read(struct file *filp, char __user *buffer, size_t count,
                                     loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        struct dsa_switch *ds = p->dp->ds;
        struct rtl838x_switch_priv *priv = ds->priv;
        int value;
@@ -641,7 +641,7 @@ static ssize_t port_egress_rate_read(struct file *filp, char __user *buffer, siz
 static ssize_t port_egress_rate_write(struct file *filp, const char __user *buffer,
                                      size_t count, loff_t *ppos)
 {
-       struct rtl838x_port *p = filp->private_data;
+       struct rtldsa_port *p = filp->private_data;
        struct dsa_switch *ds = p->dp->ds;
        struct rtl838x_switch_priv *priv = ds->priv;
        u32 value;
index 8f4ed35f125e83ca990fe18bd9c5d80113e00836..90dbdf9c3a2a62718e7e771dd49470e01588e864 100644 (file)
@@ -1360,10 +1360,10 @@ static void rtldsa_update_port_member(struct rtl838x_switch_priv *priv, int port
                                      __must_hold(&priv->reg_mutex)
 {
        struct dsa_port *dp = dsa_to_port(priv->ds, port);
-       struct rtl838x_port *p = &priv->ports[port];
+       struct rtldsa_port *p = &priv->ports[port];
        struct dsa_port *cpu_dp = dp->cpu_dp;
        u64 port_mask = BIT_ULL(cpu_dp->index);
-       struct rtl838x_port *other_p;
+       struct rtldsa_port *other_p;
        struct dsa_port *other_dp;
        int other_port;
        bool isolated;
@@ -2467,7 +2467,7 @@ static int rtldsa_cls_flower_add(struct dsa_switch *ds, int port,
                                 bool ingress)
 {
        struct rtl838x_switch_priv *priv = ds->priv;
-       struct rtl838x_port *p = &priv->ports[port];
+       struct rtldsa_port *p = &priv->ports[port];
        const struct flow_action_entry *act;
        int ret;
 
@@ -2513,7 +2513,7 @@ static int rtldsa_cls_flower_del(struct dsa_switch *ds, int port,
                                 bool ingress)
 {
        struct rtl838x_switch_priv *priv = ds->priv;
-       struct rtl838x_port *p = &priv->ports[port];
+       struct rtldsa_port *p = &priv->ports[port];
        int ret;
 
        if (!priv->r->port_rate_police_del)
index c900da01cdd1044c51666aebab92546db33d2b14..eafd43b5db78f6d7a6e65457d9d42fdeab2b31ed 100644 (file)
@@ -874,7 +874,7 @@ struct rtldsa_counter_state {
        struct rtnl_link_stats64 link_stat;
 };
 
-struct rtl838x_port {
+struct rtldsa_port {
        bool enable:1;
        bool phy_is_integrated:1;
        bool is10G:1;
@@ -1375,7 +1375,7 @@ struct rtl838x_switch_priv {
        struct device *dev;
        u16 id;
        u16 family_id;
-       struct rtl838x_port ports[57];
+       struct rtldsa_port ports[57];
        struct mutex reg_mutex;         /* Mutex for individual register manipulations */
        struct mutex pie_mutex;         /* Mutex for Packet Inspection Engine */
        int link_state_irq;