Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f56ae6f8 authored by Ajay Agarwal's avatar Ajay Agarwal
Browse files

usb: gadget: f_gsi: Increase num of buffers to 50 for ECM



Currently the ECM interface has 15 data buffers allocated by the
driver which can be used by IPA. In some telematics platform
concurrency scenarios like Ethernet and USB together, this number
is not enough for IPA to keep packets in its stack and service
the Ethernet pipe. Hence the packets get dropped leading to lower
throughput on both the pipes. Fix this by increasing the number
of buffers to 50 for relevant interfaces.

Change-Id: I65e0282143d489ab9f6b9fcc640cad7808adb68d
Signed-off-by: default avatarAjay Agarwal <ajaya@codeaurora.org>
parent 4c326afe
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -2968,7 +2968,7 @@ static int gsi_bind(struct usb_configuration *c, struct usb_function *f)
		info.out_epname = "gsi-epout";
		info.in_req_buf_len = GSI_IN_RNDIS_BUFF_SIZE;
		gsi->d_port.in_aggr_size = GSI_IN_RNDIS_AGGR_SIZE;
		info.in_req_num_buf = GSI_NUM_IN_RNDIS_BUFFERS;
		info.in_req_num_buf = GSI_NUM_IN_RNDIS_RMNET_ECM_BUFFERS;
		gsi->d_port.out_aggr_size = GSI_OUT_AGGR_SIZE;
		info.out_req_buf_len = GSI_OUT_AGGR_SIZE;
		info.out_req_num_buf = GSI_NUM_OUT_BUFFERS;
@@ -3167,7 +3167,7 @@ static int gsi_bind(struct usb_configuration *c, struct usb_function *f)
		info.out_epname = "gsi-epout";
		gsi->d_port.in_aggr_size = GSI_IN_RMNET_AGGR_SIZE;
		info.in_req_buf_len = GSI_IN_RMNET_BUFF_SIZE;
		info.in_req_num_buf = GSI_NUM_IN_RMNET_BUFFERS;
		info.in_req_num_buf = GSI_NUM_IN_RNDIS_RMNET_ECM_BUFFERS;
		gsi->d_port.out_aggr_size = GSI_OUT_AGGR_SIZE;
		info.out_req_buf_len = GSI_OUT_RMNET_BUF_LEN;
		info.out_req_num_buf = GSI_NUM_OUT_BUFFERS;
@@ -3200,7 +3200,7 @@ static int gsi_bind(struct usb_configuration *c, struct usb_function *f)
		info.out_epname = "gsi-epout";
		gsi->d_port.in_aggr_size = GSI_ECM_AGGR_SIZE;
		info.in_req_buf_len = GSI_IN_BUFF_SIZE;
		info.in_req_num_buf = GSI_NUM_IN_BUFFERS;
		info.in_req_num_buf = GSI_NUM_IN_RNDIS_RMNET_ECM_BUFFERS;
		gsi->d_port.out_aggr_size = GSI_ECM_AGGR_SIZE;
		info.out_req_buf_len = GSI_OUT_ECM_BUF_LEN;
		info.out_req_num_buf = GSI_NUM_OUT_BUFFERS;
+1 −2
Original line number Diff line number Diff line
@@ -44,8 +44,7 @@
#define GSI_MAX_CTRL_PKT_SIZE 8192
#define GSI_CTRL_DTR (1 << 0)

#define GSI_NUM_IN_RNDIS_BUFFERS 50
#define GSI_NUM_IN_RMNET_BUFFERS 50
#define GSI_NUM_IN_RNDIS_RMNET_ECM_BUFFERS 50
#define GSI_NUM_IN_BUFFERS 15
#define GSI_IN_BUFF_SIZE 2048
#define GSI_IN_RMNET_BUFF_SIZE 31744