summaryrefslogtreecommitdiffstats
path: root/src/net/ipv4.c
diff options
context:
space:
mode:
authorNikhil Chandru Rao2006-08-01 22:27:26 +0200
committerNikhil Chandru Rao2006-08-01 22:27:26 +0200
commitc24546c70b420ce84e60cd245d570eb87e6d37d3 (patch)
treed9658ad7ba47002476144712add0dc0a5b4ec401 /src/net/ipv4.c
parentRemove unused functions. (diff)
downloadipxe-c24546c70b420ce84e60cd245d570eb87e6d37d3.tar.gz
ipxe-c24546c70b420ce84e60cd245d570eb87e6d37d3.tar.xz
ipxe-c24546c70b420ce84e60cd245d570eb87e6d37d3.zip
Minor changes to the network layer rx() functions
Diffstat (limited to 'src/net/ipv4.c')
-rw-r--r--src/net/ipv4.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/net/ipv4.c b/src/net/ipv4.c
index 4190ef73..147d2672 100644
--- a/src/net/ipv4.c
+++ b/src/net/ipv4.c
@@ -347,7 +347,8 @@ int ipv4_uip_tx ( struct pk_buff *pkb ) {
* This function expects a transport-layer segment and prepends the IP header
*/
int ipv4_tx ( struct pk_buff *pkb, struct tcpip_protocol *tcpip,
- struct in_addr *dest ) {
+ struct sockaddr* sock ) {
+ struct in_addr *dest = &sock->sin.sin_addr;
struct iphdr *iphdr = pkb_push ( pkb, sizeof ( *iphdr ) );
struct ipv4_miniroute *miniroute;
struct net_device *netdev = NULL;
@@ -613,6 +614,8 @@ NET_PROTOCOL ( ipv4_protocol );
/** IPv4 TCPIP net protocol */
struct tcpip_net_protocol ipv4_tcpip_protocol = {
.net_protocol = &ipv4_protocol,
+ .sa_family = AF_INET,
+ .tx = ipv4_tx,
.tx_csum = ipv4_tx_csum,
};