From: Andrew Morton <akpm@osdl.org>
To: netdev@oss.sgi.com
Cc: Russell Leighton <russ@elegant-software.com>
Subject: Fw: F_SETSIG broken/changed in 2.6 for UDP and TCP sockets?
Date: Mon, 31 May 2004 15:18:43 -0700 [thread overview]
Message-ID: <20040531151843.7144dfce.akpm@osdl.org> (raw)
Begin forwarded message:
Date: Mon, 31 May 2004 14:45:08 -0400
From: Russell Leighton <russ@elegant-software.com>
To: linux-kernel@vger.kernel.org
Subject: F_SETSIG broken/changed in 2.6 for UDP and TCP sockets?
I have a program that works fine under stock rh9 (2.4.2-8) but has
issues getting signaled under FedoraCore2 (2.6.5-1.358)
using SETSIG to a Posix RT signal.
The program does the standard:
/* hook to process */
if ( fcntl(fdcallback->fd, F_SETOWN, mon->handler_q.thread->pid) == -1 ) {
aw_log(fdcallback->handler->logger, AW_ERROR_LOG_LEVEL,
"cannot set owner on fd (%s)",
strerror(errno));
}/* end if */
/* make async */
if ( fcntl(fdcallback->fd, F_SETFL, (O_NONBLOCK | O_ASYNC) ) == -1 ) {
aw_log(fdcallback->handler->logger, AW_ERROR_LOG_LEVEL,
"cannot set async on fd (%s)",
strerror(errno));
}/* end if */
/* hook to signal */
if ( fcntl(fdcallback->fd, F_SETSIG, AW_SIG_FD) == -1 ) {
aw_log(fdcallback->handler->logger, AW_ERROR_LOG_LEVEL,
"cannot set signal on fd (%s)",
strerror(errno));
}/* end if */
Under Fedora things work well for raw sockets (much lower latency than
in 2.4!) but are inconsistent with udp or tcp sockets.
In the udp case, I when I listen for multicast packets my app only
receives them when I am running a tcpdump (bizarre!).
In the tcp case, I don't get signaled if I do the F_SETSIG on more than
1 fd.
Any tips on tracking this down would be much appreciated.
Thx
Russ
next reply other threads:[~2004-05-31 22:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-31 22:18 Andrew Morton [this message]
2004-06-01 20:19 ` Fw: F_SETSIG broken/changed in 2.6 for UDP and TCP sockets? David Stevens
2004-06-01 22:48 ` Russell Leighton
2004-06-01 23:08 ` Russell Leighton
2004-06-04 2:24 ` Russell Leighton
2004-06-05 15:14 ` Russell Leighton
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=20040531151843.7144dfce.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=netdev@oss.sgi.com \
--cc=russ@elegant-software.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;
as well as URLs for NNTP newsgroup(s).