summaryrefslogtreecommitdiff
path: root/sys/dev/mlx/mlx_disk.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/mlx/mlx_disk.c')
-rw-r--r--sys/dev/mlx/mlx_disk.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/dev/mlx/mlx_disk.c b/sys/dev/mlx/mlx_disk.c
index 1fb0a27c9da7..bc487d1330a0 100644
--- a/sys/dev/mlx/mlx_disk.c
+++ b/sys/dev/mlx/mlx_disk.c
@@ -157,6 +157,11 @@ mlxd_strategy(struct bio *bp)
goto bad;
}
+ if ((bp->bio_cmd != BIO_READ) && (bp->bio_cmd != BIO_WRITE)) {
+ bp->bio_error = EOPNOTSUPP;
+ goto bad;
+ }
+
/* XXX may only be temporarily offline - sleep? */
MLX_IO_LOCK(sc->mlxd_controller);
if (sc->mlxd_drive->ms_state == MLX_SYSD_OFFLINE) {