/** * struct fimc_dma_offset - pixel offset information for DMA * @y_h: y value horizontal offset * @y_v: y value vertical offset * @cb_h: cb value horizontal offset * @cb_v: cb value vertical offset * @cr_h: cr value horizontal offset * @cr_v: cr value vertical offset
*/ struct fimc_dma_offset { int y_h; int y_v; int cb_h; int cb_v; int cr_h; int cr_v;
};
/** * struct fimc_effect - color effect information * @type: effect type * @pat_cb: cr value when type is "arbitrary" * @pat_cr: cr value when type is "arbitrary"
*/ struct fimc_effect {
u32 type;
u8 pat_cb;
u8 pat_cr;
};
/** * struct fimc_scaler - the configuration data for FIMC inetrnal scaler * @scaleup_h: flag indicating scaling up horizontally * @scaleup_v: flag indicating scaling up vertically * @copy_mode: flag indicating transparent DMA transfer (no scaling * and color format conversion) * @enabled: flag indicating if the scaler is used * @hfactor: horizontal shift factor * @vfactor: vertical shift factor * @pre_hratio: horizontal ratio of the prescaler * @pre_vratio: vertical ratio of the prescaler * @pre_dst_width: the prescaler's destination width * @pre_dst_height: the prescaler's destination height * @main_hratio: the main scaler's horizontal ratio * @main_vratio: the main scaler's vertical ratio * @real_width: source pixel (width - offset) * @real_height: source pixel (height - offset)
*/ struct fimc_scaler { unsignedint scaleup_h:1; unsignedint scaleup_v:1; unsignedint copy_mode:1; unsignedint enabled:1;
u32 hfactor;
u32 vfactor;
u32 pre_hratio;
u32 pre_vratio;
u32 pre_dst_width;
u32 pre_dst_height;
u32 main_hratio;
u32 main_vratio;
u32 real_width;
u32 real_height;
};
/** * struct fimc_vid_cap - camera capture device information * @ctx: hardware context data * @subdev: subdev exposing the FIMC processing block * @ve: exynos video device entity structure * @vd_pad: fimc video capture node pad * @sd_pads: fimc video processing block pads * @ci_fmt: image format at the FIMC camera input (and the scaler output) * @wb_fmt: image format at the FIMC ISP Writeback input * @source_config: external image source related configuration structure * @pending_buf_q: the pending buffer queue head * @active_buf_q: the queue head of buffers scheduled in hardware * @vbq: the capture am video buffer queue * @active_buf_cnt: number of video buffers scheduled in hardware * @buf_index: index for managing the output DMA buffers * @frame_count: the frame counter for statistics * @reqbufs_count: the number of buffers requested in REQBUFS ioctl * @streaming: is streaming in progress? * @input: capture input type, grp_id of the attached subdev * @user_subdev_api: true if subdevs are not configured by the host driver
*/ struct fimc_vid_cap { struct fimc_ctx *ctx; struct v4l2_subdev subdev; struct exynos_video_entity ve; struct media_pad vd_pad; struct media_pad sd_pads[FIMC_SD_PADS_NUM]; struct v4l2_mbus_framefmt ci_fmt; struct v4l2_mbus_framefmt wb_fmt; struct fimc_source_info source_config; struct list_head pending_buf_q; struct list_head active_buf_q; struct vb2_queue vbq; int active_buf_cnt; int buf_index; unsignedint frame_count; unsignedint reqbufs_count; bool streaming;
u32 input; bool user_subdev_api;
};
/** * struct fimc_pix_limit - image pixel size limits in various IP configurations * * @scaler_en_w: max input pixel width when the scaler is enabled * @scaler_dis_w: max input pixel width when the scaler is disabled * @in_rot_en_h: max input width with the input rotator is on * @in_rot_dis_w: max input width with the input rotator is off * @out_rot_en_w: max output width with the output rotator on * @out_rot_dis_w: max output width with the output rotator off
*/ struct fimc_pix_limit {
u16 scaler_en_w;
u16 scaler_dis_w;
u16 in_rot_en_h;
u16 in_rot_dis_w;
u16 out_rot_en_w;
u16 out_rot_dis_w;
};
/** * struct fimc_variant - FIMC device variant information * @has_inp_rot: set if has input rotator * @has_out_rot: set if has output rotator * @has_mainscaler_ext: 1 if extended mainscaler ratios in CIEXTEN register * are present in this IP revision * @has_cam_if: set if this instance has a camera input interface * @has_isp_wb: set if this instance has ISP writeback input * @pix_limit: pixel size constraints for the scaler * @min_inp_pixsize: minimum input pixel size * @min_out_pixsize: minimum output pixel size * @hor_offs_align: horizontal pixel offset alignment * @min_vsize_align: minimum vertical pixel size alignment
*/ struct fimc_variant { unsignedint has_inp_rot:1; unsignedint has_out_rot:1; unsignedint has_mainscaler_ext:1; unsignedint has_cam_if:1; unsignedint has_isp_wb:1; conststruct fimc_pix_limit *pix_limit;
u16 min_inp_pixsize;
u16 min_out_pixsize;
u16 hor_offs_align;
u16 min_vsize_align;
};
/** * struct fimc_drvdata - per device type driver data * @variant: variant information for this device * @num_entities: number of fimc instances available in a SoC * @lclk_frequency: local bus clock frequency * @cistatus2: 1 if the FIMC IPs have CISTATUS2 register * @dma_pix_hoff: the horizontal DMA offset unit: 1 - pixels, 0 - bytes * @alpha_color: 1 if alpha color component is supported * @out_buf_count: maximum number of output DMA buffers supported
*/ struct fimc_drvdata { conststruct fimc_variant *variant[FIMC_MAX_DEVS]; int num_entities; unsignedlong lclk_frequency; /* Fields common to all FIMC IP instances */
u8 cistatus2;
u8 dma_pix_hoff;
u8 alpha_color;
u8 out_buf_count;
};
/* -----------------------------------------------------*/ /* fimc-capture.c */ int fimc_initialize_capture_subdev(struct fimc_dev *fimc); void fimc_unregister_capture_subdev(struct fimc_dev *fimc); int fimc_capture_ctrls_create(struct fimc_dev *fimc); void fimc_sensor_notify(struct v4l2_subdev *sd, unsignedint notification, void *arg); int fimc_capture_suspend(struct fimc_dev *fimc); int fimc_capture_resume(struct fimc_dev *fimc);
/* * Buffer list manipulation functions. Must be called with fimc.slock held.
*/
/** * fimc_active_queue_add - add buffer to the capture active buffers queue * @vid_cap: camera capture device information * @buf: buffer to add to the active buffers list
*/ staticinlinevoid fimc_active_queue_add(struct fimc_vid_cap *vid_cap, struct fimc_vid_buffer *buf)
{
list_add_tail(&buf->list, &vid_cap->active_buf_q);
vid_cap->active_buf_cnt++;
}
/** * fimc_active_queue_pop - pop buffer from the capture active buffers queue * @vid_cap: camera capture device information * * The caller must assure the active_buf_q list is not empty.
*/ staticinlinestruct fimc_vid_buffer *fimc_active_queue_pop( struct fimc_vid_cap *vid_cap)
{ struct fimc_vid_buffer *buf;
buf = list_entry(vid_cap->active_buf_q.next, struct fimc_vid_buffer, list);
list_del(&buf->list);
vid_cap->active_buf_cnt--; return buf;
}
/** * fimc_pending_queue_add - add buffer to the capture pending buffers queue * @vid_cap: camera capture device information * @buf: buffer to add to the pending buffers list
*/ staticinlinevoid fimc_pending_queue_add(struct fimc_vid_cap *vid_cap, struct fimc_vid_buffer *buf)
{
list_add_tail(&buf->list, &vid_cap->pending_buf_q);
}
/** * fimc_pending_queue_pop - pop buffer from the capture pending buffers queue * @vid_cap: camera capture device information * * The caller must assure the pending_buf_q list is not empty.
*/ staticinlinestruct fimc_vid_buffer *fimc_pending_queue_pop( struct fimc_vid_cap *vid_cap)
{ struct fimc_vid_buffer *buf;
buf = list_entry(vid_cap->pending_buf_q.next, struct fimc_vid_buffer, list);
list_del(&buf->list); return buf;
}
#endif/* FIMC_CORE_H_ */
Messung V0.5
¤ Dauer der Verarbeitung: 0.2 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.