diff options
| author | Arnd Bergmann <arnd@arndb.de> | 2013-05-06 23:38:00 +0200 | 
|---|---|---|
| committer | Arnd Bergmann <arnd@arndb.de> | 2013-05-06 23:38:00 +0200 | 
| commit | 4183bef2e093a2f0aab45f2d5fed82b0e02aeacf (patch) | |
| tree | e84c484db3746a0f3ead0fb7a2bb9e5a42b89e85 /drivers/net/hyperv/netvsc.c | |
| parent | 662478d060a39b8faf2b1fe2fbbb212556c2e052 (diff) | |
| parent | 775c4f66fd855e68a98fc5049003810fe98e2e20 (diff) | |
| download | olio-linux-3.10-4183bef2e093a2f0aab45f2d5fed82b0e02aeacf.tar.xz olio-linux-3.10-4183bef2e093a2f0aab45f2d5fed82b0e02aeacf.zip  | |
Merge branch 'late/dt' into next/dt2
This is support for the ARM Chromebook, originally scheduled
as a "late" pull request. Since it's already late now, we
can combine this into the existing next/dt2 branch.
* late/dt:
  ARM: exynos: dts: cros5250: add EC device
  ARM: dts: Add sbs-battery for exynos5250-snow
  ARM: dts: Add i2c-arbitrator bus for exynos5250-snow
  ARM: dts: Add chip-id controller node on Exynos4/5 SoC
  ARM: EXYNOS: Create virtual I/O mapping for Chip-ID controller using device tree
Diffstat (limited to 'drivers/net/hyperv/netvsc.c')
| -rw-r--r-- | drivers/net/hyperv/netvsc.c | 17 | 
1 files changed, 12 insertions, 5 deletions
diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c index 1cd77483da5..f5f0f09e4cc 100644 --- a/drivers/net/hyperv/netvsc.c +++ b/drivers/net/hyperv/netvsc.c @@ -470,8 +470,10 @@ static void netvsc_send_completion(struct hv_device *device,  			packet->trans_id;  		/* Notify the layer above us */ -		nvsc_packet->completion.send.send_completion( -			nvsc_packet->completion.send.send_completion_ctx); +		if (nvsc_packet) +			nvsc_packet->completion.send.send_completion( +				nvsc_packet->completion.send. +				send_completion_ctx);  		num_outstanding_sends =  			atomic_dec_return(&net_device->num_outstanding_sends); @@ -498,6 +500,7 @@ int netvsc_send(struct hv_device *device,  	int ret = 0;  	struct nvsp_message sendMessage;  	struct net_device *ndev; +	u64 req_id;  	net_device = get_outbound_net_device(device);  	if (!net_device) @@ -518,20 +521,24 @@ int netvsc_send(struct hv_device *device,  		0xFFFFFFFF;  	sendMessage.msg.v1_msg.send_rndis_pkt.send_buf_section_size = 0; +	if (packet->completion.send.send_completion) +		req_id = (u64)packet; +	else +		req_id = 0; +  	if (packet->page_buf_cnt) {  		ret = vmbus_sendpacket_pagebuffer(device->channel,  						  packet->page_buf,  						  packet->page_buf_cnt,  						  &sendMessage,  						  sizeof(struct nvsp_message), -						  (unsigned long)packet); +						  req_id);  	} else {  		ret = vmbus_sendpacket(device->channel, &sendMessage,  				sizeof(struct nvsp_message), -				(unsigned long)packet, +				req_id,  				VM_PKT_DATA_INBAND,  				VMBUS_DATA_PACKET_FLAG_COMPLETION_REQUESTED); -  	}  	if (ret == 0) {  |