summaryrefslogtreecommitdiffstats
path: root/src/drivers/net/phantom
diff options
context:
space:
mode:
authorMichael Brown2009-07-17 23:48:31 +0200
committerMichael Brown2009-07-18 00:02:48 +0200
commitd09290161e33574d8f0fa900ebe739214d17fe1a (patch)
tree9cb59387262344ed50fc755362154206017ab220 /src/drivers/net/phantom
parent[ata] Make ATA command issuing partially asynchronous (diff)
downloadipxe-d09290161e33574d8f0fa900ebe739214d17fe1a.tar.gz
ipxe-d09290161e33574d8f0fa900ebe739214d17fe1a.tar.xz
ipxe-d09290161e33574d8f0fa900ebe739214d17fe1a.zip
[netdevice] Make ll_broadcast per-netdevice rather than per-ll_protocol
IPoIB has a link-layer broadcast address that varies according to the partition key. We currently go through several contortions to pretend that the link-layer address is a fixed constant; by making the broadcast address a property of the network device rather than the link-layer protocol it will be possible to simplify IPoIB's broadcast handling.
Diffstat (limited to 'src/drivers/net/phantom')
-rw-r--r--src/drivers/net/phantom/phantom.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/drivers/net/phantom/phantom.c b/src/drivers/net/phantom/phantom.c
index ad17cdfe..85949c29 100644
--- a/src/drivers/net/phantom/phantom.c
+++ b/src/drivers/net/phantom/phantom.c
@@ -1156,7 +1156,7 @@ static int phantom_open ( struct net_device *netdev ) {
* firmware doesn't currently support this.
*/
if ( ( rc = phantom_add_macaddr ( phantom,
- netdev->ll_protocol->ll_broadcast ) ) != 0 )
+ netdev->ll_broadcast ) ) != 0 )
goto err_add_macaddr_broadcast;
if ( ( rc = phantom_add_macaddr ( phantom,
netdev->ll_addr ) ) != 0 )
@@ -1166,8 +1166,7 @@ static int phantom_open ( struct net_device *netdev ) {
phantom_del_macaddr ( phantom, netdev->ll_addr );
err_add_macaddr_unicast:
- phantom_del_macaddr ( phantom,
- netdev->ll_protocol->ll_broadcast );
+ phantom_del_macaddr ( phantom, netdev->ll_broadcast );
err_add_macaddr_broadcast:
phantom_destroy_tx_ctx ( phantom );
err_create_tx_ctx:
@@ -1191,8 +1190,7 @@ static void phantom_close ( struct net_device *netdev ) {
/* Shut down the port */
phantom_del_macaddr ( phantom, netdev->ll_addr );
- phantom_del_macaddr ( phantom,
- netdev->ll_protocol->ll_broadcast );
+ phantom_del_macaddr ( phantom, netdev->ll_broadcast );
phantom_destroy_tx_ctx ( phantom );
phantom_destroy_rx_ctx ( phantom );
free_dma ( phantom->desc, sizeof ( *(phantom->desc) ) );