* [PATCH][net-next] net: Use RCU_POINTER_INITIALIZER() to init static variable
@ 2019-02-25 2:43 Li RongQing
2019-02-26 22:52 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Li RongQing @ 2019-02-25 2:43 UTC (permalink / raw)
To: netdev
This pointer is RCU protected, so proper primitives should be used.
Signed-off-by: Zhang Yu <zhangyu31@baidu.com>
Signed-off-by: Li RongQing <lirongqing@baidu.com>
---
net/sched/sch_generic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
index 38e5add14fab..7bcee8b8f803 100644
--- a/net/sched/sch_generic.c
+++ b/net/sched/sch_generic.c
@@ -559,7 +559,7 @@ struct Qdisc_ops noop_qdisc_ops __read_mostly = {
};
static struct netdev_queue noop_netdev_queue = {
- .qdisc = &noop_qdisc,
+ RCU_POINTER_INITIALIZER(qdisc, &noop_qdisc),
.qdisc_sleeping = &noop_qdisc,
};
--
2.16.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH][net-next] net: Use RCU_POINTER_INITIALIZER() to init static variable
2019-02-25 2:43 [PATCH][net-next] net: Use RCU_POINTER_INITIALIZER() to init static variable Li RongQing
@ 2019-02-26 22:52 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2019-02-26 22:52 UTC (permalink / raw)
To: lirongqing; +Cc: netdev
From: Li RongQing <lirongqing@baidu.com>
Date: Mon, 25 Feb 2019 10:43:06 +0800
> This pointer is RCU protected, so proper primitives should be used.
>
> Signed-off-by: Zhang Yu <zhangyu31@baidu.com>
> Signed-off-by: Li RongQing <lirongqing@baidu.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-02-26 22:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-25 2:43 [PATCH][net-next] net: Use RCU_POINTER_INITIALIZER() to init static variable Li RongQing
2019-02-26 22:52 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).