Loading arch/arm64/boot/dts/qcom/sm8150.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -2673,6 +2673,7 @@ qcom,modem_qrtr { qcom,glink-channels = "IPCRTR"; qcom,low-latency; qcom,intents = <0x800 5 0x2000 3 0x4400 2>; Loading Loading @@ -2747,6 +2748,7 @@ qcom,slpi_qrtr { qcom,glink-channels = "IPCRTR"; qcom,low-latency; qcom,intents = <0x800 5 0x2000 3 0x4400 2>; Loading net/qrtr/fifo.c +2 −2 Original line number Diff line number Diff line /* * Copyright (c) 2016, Linaro Ltd * Copyright (c) 2018, The Linux Foundation. All rights reserved. * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -354,7 +354,7 @@ static int qrtr_fifo_xprt_probe(struct platform_device *pdev) } xprtp->ep.xmit = xprt_write; ret = qrtr_endpoint_register(&xprtp->ep, QRTR_EP_NID_AUTO); ret = qrtr_endpoint_register(&xprtp->ep, QRTR_EP_NID_AUTO, false); if (ret) return ret; Loading net/qrtr/mhi.c +5 −2 Original line number Diff line number Diff line /* Copyright (c) 2018, The Linux Foundation. All rights reserved. /* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -132,6 +132,7 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev, { struct qrtr_mhi_dev *qdev; u32 net_id; bool rt; int rc; qdev = devm_kzalloc(&mhi_dev->dev, sizeof(*qdev), GFP_KERNEL); Loading @@ -146,10 +147,12 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev, if (rc < 0) net_id = QRTR_EP_NET_ID_AUTO; rt = of_property_read_bool(mhi_dev->dev.of_node, "qcom,low-latency"); INIT_LIST_HEAD(&qdev->ul_pkts); spin_lock_init(&qdev->ul_lock); rc = qrtr_endpoint_register(&qdev->ep, net_id); rc = qrtr_endpoint_register(&qdev->ep, net_id, rt); if (rc) return rc; Loading net/qrtr/qrtr.c +7 −1 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ #include <linux/uidgid.h> #include <net/sock.h> #include <uapi/linux/sched/types.h> #include "qrtr.h" Loading Loading @@ -903,13 +904,16 @@ static void qrtr_node_rx_work(struct kthread_work *work) * qrtr_endpoint_register() - register a new endpoint * @ep: endpoint to register * @nid: desired node id; may be QRTR_EP_NID_AUTO for auto-assignment * @rt: flag to notify real time low latency endpoint * Return: 0 on success; negative error code on failure * * The specified endpoint must have the xmit function pointer set on call. */ int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id) int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id, bool rt) { struct qrtr_node *node; struct sched_param param = {.sched_priority = 1}; if (!ep || !ep->xmit) return -EINVAL; Loading @@ -932,6 +936,8 @@ int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id) kfree(node); return -ENOMEM; } if (rt) sched_setscheduler(node->task, SCHED_FIFO, ¶m); mutex_init(&node->qrtr_tx_lock); INIT_RADIX_TREE(&node->qrtr_tx_flow, GFP_KERNEL); Loading net/qrtr/qrtr.h +2 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,8 @@ struct qrtr_endpoint { struct qrtr_node *node; }; int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id); int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id, bool rt); void qrtr_endpoint_unregister(struct qrtr_endpoint *ep); Loading Loading
arch/arm64/boot/dts/qcom/sm8150.dtsi +2 −0 Original line number Diff line number Diff line Loading @@ -2673,6 +2673,7 @@ qcom,modem_qrtr { qcom,glink-channels = "IPCRTR"; qcom,low-latency; qcom,intents = <0x800 5 0x2000 3 0x4400 2>; Loading Loading @@ -2747,6 +2748,7 @@ qcom,slpi_qrtr { qcom,glink-channels = "IPCRTR"; qcom,low-latency; qcom,intents = <0x800 5 0x2000 3 0x4400 2>; Loading
net/qrtr/fifo.c +2 −2 Original line number Diff line number Diff line /* * Copyright (c) 2016, Linaro Ltd * Copyright (c) 2018, The Linux Foundation. All rights reserved. * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -354,7 +354,7 @@ static int qrtr_fifo_xprt_probe(struct platform_device *pdev) } xprtp->ep.xmit = xprt_write; ret = qrtr_endpoint_register(&xprtp->ep, QRTR_EP_NID_AUTO); ret = qrtr_endpoint_register(&xprtp->ep, QRTR_EP_NID_AUTO, false); if (ret) return ret; Loading
net/qrtr/mhi.c +5 −2 Original line number Diff line number Diff line /* Copyright (c) 2018, The Linux Foundation. All rights reserved. /* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -132,6 +132,7 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev, { struct qrtr_mhi_dev *qdev; u32 net_id; bool rt; int rc; qdev = devm_kzalloc(&mhi_dev->dev, sizeof(*qdev), GFP_KERNEL); Loading @@ -146,10 +147,12 @@ static int qcom_mhi_qrtr_probe(struct mhi_device *mhi_dev, if (rc < 0) net_id = QRTR_EP_NET_ID_AUTO; rt = of_property_read_bool(mhi_dev->dev.of_node, "qcom,low-latency"); INIT_LIST_HEAD(&qdev->ul_pkts); spin_lock_init(&qdev->ul_lock); rc = qrtr_endpoint_register(&qdev->ep, net_id); rc = qrtr_endpoint_register(&qdev->ep, net_id, rt); if (rc) return rc; Loading
net/qrtr/qrtr.c +7 −1 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ #include <linux/uidgid.h> #include <net/sock.h> #include <uapi/linux/sched/types.h> #include "qrtr.h" Loading Loading @@ -903,13 +904,16 @@ static void qrtr_node_rx_work(struct kthread_work *work) * qrtr_endpoint_register() - register a new endpoint * @ep: endpoint to register * @nid: desired node id; may be QRTR_EP_NID_AUTO for auto-assignment * @rt: flag to notify real time low latency endpoint * Return: 0 on success; negative error code on failure * * The specified endpoint must have the xmit function pointer set on call. */ int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id) int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id, bool rt) { struct qrtr_node *node; struct sched_param param = {.sched_priority = 1}; if (!ep || !ep->xmit) return -EINVAL; Loading @@ -932,6 +936,8 @@ int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id) kfree(node); return -ENOMEM; } if (rt) sched_setscheduler(node->task, SCHED_FIFO, ¶m); mutex_init(&node->qrtr_tx_lock); INIT_RADIX_TREE(&node->qrtr_tx_flow, GFP_KERNEL); Loading
net/qrtr/qrtr.h +2 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,8 @@ struct qrtr_endpoint { struct qrtr_node *node; }; int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id); int qrtr_endpoint_register(struct qrtr_endpoint *ep, unsigned int net_id, bool rt); void qrtr_endpoint_unregister(struct qrtr_endpoint *ep); Loading