1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-02-21 20:38:57 +00:00

external/revent: make inlines static

Add "static" qualifier to inline functions. This avoids linking errors
when compiling without -O flags. The "static" forces the inlining as
described here:

https://gcc.gnu.org/onlinedocs/gcc/Inline.html
This commit is contained in:
Sergei Trofimov 2017-12-04 10:14:29 +00:00 committed by marcbonnici
parent e33245ac72
commit d295b7d92d
3 changed files with 6 additions and 6 deletions

Binary file not shown.

Binary file not shown.

View File

@ -226,31 +226,31 @@ void destroy_replay_device(int fd)
die("Could not destroy replay device"); die("Could not destroy replay device");
} }
inline void set_evbit(int fd, int bit) static inline void set_evbit(int fd, int bit)
{ {
if(ioctl(fd, UI_SET_EVBIT, bit) < 0) if(ioctl(fd, UI_SET_EVBIT, bit) < 0)
die("Could not set EVBIT %i", bit); die("Could not set EVBIT %i", bit);
} }
inline void set_keybit(int fd, int bit) static inline void set_keybit(int fd, int bit)
{ {
if(ioctl(fd, UI_SET_KEYBIT, bit) < 0) if(ioctl(fd, UI_SET_KEYBIT, bit) < 0)
die("Could not set KEYBIT %i", bit); die("Could not set KEYBIT %i", bit);
} }
inline void set_absbit(int fd, int bit) static inline void set_absbit(int fd, int bit)
{ {
if(ioctl(fd, UI_SET_ABSBIT, bit) < 0) if(ioctl(fd, UI_SET_ABSBIT, bit) < 0)
die("Could not set ABSBIT %i", bit); die("Could not set ABSBIT %i", bit);
} }
inline void set_relbit(int fd, int bit) static inline void set_relbit(int fd, int bit)
{ {
if(ioctl(fd, UI_SET_RELBIT, bit) < 0) if(ioctl(fd, UI_SET_RELBIT, bit) < 0)
die("Could not set RELBIT %i", bit); die("Could not set RELBIT %i", bit);
} }
inline void block_sigterm(sigset_t *oldset) static inline void block_sigterm(sigset_t *oldset)
{ {
sigset_t sigset; sigset_t sigset;
sigemptyset(&sigset); sigemptyset(&sigset);
@ -941,7 +941,7 @@ int create_replay_device_or_die(const device_info_t *info)
return fd; return fd;
} }
inline void read_revent_recording_or_die(const char *filepath, revent_recording_t *recording) static inline void read_revent_recording_or_die(const char *filepath, revent_recording_t *recording)
{ {
int ret; int ret;
FILE *fin; FILE *fin;