Message ID | 1426792426-12507-6-git-send-email-zoltan.kiss@linaro.org |
---|---|
State | New |
Headers | show |
On 03/19/15 22:13, Zoltan Kiss wrote: > For odp_packet_push_tail > > Signed-off-by: Zoltan Kiss <zoltan.kiss@linaro.org> > --- > lib/netdev-odp.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/lib/netdev-odp.c b/lib/netdev-odp.c > index 4b13bfe..87f6ec4 100644 > --- a/lib/netdev-odp.c > +++ b/lib/netdev-odp.c > @@ -329,7 +329,8 @@ clone_pkts(struct netdev_odp *dev, struct dpif_packet **pkts, > > odp_packet_l2_offset_set(pkt, 0); > > - odp_packet_push_tail(pkt, size); > + if (!odp_packet_push_tail(pkt, size)) odp_unlikely() is good to be here. Maxim. > + VLOG_WARN_RL(&rl, "Can't push tail with %lu", size); > odp_packet_copydata_in(pkt, 0, size, ofpbuf_data(&pkts[i]->ofpbuf)); > odp_pkts[newcnt] = pkt; > newcnt++;
On 20/03/15 15:41, Maxim Uvarov wrote: > On 03/19/15 22:13, Zoltan Kiss wrote: >> For odp_packet_push_tail >> >> Signed-off-by: Zoltan Kiss <zoltan.kiss@linaro.org> >> --- >> lib/netdev-odp.c | 3 ++- >> 1 file changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/lib/netdev-odp.c b/lib/netdev-odp.c >> index 4b13bfe..87f6ec4 100644 >> --- a/lib/netdev-odp.c >> +++ b/lib/netdev-odp.c >> @@ -329,7 +329,8 @@ clone_pkts(struct netdev_odp *dev, struct >> dpif_packet **pkts, >> odp_packet_l2_offset_set(pkt, 0); >> - odp_packet_push_tail(pkt, size); >> + if (!odp_packet_push_tail(pkt, size)) > odp_unlikely() is good to be here. Ok > > Maxim. >> + VLOG_WARN_RL(&rl, "Can't push tail with %lu", size); >> odp_packet_copydata_in(pkt, 0, size, >> ofpbuf_data(&pkts[i]->ofpbuf)); >> odp_pkts[newcnt] = pkt; >> newcnt++; > > > _______________________________________________ > lng-odp mailing list > lng-odp@lists.linaro.org > http://lists.linaro.org/mailman/listinfo/lng-odp
diff --git a/lib/netdev-odp.c b/lib/netdev-odp.c index 4b13bfe..87f6ec4 100644 --- a/lib/netdev-odp.c +++ b/lib/netdev-odp.c @@ -329,7 +329,8 @@ clone_pkts(struct netdev_odp *dev, struct dpif_packet **pkts, odp_packet_l2_offset_set(pkt, 0); - odp_packet_push_tail(pkt, size); + if (!odp_packet_push_tail(pkt, size)) + VLOG_WARN_RL(&rl, "Can't push tail with %lu", size); odp_packet_copydata_in(pkt, 0, size, ofpbuf_data(&pkts[i]->ofpbuf)); odp_pkts[newcnt] = pkt; newcnt++;
For odp_packet_push_tail Signed-off-by: Zoltan Kiss <zoltan.kiss@linaro.org> --- lib/netdev-odp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)