Ensure that remainder of completion records are read only after
verifying the generation bit (or sequence number).
Signed-off-by: Michael Brown <mcb30@ipxe.org>
bit = ( dqo->flags & GVE_DQO_TXF_GEN );
if ( ( !! bit ) == ( !! gen ) )
break;
+ rmb();
tx->done++;
/* Ignore non-packet completions */
bit = ( dqo->len & cpu_to_le16 ( GVE_DQO_RXL_GEN ) );
if ( ( !! bit ) == ( !! gen ) )
break;
+ rmb();
/* Parse completion */
len = ( le16_to_cpu ( dqo->len ) &
/* Check sequence number */
if ( ( gqi->seq & GVE_GQI_RX_SEQ_MASK ) != seq )
break;
+ rmb();
seq = gve_next ( seq );
/* Parse completion */