libs: display: lock ensure_profile()

Thread safety patch for ensure_profile() function

Fixes #133
9 jobs from ensure_profile_thread_safe in 33 minutes and 11 seconds (queued for 13 minutes and 14 seconds)
latest
Status Job ID Name Coverage
  Preparation
passed #108196
gst indent

00:00:35

passed #108195
manifest

00:00:41

 
  Build
passed #108197
build fedora x86_64

00:03:15

 
  Test
passed #108198
check fedora

00:04:51

 
  Full Builds
passed #108199
build android arm64 api28

00:04:11

passed #108201
build cerbero cross win32

00:10:34

passed #108202
build cerbero cross win64

00:07:57

passed #110110
build cerbero fedora x86_64

00:09:02

failed #108200
build cerbero fedora x86_64

00:06:09