diff options
author | Michael Brown | 2010-10-07 17:03:16 +0200 |
---|---|---|
committer | Michael Brown | 2010-10-07 20:15:04 +0200 |
commit | 88dd921e24af0893734d4e197d646cfc7732ed54 (patch) | |
tree | 8ecbe7ef1e5d84b2243894769a9ab1251d5c56de /src/usr/lotest.c | |
parent | [int13] Fix typo in debug message (diff) | |
download | ipxe-88dd921e24af0893734d4e197d646cfc7732ed54.tar.gz ipxe-88dd921e24af0893734d4e197d646cfc7732ed54.tar.xz ipxe-88dd921e24af0893734d4e197d646cfc7732ed54.zip |
[netdevice] Pass both link-layer addresses in net_tx() and net_rx()
FCoE requires the use of fabric-provided MAC addresses, which breaks
the assumption that the net device's MAC address is implicitly the
source address for net_tx() and the (unicast) destination address for
net_rx().
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/usr/lotest.c')
-rw-r--r-- | src/usr/lotest.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/usr/lotest.c b/src/usr/lotest.c index 8bbda51a..407f6844 100644 --- a/src/usr/lotest.c +++ b/src/usr/lotest.c @@ -45,11 +45,13 @@ FILE_LICENCE ( GPL2_OR_LATER ); * * @v iobuf I/O buffer * @v netdev Network device + * @v ll_dest Link-layer destination address * @v ll_source Link-layer source address * @ret rc Return status code */ static int lotest_rx ( struct io_buffer *iobuf, struct net_device *netdev __unused, + const void *ll_dest __unused, const void *ll_source __unused ) { free_iob ( iobuf ); return -ENOTSUP; @@ -138,8 +140,8 @@ int loopback_test ( struct net_device *sender, struct net_device *receiver, /* Transmit packet */ if ( ( rc = net_tx ( iob_disown ( iobuf ), sender, - &lotest_protocol, - receiver->ll_addr ) ) != 0 ) { + &lotest_protocol, receiver->ll_addr, + sender->ll_addr ) ) != 0 ) { printf ( "\nFailed to transmit packet: %s", strerror ( rc ) ); goto done; |