Loading drivers/soc/qcom/qmi_interface.c +2 −5 Original line number Diff line number Diff line Loading @@ -351,8 +351,7 @@ int qmi_txn_wait(struct qmi_txn *txn, unsigned long timeout) struct qmi_handle *qmi = txn->qmi; int ret; ret = wait_for_completion_interruptible_timeout(&txn->completion, timeout); ret = wait_for_completion_timeout(&txn->completion, timeout); mutex_lock(&qmi->txn_lock); mutex_lock(&txn->lock); Loading @@ -360,9 +359,7 @@ int qmi_txn_wait(struct qmi_txn *txn, unsigned long timeout) mutex_unlock(&txn->lock); mutex_unlock(&qmi->txn_lock); if (ret < 0) return ret; else if (ret == 0) if (ret == 0) return -ETIMEDOUT; else return txn->result; Loading net/qrtr/qrtr.c +6 −3 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/wait.h> #include <linux/rwsem.h> #include <linux/ipc_logging.h> #include <linux/uidgid.h> #include <net/sock.h> Loading @@ -38,6 +39,8 @@ #define QRTR_STATE_MULTI -2 #define QRTR_STATE_INIT -1 #define AID_VENDOR_QRTR KGIDT_INIT(2906) /** * struct qrtr_hdr_v1 - (I|R)PCrouter packet header version 1 * @version: protocol version Loading Loading @@ -920,7 +923,8 @@ static int qrtr_port_assign(struct qrtr_sock *ipc, int *port) GFP_ATOMIC); if (rc >= 0) *port = rc; } else if (*port < QRTR_MIN_EPH_SOCKET && !capable(CAP_NET_ADMIN)) { } else if (*port < QRTR_MIN_EPH_SOCKET && !(capable(CAP_NET_ADMIN) || in_egroup_p(AID_VENDOR_QRTR))) { rc = -EACCES; } else if (*port == QRTR_PORT_CTRL) { rc = idr_alloc(&qrtr_ports, ipc, 0, 1, GFP_ATOMIC); Loading Loading @@ -1493,8 +1497,7 @@ static int qrtr_addr_doit(struct sk_buff *skb, struct nlmsghdr *nlh, struct ifaddrmsg *ifm; int rc; if (!netlink_capable(skb, CAP_NET_ADMIN) && !netlink_capable(skb, CAP_NET_BIND_SERVICE)) if (!netlink_capable(skb, CAP_NET_ADMIN)) return -EPERM; ASSERT_RTNL(); Loading Loading
drivers/soc/qcom/qmi_interface.c +2 −5 Original line number Diff line number Diff line Loading @@ -351,8 +351,7 @@ int qmi_txn_wait(struct qmi_txn *txn, unsigned long timeout) struct qmi_handle *qmi = txn->qmi; int ret; ret = wait_for_completion_interruptible_timeout(&txn->completion, timeout); ret = wait_for_completion_timeout(&txn->completion, timeout); mutex_lock(&qmi->txn_lock); mutex_lock(&txn->lock); Loading @@ -360,9 +359,7 @@ int qmi_txn_wait(struct qmi_txn *txn, unsigned long timeout) mutex_unlock(&txn->lock); mutex_unlock(&qmi->txn_lock); if (ret < 0) return ret; else if (ret == 0) if (ret == 0) return -ETIMEDOUT; else return txn->result; Loading
net/qrtr/qrtr.c +6 −3 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ #include <linux/wait.h> #include <linux/rwsem.h> #include <linux/ipc_logging.h> #include <linux/uidgid.h> #include <net/sock.h> Loading @@ -38,6 +39,8 @@ #define QRTR_STATE_MULTI -2 #define QRTR_STATE_INIT -1 #define AID_VENDOR_QRTR KGIDT_INIT(2906) /** * struct qrtr_hdr_v1 - (I|R)PCrouter packet header version 1 * @version: protocol version Loading Loading @@ -920,7 +923,8 @@ static int qrtr_port_assign(struct qrtr_sock *ipc, int *port) GFP_ATOMIC); if (rc >= 0) *port = rc; } else if (*port < QRTR_MIN_EPH_SOCKET && !capable(CAP_NET_ADMIN)) { } else if (*port < QRTR_MIN_EPH_SOCKET && !(capable(CAP_NET_ADMIN) || in_egroup_p(AID_VENDOR_QRTR))) { rc = -EACCES; } else if (*port == QRTR_PORT_CTRL) { rc = idr_alloc(&qrtr_ports, ipc, 0, 1, GFP_ATOMIC); Loading Loading @@ -1493,8 +1497,7 @@ static int qrtr_addr_doit(struct sk_buff *skb, struct nlmsghdr *nlh, struct ifaddrmsg *ifm; int rc; if (!netlink_capable(skb, CAP_NET_ADMIN) && !netlink_capable(skb, CAP_NET_BIND_SERVICE)) if (!netlink_capable(skb, CAP_NET_ADMIN)) return -EPERM; ASSERT_RTNL(); Loading