Use GFP_NOIO in vdev_disk_io_flush()
[zfs.git] / module / zfs / vdev_disk.c
index 08f64a9..2869716 100644 (file)
@@ -407,8 +407,7 @@ vdev_disk_dio_put(dio_request_t *dr)
                vdev_disk_dio_free(dr);
 
                if (zio) {
-                       zio->io_delay = jiffies_to_msecs(
-                           jiffies_64 - zio->io_delay);
+                       zio->io_delay = jiffies_64 - zio->io_delay;
                        zio->io_error = error;
                        ASSERT3S(zio->io_error, >=, 0);
                        if (zio->io_error)
@@ -609,7 +608,7 @@ BIO_END_IO_PROTO(vdev_disk_io_flush_completion, bio, size, rc)
 {
        zio_t *zio = bio->bi_private;
 
-       zio->io_delay = jiffies_to_msecs(jiffies_64 - zio->io_delay);
+       zio->io_delay = jiffies_64 - zio->io_delay;
        zio->io_error = -rc;
        if (rc && (rc == -EOPNOTSUPP))
                zio->io_vd->vdev_nowritecache = B_TRUE;
@@ -633,7 +632,7 @@ vdev_disk_io_flush(struct block_device *bdev, zio_t *zio)
        if (!q)
                return ENXIO;
 
-       bio = bio_alloc(GFP_KERNEL, 0);
+       bio = bio_alloc(GFP_NOIO, 0);
        if (!bio)
                return ENOMEM;