Lines Matching refs:links
80 struct media_link *links = entity->links; in __media_entity_add_link() local
84 links = (struct media_link*)realloc(links, max_links * sizeof *links); in __media_entity_add_link()
85 if (links == NULL) in __media_entity_add_link()
89 links[i].twin->twin = &links[i]; in __media_entity_add_link()
92 entity->links = links; in __media_entity_add_link()
95 return &entity->links[entity->num_links++]; in __media_entity_add_link()
107 struct media_links_enum links; in __media_enum_links() local
110 links.entity = entity->info.id; in __media_enum_links()
111 … links.pads = (struct media_pad_desc*)malloc(entity->info.pads * sizeof(struct media_pad_desc)); in __media_enum_links()
112 …links.links = (struct media_link_desc*)malloc(entity->info.links * sizeof(struct media_link_desc)); in __media_enum_links()
114 if (ioctl(media->fd, MEDIA_IOC_ENUM_LINKS, &links) < 0) { in __media_enum_links()
116 free(links.pads); in __media_enum_links()
117 free(links.links); in __media_enum_links()
123 entity->pads[i].index = links.pads[i].index; in __media_enum_links()
124 entity->pads[i].flags = links.pads[i].flags; in __media_enum_links()
127 for (i = 0; i < entity->info.links; ++i) { in __media_enum_links()
128 struct media_link_desc *link = &links.links[i]; in __media_enum_links()
159 free(links.pads); in __media_enum_links()
160 free(links.links); in __media_enum_links()
244 entity->max_links = entity->info.pads + entity->info.links; in __media_enum_entities()
247 entity->links = (struct media_link*)malloc(entity->max_links * sizeof(*entity->links)); in __media_enum_entities()
248 if (entity->pads == NULL || entity->links == NULL) { in __media_enum_entities()
352 free(entity->links); in exynos_media_close()
380 struct media_link *link = &pad->entity->links[i]; in exynos_media_entity_remote_source()
469 link = &source->entity->links[i]; in exynos_media_setup_link()
524 struct media_link *link = &entity->links[j]; in exynos_media_reset_links()
695 link = &source->entity->links[i]; in exynos_media_parse_link()