aboutsummaryrefslogtreecommitdiffstats
path: root/sys/cam/nvme/nvme_da.c
diff options
context:
space:
mode:
authorConrad Meyer <cem@FreeBSD.org>2018-08-09 21:53:32 +0000
committerConrad Meyer <cem@FreeBSD.org>2018-08-09 21:53:32 +0000
commit2077be2b731a284ceebb8363eafd7f5ea88c669c (patch)
tree565635011ef87929959016cef58b29d1118325da /sys/cam/nvme/nvme_da.c
parent2d73ac5e4a12f6231f9ad6c7fcd20ef84c8b41b3 (diff)
downloadsrc-2077be2b731a284ceebb8363eafd7f5ea88c669c.tar.gz
src-2077be2b731a284ceebb8363eafd7f5ea88c669c.zip
cam(4): Add an xpt-neutral flag indicating a valid panic CCB
No functional change. Note that this change is careful to set the CCB header xflags after foo_fill_bar() routines, which generally zero existing flags. An earlier version of this patch mistakenly set the flag before the fill routines. Submitted by: Scott Ferris <sferris AT isilon.com>, jhibbits@ Reviewed by: bdrewery@, markj@, and non-committer FreeBSD contributor Anton Rang Sponsored by: Dell EMC Isilon
Notes
Notes: svn path=/head/; revision=337554
Diffstat (limited to 'sys/cam/nvme/nvme_da.c')
-rw-r--r--sys/cam/nvme/nvme_da.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/cam/nvme/nvme_da.c b/sys/cam/nvme/nvme_da.c
index f83a038506aa..a430798ae016 100644
--- a/sys/cam/nvme/nvme_da.c
+++ b/sys/cam/nvme/nvme_da.c
@@ -426,6 +426,7 @@ ndadump(void *arg, void *virtual, vm_offset_t physical, off_t offset, size_t len
xpt_setup_ccb(&nvmeio.ccb_h, periph->path, CAM_PRIORITY_NORMAL);
nvmeio.ccb_state = NDA_CCB_DUMP;
nda_nvme_write(softc, &nvmeio, virtual, lba, length, count);
+ nvmeio.ccb_h.xflags |= CAM_CCB_DUMP;
error = cam_periph_runccb((union ccb *)&nvmeio, cam_periph_error,
0, SF_NO_RECOVERY | SF_NO_RETRY, NULL);
if (error != 0)
@@ -439,6 +440,7 @@ ndadump(void *arg, void *virtual, vm_offset_t physical, off_t offset, size_t len
nvmeio.ccb_state = NDA_CCB_DUMP;
nda_nvme_flush(softc, &nvmeio);
+ nvmeio.ccb_h.xflags |= CAM_CCB_DUMP;
error = cam_periph_runccb((union ccb *)&nvmeio, cam_periph_error,
0, SF_NO_RECOVERY | SF_NO_RETRY, NULL);
if (error != 0)