mirror of
https://github.com/openvswitch/ovs
synced 2025-10-17 14:28:02 +00:00
dpif-netdev: Correctly update 'key' in emc_processing().
The 'key' pointer must point at the first unused element in the key
array.
Fixes: b89c678b7a
("dpif-netdev: optmizing emc_processing()")
CC: Andy Zhou <azhou@ovn.org>
Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
Acked-by: Andy Zhou <azhou@nicira.com>
This commit is contained in:
@@ -3357,7 +3357,10 @@ emc_processing(struct dp_netdev_pmd_thread *pmd, struct dp_packet **packets,
|
||||
/* Exact match cache missed. Group missed packets together at
|
||||
* the beginning of the 'packets' array. */
|
||||
packets[n_missed] = packet;
|
||||
key = &keys[n_missed++];
|
||||
/* 'key[n_missed]' contains the key of the current packet and it
|
||||
* must be returned to the caller. The next key should be extracted
|
||||
* to 'keys[n_missed + 1]'. */
|
||||
key = &keys[++n_missed];
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user