From: Teemu Koponen <tkoponen@iki.fi>
To: netdev@oss.sgi.com
Subject: New address announcements in RTMGRP_IPV4_IFADDR netlink group
Date: Mon, 6 Jun 2005 11:59:38 -0700 [thread overview]
Message-ID: <aa027950f2fc7f2ad640cac4a11fbe93@iki.fi> (raw)
Netlink developers and gurus,
While fine-tuning the handover speed for a certain L3 mobility daemon
under Linux 2.6.11.10, I stumbled into the following behavior which
intuitively does not follow the semantics of the RTMGRP_IPV4_IFADDR
group:
0) A userspace daemon process is running and listening to the broadcast
group.
1) Address is inserted to an interface (ip addr add ... at shell).
2) The daemon receives a NEWADDR message, just as is should, but the
daemon is unable to bind to the address *immediately* (actually in the
function that processes the netlink message). The result is "cannot
assign an address" from the bind call. However, if I do insert a single
nanosleep, even with an arbitrary low sleep value, before the bind
call, the bind then succeeds.
So, what is the semantics of NEWADDR? Should the address be bindable
right after receiving the message? Or is there a race-condition between
userspace and kernel that the inserted sleep helps to overcome by
letting the kernel to run again before the bind call?
TIA,
Teemu
--
next reply other threads:[~2005-06-06 18:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-06 18:59 Teemu Koponen [this message]
2005-06-06 19:54 ` New address announcements in RTMGRP_IPV4_IFADDR netlink group Thomas Graf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aa027950f2fc7f2ad640cac4a11fbe93@iki.fi \
--to=tkoponen@iki.fi \
--cc=netdev@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox