[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ns] Packet copy function
Is it possible to do a more intelligent version of a packet copy whereby the same packet itself is simply set back up in the scheduler and ready to be scheduled on a link?
1 Packet comes in via recv
2 Packet is going out on only 1 link (encapsulated header info)
3 Packet is somehow modified (???)
4 Packet is sent out on link
Currently, I have written my own version of the multicast replicator and I would like to avoid unnecessary replications, i.e. the packet comes into a link and leaves on only one interface. I think this is where the majority of my simulation is spent since each time a multicast packet enters and leaves a link, it has to go through the copy function. It wouldn't be so bad, but the copy functions copies over some 3000 bytes of header information.
I would like to simply set a few values in the packet (whatever appropriate headers are required) and then put it out onto the link. I already have the transfer to the link working but I'm not sure what are the critical components to allow a packet to be scheduled again. I glanced at the alloc() function but I was hoping for a bit of enlightenment from anyone who has worked with those functions.
I am just missing the third step and I would like to do the step as efficiently as possible to help speed up my simulation runs. Thanks!
Aaron
---------------------------------------
Aaron Striegel
Ph.D Candidate, Computer Engineering - Internet QoS
Dept. of Electrical & Computer Engineering
Iowa State University
Webpage: http://www.public.iastate.edu/~magico