Displaying 2 results from an estimated 2 matches for "ic_channel_initcnt".
2010 May 26
1
[PATCH 1/1] staging: hv: Fix race condition on IC channel initialization (modified)
.../hv/channel_mgmt.c b/drivers/staging/hv/channel_mgmt.c
index 3f53b4d..f99db1b 100644
--- a/drivers/staging/hv/channel_mgmt.c
+++ b/drivers/staging/hv/channel_mgmt.c
@@ -305,6 +305,7 @@ static void VmbusChannelProcessOffer(void *context)
int ret;
int cnt;
unsigned long flags;
+ static atomic_t ic_channel_initcnt = ATOMIC_INIT(0);
DPRINT_ENTER(VMBUS);
@@ -373,22 +374,24 @@ static void VmbusChannelProcessOffer(void *context)
* can cleanup properly
*/
newChannel->State = CHANNEL_OPEN_STATE;
- cnt = 0;
- while (cnt != MAX_MSG_TYPES) {
+ /* Open IC channels */
+ for (cnt = 0; cnt <...
2010 May 26
1
[PATCH 1/1] staging: hv: Fix race condition on IC channel initialization (modified)
.../hv/channel_mgmt.c b/drivers/staging/hv/channel_mgmt.c
index 3f53b4d..f99db1b 100644
--- a/drivers/staging/hv/channel_mgmt.c
+++ b/drivers/staging/hv/channel_mgmt.c
@@ -305,6 +305,7 @@ static void VmbusChannelProcessOffer(void *context)
int ret;
int cnt;
unsigned long flags;
+ static atomic_t ic_channel_initcnt = ATOMIC_INIT(0);
DPRINT_ENTER(VMBUS);
@@ -373,22 +374,24 @@ static void VmbusChannelProcessOffer(void *context)
* can cleanup properly
*/
newChannel->State = CHANNEL_OPEN_STATE;
- cnt = 0;
- while (cnt != MAX_MSG_TYPES) {
+ /* Open IC channels */
+ for (cnt = 0; cnt <...