commit | 86ac7dc10af252a05fbbe622a6b27d5eaf83003f | [log] [tgz] |
---|---|---|
author | Andy Ross <andrew.j.ross@intel.com> | Fri Jan 17 11:55:26 2020 -0800 |
committer | Andrew Boie <andrewboie@gmail.com> | Tue Jan 21 14:47:52 2020 -0800 |
tree | 81f053498161938337f5b09ce6f46f99f996fdc4 | |
parent | 4c2fc2aed7c7d279f867a574c0459295b35ee029 [diff] |
samples/userspace/shared_mem: Fix SMP race There was some unlocked initialization code in the "enc" thread that would race with the "pt" and "ct" threads if another CPU was available to run them (it was safe on UP because "enc" entered the queue first and was cooperative, the others wouldn't run until it blocked). Move it to main() and remove the enc_state guard variable which is no longer doing anything. Signed-off-by: Andy Ross <andrew.j.ross@intel.com>