I am trying to modify the CPU scheduler so that each user receives a different priority. I have done this by modifying the order in which they go into the priority scheduling tree in sched_fair.c Here is a snippet of my code:

while(*link) {
parent = *link;
entry = rb_entry(parent, struct sched_entity, rn_node);
/*
* We don't care about collisions. nodes with
* the same key stay together.
*/

//My code
if(uid==500)
link = &parent->rb_right

else if (uid== 501)
link=&parent->rb_left

//Rest of code
else{
if (key < entity_key(cfs_rq, entry))
link = &parent->rb_left;

else {
link = &parent->rb_right;
leftmost = 0;
}
}
}

/*
* Maintain a cache of leftmost tree entries (it is frequently used);
*/


Unfortunately, when I compile it, the variable "uid" is not recognized. Could somebody please tell me if there is a keyword in place to make the compiler recognize the uid as a user?

Thanks!