diff --git a/src/scsi/scsi_aha154x.c b/src/scsi/scsi_aha154x.c index 914709fc6..b0ac065c3 100644 --- a/src/scsi/scsi_aha154x.c +++ b/src/scsi/scsi_aha154x.c @@ -66,6 +66,7 @@ uint16_t aha_ports[] = { }; +#pragma pack(push,1) typedef struct { uint8_t CustomerSignature[20]; uint8_t uAutoRetry; @@ -74,6 +75,7 @@ typedef struct { uint8_t uUnknown; addr24 BIOSMailboxAddress; } aha_setup_t; +#pragma pack(pop) #ifdef ENABLE_AHA154X_LOG diff --git a/src/scsi/scsi_buslogic.c b/src/scsi/scsi_buslogic.c index 206aa5590..8197533b2 100644 --- a/src/scsi/scsi_buslogic.c +++ b/src/scsi/scsi_buslogic.c @@ -208,6 +208,7 @@ typedef struct { } MailboxInitExtended_t; #pragma pack(pop) +#pragma pack(push,1) typedef struct { rom_t bios; int ExtendedLUNCCBFormat; @@ -223,6 +224,7 @@ typedef struct { uint8_t AutoSCSIROM[32768]; uint8_t SCAMData[65536]; } buslogic_data_t; +#pragma pack(pop) enum { diff --git a/src/scsi/scsi_x54x.c b/src/scsi/scsi_x54x.c index cc2a982cc..451c6aa30 100644 --- a/src/scsi/scsi_x54x.c +++ b/src/scsi/scsi_x54x.c @@ -1450,8 +1450,7 @@ x54x_reset_poll(void *priv) { x54x_t *dev = (x54x_t *)priv; - dev->Status &= ~STAT_STST; - dev->Status |= STAT_IDLE; + dev->Status = STAT_INIT | STAT_IDLE; dev->ResetCB = 0LL; } @@ -1661,6 +1660,7 @@ x54x_out(uint16_t port, uint8_t val, void *priv) case CMD_INQUIRY: /* Inquiry */ memcpy(dev->DataBuf, dev->fw_rev, 4); + x54x_log("Adapter inquiry: %c %c %c %c\n", dev->fw_rev[0], dev->fw_rev[1], dev->fw_rev[2], dev->fw_rev[3]); dev->DataReplyLeft = 4; break; @@ -1699,13 +1699,14 @@ x54x_out(uint16_t port, uint8_t val, void *priv) case CMD_RETDEVS: /* return Installed Devices */ memset(dev->DataBuf, 0x00, 8); + + if (dev->ven_get_host_id) + host_id = dev->ven_get_host_id(dev); + for (i=0; iDataBuf[i] = 0x00; /* Skip the HA .. */ - if (dev->ven_get_host_id) - host_id = dev->ven_get_host_id(dev); - if (i == host_id) continue; for (j=0; jDataBuf[2] = dev->ven_get_host_id(dev); else dev->DataBuf[2] = dev->HostID; + x54x_log("Configuration data: %02X %02X %02X\n", dev->DataBuf[0], dev->DataBuf[1], dev->DataBuf[2]); dev->DataReplyLeft = 3; break;