diff options
author | Bjorn Andersson <bjorn.andersson@linaro.org> | 2020-03-01 23:03:05 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-03-03 17:52:21 -0800 |
commit | 71046abfffe9d34ae90c82cf9c8e44355c2e114c (patch) | |
tree | 25164161f82b117ff683f9a075663ffdb50d4f41 /net/qrtr/qrtr.c | |
parent | a1dc1d6a05a730b62b45828975a088db577d3139 (diff) | |
download | lwn-71046abfffe9d34ae90c82cf9c8e44355c2e114c.tar.gz lwn-71046abfffe9d34ae90c82cf9c8e44355c2e114c.zip |
net: qrtr: Fix FIXME related to qrtr_ns_init()
The 2 second delay before calling qrtr_ns_init() meant that the remote
processors would register as endpoints in qrtr and the say_hello() call
would therefor broadcast the outgoing HELLO to them. With the HELLO
handshake corrected this delay is no longer needed.
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/qrtr/qrtr.c')
-rw-r--r-- | net/qrtr/qrtr.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/net/qrtr/qrtr.c b/net/qrtr/qrtr.c index 423310896285..e22092e4a783 100644 --- a/net/qrtr/qrtr.c +++ b/net/qrtr/qrtr.c @@ -9,7 +9,6 @@ #include <linux/termios.h> /* For TIOCINQ/OUTQ */ #include <linux/spinlock.h> #include <linux/wait.h> -#include <linux/workqueue.h> #include <net/sock.h> @@ -110,8 +109,6 @@ static DEFINE_MUTEX(qrtr_node_lock); static DEFINE_IDR(qrtr_ports); static DEFINE_MUTEX(qrtr_port_lock); -static struct delayed_work qrtr_ns_work; - /** * struct qrtr_node - endpoint node * @ep_lock: lock for endpoint management and callbacks @@ -1263,11 +1260,7 @@ static int __init qrtr_proto_init(void) return rc; } - /* FIXME: Currently, this 2s delay is required to catch the NEW_SERVER - * messages from routers. But the fix could be somewhere else. - */ - INIT_DELAYED_WORK(&qrtr_ns_work, qrtr_ns_init); - schedule_delayed_work(&qrtr_ns_work, msecs_to_jiffies(2000)); + qrtr_ns_init(); return rc; } @@ -1275,7 +1268,6 @@ postcore_initcall(qrtr_proto_init); static void __exit qrtr_proto_fini(void) { - cancel_delayed_work_sync(&qrtr_ns_work); qrtr_ns_remove(); sock_unregister(qrtr_family.family); proto_unregister(&qrtr_proto); |