hyper-v: Hyper-V network broken for Trusty on Server 2008R2

Bug #1290151 reported by Abhishek Gupta
24
This bug affects 3 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
High
Andy Whitcroft

Bug Description

Due to a bug in the Hyper-V host verion 2008R2, we need to use a slightly smaller receive buffer size, otherwise the buffer will not be accepted by the legacy hosts. Without this fix, the network driver will not load while hosting Trusty on Server 2008R2. The following patch addresses the problem:

[PATCH net-next] hyperv: Change the receive buffer size for legacy hosts

Due to a bug in the Hyper-V host verion 2008R2, we need to use a slightly smaller
 receive buffer size, otherwise the buffer will not be accepted by the legacy hosts.

 Signed-off-by: Haiyang Zhang <email address hidden>
 ---
  drivers/net/hyperv/hyperv_net.h | 1 +
  drivers/net/hyperv/netvsc.c | 6 +++++-
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/drivers/net/hyperv/hyperv_net.h b/drivers/net/hyperv/hyperv_net.h
 index 39fc230..ea5f182 100644
 --- a/drivers/net/hyperv/hyperv_net.h
 +++ b/drivers/net/hyperv/hyperv_net.h
 @@ -516,6 +516,7 @@ struct nvsp_message {
  #define NETVSC_MTU 65536

  #define NETVSC_RECEIVE_BUFFER_SIZE (1024*1024*16) /* 16MB */
 +#define NETVSC_RECEIVE_BUFFER_SIZE_LEGACY (1024*1024*15) /* 15MB */

  #define NETVSC_RECEIVE_BUFFER_ID 0xcafe

 diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
 index 1a0280d..daddea2 100644
 --- a/drivers/net/hyperv/netvsc.c
 +++ b/drivers/net/hyperv/netvsc.c
 @@ -365,6 +365,11 @@ static int netvsc_connect_vsp(struct hv_device *device)
                  goto cleanup;

          /* Post the big receive buffer to NetVSP */
 + if (net_device->nvsp_version <= NVSP_PROTOCOL_VERSION_2)
 + net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE_LEGACY;
 + else
 + net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE;
 +
          ret = netvsc_init_recv_buf(device);

  cleanup:
 @@ -898,7 +903,6 @@ int netvsc_device_add(struct hv_device *device, void *additional_info)
          ndev = net_device->ndev;

          /* Initialize the NetVSC channel extension */
 - net_device->recv_buf_size = NETVSC_RECEIVE_BUFFER_SIZE;
          spin_lock_init(&net_device->recv_pkt_list_lock);

          INIT_LIST_HEAD(&net_device->recv_pkt_list);
 --
 1.7.4.1

Abhishek Gupta (abgupta)
affects: efibootmgr (Ubuntu) → linux (Ubuntu)
Revision history for this message
Brad Figg (brad-figg) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. From a terminal window please run:

apport-collect 1290151

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: trusty
Revision history for this message
Abhishek Gupta (abgupta) wrote :

Logs not required.

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Andy Whitcroft (apw)
tags: added: kernel-hyper-v
Changed in linux (Ubuntu):
importance: Undecided → High
tags: added: kernel-da-key
Revision history for this message
Andy Whitcroft (apw) wrote :

Applied to trusty. Will be in the next upload -- 3.13.0-18.*

Changed in linux (Ubuntu):
assignee: nobody → Andy Whitcroft (apw)
status: Confirmed → Fix Committed
Revision history for this message
CSRedRat (csredrat) wrote :

Released in daily build?

Revision history for this message
Chris Valean (chvale) wrote :

Daily build ISO dated 13-Mar-2014 06:46 with size 564M has still the old kernel version branch: 3.13.0-17

Revision history for this message
CSRedRat (csredrat) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package linux - 3.13.0-18.38

---------------
linux (3.13.0-18.38) trusty; urgency=low

  [ Tim Gardner ]

  * Release Tracking Bug
    - LP: #1293725
  * [Config] Add hv_balloon to d-i virtio-modules
    - LP: #1292216

  [ Andy Whitcroft ]

  * [Config] d-i -- add virtio_scsi to virtio-modules
    - LP: #1288607

  [ Colin Ian King ]

  * SAUCE: intel_pstate: inform user that thermald is worth considering

  [ dann frazier ]

  * [Config] arm64: KVM=y

  [ Gerd Hoffmann ]

  * SAUCE: vmbus: add missing breaks
    - LP: #1287398
  * SAUCE: vmbus: use resource for hyperv mmio region
    - LP: #1287398
  * SAUCE: hyperv-fb: add support for generation 2 virtual machines.
    - LP: #1287398
  * SAUCE: hyperv-fb: kick off efifb early
    - LP: #1287398

  [ Haiyang Zhang ]

  * SAUCE: hyperv: Change the receive buffer size for legacy hosts
    - LP: #1290151

  [ K. Y. Srinivasan ]

  * SAUCE: Drivers: hv: vmbus: Extract the mmio information from DSDT
    - LP: #1287398

  [ Paolo Pisati ]

  * SAUCE: leds-gpio: of: introduce MODULE_DEVICE_TABLE for module
    autoloading
  * [Config] amhf: LEDS_TRIGGER_HEARTBEAT=y

  [ Upstream Kernel Changes ]

  * Revert "xhci 1.0: Limit arbitrarily-aligned scatter gather."
    - LP: #1293361
  * Revert "USBNET: ax88179_178a: enable tso if usb host supports sg dma"
    - LP: #1293361
  * powerpc/tm: Fix crash when forking inside a transaction
  * AX88179_178A: Add VID:DID for Lenovo OneLinkDock Gigabit LAN
    - LP: #1291890
  * drm/vmwgfx: Fix a surface reference corner-case in legacy emulation
    mode
  * Input: wacom - scale up touch width and height values for Intuos Pro
  * Input: wacom - make sure touch_max is set for touch devices
  * Input: wacom - add support for three new Intuos devices
  * Input: wacom - add reporting of SW_MUTE_DEVICE events
  * Input: wacom - fix wacom->shared guards for dual input devices
  * Input: wacom - add support for DTU-1031
  * net: fix for a race condition in the inet frag code
    - CVE-2014-0100
  * net: sctp: fix sctp_sf_do_5_1D_ce to verify if we/peer is AUTH capable
    - CVE-2014-0101
  * KEYS: Make the keyring cycle detector ignore other keyrings of the same
    name
    - CVE-2014-0102
  * ipv6: don't set DST_NOCOUNT for remotely added routes
    - CVE-2014-2309
 -- Andy Whitcroft <email address hidden> Thu, 13 Mar 2014 10:06:05 +0000

Changed in linux (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
CSRedRat (csredrat) wrote :

Status: Trusty Development Kernel

The 3.13.0-18.38 Trusty kernel has been uploaded to the archive. This
is based on the v3.13.6 upstream stable kernel. I would also like to
remind everyone that Trusty Kernel Freeze is fast approaching on Thurs,
Apr 3

http://voices.canonical.com/kernelteam/2014/03/18/kernel-team-meeting-minutes-march-18-2014/

Revision history for this message
CSRedRat (csredrat) wrote :
Revision history for this message
CSRedRat (csredrat) wrote :

Test, network is work. On start screen ubiquity and later I do not see the connection icon - it should be? After install i see.

Revision history for this message
CSRedRat (csredrat) wrote :

In uniquity i'm change Russian language, but it doesn't install and after install i can't do this. Network message.

Revision history for this message
CSRedRat (csredrat) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.