descriptor concept in NIC
I am trying to understand the concept of Rx and Tx descriptors used in Network driver code.
- Are Descriptors in software(RAM) or hardware (NIC card).
- How do they get filled.
EDIT: So in a Realtek card driver code. I have a following struct defined.
struct Desc
{
uint32_t opts1;
uint32_t opts2;
uint64_t addr;
};
txd->addr = cpu_to_le64(mapping);
txd->opts2 = cpu_to_le32(opts2);
txd->opts1 = cpu_to_le32(opts1 & ~DescOwn);
So are the opts1 and opts2 and there bits like DescOwn card specific? Will they be defined by the manufacturer in the datasheet?