/** * ibmvscsi_task: - Process srps asynchronously * @data: ibmvscsi_host_data of host */ static void ibmvscsi_task(void *data) { struct ibmvscsi_host_data *hostdata = (struct ibmvscsi_host_data *)data; struct vio_dev *vdev = to_vio_dev(hostdata->dev); struct viosrp_crq *crq; int done = 0; while (!done) { /* Pull all the valid messages off the CRQ */ while ((crq = crq_queue_next_crq(&hostdata->queue)) != NULL) { ibmvscsi_handle_crq(crq, hostdata); crq->valid = 0x00; } vio_enable_interrupts(vdev); if ((crq = crq_queue_next_crq(&hostdata->queue)) != NULL) { vio_disable_interrupts(vdev); ibmvscsi_handle_crq(crq, hostdata); crq->valid = 0x00; } else { done = 1; } } }
/** * standard interface for handling logical partition events. */ static void ibmvscsi_handle_event(struct HvLpEvent *lpevt) { struct srp_lp_event *evt = (struct srp_lp_event *)lpevt; if (!evt) { printk(KERN_ERR "ibmvscsi: received null event\n"); return; } if (single_host_data == NULL) { printk(KERN_ERR "ibmvscsi: received event, no adapter present\n"); return; } ibmvscsi_handle_crq(&evt->crq, single_host_data); }
/** * standard interface for handling logical partition events. */ static void iseriesvscsi_handle_event(struct HvLpEvent *lpevt) { struct srp_lp_event *evt = (struct srp_lp_event *)lpevt; if (!evt) { ; return; } if (single_host_data == NULL) { // printk(KERN_ERR ; return; } ibmvscsi_handle_crq(&evt->crq, single_host_data); }