aboutsummaryrefslogtreecommitdiff
path: root/sys/cam
diff options
context:
space:
mode:
authorAlexander Motin <mav@FreeBSD.org>2010-04-30 07:56:21 +0000
committerAlexander Motin <mav@FreeBSD.org>2010-04-30 07:56:21 +0000
commite2a751891fb250e505d5f2982b7df48bf134377d (patch)
treecf5db53ce894f89b0d1c34472e1d9311b864e522 /sys/cam
parentd8665eb1f6c066967cedf5120ecd07af1d285c78 (diff)
downloadsrc-e2a751891fb250e505d5f2982b7df48bf134377d.tar.gz
src-e2a751891fb250e505d5f2982b7df48bf134377d.zip
Report PMP absence using target 15, same as for precence (not a wildcard),
to not confuse target ID checks at SIMs.
Notes
Notes: svn path=/head/; revision=207428
Diffstat (limited to 'sys/cam')
-rw-r--r--sys/cam/ata/ata_xpt.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/sys/cam/ata/ata_xpt.c b/sys/cam/ata/ata_xpt.c
index 10e61827ad7b..bd748cd4f453 100644
--- a/sys/cam/ata/ata_xpt.c
+++ b/sys/cam/ata/ata_xpt.c
@@ -1118,13 +1118,13 @@ ata_scan_bus(struct cam_periph *periph, union ccb *request_ccb)
work_ccb = request_ccb;
/* Reuse the same CCB to query if a device was really found */
scan_info = (ata_scan_bus_info *)work_ccb->ccb_h.ppriv_ptr0;
- /* Free the current request path- we're done with it. */
- xpt_free_path(work_ccb->ccb_h.path);
/* If there is PMP... */
if ((scan_info->cpi->hba_inquiry & PI_SATAPM) &&
(scan_info->counter == scan_info->cpi->max_target)) {
if (work_ccb->ccb_h.status == CAM_REQ_CMP) {
- /* everything else willbe probed by it */
+ /* everything else will be probed by it */
+ /* Free the current request path- we're done with it. */
+ xpt_free_path(work_ccb->ccb_h.path);
goto done;
} else {
struct ccb_trans_settings cts;
@@ -1132,7 +1132,7 @@ ata_scan_bus(struct cam_periph *periph, union ccb *request_ccb)
/* Report SIM that PM is absent. */
bzero(&cts, sizeof(cts));
xpt_setup_ccb(&cts.ccb_h,
- scan_info->request_ccb->ccb_h.path, 1);
+ work_ccb->ccb_h.path, CAM_PRIORITY_NONE);
cts.ccb_h.func_code = XPT_SET_TRAN_SETTINGS;
cts.type = CTS_TYPE_CURRENT_SETTINGS;
cts.xport_specific.sata.pm_present = 0;
@@ -1140,6 +1140,8 @@ ata_scan_bus(struct cam_periph *periph, union ccb *request_ccb)
xpt_action((union ccb *)&cts);
}
}
+ /* Free the current request path- we're done with it. */
+ xpt_free_path(work_ccb->ccb_h.path);
if (scan_info->counter ==
((scan_info->cpi->hba_inquiry & PI_SATAPM) ?
0 : scan_info->cpi->max_target)) {