cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

rwsem.h (393B)


      1#ifndef _PERF_RWSEM_H
      2#define _PERF_RWSEM_H
      3
      4#include <pthread.h>
      5
      6struct rw_semaphore {
      7	pthread_rwlock_t lock;
      8};
      9
     10int init_rwsem(struct rw_semaphore *sem);
     11int exit_rwsem(struct rw_semaphore *sem);
     12
     13int down_read(struct rw_semaphore *sem);
     14int up_read(struct rw_semaphore *sem);
     15
     16int down_write(struct rw_semaphore *sem);
     17int up_write(struct rw_semaphore *sem);
     18
     19#endif /* _PERF_RWSEM_H */