diff options
author | 2016-12-28 09:28:53 -0800 | |
---|---|---|
committer | 2016-12-28 09:29:20 -0800 | |
commit | c03d283e8b3f830d76dd94822b2a13872c05c730 (patch) | |
tree | 514c1b1518ea1b3b863856857ad1cd79b88d00f1 | |
parent | f38ec8abdf0a77b3e0e58dbc470a52d2f25a5eb4 (diff) | |
parent | 525a5f2da844d1acc9e405fc4935d8a1cb2ece67 (diff) |
resolve merge conflicts of 525a5f2 to master
Test: build
Change-Id: Id1c6d3d9dd158fb086b0d8ab74f7838ef0a51af1
55 files changed, 197 insertions, 183 deletions
diff --git a/cmds/dumpstate/utils.cpp b/cmds/dumpstate/utils.cpp index ee887058ba..0f50fc9ed2 100644 --- a/cmds/dumpstate/utils.cpp +++ b/cmds/dumpstate/utils.cpp @@ -23,9 +23,25 @@ #include <libgen.h> #include <math.h> #include <poll.h> +#include <signal.h> +#include <stdarg.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include <sys/capability.h> #include <sys/inotify.h> #include <sys/klog.h> +#include <sys/prctl.h> +#include <sys/stat.h> +#include <sys/time.h> +#include <sys/wait.h> +#include <time.h> +#include <unistd.h> +#include <string> +#include <vector> + +#include <android/log.h> #include <android-base/file.h> #include <android-base/properties.h> #include <android-base/stringprintf.h> diff --git a/cmds/installd/dexopt.cpp b/cmds/installd/dexopt.cpp index 37f329000d..a2bce41eca 100644 --- a/cmds/installd/dexopt.cpp +++ b/cmds/installd/dexopt.cpp @@ -13,6 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +#define LOG_TAG "installed" #include <fcntl.h> #include <stdlib.h> @@ -26,11 +27,11 @@ #include <sys/wait.h> #include <unistd.h> +#include <android/log.h> // TODO: Move everything to base/logging. #include <android-base/logging.h> #include <android-base/stringprintf.h> #include <android-base/strings.h> #include <android-base/unique_fd.h> -#include <cutils/log.h> // TODO: Move everything to base/logging. #include <cutils/properties.h> #include <cutils/sched_policy.h> #include <private/android_filesystem_config.h> diff --git a/cmds/installd/globals.cpp b/cmds/installd/globals.cpp index 93e1ce54af..c0ea79cd0b 100644 --- a/cmds/installd/globals.cpp +++ b/cmds/installd/globals.cpp @@ -14,19 +14,17 @@ ** limitations under the License. */ +#define LOG_TAG "installd" + #include <stdlib.h> #include <string.h> -#include <cutils/log.h> // TODO: Move everything to base::logging. +#include <android/log.h> // TODO: Move everything to base::logging. #include <globals.h> #include <installd_constants.h> #include <utils.h> -#ifndef LOG_TAG -#define LOG_TAG "installd" -#endif - namespace android { namespace installd { diff --git a/cmds/installd/installd.cpp b/cmds/installd/installd.cpp index 6c49aa3d48..35936a23af 100644 --- a/cmds/installd/installd.cpp +++ b/cmds/installd/installd.cpp @@ -13,6 +13,7 @@ ** See the License for the specific language governing permissions and ** limitations under the License. */ +#define LOG_TAG "installd" #include <fcntl.h> #include <selinux/android.h> @@ -24,8 +25,8 @@ #include <android-base/logging.h> #include <cutils/fs.h> -#include <cutils/log.h> // TODO: Move everything to base::logging. #include <cutils/properties.h> +#include <log/log.h> // TODO: Move everything to base::logging. #include <private/android_filesystem_config.h> #include "InstalldNativeService.h" @@ -34,10 +35,6 @@ #include "installd_deps.h" // Need to fill in requirements of commands. #include "utils.h" -#ifndef LOG_TAG -#define LOG_TAG "installd" -#endif - namespace android { namespace installd { @@ -63,12 +60,12 @@ bool calculate_oat_file_path(char path[PKG_PATH_MAX], file_name_start = strrchr(apk_path, '/'); if (file_name_start == NULL) { - ALOGE("apk_path '%s' has no '/'s in it\n", apk_path); + SLOGE("apk_path '%s' has no '/'s in it\n", apk_path); return false; } file_name_end = strrchr(apk_path, '.'); if (file_name_end < file_name_start) { - ALOGE("apk_path '%s' has no extension\n", apk_path); + SLOGE("apk_path '%s' has no extension\n", apk_path); return false; } @@ -94,14 +91,14 @@ bool calculate_odex_file_path(char path[PKG_PATH_MAX], const char *instruction_set) { if (strlen(apk_path) + strlen("oat/") + strlen(instruction_set) + strlen("/") + strlen("odex") + 1 > PKG_PATH_MAX) { - ALOGE("apk_path '%s' may be too long to form odex file path.\n", apk_path); + SLOGE("apk_path '%s' may be too long to form odex file path.\n", apk_path); return false; } strcpy(path, apk_path); char *end = strrchr(path, '/'); if (end == NULL) { - ALOGE("apk_path '%s' has no '/'s in it?!\n", apk_path); + SLOGE("apk_path '%s' has no '/'s in it?!\n", apk_path); return false; } const char *apk_end = apk_path + (end - path); // strrchr(apk_path, '/'); @@ -111,7 +108,7 @@ bool calculate_odex_file_path(char path[PKG_PATH_MAX], strcat(path, apk_end); // path = /system/framework/oat/<isa>/whatever.jar\0 end = strrchr(path, '.'); if (end == NULL) { - ALOGE("apk_path '%s' has no extension.\n", apk_path); + SLOGE("apk_path '%s' has no extension.\n", apk_path); return false; } strcpy(end + 1, "odex"); @@ -170,12 +167,12 @@ bool create_cache_path(char path[PKG_PATH_MAX], static bool initialize_globals() { const char* data_path = getenv("ANDROID_DATA"); if (data_path == nullptr) { - ALOGE("Could not find ANDROID_DATA"); + SLOGE("Could not find ANDROID_DATA"); return false; } const char* root_path = getenv("ANDROID_ROOT"); if (root_path == nullptr) { - ALOGE("Could not find ANDROID_ROOT"); + SLOGE("Could not find ANDROID_ROOT"); return false; } @@ -201,12 +198,12 @@ static int initialize_directories() { } if (ensure_config_user_dirs(0) == -1) { - ALOGE("Failed to setup misc for user 0"); + SLOGE("Failed to setup misc for user 0"); goto fail; } if (version == 2) { - ALOGD("Upgrading to /data/misc/user directories"); + SLOGD("Upgrading to /data/misc/user directories"); char misc_dir[PATH_MAX]; snprintf(misc_dir, PATH_MAX, "%smisc", android_data_dir.path); @@ -247,12 +244,12 @@ static int initialize_directories() { gid_t gid = uid; if (access(keychain_added_dir, F_OK) == 0) { if (copy_dir_files(keychain_added_dir, misc_added_dir, uid, gid) != 0) { - ALOGE("Some files failed to copy"); + SLOGE("Some files failed to copy"); } } if (access(keychain_removed_dir, F_OK) == 0) { if (copy_dir_files(keychain_removed_dir, misc_removed_dir, uid, gid) != 0) { - ALOGE("Some files failed to copy"); + SLOGE("Some files failed to copy"); } } } @@ -272,7 +269,7 @@ static int initialize_directories() { // Persist layout version if changed if (version != oldVersion) { if (fs_write_atomic_int(version_path, version) == -1) { - ALOGE("Failed to save version to %s: %s", version_path, strerror(errno)); + SLOGE("Failed to save version to %s: %s", version_path, strerror(errno)); goto fail; } } @@ -312,29 +309,29 @@ static int installd_main(const int argc ATTRIBUTE_UNUSED, char *argv[]) { setenv("ANDROID_LOG_TAGS", "*:v", 1); android::base::InitLogging(argv); - LOG(INFO) << "installd firing up"; + SLOGI("installd firing up"); union selinux_callback cb; cb.func_log = log_callback; selinux_set_callback(SELINUX_CB_LOG, cb); if (!initialize_globals()) { - ALOGE("Could not initialize globals; exiting.\n"); + SLOGE("Could not initialize globals; exiting.\n"); exit(1); } if (initialize_directories() < 0) { - ALOGE("Could not create directories; exiting.\n"); + SLOGE("Could not create directories; exiting.\n"); exit(1); } if (selinux_enabled && selinux_status_open(true) < 0) { - ALOGE("Could not open selinux status; exiting.\n"); + SLOGE("Could not open selinux status; exiting.\n"); exit(1); } if ((ret = InstalldNativeService::start()) != android::OK) { - ALOGE("Unable to start InstalldNativeService: %d", ret); + SLOGE("Unable to start InstalldNativeService: %d", ret); exit(1); } diff --git a/cmds/installd/otapreopt.cpp b/cmds/installd/otapreopt.cpp index d53018ff55..7aba5d049d 100644 --- a/cmds/installd/otapreopt.cpp +++ b/cmds/installd/otapreopt.cpp @@ -27,12 +27,12 @@ #include <sys/stat.h> #include <sys/wait.h> +#include <android/log.h> #include <android-base/logging.h> #include <android-base/macros.h> #include <android-base/stringprintf.h> #include <android-base/strings.h> #include <cutils/fs.h> -#include <cutils/log.h> #include <cutils/properties.h> #include <private/android_filesystem_config.h> diff --git a/cmds/installd/utils.cpp b/cmds/installd/utils.cpp index 4bd98e4ae5..37e303da97 100644 --- a/cmds/installd/utils.cpp +++ b/cmds/installd/utils.cpp @@ -29,10 +29,10 @@ #include <sys/statfs.h> #endif +#include <android/log.h> #include <android-base/logging.h> #include <android-base/stringprintf.h> #include <cutils/fs.h> -#include <cutils/log.h> #include <private/android_filesystem_config.h> #include "globals.h" // extern variables. diff --git a/cmds/ip-up-vpn/ip-up-vpn.c b/cmds/ip-up-vpn/ip-up-vpn.c index 75b907c2b2..5c566fcb57 100644 --- a/cmds/ip-up-vpn/ip-up-vpn.c +++ b/cmds/ip-up-vpn/ip-up-vpn.c @@ -14,22 +14,22 @@ * limitations under the License. */ -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <errno.h> +#define LOG_TAG "ip-up-vpn" #include <arpa/inet.h> +#include <errno.h> +#include <linux/if.h> +#include <linux/route.h> #include <netinet/in.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include <sys/ioctl.h> +#include <sys/socket.h> #include <sys/stat.h> #include <sys/types.h> -#include <sys/socket.h> -#include <sys/ioctl.h> -#include <linux/if.h> -#include <linux/route.h> -#define LOG_TAG "ip-up-vpn" -#include <cutils/log.h> +#include <android/log.h> #define DIR "/data/misc/vpn/" diff --git a/cmds/servicemanager/binder.c b/cmds/servicemanager/binder.c index 27c461a27c..cb557aa62e 100644 --- a/cmds/servicemanager/binder.c +++ b/cmds/servicemanager/binder.c @@ -1,14 +1,18 @@ /* Copyright 2008 The Android Open Source Project */ +#define LOG_TAG "Binder" + +#include <errno.h> +#include <fcntl.h> #include <inttypes.h> #include <stdio.h> #include <stdlib.h> #include <string.h> -#include <errno.h> -#include <unistd.h> -#include <fcntl.h> #include <sys/mman.h> +#include <unistd.h> + +#include <android/log.h> #include "binder.h" @@ -16,9 +20,6 @@ #define TRACE 0 -#define LOG_TAG "Binder" -#include <cutils/log.h> - void bio_init_from_txn(struct binder_io *io, struct binder_transaction_data *txn); #if TRACE diff --git a/cmds/servicemanager/service_manager.c b/cmds/servicemanager/service_manager.c index ea4155848b..8f4e01be10 100644 --- a/cmds/servicemanager/service_manager.c +++ b/cmds/servicemanager/service_manager.c @@ -22,7 +22,7 @@ #define ALOGE(x...) fprintf(stderr, "svcmgr: " x) #else #define LOG_TAG "ServiceManager" -#include <cutils/log.h> +#include <android/log.h> #endif struct audit_data { diff --git a/include/gui/BitTube.h b/include/gui/BitTube.h index 3ecac52ad7..9d65fad228 100644 --- a/include/gui/BitTube.h +++ b/include/gui/BitTube.h @@ -20,10 +20,9 @@ #include <stdint.h> #include <sys/types.h> +#include <android/log.h> #include <utils/Errors.h> #include <utils/RefBase.h> -#include <cutils/log.h> - namespace android { // ---------------------------------------------------------------------------- diff --git a/libs/binder/IMemory.cpp b/libs/binder/IMemory.cpp index 4a39741569..45633f3e07 100644 --- a/libs/binder/IMemory.cpp +++ b/libs/binder/IMemory.cpp @@ -17,21 +17,20 @@ #define LOG_TAG "IMemory" #include <atomic> +#include <fcntl.h> #include <stdint.h> #include <stdio.h> #include <stdlib.h> -#include <fcntl.h> -#include <unistd.h> - #include <sys/types.h> #include <sys/mman.h> +#include <unistd.h> +#include <android/log.h> #include <binder/IMemory.h> -#include <cutils/log.h> -#include <utils/KeyedVector.h> -#include <utils/threads.h> #include <binder/Parcel.h> #include <utils/CallStack.h> +#include <utils/KeyedVector.h> +#include <utils/threads.h> #define VERBOSE 0 diff --git a/libs/binder/MemoryHeapBase.cpp b/libs/binder/MemoryHeapBase.cpp index b4b1062b66..415c252182 100644 --- a/libs/binder/MemoryHeapBase.cpp +++ b/libs/binder/MemoryHeapBase.cpp @@ -16,16 +16,16 @@ #define LOG_TAG "MemoryHeapBase" -#include <stdlib.h> -#include <stdint.h> -#include <unistd.h> -#include <fcntl.h> #include <errno.h> -#include <sys/types.h> -#include <sys/stat.h> +#include <fcntl.h> +#include <stdint.h> +#include <stdlib.h> #include <sys/ioctl.h> +#include <sys/stat.h> +#include <sys/types.h> +#include <unistd.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/ashmem.h> #include <cutils/atomic.h> diff --git a/libs/binder/PersistableBundle.cpp b/libs/binder/PersistableBundle.cpp index e7078baa82..70d425e8d3 100644 --- a/libs/binder/PersistableBundle.cpp +++ b/libs/binder/PersistableBundle.cpp @@ -20,9 +20,9 @@ #include <limits> +#include <android/log.h> #include <binder/IBinder.h> #include <binder/Parcel.h> -#include <log/log.h> #include <utils/Errors.h> using android::BAD_TYPE; diff --git a/libs/gui/GraphicBufferAlloc.cpp b/libs/gui/GraphicBufferAlloc.cpp index 9d045dd44e..7d91d33746 100644 --- a/libs/gui/GraphicBufferAlloc.cpp +++ b/libs/gui/GraphicBufferAlloc.cpp @@ -15,7 +15,7 @@ ** limitations under the License. */ -#include <cutils/log.h> +#include <android/log.h> #include <ui/GraphicBuffer.h> diff --git a/libs/gui/Sensor.cpp b/libs/gui/Sensor.cpp index 053d153296..dbf03a5232 100644 --- a/libs/gui/Sensor.cpp +++ b/libs/gui/Sensor.cpp @@ -14,21 +14,20 @@ * limitations under the License. */ +#include <inttypes.h> +#include <stdint.h> +#include <sys/limits.h> +#include <sys/types.h> +#include <android/log.h> #include <binder/AppOpsManager.h> #include <binder/IServiceManager.h> #include <gui/Sensor.h> #include <hardware/sensors.h> -#include <log/log.h> #include <utils/Errors.h> #include <utils/String8.h> #include <utils/Flattenable.h> -#include <inttypes.h> -#include <stdint.h> -#include <sys/types.h> -#include <sys/limits.h> - // ---------------------------------------------------------------------------- namespace android { // ---------------------------------------------------------------------------- diff --git a/libs/input/InputTransport.cpp b/libs/input/InputTransport.cpp index 2dff4e0918..136dd7fcdf 100644 --- a/libs/input/InputTransport.cpp +++ b/libs/input/InputTransport.cpp @@ -19,20 +19,18 @@ // Log debug messages about touch event resampling #define DEBUG_RESAMPLING 0 - #include <errno.h> #include <fcntl.h> #include <inttypes.h> #include <math.h> -#include <sys/types.h> #include <sys/socket.h> +#include <sys/types.h> #include <unistd.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <input/InputTransport.h> - namespace android { // Socket buffer size. The default is typically about 128KB, which is much larger than diff --git a/libs/ui/GraphicBufferAllocator.cpp b/libs/ui/GraphicBufferAllocator.cpp index f30ec84a25..6f57d37043 100644 --- a/libs/ui/GraphicBufferAllocator.cpp +++ b/libs/ui/GraphicBufferAllocator.cpp @@ -18,7 +18,7 @@ #define LOG_TAG "GraphicBufferAllocator" #define ATRACE_TAG ATRACE_TAG_GRAPHICS -#include <cutils/log.h> +#include <android/log.h> #include <utils/Singleton.h> #include <utils/String8.h> diff --git a/opengl/libagl/egl.cpp b/opengl/libagl/egl.cpp index c1efd1cae6..bb20409819 100644 --- a/opengl/libagl/egl.cpp +++ b/opengl/libagl/egl.cpp @@ -18,16 +18,16 @@ #include <assert.h> #include <atomic> #include <errno.h> -#include <stdlib.h> +#include <fcntl.h> #include <stdio.h> +#include <stdlib.h> #include <string.h> -#include <unistd.h> -#include <fcntl.h> #include <sys/ioctl.h> #include <sys/types.h> #include <sys/mman.h> +#include <unistd.h> -#include <cutils/log.h> +#include <android/log.h> #include <utils/threads.h> #include <ui/ANativeObjectBase.h> diff --git a/opengl/libs/EGL/Loader.cpp b/opengl/libs/EGL/Loader.cpp index 459fd50ac2..27d81fed2c 100644 --- a/opengl/libs/EGL/Loader.cpp +++ b/opengl/libs/EGL/Loader.cpp @@ -15,15 +15,15 @@ */ #include <ctype.h> -#include <stdlib.h> -#include <stdio.h> -#include <string.h> -#include <errno.h> +#include <dirent.h> #include <dlfcn.h> +#include <errno.h> #include <limits.h> -#include <dirent.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <EGL/egl.h> diff --git a/opengl/libs/EGL/egl.cpp b/opengl/libs/EGL/egl.cpp index 18cf26174e..4245a92a3c 100644 --- a/opengl/libs/EGL/egl.cpp +++ b/opengl/libs/EGL/egl.cpp @@ -24,7 +24,7 @@ #include <EGL/egl.h> #include <EGL/eglext.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/atomic.h> #include <cutils/properties.h> diff --git a/opengl/libs/EGL/eglApi.cpp b/opengl/libs/EGL/eglApi.cpp index 6328c9c1f3..3af7e935e3 100644 --- a/opengl/libs/EGL/eglApi.cpp +++ b/opengl/libs/EGL/eglApi.cpp @@ -16,8 +16,8 @@ #define ATRACE_TAG ATRACE_TAG_GRAPHICS -#include <dlfcn.h> #include <ctype.h> +#include <dlfcn.h> #include <stdlib.h> #include <string.h> @@ -27,11 +27,11 @@ #include <EGL/egl.h> #include <EGL/eglext.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/atomic.h> #include <cutils/compiler.h> -#include <cutils/properties.h> #include <cutils/memory.h> +#include <cutils/properties.h> #include <gui/ISurfaceComposer.h> diff --git a/opengl/libs/EGL/egl_tls.cpp b/opengl/libs/EGL/egl_tls.cpp index f3739aafad..125700405f 100644 --- a/opengl/libs/EGL/egl_tls.cpp +++ b/opengl/libs/EGL/egl_tls.cpp @@ -14,10 +14,10 @@ ** limitations under the License. */ -#include <stdlib.h> #include <pthread.h> +#include <stdlib.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <utils/CallStack.h> @@ -26,7 +26,6 @@ #include "egl_tls.h" - namespace android { pthread_key_t egl_tls_t::sKey = TLS_KEY_NOT_INITIALIZED; diff --git a/opengl/libs/EGL/getProcAddress.cpp b/opengl/libs/EGL/getProcAddress.cpp index 336c2642ad..450c4021d1 100644 --- a/opengl/libs/EGL/getProcAddress.cpp +++ b/opengl/libs/EGL/getProcAddress.cpp @@ -15,10 +15,10 @@ */ #include <ctype.h> -#include <stdlib.h> #include <errno.h> +#include <stdlib.h> -#include <cutils/log.h> +#include <android/log.h> #include "egldefs.h" diff --git a/opengl/libs/GLES2/gl2.cpp b/opengl/libs/GLES2/gl2.cpp index 6dd87c28e4..c2060419e8 100644 --- a/opengl/libs/GLES2/gl2.cpp +++ b/opengl/libs/GLES2/gl2.cpp @@ -15,12 +15,11 @@ */ #include <ctype.h> -#include <string.h> #include <errno.h> - +#include <string.h> #include <sys/ioctl.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include "../hooks.h" diff --git a/opengl/libs/GLES_CM/gl.cpp b/opengl/libs/GLES_CM/gl.cpp index 8bde4e5f04..e698fcd64c 100644 --- a/opengl/libs/GLES_CM/gl.cpp +++ b/opengl/libs/GLES_CM/gl.cpp @@ -1,31 +1,30 @@ -/* +/* ** Copyright 2007, The Android Open Source Project ** - ** Licensed under the Apache License, Version 2.0 (the "License"); - ** you may not use this file except in compliance with the License. - ** You may obtain a copy of the License at + ** Licensed under the Apache License, Version 2.0 (the "License"); + ** you may not use this file except in compliance with the License. + ** You may obtain a copy of the License at ** - ** http://www.apache.org/licenses/LICENSE-2.0 + ** http://www.apache.org/licenses/LICENSE-2.0 ** - ** Unless required by applicable law or agreed to in writing, software - ** distributed under the License is distributed on an "AS IS" BASIS, - ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ** See the License for the specific language governing permissions and + ** Unless required by applicable law or agreed to in writing, software + ** distributed under the License is distributed on an "AS IS" BASIS, + ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ** See the License for the specific language governing permissions and ** limitations under the License. */ #include <ctype.h> -#include <string.h> #include <errno.h> - +#include <string.h> #include <sys/ioctl.h> +#include <android/log.h> +#include <cutils/properties.h> + #include <GLES/gl.h> #include <GLES/glext.h> -#include <cutils/log.h> -#include <cutils/properties.h> - #include "../hooks.h" #include "../egl_impl.h" diff --git a/services/inputflinger/InputApplication.cpp b/services/inputflinger/InputApplication.cpp index a99e637fdf..9e90631840 100644 --- a/services/inputflinger/InputApplication.cpp +++ b/services/inputflinger/InputApplication.cpp @@ -18,7 +18,7 @@ #include "InputApplication.h" -#include <cutils/log.h> +#include <android/log.h> namespace android { diff --git a/services/inputflinger/InputDispatcher.cpp b/services/inputflinger/InputDispatcher.cpp index 3f69d49f0b..793d59a0c0 100644 --- a/services/inputflinger/InputDispatcher.cpp +++ b/services/inputflinger/InputDispatcher.cpp @@ -45,16 +45,16 @@ #include "InputDispatcher.h" -#include <utils/Trace.h> -#include <cutils/log.h> -#include <powermanager/PowerManager.h> -#include <ui/Region.h> - -#include <stddef.h> -#include <unistd.h> #include <errno.h> #include <limits.h> +#include <stddef.h> #include <time.h> +#include <unistd.h> + +#include <android/log.h> +#include <utils/Trace.h> +#include <powermanager/PowerManager.h> +#include <ui/Region.h> #define INDENT " " #define INDENT2 " " diff --git a/services/inputflinger/InputListener.cpp b/services/inputflinger/InputListener.cpp index dded47dc88..2ee222b2bd 100644 --- a/services/inputflinger/InputListener.cpp +++ b/services/inputflinger/InputListener.cpp @@ -20,7 +20,7 @@ #include "InputListener.h" -#include <cutils/log.h> +#include <android/log.h> namespace android { diff --git a/services/inputflinger/InputManager.cpp b/services/inputflinger/InputManager.cpp index 6a6547bdf0..6fe4d36af4 100644 --- a/services/inputflinger/InputManager.cpp +++ b/services/inputflinger/InputManager.cpp @@ -20,7 +20,7 @@ #include "InputManager.h" -#include <cutils/log.h> +#include <android/log.h> namespace android { diff --git a/services/inputflinger/InputReader.cpp b/services/inputflinger/InputReader.cpp index 4dec34bc93..fbc7b12b92 100644 --- a/services/inputflinger/InputReader.cpp +++ b/services/inputflinger/InputReader.cpp @@ -44,17 +44,18 @@ #include "InputReader.h" -#include <cutils/log.h> -#include <input/Keyboard.h> -#include <input/VirtualKeyMap.h> - +#include <errno.h> #include <inttypes.h> +#include <limits.h> +#include <math.h> #include <stddef.h> #include <stdlib.h> #include <unistd.h> -#include <errno.h> -#include <limits.h> -#include <math.h> + +#include <android/log.h> + +#include <input/Keyboard.h> +#include <input/VirtualKeyMap.h> #define INDENT " " #define INDENT2 " " diff --git a/services/inputflinger/InputWindow.cpp b/services/inputflinger/InputWindow.cpp index d7b514b0b6..297b0680e8 100644 --- a/services/inputflinger/InputWindow.cpp +++ b/services/inputflinger/InputWindow.cpp @@ -19,7 +19,7 @@ #include "InputWindow.h" -#include <cutils/log.h> +#include <android/log.h> #include <ui/Rect.h> #include <ui/Region.h> diff --git a/services/inputflinger/host/InputFlinger.cpp b/services/inputflinger/host/InputFlinger.cpp index 859c3b8332..8edea3f7f6 100644 --- a/services/inputflinger/host/InputFlinger.cpp +++ b/services/inputflinger/host/InputFlinger.cpp @@ -16,21 +16,19 @@ #define LOG_TAG "InputFlinger" - #include <stdint.h> -#include <unistd.h> - #include <sys/types.h> +#include <unistd.h> -#include "InputFlinger.h" -#include "InputDriver.h" - +#include <android/log.h> #include <binder/IPCThreadState.h> #include <binder/PermissionCache.h> #include <hardware/input.h> -#include <cutils/log.h> #include <private/android_filesystem_config.h> +#include "InputFlinger.h" +#include "InputDriver.h" + namespace android { const String16 sAccessInputFlingerPermission("android.permission.ACCESS_INPUT_FLINGER"); diff --git a/services/surfaceflinger/DdmConnection.cpp b/services/surfaceflinger/DdmConnection.cpp index 659c2c8e49..ba09b36e1d 100644 --- a/services/surfaceflinger/DdmConnection.cpp +++ b/services/surfaceflinger/DdmConnection.cpp @@ -15,8 +15,10 @@ */ #include <dlfcn.h> +#include <sys/types.h> +#include <unistd.h> -#include <cutils/log.h> +#include <android/log.h> #include "jni.h" #include "DdmConnection.h" diff --git a/services/surfaceflinger/DispSync.cpp b/services/surfaceflinger/DispSync.cpp index 836fb89d87..3229b6644c 100644 --- a/services/surfaceflinger/DispSync.cpp +++ b/services/surfaceflinger/DispSync.cpp @@ -22,20 +22,19 @@ #include <math.h> -#include <cutils/log.h> - -#include <ui/Fence.h> +#include <algorithm> +#include <android/log.h> #include <utils/String8.h> #include <utils/Thread.h> #include <utils/Trace.h> #include <utils/Vector.h> +#include <ui/Fence.h> + #include "DispSync.h" #include "EventLog/EventLog.h" -#include <algorithm> - using std::max; using std::min; diff --git a/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp b/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp index 61c231dc87..96dd55fecf 100644 --- a/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp +++ b/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp @@ -19,13 +19,12 @@ #undef LOG_TAG #define LOG_TAG "FramebufferSurface" -#include <stdlib.h> +#include <errno.h> #include <stdio.h> +#include <stdlib.h> #include <string.h> -#include <errno.h> - -#include <cutils/log.h> +#include <android/log.h> #include <utils/String8.h> #include <ui/Rect.h> diff --git a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp index c4f845d6b9..51e92b2360 100644 --- a/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp +++ b/services/surfaceflinger/DisplayHardware/HWC2On1Adapter.cpp @@ -22,15 +22,16 @@ #include "HWC2On1Adapter.h" -#include <hardware/hwcomposer.h> -#include <log/log.h> -#include <utils/Trace.h> +#include <inttypes.h> -#include <cstdlib> #include <chrono> -#include <inttypes.h> +#include <cstdlib> #include <sstream> +#include <android/log.h> +#include <hardware/hwcomposer.h> +#include <utils/Trace.h> + using namespace std::chrono_literals; static bool operator==(const hwc_color_t& lhs, const hwc_color_t& rhs) { diff --git a/services/surfaceflinger/DisplayHardware/HWComposer.cpp b/services/surfaceflinger/DisplayHardware/HWComposer.cpp index 034a394e2a..3f38c8623e 100644 --- a/services/surfaceflinger/DisplayHardware/HWComposer.cpp +++ b/services/surfaceflinger/DisplayHardware/HWComposer.cpp @@ -43,7 +43,7 @@ #include <android/configuration.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include "HWComposer.h" diff --git a/services/surfaceflinger/DisplayHardware/HWComposer_hwc1.cpp b/services/surfaceflinger/DisplayHardware/HWComposer_hwc1.cpp index e3afd506e1..facf82080e 100644 --- a/services/surfaceflinger/DisplayHardware/HWComposer_hwc1.cpp +++ b/services/surfaceflinger/DisplayHardware/HWComposer_hwc1.cpp @@ -39,7 +39,7 @@ #include <android/configuration.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <system/graphics.h> diff --git a/services/surfaceflinger/DisplayHardware/PowerHAL.cpp b/services/surfaceflinger/DisplayHardware/PowerHAL.cpp index 1c0a1fe2ed..a6f076e74f 100644 --- a/services/surfaceflinger/DisplayHardware/PowerHAL.cpp +++ b/services/surfaceflinger/DisplayHardware/PowerHAL.cpp @@ -18,7 +18,7 @@ #include <stdint.h> #include <sys/types.h> -#include <cutils/log.h> +#include <android/log.h> #include <utils/Errors.h> #include <binder/IServiceManager.h> diff --git a/services/surfaceflinger/EventLog/EventLog.cpp b/services/surfaceflinger/EventLog/EventLog.cpp index 47bab83bf7..365a0bd868 100644 --- a/services/surfaceflinger/EventLog/EventLog.cpp +++ b/services/surfaceflinger/EventLog/EventLog.cpp @@ -16,7 +16,7 @@ #include <stdio.h> #include <stdlib.h> -#include <cutils/log.h> +#include <log/log.h> #include <utils/String8.h> #include "EventLog.h" diff --git a/services/surfaceflinger/FrameTracker.cpp b/services/surfaceflinger/FrameTracker.cpp index 319c2a7116..99c4daaba5 100644 --- a/services/surfaceflinger/FrameTracker.cpp +++ b/services/surfaceflinger/FrameTracker.cpp @@ -19,12 +19,11 @@ #include <inttypes.h> -#include <cutils/log.h> +#include <android/log.h> +#include <utils/String8.h> #include <ui/FrameStats.h> -#include <utils/String8.h> - #include "FrameTracker.h" #include "EventLog/EventLog.h" diff --git a/services/surfaceflinger/RenderEngine/Program.cpp b/services/surfaceflinger/RenderEngine/Program.cpp index 0424e0cca0..38a0039fe8 100644 --- a/services/surfaceflinger/RenderEngine/Program.cpp +++ b/services/surfaceflinger/RenderEngine/Program.cpp @@ -16,12 +16,12 @@ #include <stdint.h> -#include <log/log.h> +#include <android/log.h> +#include <utils/String8.h> #include "Program.h" #include "ProgramCache.h" #include "Description.h" -#include <utils/String8.h> namespace android { diff --git a/services/surfaceflinger/RenderEngine/RenderEngine.cpp b/services/surfaceflinger/RenderEngine/RenderEngine.cpp index 2b82d0e6d2..986c6dfafb 100644 --- a/services/surfaceflinger/RenderEngine/RenderEngine.cpp +++ b/services/surfaceflinger/RenderEngine/RenderEngine.cpp @@ -14,7 +14,7 @@ * limitations under the License. */ -#include <cutils/log.h> +#include <android/log.h> #include <ui/Rect.h> #include <ui/Region.h> diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp index 6625a8bc61..f0961341ae 100644 --- a/services/surfaceflinger/SurfaceFlinger.cpp +++ b/services/surfaceflinger/SurfaceFlinger.cpp @@ -28,7 +28,7 @@ #include <EGL/egl.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <binder/IPCThreadState.h> diff --git a/services/surfaceflinger/SurfaceFlinger_hwc1.cpp b/services/surfaceflinger/SurfaceFlinger_hwc1.cpp index ada0046408..76680e0540 100644 --- a/services/surfaceflinger/SurfaceFlinger_hwc1.cpp +++ b/services/surfaceflinger/SurfaceFlinger_hwc1.cpp @@ -27,7 +27,7 @@ #include <EGL/egl.h> -#include <cutils/log.h> +#include <android/log.h> #include <cutils/properties.h> #include <binder/IPCThreadState.h> diff --git a/vulkan/libvulkan/api.cpp b/vulkan/libvulkan/api.cpp index b699fe97fc..4d30bbb965 100644 --- a/vulkan/libvulkan/api.cpp +++ b/vulkan/libvulkan/api.cpp @@ -27,8 +27,9 @@ #include <mutex> #include <new> #include <utility> + +#include <android/log.h> #include <cutils/properties.h> -#include <log/log.h> #include <vulkan/vk_layer_interface.h> #include "api.h" diff --git a/vulkan/libvulkan/api_gen.cpp b/vulkan/libvulkan/api_gen.cpp index 6458497557..40041354e3 100644 --- a/vulkan/libvulkan/api_gen.cpp +++ b/vulkan/libvulkan/api_gen.cpp @@ -17,8 +17,10 @@ // WARNING: This file is generated. See ../README.md for instructions. #include <string.h> + #include <algorithm> -#include <log/log.h> + +#include <android/log.h> // to catch mismatches between vulkan.h and this file #undef VK_NO_PROTOTYPES diff --git a/vulkan/libvulkan/code-generator.tmpl b/vulkan/libvulkan/code-generator.tmpl index 5e1777d072..c6d485a016 100644 --- a/vulkan/libvulkan/code-generator.tmpl +++ b/vulkan/libvulkan/code-generator.tmpl @@ -92,7 +92,7 @@ bool InitDispatchTable( ¶ #include <string.h> #include <algorithm> -#include <log/log.h> +#include <android/log.h> ¶ // to catch mismatches between vulkan.h and this file #undef VK_NO_PROTOTYPES @@ -271,7 +271,7 @@ bool InitDriverTable(VkDevice dev, PFN_vkGetDeviceProcAddr get_proc, ¶ #include <string.h> #include <algorithm> -#include <log/log.h> +#include <android/log.h> ¶ #include "driver.h" ¶ diff --git a/vulkan/libvulkan/driver.h b/vulkan/libvulkan/driver.h index a1612c7081..d74d9e917f 100644 --- a/vulkan/libvulkan/driver.h +++ b/vulkan/libvulkan/driver.h @@ -18,9 +18,11 @@ #define LIBVULKAN_DRIVER_H 1 #include <inttypes.h> + #include <bitset> #include <type_traits> -#include <log/log.h> + +#include <android/log.h> #include <vulkan/vulkan.h> #include <hardware/hwvulkan.h> diff --git a/vulkan/libvulkan/driver_gen.cpp b/vulkan/libvulkan/driver_gen.cpp index 9c58c56ba9..1312a62166 100644 --- a/vulkan/libvulkan/driver_gen.cpp +++ b/vulkan/libvulkan/driver_gen.cpp @@ -17,8 +17,10 @@ // WARNING: This file is generated. See ../README.md for instructions. #include <string.h> + #include <algorithm> -#include <log/log.h> + +#include <android/log.h> #include "driver.h" diff --git a/vulkan/libvulkan/layers_extensions.cpp b/vulkan/libvulkan/layers_extensions.cpp index 8f35f4d264..5f6d2438a4 100644 --- a/vulkan/libvulkan/layers_extensions.cpp +++ b/vulkan/libvulkan/layers_extensions.cpp @@ -19,16 +19,17 @@ #include <alloca.h> #include <dirent.h> #include <dlfcn.h> -#include <mutex> +#include <string.h> #include <sys/prctl.h> + +#include <mutex> #include <string> -#include <string.h> #include <vector> -#include <android-base/strings.h> +#include <android/log.h> #include <android/dlext.h> +#include <android-base/strings.h> #include <cutils/properties.h> -#include <log/log.h> #include <ziparchive/zip_archive.h> #include <vulkan/vulkan_loader_data.h> diff --git a/vulkan/libvulkan/stubhal.cpp b/vulkan/libvulkan/stubhal.cpp index 869317bcb9..3de8970475 100644 --- a/vulkan/libvulkan/stubhal.cpp +++ b/vulkan/libvulkan/stubhal.cpp @@ -29,8 +29,10 @@ #include <array> #include <bitset> #include <mutex> + +#include <android/log.h> #include <hardware/hwvulkan.h> -#include <log/log.h> + #include "stubhal.h" namespace vulkan { diff --git a/vulkan/libvulkan/swapchain.cpp b/vulkan/libvulkan/swapchain.cpp index 9856d6a2bc..3e87abf3c8 100644 --- a/vulkan/libvulkan/swapchain.cpp +++ b/vulkan/libvulkan/swapchain.cpp @@ -16,8 +16,8 @@ #include <algorithm> +#include <android/log.h> #include <gui/BufferQueue.h> -#include <log/log.h> #include <sync/sync.h> #include <utils/StrongPointer.h> diff --git a/vulkan/nulldrv/null_driver.cpp b/vulkan/nulldrv/null_driver.cpp index c403ededf9..4a520ee878 100644 --- a/vulkan/nulldrv/null_driver.cpp +++ b/vulkan/nulldrv/null_driver.cpp @@ -16,13 +16,14 @@ #include <hardware/hwvulkan.h> -#include <algorithm> -#include <array> #include <inttypes.h> #include <stdlib.h> #include <string.h> -#include <log/log.h> +#include <algorithm> +#include <array> + +#include <android/log.h> #include <utils/Errors.h> #include "null_driver_gen.h" diff --git a/vulkan/tools/vkinfo.cpp b/vulkan/tools/vkinfo.cpp index 7cf85e683e..801eca8300 100644 --- a/vulkan/tools/vkinfo.cpp +++ b/vulkan/tools/vkinfo.cpp @@ -14,18 +14,17 @@ * limitations under the License. */ -#include <algorithm> -#include <array> #include <inttypes.h> #include <stdlib.h> +#include <unistd.h> + +#include <algorithm> +#include <array> #include <sstream> #include <vector> #include <vulkan/vulkan.h> -#define LOG_TAG "vkinfo" -#include <log/log.h> - namespace { struct Options { |