diff options
author | Scott Long <scottl@FreeBSD.org> | 2016-07-19 19:09:23 +0000 |
---|---|---|
committer | Scott Long <scottl@FreeBSD.org> | 2016-07-19 19:09:23 +0000 |
commit | 49e20d2420925a967e78702fe743655badce9e3e (patch) | |
tree | c7dbce975b48733739498b7065e8603344fe92b9 /sys/dev/nvd | |
parent | ddda1a9c2f76e24c925075d4bd224e99d5dc5352 (diff) | |
download | src-49e20d2420925a967e78702fe743655badce9e3e.tar.gz src-49e20d2420925a967e78702fe743655badce9e3e.zip |
Supporting flushing the dump before returning, and simplify/combine the
logic. Switch to a 5us delay since most NVME devices can easily do 200,000
iops.
Submitted by: imp
MFC after: 3 days
Sponsored by: Netflix, Inc.
Notes
Notes:
svn path=/head/; revision=303040
Diffstat (limited to 'sys/dev/nvd')
-rw-r--r-- | sys/dev/nvd/nvd.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/sys/dev/nvd/nvd.c b/sys/dev/nvd/nvd.c index 89ac71c59a34..9cc63fdaad56 100644 --- a/sys/dev/nvd/nvd.c +++ b/sys/dev/nvd/nvd.c @@ -237,14 +237,7 @@ nvd_dump(void *arg, void *virt, vm_offset_t phys, off_t offset, size_t len) dp = arg; ndisk = dp->d_drv1; - if (len > 0) { - if ((error = nvme_ns_dump(ndisk->ns, virt, offset, len)) != 0) - return (error); - } else { - /* XXX sync to stable storage */ - } - - return (0); + return (nvme_ns_dump(ndisk->ns, virt, offset, len)); } static void |