Lines Matching refs:reg
83 unsigned int reg) in _efx_writeq() argument
85 __raw_writeq((__force u64)value, efx->membase + reg); in _efx_writeq()
87 static inline __le64 _efx_readq(struct efx_nic *efx, unsigned int reg) in _efx_readq() argument
89 return (__force __le64)__raw_readq(efx->membase + reg); in _efx_readq()
94 unsigned int reg) in _efx_writed() argument
96 __raw_writel((__force u32)value, efx->membase + reg); in _efx_writed()
98 static inline __le32 _efx_readd(struct efx_nic *efx, unsigned int reg) in _efx_readd() argument
100 return (__force __le32)__raw_readl(efx->membase + reg); in _efx_readd()
105 unsigned int reg) in efx_writeo() argument
110 "writing register %x with " EFX_OWORD_FMT "\n", reg, in efx_writeo()
115 _efx_writeq(efx, value->u64[0], reg + 0); in efx_writeo()
116 _efx_writeq(efx, value->u64[1], reg + 8); in efx_writeo()
118 _efx_writed(efx, value->u32[0], reg + 0); in efx_writeo()
119 _efx_writed(efx, value->u32[1], reg + 4); in efx_writeo()
120 _efx_writed(efx, value->u32[2], reg + 8); in efx_writeo()
121 _efx_writed(efx, value->u32[3], reg + 12); in efx_writeo()
151 unsigned int reg) in efx_writed() argument
155 reg, EFX_DWORD_VAL(*value)); in efx_writed()
158 _efx_writed(efx, value->u32[0], reg); in efx_writed()
163 unsigned int reg) in efx_reado() argument
168 value->u32[0] = _efx_readd(efx, reg + 0); in efx_reado()
169 value->u32[1] = _efx_readd(efx, reg + 4); in efx_reado()
170 value->u32[2] = _efx_readd(efx, reg + 8); in efx_reado()
171 value->u32[3] = _efx_readd(efx, reg + 12); in efx_reado()
175 "read from register %x, got " EFX_OWORD_FMT "\n", reg, in efx_reado()
202 unsigned int reg) in efx_readd() argument
204 value->u32[0] = _efx_readd(efx, reg); in efx_readd()
207 reg, EFX_DWORD_VAL(*value)); in efx_readd()
213 unsigned int reg, unsigned int index) in efx_writeo_table() argument
215 efx_writeo(efx, value, reg + index * sizeof(efx_oword_t)); in efx_writeo_table()
220 unsigned int reg, unsigned int index) in efx_reado_table() argument
222 efx_reado(efx, value, reg + index * sizeof(efx_oword_t)); in efx_reado_table()
229 #define EFX_PAGED_REG(page, reg) \ argument
230 ((page) * EFX_VI_PAGE_SIZE + (reg))
234 unsigned int reg, unsigned int page) in _efx_writeo_page() argument
236 reg = EFX_PAGED_REG(page, reg); in _efx_writeo_page()
239 "writing register %x with " EFX_OWORD_FMT "\n", reg, in _efx_writeo_page()
243 _efx_writeq(efx, value->u64[0], reg + 0); in _efx_writeo_page()
244 _efx_writeq(efx, value->u64[1], reg + 8); in _efx_writeo_page()
246 _efx_writed(efx, value->u32[0], reg + 0); in _efx_writeo_page()
247 _efx_writed(efx, value->u32[1], reg + 4); in _efx_writeo_page()
248 _efx_writed(efx, value->u32[2], reg + 8); in _efx_writeo_page()
249 _efx_writed(efx, value->u32[3], reg + 12); in _efx_writeo_page()
252 #define efx_writeo_page(efx, value, reg, page) \ argument
254 reg + \
255 BUILD_BUG_ON_ZERO((reg) != 0x830 && (reg) != 0xa10), \
263 unsigned int reg, unsigned int page) in _efx_writed_page() argument
265 efx_writed(efx, value, EFX_PAGED_REG(page, reg)); in _efx_writed_page()
267 #define efx_writed_page(efx, value, reg, page) \ argument
269 reg + \
270 BUILD_BUG_ON_ZERO((reg) != 0x400 && \
271 (reg) != 0x420 && \
272 (reg) != 0x830 && \
273 (reg) != 0x83c && \
274 (reg) != 0xa18 && \
275 (reg) != 0xa1c), \
284 unsigned int reg, in _efx_writed_page_locked() argument
291 efx_writed(efx, value, EFX_PAGED_REG(page, reg)); in _efx_writed_page_locked()
294 efx_writed(efx, value, EFX_PAGED_REG(page, reg)); in _efx_writed_page_locked()
297 #define efx_writed_page_locked(efx, value, reg, page) \ argument
299 reg + BUILD_BUG_ON_ZERO((reg) != 0x420), \