码迷,mamicode.com
首页 > 系统相关 > 详细

linux视频之media媒体框架

时间:2017-10-09 22:52:05      阅读:325      评论:0      收藏:0      [点我收藏+]

标签:dev   obj   flags   protect   serialize   ice   nbsp   linux视频   bsp   

  linux视频媒体(kernel层分析)主要包括三个文件:

  (/drivers/media/media-device.c ,  /drivers/media/media-devnode.c , /drivers/media/media-entity.c)

一.主要分析/drivers/media/media-device.c文件,此文件中主要的结构是:

  

struct media_device {
    struct device *dev; //dev->driver_data points to this struct
    struct media_devnode devnode;
    char model[32];
    char driver_name[32];
    char serial[40];
    char bus_info[32];
    u32 hw_revision;
    u32 driver_version;
    u32 topology_version;
    u32 id;
    struct ida entity_internal_idx;
    int entity_internal_idx_max;
    struct list_head entities;
    struct list_head interfaces;
    struct list_head pads;
    struct list_head links;
    struct list_head entity_notify; //notify callback list invoked when a new entity is registered
    spinlock_t lock; //Protects the graph objects creation/removal 
    struct mutex graph_mutex; //Serializes graph operations.
    struct media_entity_graph pm_count_walk;
    void *source_priv;
    int (*enable_source)(struct media_entity *entity, struct media_pipeline *pipe);
    void (*disable_source)(struct media_entity *entity);
    int (*link_notify)(struct media_link *link, u32 flags,
               unsigned int notification);
};

 

linux视频之media媒体框架

标签:dev   obj   flags   protect   serialize   ice   nbsp   linux视频   bsp   

原文地址:http://www.cnblogs.com/xiezhaohai/p/7642908.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!