Lines Matching refs:hotplug_event

45 static void hotplug_event_begin (HotplugEvent *hotplug_event);
50 HotplugEvent *hotplug_event = (HotplugEvent *) end_token; in hotplug_event_end() local
52 hotplug_events_in_progress = g_slist_remove (hotplug_events_in_progress, hotplug_event); in hotplug_event_end()
53 g_free (hotplug_event); in hotplug_event_end()
58 hotplug_event_begin_devfs_add (HotplugEvent *hotplug_event, HalDevice *d) in hotplug_event_begin_devfs_add() argument
66 …HAL_ERROR (("devpath %s already present in store, ignore event", hotplug_event->un.devfs.devfs_pat… in hotplug_event_begin_devfs_add()
72 parent_udi = hal_device_property_get_string (hotplug_event->d, "info.parent"); in hotplug_event_begin_devfs_add()
80 if (strcmp(hotplug_event->un.devfs.devfs_path, "/") != 0) { in hotplug_event_begin_devfs_add()
81 …HAL_ERROR (("Parent is NULL devfs_path=%s parent_udi=%s", hotplug_event->un.devfs.devfs_path, pare… in hotplug_event_begin_devfs_add()
95 begin_add_func = hotplug_event->un.devfs.handler->hotplug_begin_add; in hotplug_event_begin_devfs_add()
99 begin_add_func (hotplug_event->d, in hotplug_event_begin_devfs_add()
101 hotplug_event->un.devfs.handler, in hotplug_event_begin_devfs_add()
102 (void *) hotplug_event); in hotplug_event_begin_devfs_add()
106 g_object_unref (hotplug_event->d); in hotplug_event_begin_devfs_add()
107 hotplug_event_end ((void *) hotplug_event); in hotplug_event_begin_devfs_add()
113 hotplug_event_begin_devfs_remove (HotplugEvent *hotplug_event, HalDevice *d) in hotplug_event_begin_devfs_remove() argument
116 HAL_ERROR (("devpath %s not present in store, ignore event", hotplug_event->un.devfs.devfs_path)); in hotplug_event_begin_devfs_remove()
117 hotplug_event_end ((void *) hotplug_event); in hotplug_event_begin_devfs_remove()
123 hotplug_event->un.devfs.devfs_path, in hotplug_event_begin_devfs_remove()
124 (void *) hotplug_event); in hotplug_event_begin_devfs_remove()
128 hotplug_event_begin_devfs (HotplugEvent *hotplug_event) in hotplug_event_begin_devfs() argument
132 HAL_INFO (("hotplug_event_begin_devfs: %s", hotplug_event->un.devfs.devfs_path)); in hotplug_event_begin_devfs()
135 hotplug_event->un.devfs.devfs_path); in hotplug_event_begin_devfs()
137 if (hotplug_event->action == HOTPLUG_ACTION_ADD) { in hotplug_event_begin_devfs()
138 hotplug_event_begin_devfs_add (hotplug_event, d); in hotplug_event_begin_devfs()
139 } else if (hotplug_event->action == HOTPLUG_ACTION_REMOVE) { in hotplug_event_begin_devfs()
140 hotplug_event_begin_devfs_remove (hotplug_event, d); in hotplug_event_begin_devfs()
142 HAL_ERROR (("unsupported action %d", hotplug_event->action)); in hotplug_event_begin_devfs()
143 g_object_unref (hotplug_event->d); in hotplug_event_begin_devfs()
144 hotplug_event_end ((void *) hotplug_event); in hotplug_event_begin_devfs()
149 hotplug_event_begin (HotplugEvent *hotplug_event) in hotplug_event_begin() argument
151 switch (hotplug_event->type) { in hotplug_event_begin()
154 hotplug_event_begin_devfs (hotplug_event); in hotplug_event_begin()
158 HAL_ERROR (("Unknown hotplug event type %d", hotplug_event->type)); in hotplug_event_begin()
159 g_object_unref (hotplug_event->d); in hotplug_event_begin()
160 hotplug_event_end ((void *) hotplug_event); in hotplug_event_begin()
166 hotplug_event_enqueue (HotplugEvent *hotplug_event, int front) in hotplug_event_enqueue() argument
172 g_queue_push_head (hotplug_event_queue, hotplug_event); in hotplug_event_enqueue()
174 g_queue_push_tail (hotplug_event_queue, hotplug_event); in hotplug_event_enqueue()
181 HotplugEvent *hotplug_event; in hotplug_event_process_queue() local
193 hotplug_event = g_queue_pop_head (hotplug_event_queue); in hotplug_event_process_queue()
194 if (hotplug_event == NULL) in hotplug_event_process_queue()
197 hotplug_events_in_progress = g_slist_append (hotplug_events_in_progress, hotplug_event); in hotplug_event_process_queue()
198 hotplug_event_begin (hotplug_event); in hotplug_event_process_queue()