This is the mail archive of the mailing list for the eCos project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug 1001508] New: Add freebsd CDL option to allow broadcast packetsto be sent to

Please do not reply to this email. Use the web interface provided at:

           Summary: Add freebsd CDL option to allow broadcast packets to
                    be sent to
           Product: eCos
           Version: CVS
          Platform: All
        OS/Version: Other
            Status: NEW
          Severity: enhancement
          Priority: low
         Component: TCP/IP
             Class: Advice Request

For reasons I've never understood, the BSD network stack has
historically coerced broadcast packets sent to so that
they go out the door destined for the interface's local network
broadcast address instead of the specified global broadcast address.
IOW, if your network interface is configured as and
you send a UDP broadcast packet to, it will actually be
sent with a destination IP of

People in the BSD world have been complaining about (and working
around) this for ages.

The Linux network stack takes the simpler and more useful approach of
sending the packet to the destination as specified -- if you send
broadcast packet to, it goes out to,
and if you want to send a broadcast packet to, then
you send it to

Several of our eCos based products must implement application protocols
that require UDP packets be sent to  To accomplish
this, I've been using a locally-modified bsd_tcpip stack with a CDL
option that allows you to choose either the (IMO broken) BSD behavior
or the Linux behavior.  It defaults to the BSD behavior for the sake
of backwards-compatible brokenness.

Anyhow, here's a patch that adds the CDL option


It defaults to 1 which results in the traditional BSD behavior.

Setting it to 0 allows you to send packets to by
specifying a destination address of

Configure bugmail:
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]