return 0;
 }
 
+static int mlx5_devlink_eq_depth_validate(struct devlink *devlink, u32 id,
+                                         union devlink_param_value val,
+                                         struct netlink_ext_ack *extack)
+{
+       return (val.vu16 >= 64 && val.vu16 <= 4096) ? 0 : -EINVAL;
+}
+
 static const struct devlink_param mlx5_devlink_params[] = {
        DEVLINK_PARAM_DRIVER(MLX5_DEVLINK_PARAM_ID_FLOW_STEERING_MODE,
                             "flow_steering_mode", DEVLINK_PARAM_TYPE_STRING,
        DEVLINK_PARAM_GENERIC(ENABLE_REMOTE_DEV_RESET, BIT(DEVLINK_PARAM_CMODE_RUNTIME),
                              mlx5_devlink_enable_remote_dev_reset_get,
                              mlx5_devlink_enable_remote_dev_reset_set, NULL),
+       DEVLINK_PARAM_GENERIC(IO_EQ_SIZE, BIT(DEVLINK_PARAM_CMODE_DRIVERINIT),
+                             NULL, NULL, mlx5_devlink_eq_depth_validate),
 };
 
 static void mlx5_devlink_set_params_init_values(struct devlink *devlink)
                                                   value);
        }
 #endif
+
+       value.vu32 = MLX5_COMP_EQ_SIZE;
+       devlink_param_driverinit_value_set(devlink,
+                                          DEVLINK_PARAM_GENERIC_ID_IO_EQ_SIZE,
+                                          value);
 }
 
 static const struct devlink_param enable_eth_param =
 
 #include "lib/clock.h"
 #include "diag/fw_tracer.h"
 #include "mlx5_irq.h"
+#include "devlink.h"
 
 enum {
        MLX5_EQE_OWNER_INIT_VAL = 0x1,
        }
 }
 
+static u16 comp_eq_depth_devlink_param_get(struct mlx5_core_dev *dev)
+{
+       struct devlink *devlink = priv_to_devlink(dev);
+       union devlink_param_value val;
+       int err;
+
+       err = devlink_param_driverinit_value_get(devlink,
+                                                DEVLINK_PARAM_GENERIC_ID_IO_EQ_SIZE,
+                                                &val);
+       if (!err)
+               return val.vu32;
+       mlx5_core_dbg(dev, "Failed to get param. using default. err = %d\n", err);
+       return MLX5_COMP_EQ_SIZE;
+}
+
 static int create_comp_eqs(struct mlx5_core_dev *dev)
 {
        struct mlx5_eq_table *table = dev->priv.eq_table;
 
        INIT_LIST_HEAD(&table->comp_eqs_list);
        ncomp_eqs = table->num_comp_eqs;
-       nent = MLX5_COMP_EQ_SIZE;
+       nent = comp_eq_depth_devlink_param_get(dev);
        for (i = 0; i < ncomp_eqs; i++) {
                struct mlx5_eq_param param = {};
                int vecidx = i;