diff options
author | Sean Paul <seanpaul@chromium.org> | 2016-05-16 23:24:46 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2016-05-16 23:24:46 +0000 |
commit | 57288fab52fad3f8e9bbef146c9fae2b37128cf0 (patch) | |
tree | 2fed839f2c6ddfe67d85d57c0817f10878f31781 | |
parent | aad3bb84a07e1d096308d66fc6ea685ca3a0bdd3 (diff) | |
parent | 717a44be8f9f9282e6708b78cb3f2bbc8de7cb3a (diff) | |
download | drm_hwcomposer-57288fab52fad3f8e9bbef146c9fae2b37128cf0.tar.gz |
DO NOT MERGE: drm_hwcomposer: Fix up some printf warnings and a clang-style nit
am: 717a44be8f
* commit '717a44be8f9f9282e6708b78cb3f2bbc8de7cb3a':
DO NOT MERGE: drm_hwcomposer: Fix up some printf warnings and a clang-style nit
Change-Id: Ia34f75d02c5bbce17dc2d4903074f46e0757cc15
-rw-r--r-- | drmdisplaycompositor.cpp | 4 | ||||
-rw-r--r-- | drmplane.cpp | 3 | ||||
-rw-r--r-- | drmresources.cpp | 8 | ||||
-rw-r--r-- | platform.h | 1 |
4 files changed, 9 insertions, 7 deletions
diff --git a/drmdisplaycompositor.cpp b/drmdisplaycompositor.cpp index aaef8e4..df8e331 100644 --- a/drmdisplaycompositor.cpp +++ b/drmdisplaycompositor.cpp @@ -807,7 +807,7 @@ out: if (!test_only && mode_.needs_modeset) { ret = drm_->DestroyPropertyBlob(mode_.old_blob_id); if (ret) { - ALOGE("Failed to destroy old mode property blob %lld/%d", + ALOGE("Failed to destroy old mode property blob %" PRIu32 "/%d", mode_.old_blob_id, ret); return ret; } @@ -858,7 +858,7 @@ std::tuple<int, uint32_t> DrmDisplayCompositor::CreateModeBlob( ALOGE("Failed to create mode property blob %d", ret); return std::make_tuple(ret, 0); } - ALOGE("Create blob_id %ld\n", id); + ALOGE("Create blob_id %" PRIu32 "\n", id); return std::make_tuple(ret, id); } diff --git a/drmplane.cpp b/drmplane.cpp index 2314c39..c4ea722 100644 --- a/drmplane.cpp +++ b/drmplane.cpp @@ -19,6 +19,7 @@ #include "drmplane.h" #include "drmresources.h" +#include <cinttypes> #include <errno.h> #include <stdint.h> @@ -53,7 +54,7 @@ int DrmPlane::Init() { type_ = (uint32_t)type; break; default: - ALOGE("Invalid plane type %d", type); + ALOGE("Invalid plane type %" PRIu64, type); return -EINVAL; } diff --git a/drmresources.cpp b/drmresources.cpp index 81381c3..e433239 100644 --- a/drmresources.cpp +++ b/drmresources.cpp @@ -23,6 +23,7 @@ #include "drmplane.h" #include "drmresources.h" +#include <cinttypes> #include <errno.h> #include <fcntl.h> #include <stdint.h> @@ -321,7 +322,7 @@ int DrmResources::DestroyPropertyBlob(uint32_t blob_id) { destroy_blob.blob_id = (__u32)blob_id; int ret = drmIoctl(fd(), DRM_IOCTL_MODE_DESTROYPROPBLOB, &destroy_blob); if (ret) { - ALOGE("Failed to destroy mode property blob %ld/%d", blob_id, ret); + ALOGE("Failed to destroy mode property blob %" PRIu32 "/%d", blob_id, ret); return ret; } return 0; @@ -348,7 +349,7 @@ int DrmResources::SetDisplayActiveMode(int display, const DrmMode &mode) { int DrmResources::SetDpmsMode(int display, uint64_t mode) { if (mode != DRM_MODE_DPMS_ON && mode != DRM_MODE_DPMS_OFF) { - ALOGE("Invalid dpms mode %d", mode); + ALOGE("Invalid dpms mode %" PRIu64, mode); return -EINVAL; } @@ -359,7 +360,8 @@ int DrmResources::SetDpmsMode(int display, uint64_t mode) { } int ret = comp->SetDpmsMode(display, mode); if (ret) { - ALOGE("Failed to add dpms %ld to composition on %d %d", mode, display, ret); + ALOGE("Failed to add dpms %" PRIu64 " to composition on %d %d", mode, + display, ret); return ret; } ret = compositor_.QueueComposition(std::move(comp)); @@ -47,5 +47,4 @@ class Importer { virtual int ReleaseBuffer(hwc_drm_bo_t *bo) = 0; }; } - #endif |