• Inaky Perez-Gonzalez's avatar
    wimax/i2400m: fix device crash: fix optimization in _roq_queue_update_ws · 4e5b6d00
    Inaky Perez-Gonzalez authored
    When the i2400m receives data and the device indicates there has to be
    reordering, we keep an sliding window implementation to sort the
    packets before sending them to the network stack.
    
    One of the "operations" that the device indicates is "queue a packet
    and update the window start". When the queue is empty, this is
    equivalent to "deliver the packet and update the window start".
    
    That case was optimized in i2400m_roq_queue_update_ws() so that we
    would not pointlessly queue and dequeue a packet. However, when the
    optimization was active, it wasn't updating the window start. That
    caused the reorder management code to get confused later on with what
    seemed to be wrong reorder requests from the device.
    
    Thus the fix implemented is to do the right thing and update the
    window start in both cases, when the queue is empty (and the
    optimization is done) and when not.
    Signed-off-by: default avatarInaky Perez-Gonzalez <inaky@linux.intel.com>
    4e5b6d00
rx.c 38.2 KB