mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 06:09:23 -04:00
usb: qti_gadget: Select LLCC TCM memory for USB RMNET IN buffers
This change calls available API from USB GSI function driver to select LLCC TCM memory for USB RMNET IN buffers when property "qcom,rmnet_in_use_tcm_mem" is set with RMNET USB composition device tree child node of qti_gadget node. Change-Id: Ic2c3c2fb438801ebbefe15f30b92364a07059df7 Signed-off-by: Mayank Rana <mrana@codeaurora.org>
This commit is contained in:
parent
8f812be36a
commit
dddcd91291
1 changed files with 11 additions and 0 deletions
|
|
@ -9,6 +9,7 @@
|
|||
#include <linux/platform_device.h>
|
||||
#include <linux/of.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/usb/dwc3-msm.h>
|
||||
|
||||
struct qti_usb_function {
|
||||
struct usb_function_instance *fi;
|
||||
|
|
@ -322,6 +323,16 @@ static int qti_usb_func_alloc(struct qti_usb_config *qcfg,
|
|||
memcpy(cdev->qw_sign, qw_sign, QW_SIGN_LEN);
|
||||
}
|
||||
|
||||
#if IS_ENABLED(CONFIG_USB_F_GSI)
|
||||
struct qti_usb_gadget *qg;
|
||||
|
||||
if (!strcmp(instance_name, "rmnet")) {
|
||||
qg = container_of(cdev, struct qti_usb_gadget, cdev);
|
||||
rmnet_gsi_update_in_buffer_mem_type(f,
|
||||
of_property_read_bool(qg->cfg_node,
|
||||
"qcom,rmnet_in_use_tcm_mem"));
|
||||
}
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue