radeon/vce: fix VCE fail after rebase
authorLeo Liu <leo.liu@amd.com>
Mon, 15 Jun 2015 19:20:20 +0000 (15:20 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Fri, 14 Aug 2015 13:02:30 +0000 (15:02 +0200)
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
src/gallium/drivers/radeon/radeon_vce_50.c

index 80a69b5442b8c1d5014df5f66504bde30de93af2..a11cc6a2860c4aa261fbebc5f806fdf901665074 100644 (file)
@@ -96,13 +96,11 @@ static void encode(struct rvce_encoder *enc)
        task_info(enc, 0x00000003);
 
        RVCE_BEGIN(0x05000001); // context buffer
-       RVCE_READWRITE(enc->cpb.res->cs_buf, enc->cpb.res->domains, 0); // encodeContextAddressHi
-       RVCE_CS(0x00000000); // encodeContextAddressLo
+       RVCE_READWRITE(enc->cpb.res->cs_buf, enc->cpb.res->domains, 0); // encodeContextAddressHi/Lo
        RVCE_END();
 
        RVCE_BEGIN(0x05000004); // video bitstream buffer
-       RVCE_WRITE(enc->bs_handle, RADEON_DOMAIN_GTT, 0); // videoBitstreamRingAddressHi
-       RVCE_CS(0x00000000); // videoBitstreamRingAddressLo
+       RVCE_WRITE(enc->bs_handle, RADEON_DOMAIN_GTT, 0); // videoBitstreamRingAddressHi/Lo
        RVCE_CS(enc->bs_size); // videoBitstreamRingSize
        RVCE_END();
 
@@ -127,10 +125,10 @@ static void encode(struct rvce_encoder *enc)
        RVCE_CS(0x00000000); // insertAUD
        RVCE_CS(0x00000000); // endOfSequence
        RVCE_CS(0x00000000); // endOfStream
-       RVCE_READ(enc->handle, RADEON_DOMAIN_VRAM, 0); // inputPictureLumaAddressHi
-       RVCE_CS(enc->luma->level[0].offset); // inputPictureLumaAddressLo
-       RVCE_READ(enc->handle, RADEON_DOMAIN_VRAM, 0); // inputPictureChromaAddressHi
-       RVCE_CS(enc->chroma->level[0].offset); // inputPictureChromaAddressLo
+       RVCE_READ(enc->handle, RADEON_DOMAIN_VRAM,
+               enc->luma->level[0].offset); // inputPictureLumaAddressHi/Lo
+       RVCE_READ(enc->handle, RADEON_DOMAIN_VRAM,
+               enc->chroma->level[0].offset); // inputPictureChromaAddressHi/Lo
        RVCE_CS(align(enc->luma->npix_y, 16)); // encInputFrameYPitch
        RVCE_CS(enc->luma->level[0].pitch_bytes); // encInputPicLumaPitch
        RVCE_CS(enc->chroma->level[0].pitch_bytes); // encInputPicChromaPitch