#include "venus-protocol/vn_protocol_driver_info.h"
#include "vk_enum_to_str.h"
+#define VN_RELAX_MIN_BASE_SLEEP_US (10)
+
static const struct debug_control vn_debug_options[] = {
{ "init", VN_DEBUG_INIT },
{ "result", VN_DEBUG_RESULT },
debug_get_num_option("VN_DRAW_CMD_BATCH_LIMIT", UINT32_MAX);
if (!vn_env.draw_cmd_batch_limit)
vn_env.draw_cmd_batch_limit = UINT32_MAX;
+ vn_env.relax_base_sleep_us = debug_get_num_option(
+ "VN_RELAX_BASE_SLEEP_US", VN_RELAX_MIN_BASE_SLEEP_US);
+ vn_env.relax_base_sleep_us =
+ MAX2(vn_env.relax_base_sleep_us, VN_RELAX_MIN_BASE_SLEEP_US);
}
void
* keep doubling both sleep length and count.
*/
const uint32_t busy_wait_order = 4;
- const uint32_t base_sleep_us = 10;
+ const uint32_t base_sleep_us = vn_env.relax_base_sleep_us;
const uint32_t warn_order = 12;
const uint32_t abort_order = 14;
uint64_t perf;
/* zero will be overridden to UINT32_MAX as no limit */
uint32_t draw_cmd_batch_limit;
+ uint32_t relax_base_sleep_us;
};
extern struct vn_env vn_env;