diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2012-03-23 20:14:21 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2012-03-23 20:14:21 +0000 |
commit | f054af6f3ae096c6851d8eae0d1d2e98bc631351 (patch) | |
tree | cff1dab1c7daaf9d6ba4d5aceaf5512e386bccf1 /nuttx/include/semaphore.h | |
parent | 71e43504a2fb13b8b2a2e85f94815c2eadae20d4 (diff) | |
download | px4-nuttx-f054af6f3ae096c6851d8eae0d1d2e98bc631351.tar.gz px4-nuttx-f054af6f3ae096c6851d8eae0d1d2e98bc631351.tar.bz2 px4-nuttx-f054af6f3ae096c6851d8eae0d1d2e98bc631351.zip |
Updated comments; starting to implement priority protection but backed everything out but some changes to comments
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4510 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/include/semaphore.h')
-rw-r--r-- | nuttx/include/semaphore.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/nuttx/include/semaphore.h b/nuttx/include/semaphore.h index dd1754d69..85214b9c2 100644 --- a/nuttx/include/semaphore.h +++ b/nuttx/include/semaphore.h @@ -1,8 +1,8 @@ /**************************************************************************** * include/semaphore.h * - * Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt <spudmonkey@racsa.co.cr> + * Copyright (C) 2007-2009, 2012 Gregory Nutt. All rights reserved. + * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -33,8 +33,8 @@ * ****************************************************************************/ -#ifndef __SEMAPHORE_H -#define __SEMAPHORE_H +#ifndef __INCLUDE_SEMAPHORE_H +#define __INCLUDE_SEMAPHORE_H /**************************************************************************** * Included Files @@ -83,7 +83,7 @@ struct semholder_s struct sem_s { - int16_t semcount; /* >0 -> Num counts available */ + int16_t semcount; /* >0 -> Num counts available */ /* <0 -> Num tasks waiting for semaphore */ #ifdef CONFIG_PRIORITY_INHERITANCE struct semholder_s hlist; /* List of holders of semaphore counts */ @@ -91,6 +91,8 @@ struct sem_s }; typedef struct sem_s sem_t; +/* Initializers */ + #ifdef CONFIG_PRIORITY_INHERITANCE # define SEM_INITIALIZER(c) {(c), SEMHOLDER_INITIALIZER} #else @@ -127,4 +129,4 @@ EXTERN int sem_getvalue(FAR sem_t *sem, FAR int *sval); } #endif -#endif /* __SEMAPHORE_H */ +#endif /* __INCLUDE_SEMAPHORE_H */ |