pinggit / dpdk-contrail-book

contrail dpdk day one book
9 stars 3 forks source link

ring and packet buffer #11

Closed pinggit closed 4 years ago

pinggit commented 4 years ago

ch2 page 29: image

this clearly shows, 2 different objects exist in host AND NIC:

  1. pointers (ring, array of descriptors/pointers), which points to the address of real packets
  2. the buffer which stores the real packet data

in NIC: it is called queue (pointers), and FIFO (buffer for data)

in host: it is called ring(array of pointers), and mbuf(buffer for data)

ldurandadomia commented 4 years ago

Yes. But it is more to underline we have to transfer packets from 2 distinct environments:

queue and buffers (FIFO) are generic terms. ring and mbuf are the same but in DPDK context.

pinggit commented 4 years ago

this is an important clarification I believe, when you want to pursue the conceptually accuracy. normally the term "queue" means the buffer for real data. At least in router docs it is normally that. but in this specific diagram it really means the pointers (addr of mem) pointing to the real buffers.

on the other hand, in some other context of the book, I believe we also refer "queue" as the data buffer. I hope this won't be a problem for readers.