Lines Matching refs:h
27 static int dummy_transmit_packet(struct hpsb_host *h, struct hpsb_packet *p) in dummy_transmit_packet() argument
32 static int dummy_devctl(struct hpsb_host *h, enum devctl_cmd c, int arg) in dummy_devctl() argument
122 struct hpsb_host *h; in hpsb_alloc_host() local
125 h = kmalloc(sizeof(struct hpsb_host) + extra, SLAB_KERNEL); in hpsb_alloc_host()
126 if (!h) return NULL; in hpsb_alloc_host()
127 memset(h, 0, sizeof(struct hpsb_host) + extra); in hpsb_alloc_host()
129 h->hostdata = h + 1; in hpsb_alloc_host()
130 h->driver = drv; in hpsb_alloc_host()
131 h->refcount = 1; in hpsb_alloc_host()
133 INIT_LIST_HEAD(&h->pending_packets); in hpsb_alloc_host()
134 spin_lock_init(&h->pending_pkt_lock); in hpsb_alloc_host()
136 for (i = 0; i < ARRAY_SIZE(h->tpool); i++) in hpsb_alloc_host()
137 HPSB_TPOOL_INIT(&h->tpool[i]); in hpsb_alloc_host()
139 atomic_set(&h->generation, 0); in hpsb_alloc_host()
141 init_timer(&h->timeout); in hpsb_alloc_host()
142 h->timeout.data = (unsigned long) h; in hpsb_alloc_host()
143 h->timeout.function = abort_timedouts; in hpsb_alloc_host()
144 h->timeout_interval = HZ / 20; // 50ms by default in hpsb_alloc_host()
146 h->topology_map = h->csr.topology_map + 3; in hpsb_alloc_host()
147 h->speed_map = (u8 *)(h->csr.speed_map + 2); in hpsb_alloc_host()
149 return h; in hpsb_alloc_host()