* Join Multicast returns error ENODEV
@ 2002-05-31 15:59 Steven Vacca
0 siblings, 0 replies; 2+ messages in thread
From: Steven Vacca @ 2002-05-31 15:59 UTC (permalink / raw)
To: LinuxEmbeddedMailList (E-mail)
When I call setsockopt(IP_ADD_MEMBERSHIP), it fails.
I had multicast Join/Leave working very well with enet.c, but have
recently changed to using fec.c. All ethernet comm works very well.
But, there's a problem with multicast now.
My kernel is v2.2.13. uP is MPC860T
Here's the flow I see:
My App: setsockopt(...,IP_ADD_MEMBERSHIP,...);
Kernel:
ip_sockglue.c: ip_setsockopt()
ip_mc_join_group()
igmp.c: ip_mc_join_group()
if (!imr->imr_ifindex)
in_dev = ip_mc_find_dev(imr);
if (!in_dev)
{
iml = NULL;
err = -ENODEV;
goto done;
}
Would anyone have any ideas?
Thanks,
ShutEye Thinkin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 2+ messages in thread* RE: Join Multicast returns error ENODEV
@ 2002-05-31 19:16 Steven Vacca
0 siblings, 0 replies; 2+ messages in thread
From: Steven Vacca @ 2002-05-31 19:16 UTC (permalink / raw)
To: LinuxEmbeddedMailList (E-mail)
Before, when using enet.c, I used to call setsockopt()
as follows (this worked fine):
The 1st 4 bytes of tmp64 = the multicast addr 230.0.0.3
The next 4 bytes of tmp64 = 0.0.0.0
setsockopt(sd,IPPROTO_IP,IP_ADD_MEMBERSHIP,(const INT_8*) &tmp64,8);
.
.
.
if ((recLength = recvfrom(sd,(UINT_8*)
recBuff,sizeof(MSGPKT),MSG_DONTWAIT,(struct sockaddr*) 0,0)) > 0)
{
//Process recd pkt.
}
Now, since using fec.c, I found that I can successfully call
setsockopt() if I put the local IP addr in the next 4 bytes as follows:
The 1st 4 bytes of tmp64 = the multicast addr 230.0.0.3
The next 4 bytes of tmp64 = 192.168.11.15
setsockopt(sd,IPPROTO_IP,IP_ADD_MEMBERSHIP,(const INT_8*) &tmp64,8);
.
.
.
if ((recLength = recvfrom(sd,(UINT_8*)
recBuff,sizeof(MSGPKT),MSG_DONTWAIT,(struct sockaddr*) 0,0)) > 0)
{
//Process recd pkt.
}
But, I never rec any pkts.
Any ideas, anyone?
Thanks,
ShutEye Thinkin
-----Original Message-----
From: Steven Vacca [SMTP:svacca@valcom.com]
Sent: Friday, May 31, 2002 12:00 PM
To: LinuxEmbeddedMailList (E-mail)
Subject: Join Multicast returns error ENODEV
When I call setsockopt(IP_ADD_MEMBERSHIP), it fails.
I had multicast Join/Leave working very well with enet.c, but have
recently changed to using fec.c. All ethernet comm works very well.
But, there's a problem with multicast now.
My kernel is v2.2.13. uP is MPC860T
Here's the flow I see:
My App: setsockopt(...,IP_ADD_MEMBERSHIP,...);
Kernel:
ip_sockglue.c: ip_setsockopt()
ip_mc_join_group()
igmp.c: ip_mc_join_group()
if (!imr->imr_ifindex)
in_dev = ip_mc_find_dev(imr);
if (!in_dev)
{
iml = NULL;
err = -ENODEV;
goto done;
}
Would anyone have any ideas?
Thanks,
ShutEye Thinkin
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-05-31 19:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-05-31 15:59 Join Multicast returns error ENODEV Steven Vacca
-- strict thread matches above, loose matches on Subject: below --
2002-05-31 19:16 Steven Vacca
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).