Lines Matching refs:hm

82 	struct hpi_message hm;  in asihpi_hpi_release()  local
87 hpi_init_message_response(&hm, &hr, HPI_OBJ_SUBSYSTEM, in asihpi_hpi_release()
89 hpi_send_recv_ex(&hm, &hr, file); in asihpi_hpi_release()
98 union hpi_message_buffer_v1 *hm; in asihpi_hpi_ioctl() local
108 hm = kmalloc(sizeof(*hm), GFP_KERNEL); in asihpi_hpi_ioctl()
110 if (!hm || !hr) { in asihpi_hpi_ioctl()
129 if (msg_size > sizeof(*hm)) in asihpi_hpi_ioctl()
130 msg_size = sizeof(*hm); in asihpi_hpi_ioctl()
134 uncopied_bytes = copy_from_user(hm, puhm, msg_size); in asihpi_hpi_ioctl()
142 hm->h.size = msg_size; in asihpi_hpi_ioctl()
157 switch (hm->h.function) { in asihpi_hpi_ioctl()
163 hr->h.function = hm->h.function; in asihpi_hpi_ioctl()
173 if (hm->h.object == HPI_OBJ_SUBSYSTEM) { in asihpi_hpi_ioctl()
174 hpi_send_recv_f(&hm->m0, &hr->r0, file); in asihpi_hpi_ioctl()
182 if (hm->h.adapter_index < ARRAY_SIZE(adapters)) in asihpi_hpi_ioctl()
183 pa = &adapters[array_index_nospec(hm->h.adapter_index, in asihpi_hpi_ioctl()
187 hpi_init_response(&hr->r0, hm->h.object, in asihpi_hpi_ioctl()
188 hm->h.function, HPI_ERROR_BAD_ADAPTER_NUMBER); in asihpi_hpi_ioctl()
205 switch (hm->h.function) { in asihpi_hpi_ioctl()
209 ptr = (u16 __user *)hm->m0.u.d.u.data.pb_data; in asihpi_hpi_ioctl()
210 size = hm->m0.u.d.u.data.data_size; in asihpi_hpi_ioctl()
220 hm->h.adapter_index, in asihpi_hpi_ioctl()
241 hm->m0.u.d.u.data.pb_data = pa->p_buffer; in asihpi_hpi_ioctl()
242 if (hm->h.function == HPI_ISTREAM_READ) in asihpi_hpi_ioctl()
265 hpi_send_recv_f(&hm->m0, &hr->r0, file); in asihpi_hpi_ioctl()
304 kfree(hm); in asihpi_hpi_ioctl()
352 struct hpi_message hm; in asihpi_adapter_probe() local
372 hpi_init_message_response(&hm, &hr, HPI_OBJ_SUBSYSTEM, in asihpi_adapter_probe()
377 hm.adapter_index = HPI_ADAPTER_INDEX_INVALID; in asihpi_adapter_probe()
400 hm.u.s.resource.bus_type = HPI_BUS_PCI; in asihpi_adapter_probe()
401 hm.u.s.resource.r.pci = &pci; in asihpi_adapter_probe()
404 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_probe()
422 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_probe()
424 hm.adapter_index = adapter.adapter->index; in asihpi_adapter_probe()
425 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_probe()
433 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_probe()
435 hm.adapter_index = adapter.adapter->index; in asihpi_adapter_probe()
436 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_probe()
447 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_probe()
449 hm.adapter_index = adapter.adapter->index; in asihpi_adapter_probe()
450 hm.u.ax.property_set.property = HPI_ADAPTER_PROPERTY_SUPPORTS_IRQ; in asihpi_adapter_probe()
451 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_probe()
476 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_probe()
478 hm.adapter_index = adapter.adapter->index; in asihpi_adapter_probe()
479 hm.u.ax.property_set.property = HPI_ADAPTER_PROPERTY_IRQ_RATE; in asihpi_adapter_probe()
480 hm.u.ax.property_set.parameter1 = 0; in asihpi_adapter_probe()
481 hm.u.ax.property_set.parameter2 = 0; in asihpi_adapter_probe()
482 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_probe()
531 struct hpi_message hm; in asihpi_adapter_remove() local
540 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_remove()
542 hm.adapter_index = pa->adapter->index; in asihpi_adapter_remove()
543 hm.u.ax.property_set.property = HPI_ADAPTER_PROPERTY_IRQ_RATE; in asihpi_adapter_remove()
544 hm.u.ax.property_set.parameter1 = 0; in asihpi_adapter_remove()
545 hm.u.ax.property_set.parameter2 = 0; in asihpi_adapter_remove()
546 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_remove()
548 hpi_init_message_response(&hm, &hr, HPI_OBJ_ADAPTER, in asihpi_adapter_remove()
550 hm.adapter_index = pa->adapter->index; in asihpi_adapter_remove()
551 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_adapter_remove()
574 struct hpi_message hm; in asihpi_init() local
581 hpi_init_message_response(&hm, &hr, HPI_OBJ_SUBSYSTEM, in asihpi_init()
583 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_init()
588 struct hpi_message hm; in asihpi_exit() local
591 hpi_init_message_response(&hm, &hr, HPI_OBJ_SUBSYSTEM, in asihpi_exit()
593 hpi_send_recv_ex(&hm, &hr, HOWNER_KERNEL); in asihpi_exit()