Home
last modified time | relevance | path

Searched refs:ale_entry (Results 1 – 1 of 1) sorted by relevance

/linux-6.12.1/drivers/net/ethernet/ti/
Dcpsw_ale.c128 static inline int cpsw_ale_get_field(u32 *ale_entry, u32 start, u32 bits) in cpsw_ale_get_field() argument
138 hi_val = ale_entry[idx2] << ((idx2 * 32) - start); in cpsw_ale_get_field()
142 return (hi_val + (ale_entry[idx] >> start)) & BITMASK(bits); in cpsw_ale_get_field()
145 static inline void cpsw_ale_set_field(u32 *ale_entry, u32 start, u32 bits, in cpsw_ale_set_field() argument
156 ale_entry[idx2] &= ~(BITMASK(bits + start - (idx2 * 32))); in cpsw_ale_set_field()
157 ale_entry[idx2] |= (value >> ((idx2 * 32) - start)); in cpsw_ale_set_field()
161 ale_entry[idx] &= ~(BITMASK(bits) << start); in cpsw_ale_set_field()
162 ale_entry[idx] |= (value << start); in cpsw_ale_set_field()
166 static inline int cpsw_ale_get_##name(u32 *ale_entry) \
168 return cpsw_ale_get_field(ale_entry, start, bits); \
[all …]