From 16b439ec074f0817dcbc2c93051b1592029ec48b Mon Sep 17 00:00:00 2001 From: klueska Date: Fri, 15 Aug 2008 16:41:19 +0000 Subject: [PATCH] Update to set resId to 0xFF while granting --- tos/system/ArbiterP.nc | 1 + tos/system/SimpleArbiterP.nc | 1 + 2 files changed, 2 insertions(+) diff --git a/tos/system/ArbiterP.nc b/tos/system/ArbiterP.nc index f7b2fced..b07f975d 100644 --- a/tos/system/ArbiterP.nc +++ b/tos/system/ArbiterP.nc @@ -110,6 +110,7 @@ implementation { if(state == RES_BUSY && resId == id) { if(call Queue.isEmpty() == FALSE) { reqResId = call Queue.dequeue(); + resId = NO_RES; state = RES_GRANTING; post grantedTask(); call ResourceConfigure.unconfigure[id](); diff --git a/tos/system/SimpleArbiterP.nc b/tos/system/SimpleArbiterP.nc index ac4c839e..30f185f2 100644 --- a/tos/system/SimpleArbiterP.nc +++ b/tos/system/SimpleArbiterP.nc @@ -99,6 +99,7 @@ implementation { atomic { if(state == RES_BUSY && resId == id) { if(call Queue.isEmpty() == FALSE) { + resId = NO_RES; reqResId = call Queue.dequeue(); state = RES_GRANTING; post grantedTask(); -- 2.39.2