Diff reduction with Adaptec's vendor driver.

Driver version 2.1.9 chosen as that Adaptec version roughly corresponds
with the current feature set merged to the in-tree driver.
This commit is contained in:
Ed Maste 2010-02-14 17:14:11 +00:00
parent 438e84ae72
commit 8e7e6335bc
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=203885
4 changed files with 28 additions and 15 deletions

View File

@ -33,7 +33,6 @@ __FBSDID("$FreeBSD$");
/*
* Driver for the Adaptec 'FSA' family of PCI/SCSI RAID adapters.
*/
#define AAC_DRIVER_VERSION 0x02000000
#define AAC_DRIVERNAME "aac"
#include "opt_aac.h"
@ -2767,10 +2766,8 @@ aac_describe_controller(struct aac_softc *sc)
}
device_printf(sc->aac_dev, "%s, aac driver %d.%d.%d-%d\n",
adapter_type,
AAC_DRIVER_VERSION >> 24,
(AAC_DRIVER_VERSION >> 16) & 0xFF,
AAC_DRIVER_VERSION & 0xFF,
AAC_DRIVER_BUILD);
AAC_DRIVER_MAJOR_VERSION, AAC_DRIVER_MINOR_VERSION,
AAC_DRIVER_BUGFIX_LEVEL, AAC_DRIVER_BUILD);
aac_release_sync_fib(sc);
mtx_unlock(&sc->aac_io_lock);
@ -3255,10 +3252,16 @@ aac_rev_check(struct aac_softc *sc, caddr_t udata)
* Doctor up the response struct.
*/
rev_check_resp.possiblyCompatible = 1;
rev_check_resp.adapterSWRevision.external.ul =
sc->aac_revision.external.ul;
rev_check_resp.adapterSWRevision.external.comp.major =
AAC_DRIVER_MAJOR_VERSION;
rev_check_resp.adapterSWRevision.external.comp.minor =
AAC_DRIVER_MINOR_VERSION;
rev_check_resp.adapterSWRevision.external.comp.type =
AAC_DRIVER_TYPE;
rev_check_resp.adapterSWRevision.external.comp.dash =
AAC_DRIVER_BUGFIX_LEVEL;
rev_check_resp.adapterSWRevision.buildNumber =
sc->aac_revision.buildNumber;
AAC_DRIVER_BUILD;
return(copyout((caddr_t)&rev_check_resp, udata,
sizeof(struct aac_rev_check_resp)));

View File

@ -405,10 +405,10 @@ aac_cam_action(struct cam_sim *sim, union ccb *ccb)
if (ccb->ccb_h.flags & CAM_DATA_PHYS) {
/* Send a 32bit command */
fib->Header.Command = ScsiPortCommand;
srb->sg_map32.SgCount = 1;
srb->sg_map32.SgEntry[0].SgAddress =
srb->sg_map.SgCount = 1;
srb->sg_map.SgEntry[0].SgAddress =
(uint32_t)(uintptr_t)csio->data_ptr;
srb->sg_map32.SgEntry[0].SgByteCount =
srb->sg_map.SgEntry[0].SgByteCount =
csio->dxfer_len;
} else {
/*
@ -417,15 +417,15 @@ aac_cam_action(struct cam_sim *sim, union ccb *ccb)
*/
cm->cm_data = (void *)csio->data_ptr;
cm->cm_datalen = csio->dxfer_len;
cm->cm_sgtable = &srb->sg_map32;
cm->cm_sgtable = &srb->sg_map;
}
} else {
/* XXX Need to handle multiple s/g elements */
panic("aac_cam: multiple s/g elements");
}
} else {
srb->sg_map32.SgCount = 0;
srb->sg_map32.SgEntry[0].SgByteCount = 0;
srb->sg_map.SgCount = 0;
srb->sg_map.SgEntry[0].SgByteCount = 0;
srb->data_len = 0;
}

View File

@ -1374,7 +1374,7 @@ struct aac_srb {
u_int32_t retry_limit;
u_int32_t cdb_len;
u_int8_t cdb[16];
struct aac_sg_table sg_map32;
struct aac_sg_table sg_map;
};
enum {

View File

@ -37,6 +37,16 @@
#include <sys/selinfo.h>
#include <geom/geom_disk.h>
#define AAC_TYPE_DEVO 1
#define AAC_TYPE_ALPHA 2
#define AAC_TYPE_BETA 3
#define AAC_TYPE_RELEASE 4
#define AAC_DRIVER_MAJOR_VERSION 2
#define AAC_DRIVER_MINOR_VERSION 1
#define AAC_DRIVER_BUGFIX_LEVEL 9
#define AAC_DRIVER_TYPE AAC_TYPE_RELEASE
#ifndef AAC_DRIVER_BUILD
# define AAC_DRIVER_BUILD 1
#endif