Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next 0/2] Introduce rtnl_lock_killable()
@ 2018-03-14 19:17 Kirill Tkhai
  2018-03-14 19:17 ` [PATCH net-next 1/2] net: Add rtnl_lock_killable() Kirill Tkhai
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Kirill Tkhai @ 2018-03-14 19:17 UTC (permalink / raw)
  To: davem, ktkhai, vyasevic, edumazet, nicolas.dichtel, netdev

rtnl_lock() is widely used mutex in kernel. Some of kernel code
does memory allocations under it. In case of memory deficit this
may invoke OOM killer, but the problem is a killed task can't
exit if it's waiting for the mutex. This may be a reason of deadlock
and panic.

This patchset adds a new primitive, which responds on SIGKILL,
and it allows to use it in the places, where we don't want
to sleep forever. Also, the first place is made to use it.

---

Kirill Tkhai (2):
      net: Add rtnl_lock_killable()
      net: Use rtnl_lock_killable() in register_netdev()


 include/linux/rtnetlink.h |    1 +
 net/core/dev.c            |    3 ++-
 net/core/rtnetlink.c      |    6 ++++++
 3 files changed, 9 insertions(+), 1 deletion(-)

--
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-03-16 16:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-14 19:17 [PATCH net-next 0/2] Introduce rtnl_lock_killable() Kirill Tkhai
2018-03-14 19:17 ` [PATCH net-next 1/2] net: Add rtnl_lock_killable() Kirill Tkhai
2018-03-14 19:17 ` [PATCH net-next 2/2] net: Use rtnl_lock_killable() in register_netdev() Kirill Tkhai
2018-03-16 16:31 ` [PATCH net-next 0/2] Introduce rtnl_lock_killable() David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox