npkt.next filed -- what is it ?

Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?

Thanks,
vasilii mailto:vasilii@cambira.com

vasilii <vv40in@rambler.ru> wrote:

Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?

Yes.

chris

\

Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Chris McKillop <cdm@qnx.com> ÐÉÛÅÔ × ÓÏÏÂÝÅÎÉÉ:a9q6mr$4gc$1@nntp.qnx.com

vasilii <> vv40in@rambler.ru> > wrote:
Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?


Yes.

Does it mean that before exit
from my rx_up handler
it is need to do tx_done()
for each of npkt-s from this chain?

Thanks,
vasilii


chris

\

Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

No…When you do tx_done…all the npkts in the chain are taken care of.

Sreekanth

“vasilii” <vv40in@rambler.ru> wrote in message
news:a9snh2$g1g$1@inn.qnx.com

Chris McKillop <> cdm@qnx.com> > ÐÉÛÅÔ ×
ÓÏÏÂÝÅÎÉÉ:a9q6mr$4gc$> 1@nntp.qnx.com> …
vasilii <> vv40in@rambler.ru> > wrote:
Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?


Yes.

Does it mean that before exit
from my rx_up handler
it is need to do tx_done()
for each of npkt-s from this chain?

Thanks,
vasilii



chris

\

Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I
get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/
\

No…When you do tx_done…all the npkts in the chain are taken care of.
Sreekanth
AFAIK io-net does not take care of this chain.

I doubt that originator should take care of this npkt chain, is not it ?

if so – one more questions:
Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?
Q2: who have privilages to set next filed? originator of npkt, is not it?
Q3: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?


Thanks
vasilii mailto:vv40in@rambler.ru

Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?


Yes.

Does it mean that before exit
from my rx_up handler
it is need to do tx_done()
for each of npkt-s from this chain?

Thanks,
vasilii



chris
Chris McKillop <> cdm@qnx.com> > "The faster I go, the behinder I

i am sorry, i have mistaken in previouse message:

I doubt that originator should take care of this npkt chain, is not it ?
it need to read as
IMHO originator should take care of this npkt chain, is not it ?

vasilii <vv40in@rambler.ru> ÐÉÛÅÔ × ÓÏÏÂÝÅÎÉÉ:aa1j8u$df$1@inn.qnx.com

No…When you do tx_done…all the npkts in the chain are taken care of.
Sreekanth
AFAIK io-net does not take care of this chain.
I doubt that originator should take care of this npkt chain, is not it ?

if so – one more questions:
Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?
Q2: who have privilages to set next filed? originator of npkt, is not it?
Q3: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?


Thanks
vasilii mailto:> vv40in@rambler.ru

Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?


Yes.

Does it mean that before exit
from my rx_up handler
it is need to do tx_done()
for each of npkt-s from this chain?

Thanks,
vasilii



chris
Chris McKillop <> cdm@qnx.com> > "The faster I go, the behinder I









\

You are absolutely right.Io-net does not take care of the Chain.The
originator has to take care of the Chain.But the module which does tx_done
need not go through the chain to do tx_done for each of the npkts in the
link(which i thought, was your previous question).Please note that the
originator of the packet need not(probably should not) call tx_done…

regards,

Sreekanth

“vasilii” <vv40in@rambler.ru> wrote in message
news:aa1jfq$lf$1@inn.qnx.com

i am sorry, i have mistaken in previouse message:
I doubt that originator should take care of this npkt chain, is not it
?
it need to read as
IMHO originator should take care of this npkt chain, is not it ?


vasilii <> vv40in@rambler.ru> > ÐÉÛÅÔ × ÓÏÏÂÝÅÎÉÉ:aa1j8u$df$> 1@inn.qnx.com> …

No…When you do tx_done…all the npkts in the chain are taken care of.
Sreekanth
AFAIK io-net does not take care of this chain.
I doubt that originator should take care of this npkt chain, is not it
?

if so – one more questions:
Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?
Q2: who have privilages to set next filed? originator of npkt, is not
it?
Q3: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?


Thanks
vasilii mailto:> vv40in@rambler.ru

Hi,

what is “next” field in npkt_t ?
Does it mean –
if my rx_up handler has arrived npkt
with non zero next filed — should
i concern this npkt as chain of npkt-s ?


Yes.

Does it mean that before exit
from my rx_up handler
it is need to do tx_done()
for each of npkt-s from this chain?

Thanks,
vasilii



chris
Chris McKillop <> cdm@qnx.com> > "The faster I go, the behinder
I











\

anybody, could you answer the following questions:

Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?
Q2: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?

Thanks
vasilii mailto:vv40in@rambler.ru

“vasilii” <vv40in@rambler.ru> wrote in message
news:aa2qjs$ovs$1@inn.qnx.com

anybody, could you answer the following questions:

Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?
Same IP packet.
Q2: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?
First one will have an offset of ETHER_HDR_LEN(14)( assuming it is ethernet)

and all the others will have Zero

Thanks
vasilii mailto:> vv40in@rambler.ru



Regards,

Sreekanth

vasilii <vv40in@rambler.ru> wrote:

anybody, could you answer the following questions:

Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?

If they are coming up from a device they are going to simply be ethernet
packets. Devices know nothing of protocols and can’t control data flow.
Obviously in both directions an IP packet will be contained within a single
npkt and if you have several npkt’s chained they are going to be different
packets to be put out on, or taken from, the wire.


Q2: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?

This is going to depend on where you insert your filter I think. For
somethings the offsets will be the same. I am not sure if io-net will break
up the npkt’s if they are not.

chris


Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Hi,

What can i do if i need to do tx_up()
only for some packets in npkt chain
or do tx_done() in different time
for different packets in npkt chain?

Thanks
vasa

Q1: are those npkt-s in the chain the single ip packet
or its are different ip packets ?


If they are coming up from a device they are going to simply be ethernet
packets. Devices know nothing of protocols and can’t control data flow.
Obviously in both directions an IP packet will be contained within a
single
npkt and if you have several npkt’s chained they are going to be different
packets to be put out on, or taken from, the wire.



Q2: about offset and framlen_sub in npkt
(its are parameters of rx_up handler in filter) –
my rx_up handler arrives all npkt-s in chain
with the same values of offset and framlen_sub, are not it?


This is going to depend on where you insert your filter I think. For
somethings the offsets will be the same. I am not sure if io-net will
break
up the npkt’s if they are not.

chris


Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Hi,

What can i do if i need to do tx_up()
only for some packets in npkt chain
or do tx_done() in different time
for different packets in npkt chain?

i what to extend question:

can i do the following:

npkt_t *n0 = npkpt->next;
npkt->next = 0;
npkt_t *n1 = n0->next;
n0->next = 0;

io_net->tx_done(npkt);
io_net->tx_up(n0);
io_net->tx_done(n0);
io_net->tx_done(n1);


Thanks
vasa

For up headed packets, you call tx_done() if you don’t attempt
to pass it up, or you do but ion->tx_up() returns 0. You should
only ever call ion->tx_up() on a single packet at a time.

-seanb

vasa <vv40in@newmail.ru> wrote:
: Hi,
:>
:> What can i do if i need to do tx_up()
:> only for some packets in npkt chain
:> or do tx_done() in different time
:> for different packets in npkt chain?

: i what to extend question:

: can i do the following:

: npkt_t *n0 = npkpt->next;
: npkt->next = 0;
: npkt_t *n1 = n0->next;
: n0->next = 0;

: io_net->tx_done(npkt);
: io_net->tx_up(n0);
: io_net->tx_done(n0);
: io_net->tx_done(n1);


: Thanks
: vasa