From 3bede2908acc6cbc8e809d63d7c9b5fd95932dfb Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Wed, 19 May 2021 15:56:54 -0700 Subject: [PATCH] cxgbei: Add tunable sysctls for the FirstBurstLength and MaxBurstLength. Reviewed by: np Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D30269 --- sys/dev/cxgbe/cxgbei/icl_cxgbei.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/dev/cxgbe/cxgbei/icl_cxgbei.c b/sys/dev/cxgbe/cxgbei/icl_cxgbei.c index d54464b63542..fce593b54032 100644 --- a/sys/dev/cxgbe/cxgbei/icl_cxgbei.c +++ b/sys/dev/cxgbe/cxgbei/icl_cxgbei.c @@ -104,6 +104,12 @@ static MALLOC_DEFINE(M_CXGBEI, "cxgbei", "cxgbei(4)"); SYSCTL_NODE(_kern_icl, OID_AUTO, cxgbei, CTLFLAG_RD | CTLFLAG_MPSAFE, 0, "Chelsio iSCSI offload"); +static int first_burst_length = 8192; +SYSCTL_INT(_kern_icl_cxgbei, OID_AUTO, first_burst_length, CTLFLAG_RWTUN, + &first_burst_length, 0, "First burst length"); +static int max_burst_length = 2 * 1024 * 1024; +SYSCTL_INT(_kern_icl_cxgbei, OID_AUTO, max_burst_length, CTLFLAG_RWTUN, + &max_burst_length, 0, "Maximum burst length"); static int sendspace = 1048576; SYSCTL_INT(_kern_icl_cxgbei, OID_AUTO, sendspace, CTLFLAG_RWTUN, &sendspace, 0, "Default send socket buffer size"); @@ -1206,8 +1212,8 @@ icl_cxgbei_limits(struct icl_drv_limits *idl) idl->idl_max_send_data_segment_length = (1 << 24) - 1; /* These are somewhat arbitrary. */ - idl->idl_max_burst_length = 2 * 1024 * 1024; - idl->idl_first_burst_length = 8192; + idl->idl_max_burst_length = max_burst_length; + idl->idl_first_burst_length = first_burst_length; t4_iterate(cxgbei_limits, idl);