• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/net/atl1c/

Lines Matching refs:tpd_ring

705 	adapter->tpd_ring[0].count = 1024;
802 struct atl1c_tpd_ring *tpd_ring = &adapter->tpd_ring[type];
807 ring_count = tpd_ring->count;
809 buffer_info = &tpd_ring->buffer_info[index];
814 memset(tpd_ring->desc, 0, sizeof(struct atl1c_tpd_desc) *
816 atomic_set(&tpd_ring->next_to_clean, 0);
817 tpd_ring->next_to_use = 0;
851 struct atl1c_tpd_ring *tpd_ring = adapter->tpd_ring;
858 tpd_ring[i].next_to_use = 0;
859 atomic_set(&tpd_ring[i].next_to_clean, 0);
860 buffer_info = tpd_ring[i].buffer_info;
861 for (j = 0; j < tpd_ring->count; j++)
894 if (adapter->tpd_ring[0].buffer_info) {
895 kfree(adapter->tpd_ring[0].buffer_info);
896 adapter->tpd_ring[0].buffer_info = NULL;
909 struct atl1c_tpd_ring *tpd_ring = adapter->tpd_ring;
922 tpd_ring[i].count = tpd_ring[0].count;
929 size = sizeof(struct atl1c_buffer) * (tpd_ring->count * 2 +
931 tpd_ring->buffer_info = kzalloc(size, GFP_KERNEL);
932 if (unlikely(!tpd_ring->buffer_info)) {
938 tpd_ring[i].buffer_info =
939 (struct atl1c_buffer *) (tpd_ring->buffer_info + count);
940 count += tpd_ring[i].count;
945 (struct atl1c_buffer *) (tpd_ring->buffer_info + count);
955 sizeof(struct atl1c_tpd_desc) * tpd_ring->count * 2 +
970 tpd_ring[0].dma = roundup(ring_header->dma, 8);
971 offset = tpd_ring[0].dma - ring_header->dma;
973 tpd_ring[i].dma = ring_header->dma + offset;
974 tpd_ring[i].desc = (u8 *) ring_header->desc + offset;
975 tpd_ring[i].size =
976 sizeof(struct atl1c_tpd_desc) * tpd_ring[i].count;
977 offset += roundup(tpd_ring[i].size, 8);
1002 kfree(tpd_ring->buffer_info);
1013 struct atl1c_tpd_ring *tpd_ring = (struct atl1c_tpd_ring *)
1014 adapter->tpd_ring;
1022 (u32)((tpd_ring[atl1c_trans_normal].dma &
1026 (u32)(tpd_ring[atl1c_trans_normal].dma &
1029 (u32)(tpd_ring[atl1c_trans_high].dma &
1032 (u32)(tpd_ring[0].count & TPD_RING_SIZE_MASK));
1607 struct atl1c_tpd_ring *tpd_ring = (struct atl1c_tpd_ring *)
1608 &adapter->tpd_ring[type];
1611 u16 next_to_clean = atomic_read(&tpd_ring->next_to_clean);
1625 buffer_info = &tpd_ring->buffer_info[next_to_clean];
1627 if (++next_to_clean == tpd_ring->count)
1629 atomic_set(&tpd_ring->next_to_clean, next_to_clean);
1939 struct atl1c_tpd_ring *tpd_ring = &adapter->tpd_ring[type];
1943 next_to_clean = atomic_read(&tpd_ring->next_to_clean);
1944 next_to_use = tpd_ring->next_to_use;
1948 (tpd_ring->count + next_to_clean - next_to_use - 1);
1959 struct atl1c_tpd_ring *tpd_ring = &adapter->tpd_ring[type];
1963 next_to_use = tpd_ring->next_to_use;
1964 if (++tpd_ring->next_to_use == tpd_ring->count)
1965 tpd_ring->next_to_use = 0;
1966 tpd_desc = ATL1C_TPD_DESC(tpd_ring, next_to_use);
1974 struct atl1c_tpd_ring *tpd_ring = adapter->tpd_ring;
1976 return &tpd_ring->buffer_info[tpd -
1977 (struct atl1c_tpd_desc *)tpd_ring->desc];
2184 struct atl1c_tpd_ring *tpd_ring = &adapter->tpd_ring[type];
2191 prod_data |= tpd_ring->next_to_use & 0xFFFF;
2195 prod_data |= (tpd_ring->next_to_use & 0xFFFF) << 16;