Skip to content

Commit

Permalink
xen: netfront: assume all hw features are available until backend con…
Browse files Browse the repository at this point in the history
…nection setup

We need to assume that all features will be available when registering the
netdev otherwise they are ommitted from the initial set of
dev->wanted_features. When we connect to the backed we reduce the set as
necessary due to the call to netdev_update_features() in xennet_connect().

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Ian Campbell authored and David S. Miller committed Apr 4, 2011
1 parent 083dd8b commit fc3e594
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions drivers/net/xen-netfront.c
Original file line number Diff line number Diff line change
Expand Up @@ -1251,6 +1251,14 @@ static struct net_device * __devinit xennet_create_dev(struct xenbus_device *dev
NETIF_F_GSO_ROBUST;
netdev->hw_features = NETIF_F_IP_CSUM | NETIF_F_SG | NETIF_F_TSO;

/*
* Assume that all hw features are available for now. This set
* will be adjusted by the call to netdev_update_features() in
* xennet_connect() which is the earliest point where we can
* negotiate with the backend regarding supported features.
*/
netdev->features |= netdev->hw_features;

SET_ETHTOOL_OPS(netdev, &xennet_ethtool_ops);
SET_NETDEV_DEV(netdev, &dev->dev);

Expand Down

0 comments on commit fc3e594

Please sign in to comment.