gallium/hud: fix a problem where objects are free'd while in use.
authorSteven Toth <stoth@kernellabs.com>
Mon, 24 Oct 2016 14:10:49 +0000 (10:10 -0400)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Mon, 7 Nov 2016 17:31:52 +0000 (18:31 +0100)
commit6ffed086795aaa84ab35668bb59d712cdde34da3
tree449619d40097991f2a8e3c105c3a2f18b41ad870
parenta5e733c6b52e93de3000647d075f5ca2f55fcb71
gallium/hud: fix a problem where objects are free'd while in use.

Instead of trying to maintain a reference counted list of valid HUD
objects, and freeing them accordingly, creating race conditions
between unanticipated multiple threads, simply accept they're
allocated once and never released until the process terminates.

They're a shared resource between multiple threads, so accept
they're always available for use.

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/gallium/auxiliary/hud/hud_cpufreq.c
src/gallium/auxiliary/hud/hud_diskstat.c
src/gallium/auxiliary/hud/hud_nic.c
src/gallium/auxiliary/hud/hud_sensors_temp.c