You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2022/05/24 15:24:16 UTC

[GitHub] [incubator-nuttx] pkarashchenko commented on a diff in pull request #6320: use rmutex inside of all repeated implementation

pkarashchenko commented on code in PR #6320:
URL: https://github.com/apache/incubator-nuttx/pull/6320#discussion_r880655857


##########
drivers/1wire/1wire.c:
##########
@@ -221,37 +219,7 @@ static int onewire_pm_prepare(FAR struct pm_callback_s *cb, int domain,
 
 int onewire_sem_wait(FAR struct onewire_master_s *master)

Review Comment:
   ditto



##########
drivers/1wire/1wire.c:
##########
@@ -124,9 +122,9 @@ static inline void onewire_sem_init(FAR struct onewire_sem_s *sem)
  *
  ****************************************************************************/
 
-static inline void onewire_sem_destroy(FAR struct onewire_sem_s *sem)
+static inline void onewire_sem_destroy(FAR rmutex_t *lock)

Review Comment:
   maybe can replace `onewire_sem_destroy` with `nxrmutex_destroy` in all the places? Or do a define



##########
drivers/1wire/1wire.c:
##########
@@ -110,11 +110,9 @@ static inline uint32_t onewire_leuint32(uint32_t x)
  *
  ****************************************************************************/
 
-static inline void onewire_sem_init(FAR struct onewire_sem_s *sem)
+static inline void onewire_sem_init(FAR rmutex_t *lock)

Review Comment:
   maybe can replace `onewire_sem_init` with `nxrmutex_init` in all the places? Or do a define



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org