Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Altera_Forum
Honored Contributor I
803 Views

Maximum UDP packet Size for NIOS-ii

Hello Friend's, 

 

finally i have come out from "no free buffer for rx":). 

 

Just by increasing the UDP packet size from 512 to 1472 bytes. 

 

So if we increase the UDP packet size the number of call "recivefrom"  

 

minimize. and processor have enough time to handel the receive packets. 

 

now can any one tell me what is the maximum limit for udp packet size for  

 

nios-ii, because as i increase the UDP packet size from 1472 to 2048. it stop  

 

receiving the packets.  

 

 

Regards 

 

kaushal
0 Kudos
4 Replies
Altera_Forum
Honored Contributor I
60 Views

Maximum packet size is determined by MTU: http://en.wikipedia.org/wiki/maximum_transmission_unit 

 

So Your packet size 2048 bytes doesn't make any sense.
Altera_Forum
Honored Contributor I
60 Views

A UDP packet can have a size of up to 64k (including headers), but if the transport interface used under IP doesn't support packets this size, it will either be fragmented or dropped. I think that a most IP stacks just choose to drop them. In order to avoid fragmentation on an Ethernet link, the biggest payload size is 1472 bytes.

Altera_Forum
Honored Contributor I
60 Views

Thanking you Daixiwen/Socrates, 

 

i have set the packet size 1472 bytes for further processing.  

as in UDP case fragmented packet increase unreliability because of chance of dropping packet,so fix my packet size 1472. 

 

Thanx  

 

Kaushal
Altera_Forum
Honored Contributor I
60 Views

Most 'real' UDP/IP stacks fragment UDP datagrams that exceed the ethernet (or other network) frame size. 

For instance NFS (over UDP) will typically do 8k transfers as a single UDP packet that gets transferred as 6 back-to-back ethernet frames.