Lines Matching refs:cgx_dev
132 struct cgx *cgx_dev; in cgx_get_cgxcnt_max() local
135 list_for_each_entry(cgx_dev, &cgx_list, cgx_list) in cgx_get_cgxcnt_max()
136 if (cgx_dev->cgx_id > idmax) in cgx_get_cgxcnt_max()
137 idmax = cgx_dev->cgx_id; in cgx_get_cgxcnt_max()
157 struct cgx *cgx_dev; in cgx_get_pdata() local
159 list_for_each_entry(cgx_dev, &cgx_list, cgx_list) { in cgx_get_pdata()
160 if (cgx_dev->cgx_id == cgx_id) in cgx_get_pdata()
161 return cgx_dev; in cgx_get_pdata()
168 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_write() local
170 cgx_write(cgx_dev, lmac_id, offset, val); in cgx_lmac_write()
175 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_read() local
177 return cgx_read(cgx_dev, lmac_id, offset); in cgx_lmac_read()
192 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_get_p2x() local
195 cfg = cgx_read(cgx_dev, lmac_id, CGXX_CMRX_CFG); in cgx_lmac_get_p2x()
237 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_set() local
238 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_set()
244 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_set()
251 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_set()
255 cgx_write(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8)), in cgx_lmac_addr_set()
258 cfg = cgx_read(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0); in cgx_lmac_addr_set()
261 cgx_write(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0, cfg); in cgx_lmac_addr_set()
296 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_add() local
297 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_add()
306 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_add()
312 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_add()
319 cgx_write(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8)), cfg); in cgx_lmac_addr_add()
321 cfg = cgx_read(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0); in cgx_lmac_addr_add()
332 cgx_write(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0, cfg); in cgx_lmac_addr_add()
339 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_reset() local
340 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_reset()
348 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_reset()
354 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_reset()
357 cgx_write(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8)), 0); in cgx_lmac_addr_reset()
360 cfg = cgx_read(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0); in cgx_lmac_addr_reset()
363 cgx_write(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0, cfg); in cgx_lmac_addr_reset()
374 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_update() local
380 lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_update()
384 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_update()
393 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_update()
397 cfg = cgx_read(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8))); in cgx_lmac_addr_update()
401 cgx_write(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8)), cfg); in cgx_lmac_addr_update()
407 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_del() local
408 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_del()
417 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_del()
428 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_del()
433 cfg = cgx_read(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8))); in cgx_lmac_addr_del()
440 cfg = cgx_read(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0); in cgx_lmac_addr_del()
443 cgx_write(cgx_dev, lmac_id, CGXX_CMRX_RX_DMAC_CTL0, cfg); in cgx_lmac_addr_del()
446 cgx_write(cgx_dev, 0, (CGXX_CMRX_RX_DMAC_CAM0 + (index * 0x8)), 0); in cgx_lmac_addr_del()
453 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_max_entries_get() local
454 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_max_entries_get()
464 struct cgx *cgx_dev = cgx_get_pdata(cgx_id); in cgx_lmac_addr_get() local
465 struct lmac *lmac = lmac_pdata(lmac_id, cgx_dev); in cgx_lmac_addr_get()
471 mac_ops = cgx_dev->mac_ops; in cgx_lmac_addr_get()
473 id = get_sequence_id_of_lmac(cgx_dev, lmac_id); in cgx_lmac_addr_get()
477 cfg = cgx_read(cgx_dev, 0, CGXX_CMRX_RX_DMAC_CAM0 + index * 0x8); in cgx_lmac_addr_get()