![](https://pdfstore-manualsonline.prod.a.ki/pdfasset/d/b7/db742270-ca8c-4749-a876-e49802fee529/db742270-ca8c-4749-a876-e49802fee529-bg1d.png)
2.5.5.4BufferLength
2.5.5.5PacketLength
2.5.5.6StartofPacket(SOP)Flag
2.5.5.7EndofPacket(EOP)Flag
2.5.5.8Ownership(OWNER)Flag
2.5.5.9EndofQueue(EOQ)Flag
Architecture
This16-bitfieldisusedfortwopurposes:
•Beforethedescriptorisfirstplacedonthereceivequeuebytheapplicationsoftware,thebufferlength
fieldisfirstinitializedbythesoftwaretohavethephysicalsizeoftheemptydatabufferpointedtoby
thebufferpointerfield.
•AftertheemptybufferhasbeenprocessedbytheEMACandfilledwithreceiveddatabytes,thebuffer
lengthfieldisupdatedbytheEMACtoreflecttheactualnumberofvaliddatabyteswrittentothe
buffer.
This16-bitfieldspecifiesthenumberofdatabytesintheentirepacket.Thisvalueisinitializedtozeroby
thesoftwareapplicationforemptypacketbuffers.ThevalueisfilledinbytheEMAConthefirstbuffer
usedforagivenpacket.ThisissignifiedbytheEMACsettingastartofpacket(SOP)flag.Thepacket
lengthissetbytheEMAConallSOPbufferdescriptors.
Whenset,thisflagindicatesthatthedescriptorpointstoapacketbufferthatisthestartofanewpacket.
Inthecaseofasinglefragmentpacket,boththeSOPandendofpacket(EOP)flagsareset.Otherwise,
thedescriptorpointingtothelastpacketbufferforthepackethastheEOPflagset.Thisflagisinitially
clearedbythesoftwareapplicationbeforeaddingthedescriptortothereceivequeue.Thisbitissetbythe
EMAConSOPdescriptors.
Whenset,thisflagindicatesthatthedescriptorpointstoapacketbufferthatislastforagivenpacket.In
thecaseofasinglefragmentpacket,boththestartofpacket(SOP)andEOPflagsareset.Otherwise,the
descriptorpointingtothelastpacketbufferforthepackethastheEOPflagset.Thisflagisinitiallycleared
bythesoftwareapplicationbeforeaddingthedescriptortothereceivequeue.ThisbitissetbytheEMAC
onEOPdescriptors.
Whenset,thisflagindicatesthatthedescriptoriscurrentlyownedbytheEMAC.Thisflagissetbythe
softwareapplicationbeforeaddingthedescriptortothereceivedescriptorqueue.Thisflagisclearedby
theEMAConceitisfinishedwithagivensetofdescriptors,associatedwithareceivedpacket.Theflagis
updatedbytheEMAConSOPdescriptoronly.SowhentheapplicationidentifiesthattheOWNERflagis
clearedonanSOPdescriptor,itmayassumethatalldescriptorsuptoandincludingthefirstwiththeEOP
flagsethavebeenreleasedbytheEMAC.(Notethatinthecaseofsinglebufferpackets,thesame
descriptorwillhaveboththeSOPandEOPflagsset.)
Whenset,thisflagindicatesthatthedescriptorinquestionwasthelastdescriptorinthereceivequeuefor
agivenreceivechannel,andthatthecorrespondingreceiverchannelhashalted.Thisflagisinitially
clearedbythesoftwareapplicationpriortoaddingthedescriptortothereceivequeue.Thisbitissetby
theEMACwhentheEMACidentifiesthatadescriptoristhelastforagivenpacketreceived(alsosetsthe
EOPflag),andtherearenomoredescriptorsinthereceivelist(nextdescriptorpointerisNULL).
ThesoftwareapplicationcanusethisbittodetectwhentheEMACreceiverforthecorrespondingchannel
hashalted.Thisisusefulwhentheapplicationappendsadditionalfreebufferdescriptorstoanactive
receivequeue.NotethatthisflagisvalidonEOPdescriptorsonly.
SPRUEQ6–December2007EthernetMediaAccessController(EMAC)/ManagementDataInput/Output(MDIO)29
SubmitDocumentationFeedback