pccb->cmd[7], pccb->cmd[8]);
}
-void scsi_setup_read6(ccb *pccb, lbaint_t start, unsigned short blocks)
-{
- pccb->cmd[0] = SCSI_READ6;
- pccb->cmd[1] = pccb->lun << 5 | ((unsigned char)(start >> 16) & 0x1f);
- pccb->cmd[2] = (unsigned char)(start >> 8) & 0xff;
- pccb->cmd[3] = (unsigned char)start & 0xff;
- pccb->cmd[4] = (unsigned char)blocks & 0xff;
- pccb->cmd[5] = 0;
- pccb->cmdlen = 6;
- pccb->msgout[0] = SCSI_IDENTIFY; /* NOT USED */
- debug("scsi_setup_read6: cmd: %02X %02X startblk %02X%02X blccnt %02X\n",
- pccb->cmd[0], pccb->cmd[1],
- pccb->cmd[2], pccb->cmd[3], pccb->cmd[4]);
-}
-
-
void scsi_setup_inquiry(ccb *pccb)
{
pccb->cmd[0] = SCSI_INQUIRY;
return blkcnt;
}
-int scsi_get_disk_count(void)
-{
- return scsi_max_devs;
-}
-
#if defined(CONFIG_PCI) && !defined(CONFIG_SCSI_AHCI_PLAT)
void scsi_init(void)
{
*dest = '\0';
}
-
-/* Trim trailing blanks, and NUL-terminate string
- */
-void scsi_trim_trail(unsigned char *str, unsigned int len)
-{
- unsigned char *p = str + len - 1;
-
- while (len-- > 0) {
- *p-- = '\0';
- if (*p != ' ')
- return;
- }
-}
-
int scsi_read_capacity(ccb *pccb, lbaint_t *capacity, unsigned long *blksz)
{
*capacity = 0;
void scsi_init(void);
void scsi_scan(int mode);
-/** @return the number of scsi disks */
-int scsi_get_disk_count(void);
-
#define SCSI_IDENTIFY 0xC0 /* not used */
/* Hardware errors */