diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2021-10-12 03:10:22 +0300 |
---|---|---|
committer | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2021-10-18 16:27:29 +0300 |
commit | dde088379981a660d41b7aa6c1cb2dfa9457f765 (patch) | |
tree | b0c6b091f9f189df40bf1283088685ba9ba2a823 /lib/igt_aux.h | |
parent | 996f2707195ed10c19905bcd8ccdb860a5e9d9c5 (diff) |
lib: Introduce igt_memdup()
Provide a helper to do the malloc()+memcpy() in one swift blow.
Reviewed-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Diffstat (limited to 'lib/igt_aux.h')
-rw-r--r-- | lib/igt_aux.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/igt_aux.h b/lib/igt_aux.h index 30b175d70..a3c477abc 100644 --- a/lib/igt_aux.h +++ b/lib/igt_aux.h @@ -324,4 +324,6 @@ void igt_lsof(const char *dpath); uint64_t vfs_file_max(void); +void *igt_memdup(const void *ptr, size_t len); + #endif /* IGT_AUX_H */ |