Lines Matching +full:hba +full:- +full:cap
1 /* SPDX-License-Identifier: GPL-2.0 */
11 #include <linux/blk-mq.h>
31 * enum scsi_timeout_action - How to handle a command that timed out.
49 * Additional per-command data allocated for the driver.
59 * command. It must also push it to the HBA if the scsi_cmnd
77 * For compatibility, any other non-zero return is treated the
123 * When unknown ioctl is passed return -ENOIOCTLCMD.
136 * define one of these if you don't want to - there is a default
139 * own strategy routine, this is where it is specified. Note - the
168 * Return values: 0 on success, non-0 on failure
202 * device->sdtr will be true if the device supports SDTR messages.
207 * 6. Return 0 on success, non-0 on error. The device will be marked
209 * non-0, your slave_destroy routine will never get called for this
211 * up after yourself before returning non-0
236 * Return values: 0 on success, non-0 on failure
294 * SCSI interface of blk_poll - poll for IO completions.
357 * Return values: 0 on success, -ve value on failure.
373 * This determines if we will use a non-interrupt driven
375 * of simultaneous commands a single hw queue in HBA will accept.
382 * the case, then it must be reserved. Please set this_id to -1 if
390 * of scatter-gather.
417 * individual devices (e.g. 256 for SCSI-1).
451 * True if the low-level driver performs its own reset-settle delays.
458 /* True if the host uses host-wide tagspace */
513 spin_lock_irqsave(shost->host_lock, irq_flags); \
515 spin_unlock_irqrestore(shost->host_lock, irq_flags); \
620 * In scsi-mq mode, the number of hardware queues supported by the LLD.
656 /* True if the host uses host-wide tagspace */
726 dev_printk(prefix, &(shost)->shost_gendev, fmt, ##a)
730 return (void *)shost->hostdata; in shost_priv()
738 if (!dev->parent) in dev_to_shost()
740 dev = dev->parent; in dev_to_shost()
747 return shost->shost_state == SHOST_RECOVERY || in scsi_host_in_recovery()
748 shost->shost_state == SHOST_CANCEL_RECOVERY || in scsi_host_in_recovery()
749 shost->shost_state == SHOST_DEL_RECOVERY || in scsi_host_in_recovery()
750 shost->tmf_in_progress; in scsi_host_in_recovery()
786 return shost->shost_gendev.parent; in scsi_get_device()
790 * scsi_host_scan_allowed - Is scanning of this host allowed
795 return shost->shost_state == SHOST_RUNNING || in scsi_host_scan_allowed()
796 shost->shost_state == SHOST_RECOVERY; in scsi_host_scan_allowed()
821 SHOST_DIX_TYPE0_PROTECTION = 1 << 3, /* DIX between OS and HBA only */
834 shost->prot_capabilities = mask; in scsi_host_set_prot()
839 return shost->prot_capabilities; in scsi_host_get_prot()
844 return shost->prot_capabilities >= SHOST_DIX_TYPE0_PROTECTION; in scsi_host_prot_dma()
849 static unsigned char cap[] = { 0, in scsi_host_dif_capable() local
854 if (target_type >= ARRAY_SIZE(cap)) in scsi_host_dif_capable()
857 return shost->prot_capabilities & cap[target_type] ? target_type : 0; in scsi_host_dif_capable()
863 static unsigned char cap[] = { SHOST_DIX_TYPE0_PROTECTION, in scsi_host_dix_capable() local
868 if (target_type >= ARRAY_SIZE(cap)) in scsi_host_dix_capable()
871 return shost->prot_capabilities & cap[target_type]; in scsi_host_dix_capable()
877 * All DIX-capable initiators must support the T10-mandated CRC
892 shost->prot_guard_type = type; in scsi_host_set_guard()
897 return shost->prot_guard_type; in scsi_host_get_guard()