Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/drivers/media/platform/apple/avd/avd-drv.c b/drivers/media/platform/apple/avd/avd-drv.c
- index 05c1c5260536..b143886b05ac 100644
- --- a/drivers/media/platform/apple/avd/avd-drv.c
- +++ b/drivers/media/platform/apple/avd/avd-drv.c
- @@ -426,7 +426,7 @@ static const struct avd_variant avd_t6000_variant = {
- AVD_CAPABILITY_VP9,
- .configure_stream = t8112_configure_stream,
- .fw_name = "apple/avd-fw-v3-t0.bin",
- - .revision = 4,
- + .revision = 3,
- .vp_slot_offset = 0xc,
- .submit_offset = 0x30,
- };
- diff --git a/drivers/media/platform/apple/avd/avd-h264.c b/drivers/media/platform/apple/avd/avd-h264.c
- index 668d4b258834..62fda4b4c638 100644
- --- a/drivers/media/platform/apple/avd/avd-h264.c
- +++ b/drivers/media/platform/apple/avd/avd-h264.c
- @@ -216,7 +216,7 @@ static void stream_hdr(struct avd_ctx *ctx, struct avd_h264_run *run)
- push(INST_DMA2, "cm3_dma_config_1");
- push(INST_DMA1, "cm3_dma_config_2");
- - if (avd->variant->revision == 3)
- + // if (avd->variant->revision == 3)
- push(0, "zero");
- pusha(h264_ctx->bufs.pps_tile[0].addr, "hdr_9c_pps_tile_addr_lsb8", 0);
- @@ -224,12 +224,12 @@ static void stream_hdr(struct avd_ctx *ctx, struct avd_h264_run *run)
- push(INST_DMA2, "cm3_dma_config_3");
- push(INST_DMA2, "cm3_dma_config_4");
- - if (avd->variant->revision == 3)
- + //if (avd->variant->revision == 3)
- push(0, "zero");
- - else
- + //else
- /* Frame statistics? another pps_tile?
- * i have no clue. Seems to work */
- - pusha(h264_ctx->bufs.unk.addr, "unk_addr", 0);
- + //pusha(h264_ctx->bufs.unk.addr, "unk_addr", 0);
- pusha(h264_ctx->bufs.pps_tile[1].addr, "hdr_9c_pps_tile_addr_lsb8", 1);
- pusha(h264_ctx->bufs.pps_tile[2].addr, "hdr_9c_pps_tile_addr_lsb8", 2);
- @@ -239,9 +239,9 @@ static void stream_hdr(struct avd_ctx *ctx, struct avd_h264_run *run)
- push_rvra(avd, ctx, run->addresses.rvra, ctx->rvra_offsets);
- pusha(run->addresses.y, "hdr_210_y_addr_lsb8", 0);
- - push(ctx->decoded_fmt.fmt.pix_mp.plane_fmt[0].bytesperline, "hdr_218_width_align");
- + push(ctx->decoded_fmt.fmt.pix_mp.plane_fmt[0].bytesperline >> 4, "hdr_218_width_align");
- pusha(run->addresses.uv,"hdr_214_uv_addr_lsb8", 0);
- - push(ctx->decoded_fmt.fmt.pix_mp.plane_fmt[0].bytesperline, "hdr_21c_width_align");
- + push(ctx->decoded_fmt.fmt.pix_mp.plane_fmt[0].bytesperline >> 4, "hdr_21c_width_align");
- push(0x0, "cm3_mark_end_section");
- push(((height - 1) << 16) | (width - 1), "hdr_54_height_width");
- diff --git a/drivers/media/platform/apple/avd/avd-hw.c b/drivers/media/platform/apple/avd/avd-hw.c
- index 73800cca87a9..f7eab6ef7afb 100644
- --- a/drivers/media/platform/apple/avd/avd-hw.c
- +++ b/drivers/media/platform/apple/avd/avd-hw.c
- @@ -96,7 +96,7 @@ void t8112_configure_stream(struct avd_dev *avd, dma_addr_t addr, u8 fifo_idx,
- u32 vp_slot)
- {
- w32(AVD_V4_VP_INSN_FIFO_IOVA_HI + (fifo_idx * 4), addr >> 32);
- - w32(AVD_V4_VP_INSN_FIFO_IOVA_LO + (fifo_idx * 4), addr & 0xffffffff);
- + w32(AVD_V4_VP_INSN_FIFO_IOVA_LO + (fifo_idx * 4), addr >> 8);
- w32(AVD_V4_VP_INSN_FIFO_MASK + (fifo_idx * 4), 0);
- w32(AVD_V4_VP_INSN_FIFO_CACH + (fifo_idx * 4), 0);
- w32(AVD_V4_VP_INSN_FIFO_XFER + (fifo_idx * 4), 0);
- diff --git a/drivers/media/platform/apple/avd/avd-inst.h b/drivers/media/platform/apple/avd/avd-inst.h
- index 25ec1a6c9ffb..ba2460cf6847 100644
- --- a/drivers/media/platform/apple/avd/avd-inst.h
- +++ b/drivers/media/platform/apple/avd/avd-inst.h
- @@ -38,23 +38,13 @@ static inline void push(struct avd_dev *avd, struct avd_ctx *ctx, u32 inst)
- static inline void push_address(struct avd_dev *avd, struct avd_ctx *ctx,
- dma_addr_t addr)
- {
- - if (avd->variant->revision == 4) {
- - push(avd, ctx, (u32)(addr & 0xffffffff));
- - push(avd, ctx, (u32)(addr >> 32));
- - } else {
- push(avd, ctx, (addr >> 8));
- - }
- }
- static inline void push_rvra(struct avd_dev *avd, struct avd_ctx *ctx,
- dma_addr_t addr, u32 offsets[4])
- {
- - if (avd->variant->revision == 4) {
- - for (int i = 0; i < 4; i++)
- - push_address(avd, ctx, (addr + offsets[i]));
- - } else {
- for (int i = 0; i < 4; i++)
- push(avd, ctx, (addr + offsets[i]) >> 7);
- - }
- }
- #ifdef DEBUG_INST
Advertisement
Add Comment
Please, Sign In to add comment