Lines Matching refs:host
59 int hpsb_ref_host(struct hpsb_host *host) in hpsb_ref_host() argument
66 if (host == list_entry(lh, struct hpsb_host, host_list)) { in hpsb_ref_host()
67 host->driver->devctl(host, MODIFY_USAGE, 1); in hpsb_ref_host()
68 host->refcount++; in hpsb_ref_host()
87 void hpsb_unref_host(struct hpsb_host *host) in hpsb_unref_host() argument
89 host->driver->devctl(host, MODIFY_USAGE, 0); in hpsb_unref_host()
92 host->refcount--; in hpsb_unref_host()
94 if (!host->refcount && host->is_shutdown) in hpsb_unref_host()
95 kfree(host); in hpsb_unref_host()
161 struct hpsb_host *host = list_entry(lh, struct hpsb_host, host_list); in alloc_hostnum() local
163 if (host->id == hostnum) { in alloc_hostnum()
178 void hpsb_add_host(struct hpsb_host *host) in hpsb_add_host() argument
181 host->id = alloc_hostnum(); in hpsb_add_host()
182 list_add_tail(&host->host_list, &hpsb_hosts); in hpsb_add_host()
185 highlevel_add_host(host); in hpsb_add_host()
186 host->driver->devctl(host, RESET_BUS, LONG_RESET); in hpsb_add_host()
189 void hpsb_remove_host(struct hpsb_host *host) in hpsb_remove_host() argument
192 host->is_shutdown = 1; in hpsb_remove_host()
193 host->driver = &dummy_driver; in hpsb_remove_host()
194 list_del(&host->host_list); in hpsb_remove_host()
197 highlevel_remove_host(host); in hpsb_remove_host()