summaryrefslogtreecommitdiff
path: root/sys/dev/mlx
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/mlx')
-rw-r--r--sys/dev/mlx/mlx.c2
-rw-r--r--sys/dev/mlx/mlxvar.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/mlx/mlx.c b/sys/dev/mlx/mlx.c
index dc6a4baa3cfe2..6087216901fd9 100644
--- a/sys/dev/mlx/mlx.c
+++ b/sys/dev/mlx/mlx.c
@@ -1979,7 +1979,7 @@ mlx_user_command(struct mlx_softc *sc, struct mlx_usercommand *mu)
* initial contents
*/
if (mu->mu_datasize > 0) {
- if (mu->mu_datasize > MAXPHYS) {
+ if (mu->mu_datasize > MLX_MAXPHYS) {
error = EINVAL;
goto out;
}
diff --git a/sys/dev/mlx/mlxvar.h b/sys/dev/mlx/mlxvar.h
index 345cf9933c22c..a09f9075ac32d 100644
--- a/sys/dev/mlx/mlxvar.h
+++ b/sys/dev/mlx/mlxvar.h
@@ -47,6 +47,7 @@
* making that fit cleanly without crossing page boundaries requires rounding up
* to the next power of two.
*/
+#define MLX_MAXPHYS (128 * 124)
#define MLX_NSEG 64
#define MLX_NSLOTS 256 /* max number of command slots */