On 03/20/15 15:23, Mike Holmes wrote:
Radu-Andrei Bulie or Maxim can you capture this as a bug

https://bugs.linaro.org/enter_bug.cgi?product=OpenDataPlane
https://bugs.linaro.org/show_bug.cgi?id=1383

On 20 March 2015 at 08:14, Maxim Uvarov <[email protected] <mailto:[email protected]>> wrote:

    Hello Raru-Andrei,  thanks for finding this.  Feel free to send
    patch for that issue.

    Stuart, please review that change.

    Best regards,
    Maxim.

    On 03/20/15 12:43, Radu-Andrei Bulie wrote:


        Hi,

        In the odp_pktio validation – a pktio is created and it is
        configured with a PKTIN queue.

        Packets are then enqueued to the out queue of the device.

        In the function *wait_for_packet***I think is an issue when an
        event is received.

        There is  the following condition :

        *if*(queue != ODP_QUEUE_INVALID)

                          ev = queue_deq_wait_time(queue, ns);

        *else*

                          ev  = odp_schedule(NULL, ns);

        The *queue* that comes as input param, is the PKTIN queue
        which is a scheduled queue.

        As it can be noticed the queue_deq_wait_time will be called
        (PKTN queue is valid) and there,

        *an explicit dequeue operation will be performed on a
        scheduled queue *which is not OK.

        So a schedule would be proper instead of explicit dequeue.

        A possible fix is to check for *queue type instead of
        validity*, and if the queue is POLL  then take the
        corresponding branch:

        *if*(*odp_queue_type(*queue) == ODP_QUEUE_TYPE_POLL)

                          ev = queue_deq_wait_time(queue, ns);

        *else*

                          ev  = odp_schedule(NULL, ns);

        Regards,

        Radu



        _______________________________________________
        lng-odp mailing list
        [email protected] <mailto:[email protected]>
        http://lists.linaro.org/mailman/listinfo/lng-odp



    _______________________________________________
    lng-odp mailing list
    [email protected] <mailto:[email protected]>
    http://lists.linaro.org/mailman/listinfo/lng-odp




--
Mike Holmes
Technical Manager - Linaro Networking Group
Linaro.org <http://www.linaro.org/>***│ *Open source software for ARM SoCs



_______________________________________________
lng-odp mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/lng-odp

Reply via email to