Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/vmware/vmci/vmci_event.c
Show First 20 Lines • Show All 587 Lines • ▼ Show 20 Lines | |||||
*------------------------------------------------------------------------------ | *------------------------------------------------------------------------------ | ||||
*/ | */ | ||||
static struct vmci_subscription * | static struct vmci_subscription * | ||||
vmci_event_unregister_subscription(vmci_id sub_id) | vmci_event_unregister_subscription(vmci_id sub_id) | ||||
{ | { | ||||
struct vmci_subscription *s; | struct vmci_subscription *s; | ||||
if (!vmci_initialized_lock(&subscriber_lock)) | |||||
return NULL; | |||||
vmci_grab_lock_bh(&subscriber_lock); | vmci_grab_lock_bh(&subscriber_lock); | ||||
s = vmci_event_find(sub_id); | s = vmci_event_find(sub_id); | ||||
if (s != NULL) { | if (s != NULL) { | ||||
vmci_event_release(s); | vmci_event_release(s); | ||||
vmci_list_remove(s, subscriber_list_item); | vmci_list_remove(s, subscriber_list_item); | ||||
} | } | ||||
vmci_release_lock_bh(&subscriber_lock); | vmci_release_lock_bh(&subscriber_lock); | ||||
▲ Show 20 Lines • Show All 92 Lines • Show Last 20 Lines |