Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/radeon: fix a semaphore deadlock on pre cayman asics

The out of order execution of semaphore commands on
pre cayman asics doesn't work correctly and can
cause deadlocks, so turn it off for now.

Signed-off-by: Christian König <deathsimple@vodafone.de>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>

authored by

Christian König and committed by
Dave Airlie
0be70439 dac12d1f

+4
+3
drivers/gpu/drm/radeon/r600.c
··· 2362 2362 uint64_t addr = semaphore->gpu_addr; 2363 2363 unsigned sel = emit_wait ? PACKET3_SEM_SEL_WAIT : PACKET3_SEM_SEL_SIGNAL; 2364 2364 2365 + if (rdev->family < CHIP_CAYMAN) 2366 + sel |= PACKET3_SEM_WAIT_ON_SIGNAL; 2367 + 2365 2368 radeon_ring_write(ring, PACKET3(PACKET3_MEM_SEMAPHORE, 1)); 2366 2369 radeon_ring_write(ring, addr & 0xffffffff); 2367 2370 radeon_ring_write(ring, (upper_32_bits(addr) & 0xff) | sel);
+1
drivers/gpu/drm/radeon/r600d.h
··· 831 831 #define PACKET3_STRMOUT_BUFFER_UPDATE 0x34 832 832 #define PACKET3_INDIRECT_BUFFER_MP 0x38 833 833 #define PACKET3_MEM_SEMAPHORE 0x39 834 + # define PACKET3_SEM_WAIT_ON_SIGNAL (0x1 << 12) 834 835 # define PACKET3_SEM_SEL_SIGNAL (0x6 << 29) 835 836 # define PACKET3_SEM_SEL_WAIT (0x7 << 29) 836 837 #define PACKET3_MPEG_INDEX 0x3A