Lines Matching defs:dst

44 allegro_enc_init(u32 *dst, struct mcu_msg_init_request *msg)
49 dst[i++] = msg->reserved0;
50 dst[i++] = msg->suballoc_dma;
51 dst[i++] = msg->suballoc_size;
52 dst[i++] = msg->encoder_buffer_size;
53 dst[i++] = msg->encoder_buffer_color_depth;
54 dst[i++] = msg->num_cores;
56 dst[i++] = msg->clk_rate;
57 dst[i++] = 0;
60 return i * sizeof(*dst);
88 allegro_encode_config_blob(u32 *dst, struct create_channel_param *param)
97 dst[i++] = param->layer_id;
98 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->height) |
101 dst[i++] = param->videomode;
102 dst[i++] = param->format;
104 dst[i++] = param->colorspace;
105 dst[i++] = param->src_mode;
107 dst[i++] = param->src_bit_depth;
108 dst[i++] = FIELD_PREP(GENMASK(31, 24), codec) |
111 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->tier) |
121 dst[i++] = val;
127 dst[i++] = val;
133 dst[i++] = val;
139 dst[i++] = val;
142 dst[i++] = val;
145 dst[i++] = FIELD_PREP(GENMASK(15, 8), param->beta_offset) |
147 dst[i++] = param->unknown11;
148 dst[i++] = param->unknown12;
149 dst[i++] = param->num_slices;
150 dst[i++] = param->encoder_buffer_offset;
151 dst[i++] = param->encoder_buffer_enabled;
153 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->clip_vrt_range) |
155 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->me_range[1]) |
157 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->me_range[3]) |
159 dst[i++] = FIELD_PREP(GENMASK(31, 24), param->min_tu_size) |
163 dst[i++] = FIELD_PREP(GENMASK(15, 8), param->max_transfo_depth_intra) |
165 dst[i++] = param->entropy_mode;
166 dst[i++] = param->wp_mode;
168 dst[i++] = param->rate_control_mode;
169 dst[i++] = param->initial_rem_delay;
170 dst[i++] = param->cpb_size;
171 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->clk_ratio) |
173 dst[i++] = param->target_bitrate;
174 dst[i++] = param->max_bitrate;
175 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->min_qp) |
177 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->ip_delta) |
179 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->golden_ref) |
181 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->golden_ref_frequency) |
184 dst[i++] = param->rate_control_option;
186 dst[i++] = 0;
189 dst[i++] = param->num_pixel;
190 dst[i++] = FIELD_PREP(GENMASK(31, 16), param->max_pixel_value) |
193 dst[i++] = param->maxpicturesize[j];
197 dst[i++] = param->gop_ctrl_mode;
199 dst[i++] = 0;
202 dst[i++] = FIELD_PREP(GENMASK(31, 24), param->freq_golden_ref) |
205 dst[i++] = param->freq_idr;
207 dst[i++] = param->enable_lt;
208 dst[i++] = param->freq_lt;
209 dst[i++] = param->gdr_mode;
211 dst[i++] = FIELD_PREP(GENMASK(31, 24), param->freq_golden_ref) |
216 dst[i++] = param->tmpdqp;
218 dst[i++] = param->subframe_latency;
219 dst[i++] = param->lda_control_mode;
221 dst[i++] = param->unknown41;
225 dst[i++] = param->lda_factors[j];
226 dst[i++] = param->max_num_merge_cand;
229 return i * sizeof(*dst);
233 allegro_enc_create_channel(u32 *dst, struct mcu_msg_create_channel *msg)
238 dst[i++] = msg->user_id;
241 dst[i++] = msg->blob_mcu_addr;
243 memcpy(&dst[i], msg->blob, msg->blob_size);
244 i += msg->blob_size / sizeof(*dst);
248 dst[i++] = msg->ep1_addr;
250 return i * sizeof(*dst);
271 allegro_enc_destroy_channel(u32 *dst, struct mcu_msg_destroy_channel *msg)
275 dst[i++] = msg->channel_id;
277 return i * sizeof(*dst);
281 allegro_enc_push_buffers(u32 *dst, struct mcu_msg_push_buffers_internal *msg)
288 dst[i++] = msg->channel_id;
292 dst[i++] = buffer->dma_addr;
293 dst[i++] = buffer->mcu_addr;
294 dst[i++] = buffer->size;
297 return i * sizeof(*dst);
301 allegro_enc_put_stream_buffer(u32 *dst,
306 dst[i++] = msg->channel_id;
307 dst[i++] = msg->dma_addr;
308 dst[i++] = msg->mcu_addr;
309 dst[i++] = msg->size;
310 dst[i++] = msg->offset;
311 dst[i++] = lower_32_bits(msg->dst_handle);
312 dst[i++] = upper_32_bits(msg->dst_handle);
314 return i * sizeof(*dst);
318 allegro_enc_encode_frame(u32 *dst, struct mcu_msg_encode_frame *msg)
323 dst[i++] = msg->channel_id;
325 dst[i++] = msg->reserved;
326 dst[i++] = msg->encoding_options;
327 dst[i++] = FIELD_PREP(GENMASK(31, 16), msg->padding) |
331 dst[i++] = 0;
332 dst[i++] = 0;
333 dst[i++] = 0;
334 dst[i++] = 0;
337 dst[i++] = lower_32_bits(msg->user_param);
338 dst[i++] = upper_32_bits(msg->user_param);
339 dst[i++] = lower_32_bits(msg->src_handle);
340 dst[i++] = upper_32_bits(msg->src_handle);
341 dst[i++] = msg->request_options;
342 dst[i++] = msg->src_y;
343 dst[i++] = msg->src_uv;
345 dst[i++] = msg->is_10_bit;
346 dst[i++] = msg->stride;
348 dst[i++] = msg->format;
349 dst[i++] = msg->ep2;
350 dst[i++] = lower_32_bits(msg->ep2_v);
351 dst[i++] = upper_32_bits(msg->ep2_v);
353 return i * sizeof(*dst);
465 * @dst: Pointer to the memory that will be filled with data
468 ssize_t allegro_encode_mail(u32 *dst, void *msg)
473 if (!msg || !dst)
478 size = allegro_enc_init(&dst[1], msg);
481 size = allegro_enc_create_channel(&dst[1], msg);
484 size = allegro_enc_destroy_channel(&dst[1], msg);
487 size = allegro_enc_encode_frame(&dst[1], msg);
490 size = allegro_enc_put_stream_buffer(&dst[1], msg);
494 size = allegro_enc_push_buffers(&dst[1], msg);
505 dst[0] = FIELD_PREP(GENMASK(31, 16), header->type) |
508 return size + sizeof(*dst);