sja1105.h (860dbce3d8dd90cb9e909c58fa79808766243651) | sja1105.h (9dfa69118f12d6c67d34f90bfd9a825a908d5f60) |
---|---|
1/* SPDX-License-Identifier: GPL-2.0 2 * Copyright (c) 2018, Sensor-Technik Wiedemann GmbH 3 * Copyright (c) 2018-2019, Vladimir Oltean <olteanv@gmail.com> 4 */ 5#ifndef _SJA1105_H 6#define _SJA1105_H 7 8#include <linux/dsa/sja1105.h> --- 41 unchanged lines hidden (view full) --- 50 * switch core and device_id) 51 */ 52 u64 part_no; 53 const struct sja1105_dynamic_table_ops *dyn_ops; 54 const struct sja1105_table_ops *static_ops; 55 const struct sja1105_regs *regs; 56 int (*reset_cmd)(const void *ctx, const void *data); 57 int (*setup_rgmii_delay)(const void *ctx, int port); | 1/* SPDX-License-Identifier: GPL-2.0 2 * Copyright (c) 2018, Sensor-Technik Wiedemann GmbH 3 * Copyright (c) 2018-2019, Vladimir Oltean <olteanv@gmail.com> 4 */ 5#ifndef _SJA1105_H 6#define _SJA1105_H 7 8#include <linux/dsa/sja1105.h> --- 41 unchanged lines hidden (view full) --- 50 * switch core and device_id) 51 */ 52 u64 part_no; 53 const struct sja1105_dynamic_table_ops *dyn_ops; 54 const struct sja1105_table_ops *static_ops; 55 const struct sja1105_regs *regs; 56 int (*reset_cmd)(const void *ctx, const void *data); 57 int (*setup_rgmii_delay)(const void *ctx, int port); |
58 /* Prototypes from include/net/dsa.h */ 59 int (*fdb_add_cmd)(struct dsa_switch *ds, int port, 60 const unsigned char *addr, u16 vid); 61 int (*fdb_del_cmd)(struct dsa_switch *ds, int port, 62 const unsigned char *addr, u16 vid); |
|
58 const char *name; 59}; 60 61struct sja1105_private { 62 struct sja1105_static_config static_config; 63 bool rgmii_rx_delay[SJA1105_NUM_PORTS]; 64 bool rgmii_tx_delay[SJA1105_NUM_PORTS]; 65 const struct sja1105_info *info; --- 71 unchanged lines hidden (view full) --- 137/* From sja1105_dynamic_config.c */ 138int sja1105_dynamic_config_read(struct sja1105_private *priv, 139 enum sja1105_blk_idx blk_idx, 140 int index, void *entry); 141int sja1105_dynamic_config_write(struct sja1105_private *priv, 142 enum sja1105_blk_idx blk_idx, 143 int index, void *entry, bool keep); 144 | 63 const char *name; 64}; 65 66struct sja1105_private { 67 struct sja1105_static_config static_config; 68 bool rgmii_rx_delay[SJA1105_NUM_PORTS]; 69 bool rgmii_tx_delay[SJA1105_NUM_PORTS]; 70 const struct sja1105_info *info; --- 71 unchanged lines hidden (view full) --- 142/* From sja1105_dynamic_config.c */ 143int sja1105_dynamic_config_read(struct sja1105_private *priv, 144 enum sja1105_blk_idx blk_idx, 145 int index, void *entry); 146int sja1105_dynamic_config_write(struct sja1105_private *priv, 147 enum sja1105_blk_idx blk_idx, 148 int index, void *entry, bool keep); 149 |
145u8 sja1105_fdb_hash(struct sja1105_private *priv, const u8 *addr, u16 vid); | 150u8 sja1105et_fdb_hash(struct sja1105_private *priv, const u8 *addr, u16 vid); 151int sja1105et_fdb_add(struct dsa_switch *ds, int port, 152 const unsigned char *addr, u16 vid); 153int sja1105et_fdb_del(struct dsa_switch *ds, int port, 154 const unsigned char *addr, u16 vid); 155int sja1105pqrs_fdb_add(struct dsa_switch *ds, int port, 156 const unsigned char *addr, u16 vid); 157int sja1105pqrs_fdb_del(struct dsa_switch *ds, int port, 158 const unsigned char *addr, u16 vid); |
146 147/* Common implementations for the static and dynamic configs */ 148size_t sja1105_l2_forwarding_entry_packing(void *buf, void *entry_ptr, 149 enum packing_op op); 150size_t sja1105pqrs_l2_lookup_entry_packing(void *buf, void *entry_ptr, 151 enum packing_op op); 152size_t sja1105et_l2_lookup_entry_packing(void *buf, void *entry_ptr, 153 enum packing_op op); 154size_t sja1105_vlan_lookup_entry_packing(void *buf, void *entry_ptr, 155 enum packing_op op); 156size_t sja1105pqrs_mac_config_entry_packing(void *buf, void *entry_ptr, 157 enum packing_op op); 158 159#endif | 159 160/* Common implementations for the static and dynamic configs */ 161size_t sja1105_l2_forwarding_entry_packing(void *buf, void *entry_ptr, 162 enum packing_op op); 163size_t sja1105pqrs_l2_lookup_entry_packing(void *buf, void *entry_ptr, 164 enum packing_op op); 165size_t sja1105et_l2_lookup_entry_packing(void *buf, void *entry_ptr, 166 enum packing_op op); 167size_t sja1105_vlan_lookup_entry_packing(void *buf, void *entry_ptr, 168 enum packing_op op); 169size_t sja1105pqrs_mac_config_entry_packing(void *buf, void *entry_ptr, 170 enum packing_op op); 171 172#endif |