unsigned char *luma_qtable,
                               unsigned char *chroma_qtable)
 {
-       __be32 *luma_qtable_p;
-       __be32 *chroma_qtable_p;
        u32 reg, i;
 
-       luma_qtable_p = (__be32 *)luma_qtable;
-       chroma_qtable_p = (__be32 *)chroma_qtable;
-
        for (i = 0; i < VEPU_JPEG_QUANT_TABLE_COUNT; i++) {
                reg = get_unaligned_be32(&luma_qtable[i]);
                vepu_write_relaxed(vpu, reg, VEPU_REG_JPEG_LUMA_QUAT(i));
 
                               unsigned char *luma_qtable,
                               unsigned char *chroma_qtable)
 {
-       __be32 *luma_qtable_p;
-       __be32 *chroma_qtable_p;
        u32 reg, i;
 
-       luma_qtable_p = (__be32 *)luma_qtable;
-       chroma_qtable_p = (__be32 *)chroma_qtable;
-
        for (i = 0; i < VEPU_JPEG_QUANT_TABLE_COUNT; i++) {
                reg = get_unaligned_be32(&luma_qtable[i]);
                vepu_write_relaxed(vpu, reg, VEPU_REG_JPEG_LUMA_QUAT(i));
 
                         struct device *alloc_devs[])
 {
        struct rockchip_vpu_ctx *ctx = vb2_get_drv_priv(vq);
-       const struct rockchip_vpu_fmt *vpu_fmt;
        struct v4l2_pix_format_mplane *pixfmt;
        int i;
 
        switch (vq->type) {
        case V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE:
-               vpu_fmt = ctx->vpu_dst_fmt;
                pixfmt = &ctx->dst_fmt;
                break;
        case V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE:
-               vpu_fmt = ctx->vpu_src_fmt;
                pixfmt = &ctx->src_fmt;
                break;
        default:
        struct vb2_v4l2_buffer *vbuf = to_vb2_v4l2_buffer(vb);
        struct vb2_queue *vq = vb->vb2_queue;
        struct rockchip_vpu_ctx *ctx = vb2_get_drv_priv(vq);
-       const struct rockchip_vpu_fmt *vpu_fmt;
        struct v4l2_pix_format_mplane *pixfmt;
        unsigned int sz;
        int ret = 0;
 
        switch (vq->type) {
        case V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE:
-               vpu_fmt = ctx->vpu_dst_fmt;
                pixfmt = &ctx->dst_fmt;
                break;
        case V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE:
-               vpu_fmt = ctx->vpu_src_fmt;
                pixfmt = &ctx->src_fmt;
 
                if (vbuf->field == V4L2_FIELD_ANY)