summaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown2009-01-21 04:40:39 +0100
committerMichael Brown2009-01-21 04:40:39 +0100
commitd230b53df2f44da477742094e5bbcc1b1520347c (patch)
tree4d0c8e9591509360aa7a7b1135ae39d6eab320ee /src/include
parent[ethernet] Fix eth_mc_hash() return status (diff)
downloadipxe-d230b53df2f44da477742094e5bbcc1b1520347c.tar.gz
ipxe-d230b53df2f44da477742094e5bbcc1b1520347c.tar.xz
ipxe-d230b53df2f44da477742094e5bbcc1b1520347c.zip
[tcpip] Allow for transmission to multicast IPv4 addresses
When sending to a multicast address, it may be necessary to specify the source address explicitly, since the multicast destination address does not provide enough information to deduce the source address via the miniroute table. Allow the source address specified via the data-xfer metadata to be passed down through the TCP/IP stack to the IPv4 layer, which can use it as a default source address.
Diffstat (limited to 'src/include')
-rw-r--r--src/include/gpxe/tcpip.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/include/gpxe/tcpip.h b/src/include/gpxe/tcpip.h
index 9bc3cc4a..da89530e 100644
--- a/src/include/gpxe/tcpip.h
+++ b/src/include/gpxe/tcpip.h
@@ -82,6 +82,7 @@ struct tcpip_net_protocol {
*
* @v iobuf I/O buffer
* @v tcpip_protocol Transport-layer protocol
+ * @v st_src Source address, or NULL to use default
* @v st_dest Destination address
* @v netdev Network device (or NULL to route automatically)
* @v trans_csum Transport-layer checksum to complete, or NULL
@@ -91,6 +92,7 @@ struct tcpip_net_protocol {
*/
int ( * tx ) ( struct io_buffer *iobuf,
struct tcpip_protocol *tcpip_protocol,
+ struct sockaddr_tcpip *st_src,
struct sockaddr_tcpip *st_dest,
struct net_device *netdev,
uint16_t *trans_csum );
@@ -107,7 +109,8 @@ struct tcpip_net_protocol {
extern int tcpip_rx ( struct io_buffer *iobuf, uint8_t tcpip_proto,
struct sockaddr_tcpip *st_src,
struct sockaddr_tcpip *st_dest, uint16_t pshdr_csum );
-extern int tcpip_tx ( struct io_buffer *iobuf, struct tcpip_protocol *tcpip,
+extern int tcpip_tx ( struct io_buffer *iobuf, struct tcpip_protocol *tcpip,
+ struct sockaddr_tcpip *st_src,
struct sockaddr_tcpip *st_dest,
struct net_device *netdev,
uint16_t *trans_csum );