From 8c2caad47a958799476f705e42a1fad9ec636233 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Thu, 9 Nov 2017 16:10:47 -0500 Subject: Azure: don't generate network configuration for SRIOV devices Azure kernel now configures the SRIOV devices itself so cloud-init does not need to provide any SRIOV device configuration or udev naming rules. LP: #1721579 --- cloudinit/sources/DataSourceAzure.py | 25 ++----------------------- 1 file changed, 2 insertions(+), 23 deletions(-) (limited to 'cloudinit/sources/DataSourceAzure.py') diff --git a/cloudinit/sources/DataSourceAzure.py b/cloudinit/sources/DataSourceAzure.py index 80c2bd12..8c3492d9 100644 --- a/cloudinit/sources/DataSourceAzure.py +++ b/cloudinit/sources/DataSourceAzure.py @@ -465,10 +465,8 @@ class DataSourceAzure(sources.DataSource): 1. Probe the drivers of the net-devices present and inject them in the network configuration under params: driver: value - 2. If the driver value is 'mlx4_core', the control mode should be - set to manual. The device will be later used to build a bond, - for now we want to ensure the device gets named but does not - break any network configuration + 2. Generate a fallback network config that does not include any of + the blacklisted devices. """ blacklist = ['mlx4_core'] if not self._network_config: @@ -477,25 +475,6 @@ class DataSourceAzure(sources.DataSource): netconfig = net.generate_fallback_config( blacklist_drivers=blacklist, config_driver=True) - # if we have any blacklisted devices, update the network_config to - # include the device, mac, and driver values, but with no ip - # config; this ensures udev rules are generated but won't affect - # ip configuration - bl_found = 0 - for bl_dev in [dev for dev in net.get_devicelist() - if net.device_driver(dev) in blacklist]: - bl_found += 1 - cfg = { - 'type': 'physical', - 'name': 'vf%d' % bl_found, - 'mac_address': net.get_interface_mac(bl_dev), - 'params': { - 'driver': net.device_driver(bl_dev), - 'device_id': net.device_devid(bl_dev), - }, - } - netconfig['config'].append(cfg) - self._network_config = netconfig return self._network_config -- cgit v1.2.3