Lines Matching refs:rv

527 	int rv = 0;  in mtip_device_reset()  local
533 rv = -EFAULT; in mtip_device_reset()
542 return rv; in mtip_device_reset()
609 int group, tag, bit, reissue, rv; in mtip_handle_tfe() local
684 rv = mtip_read_log_page(dd->port, ATA_LOG_SATA_NCQ, in mtip_handle_tfe()
687 if (rv) { in mtip_handle_tfe()
889 int rv = IRQ_NONE; in mtip_handle_irq() local
895 rv = IRQ_HANDLED; in mtip_handle_irq()
950 return rv; in mtip_handle_irq()
963 return rv; in mtip_handle_irq()
1106 int rv = 0; in mtip_exec_internal_command() local
1177 if ((rv = wait_for_completion_interruptible_timeout( in mtip_exec_internal_command()
1181 if (rv == -ERESTARTSYS) { /* interrupted */ in mtip_exec_internal_command()
1186 rv = -EINTR; in mtip_exec_internal_command()
1188 } else if (rv == 0) /* timeout */ in mtip_exec_internal_command()
1195 fis->command, rv, timeout); in mtip_exec_internal_command()
1203 rv = -ENXIO; in mtip_exec_internal_command()
1207 rv = -EAGAIN; in mtip_exec_internal_command()
1219 rv = -ENXIO; in mtip_exec_internal_command()
1225 rv = -ENXIO; in mtip_exec_internal_command()
1237 rv = -EIO; in mtip_exec_internal_command()
1252 rv = -ENXIO; in mtip_exec_internal_command()
1255 rv = -EAGAIN; in mtip_exec_internal_command()
1261 if (rv >= 0 && mtip_pause_ncq(port, fis)) { in mtip_exec_internal_command()
1263 return rv; in mtip_exec_internal_command()
1268 return rv; in mtip_exec_internal_command()
1343 int rv = 0; in mtip_get_identify() local
1371 rv = -1; in mtip_get_identify()
1414 rv = -EFAULT; in mtip_get_identify()
1420 return rv; in mtip_get_identify()
1434 int rv; in mtip_standby_immediate() local
1448 rv = mtip_exec_internal_command(port, in mtip_standby_immediate()
1458 if (rv) in mtip_standby_immediate()
1462 return rv; in mtip_standby_immediate()
1553 int rv, i; in mtip_get_smart_attr() local
1573 rv = mtip_get_smart_data(port, port->smart_buf, port->smart_buf_dma); in mtip_get_smart_attr()
1574 if (rv) { in mtip_get_smart_attr()
1576 return rv; in mtip_get_smart_attr()
1589 rv = -EINVAL; in mtip_get_smart_attr()
1592 return rv; in mtip_get_smart_attr()
1610 int i, rv = 0; in mtip_send_trim() local
1665 rv = -EIO; in mtip_send_trim()
1668 return rv; in mtip_send_trim()
1867 int rv = 0, xfer_sz = command[3]; in exec_drive_command() local
1926 rv = -EFAULT; in exec_drive_command()
1947 rv = -EFAULT; in exec_drive_command()
1955 return rv; in exec_drive_command()
1973 unsigned int rv = 0; in implicit_sector() local
1985 rv = 1; in implicit_sector()
1989 rv = 1; in implicit_sector()
1994 rv = 1; in implicit_sector()
1999 rv = 1; in implicit_sector()
2002 return rv; in implicit_sector()
2566 int rv = 0; in mtip_hw_read_device_status() local
2583 rv = -EFAULT; in mtip_hw_read_device_status()
2586 return rv ? rv : *offset; in mtip_hw_read_device_status()
2596 int n, rv = 0; in mtip_hw_read_registers() local
2662 rv = -EFAULT; in mtip_hw_read_registers()
2665 return rv ? rv : *offset; in mtip_hw_read_registers()
2674 int rv = 0; in mtip_hw_read_flags() local
2694 rv = -EFAULT; in mtip_hw_read_flags()
2697 return rv ? rv : *offset; in mtip_hw_read_flags()
3098 int rv; in mtip_hw_get_identify() local
3111 rv = mtip_read_log_page(dd->port, ATA_LOG_SATA_NCQ, in mtip_hw_get_identify()
3114 if (rv) { in mtip_hw_get_identify()
3147 return rv; in mtip_hw_get_identify()
3161 int rv; in mtip_hw_init() local
3169 rv = -EIO; in mtip_hw_init()
3205 rv = mtip_dma_alloc(dd); in mtip_hw_init()
3206 if (rv < 0) in mtip_hw_init()
3230 rv = -ENODEV; in mtip_hw_init()
3238 rv = -EFAULT; in mtip_hw_init()
3247 rv = -EIO; in mtip_hw_init()
3260 rv = devm_request_irq(&dd->pdev->dev, in mtip_hw_init()
3267 if (rv) { in mtip_hw_init()
3281 rv = -EFAULT; in mtip_hw_init()
3285 return rv; in mtip_hw_init()
3304 return rv; in mtip_hw_init()
3309 int rv = 0; in mtip_standby_drive() local
3320 rv = mtip_standby_immediate(dd->port); in mtip_standby_drive()
3321 if (rv) in mtip_standby_drive()
3325 return rv; in mtip_standby_drive()
3839 int rv = 0, wait_for_rebuild = 0; in mtip_block_initialize() local
3849 rv = -EINVAL; in mtip_block_initialize()
3857 rv = -EINVAL; in mtip_block_initialize()
3867 rv = ida_get_new(&rssd_index_ida, &index); in mtip_block_initialize()
3869 } while (rv == -EAGAIN); in mtip_block_initialize()
3871 if (rv) in mtip_block_initialize()
3874 rv = rssd_disk_name_format("rssd", in mtip_block_initialize()
3878 if (rv) in mtip_block_initialize()
3901 rv = blk_mq_alloc_tag_set(&dd->tags); in mtip_block_initialize()
3902 if (rv) { in mtip_block_initialize()
3913 rv = -ENOMEM; in mtip_block_initialize()
3925 rv = -EINVAL; in mtip_block_initialize()
3965 rv = -EIO; in mtip_block_initialize()
3986 return rv; /* service thread created for handling rebuild */ in mtip_block_initialize()
3998 rv = -EFAULT; in mtip_block_initialize()
4003 rv = wait_for_rebuild; in mtip_block_initialize()
4005 return rv; in mtip_block_initialize()
4032 return rv; in mtip_block_initialize()
4267 int rv = 0; in mtip_pci_probe() local
4298 rv = pcim_enable_device(pdev); in mtip_pci_probe()
4299 if (rv < 0) { in mtip_pci_probe()
4305 rv = pcim_iomap_regions(pdev, 1 << MTIP_ABAR, MTIP_DRV_NAME); in mtip_pci_probe()
4306 if (rv < 0) { in mtip_pci_probe()
4312 rv = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64)); in mtip_pci_probe()
4314 if (rv) { in mtip_pci_probe()
4315 rv = pci_set_consistent_dma_mask(pdev, in mtip_pci_probe()
4317 if (rv) { in mtip_pci_probe()
4340 rv = -ENOMEM; in mtip_pci_probe()
4399 rv = pci_enable_msi(pdev); in mtip_pci_probe()
4400 if (rv) { in mtip_pci_probe()
4409 rv = mtip_block_initialize(dd); in mtip_pci_probe()
4410 if (rv < 0) { in mtip_pci_probe()
4421 if (rv != MTIP_FTL_REBUILD_MAGIC) in mtip_pci_probe()
4424 rv = 0; /* device in rebuild state, return 0 from probe */ in mtip_pci_probe()
4450 return rv; in mtip_pci_probe()
4452 return rv; in mtip_pci_probe()
4529 int rv = 0; in mtip_pci_suspend() local
4541 rv = mtip_block_suspend(dd); in mtip_pci_suspend()
4542 if (rv < 0) { in mtip_pci_suspend()
4545 return rv; in mtip_pci_suspend()
4558 return rv; in mtip_pci_suspend()
4570 int rv = 0; in mtip_pci_resume() local
4587 rv = pcim_enable_device(pdev); in mtip_pci_resume()
4588 if (rv < 0) { in mtip_pci_resume()
4599 rv = mtip_block_resume(dd); in mtip_pci_resume()
4600 if (rv < 0) in mtip_pci_resume()
4606 return rv; in mtip_pci_resume()