diff options
author | Santiago Leon <santil@us.ibm.com> | 2005-10-26 10:47:23 -0600 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2005-10-28 16:07:31 -0400 |
commit | 82702d37a559cf94fe238cd3f8ef63cf7fa699a9 (patch) | |
tree | 695a5b7dca7e2c25aa148fc4bb968857f7bc72c6 /drivers/net | |
parent | 60296d9e4be1cd9e096f7804ce6e839e0cbd97cf (diff) | |
download | kernel_samsung_crespo-82702d37a559cf94fe238cd3f8ef63cf7fa699a9.zip kernel_samsung_crespo-82702d37a559cf94fe238cd3f8ef63cf7fa699a9.tar.gz kernel_samsung_crespo-82702d37a559cf94fe238cd3f8ef63cf7fa699a9.tar.bz2 |
[PATCH] ibmveth fix failed addbuf
This patch fixes a bug that happens when the hypervisor can't add a
buffer. The old code wrote IBM_VETH_INVALID_MAP into the free_map
array, so next time the index was used, a ibmveth_assert() caught it and
called BUG(). The patch writes the right value into the free_map array
so that the index can be reused.
Signed-off-by: Santiago Leon <santil@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ibmveth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ibmveth.c b/drivers/net/ibmveth.c index 987bcba..f5819527 100644 --- a/drivers/net/ibmveth.c +++ b/drivers/net/ibmveth.c @@ -237,7 +237,7 @@ static void ibmveth_replenish_buffer_pool(struct ibmveth_adapter *adapter, struc lpar_rc = h_add_logical_lan_buffer(adapter->vdev->unit_address, desc.desc); if(lpar_rc != H_Success) { - pool->free_map[free_index] = IBM_VETH_INVALID_MAP; + pool->free_map[free_index] = index; pool->skbuff[index] = NULL; pool->consumer_index--; dma_unmap_single(&adapter->vdev->dev, |