[Ns-developers] MacRxMiddle::SequenceControlSmaller method

Mirko Banchi mk.banchi at gmail.com
Tue Aug 17 10:46:00 PDT 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Mathieu and all,

i'd like take a look at the function  
MacRxMiddle::SequenceControlSmaller. The first question is: what this  
function does? I suppose that it is used to figure out if a packet is  
an "old" packet or not. Standard specifies that range of sequence  
number are splitted in two parts: one corresponds to packets that can  
be considered new and one to packets that can be considered old. For  
simplicity we can consider a smaller range, for example, of 10  
sequence numbers so with an initial sequence number equals to 7  
suppose to have next situation:

0  1  2  3  4  5  6  7  8  9
  *  *   |   |   |    |   |   *   *   *

* = new packet
| = old packet

Now i used that function to discover if the packet number 2 is old or  
new in comparison to packet number 7. So i used that logic (modified  
accordingly) but the function returns the following results:

SequenceControlSmaller (7<<4, 2<<4) = true
SequenceControlSmaller (2<<4, 7<<4) = false

I think that the function should return always true because if 7 is an  
old packet 2 in a new one and vice versa. What do you think about?

Second question: who uses this function?It seems that it never  
used...this function would be very useful to me... what do you think  
about moving it to qos-utils.h?

Regards,

M.

- --
Mirko Banchi

e-mail:    mk.banchi at gmail.com
id-jabber: mk.banchi at jabber.org

PGP key fingerprint:

308F BFB1 4E67 2522 C88E
DC69 7631 52ED 32A5 6456



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkxqytkACgkQdjFS7TKlZFZ3AQCbBKDiQK4toH7Cqz64xbAiwLga
srEAn2znmXijDYpqVyS25sVe39h7ZqF4
=pBBA
-----END PGP SIGNATURE-----



More information about the Ns-developers mailing list