blob: d81eb81182bb129f526d11892d6002aba88dd1b9 [file] [log] [blame]
Roshan Pius091e1c12017-01-30 16:40:50 -08001/*
Gabriel Birene58e2632022-07-15 23:25:39 +00002 * Copyright (C) 2022 The Android Open Source Project
Roshan Pius091e1c12017-01-30 16:40:50 -08003 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
Gabriel Birene58e2632022-07-15 23:25:39 +000017#include "aidl_sync_util.h"
Roshan Pius091e1c12017-01-30 16:40:50 -080018
19namespace {
20std::recursive_mutex g_mutex;
21} // namespace
22
Gabriel Birene58e2632022-07-15 23:25:39 +000023namespace aidl {
Roshan Pius091e1c12017-01-30 16:40:50 -080024namespace android {
25namespace hardware {
26namespace wifi {
Gabriel Birene58e2632022-07-15 23:25:39 +000027namespace aidl_sync_util {
Roshan Pius091e1c12017-01-30 16:40:50 -080028
29std::unique_lock<std::recursive_mutex> acquireGlobalLock() {
Roshan Piusabcf78f2017-10-06 16:30:38 -070030 return std::unique_lock<std::recursive_mutex>{g_mutex};
Roshan Pius091e1c12017-01-30 16:40:50 -080031}
32
Gabriel Birene58e2632022-07-15 23:25:39 +000033} // namespace aidl_sync_util
Roshan Pius091e1c12017-01-30 16:40:50 -080034} // namespace wifi
35} // namespace hardware
36} // namespace android
Gabriel Birene58e2632022-07-15 23:25:39 +000037} // namespace aidl