Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 49d3fe73 authored by Charlie Chen's avatar Charlie Chen
Browse files

Make PASSTHROUGH_USAGE_MASK real 64bit mask

Since GRALLOC_USAGE_SW_READ_MASK, GRALLOC_USAGE_SW_WRITE_MASK,
and GRALLOC_USAGE_PROTECTED are not uint64_t. Without casting,
PASSTHROUGH_USAGE_MASK is actually a 32bit mask.

Bug: 182361811
Change-Id: I01c1284f4696840b86f6de875243e69ab6dc324c
parent 292d9230
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -42,7 +42,9 @@ namespace /* unnamed */ {
         * Usage mask that is passed through from gralloc to Codec 2.0 usage.
         */
        PASSTHROUGH_USAGE_MASK =
            ~(GRALLOC_USAGE_SW_READ_MASK | GRALLOC_USAGE_SW_WRITE_MASK | GRALLOC_USAGE_PROTECTED)
            ~static_cast<uint64_t>(GRALLOC_USAGE_SW_READ_MASK |
                                   GRALLOC_USAGE_SW_WRITE_MASK |
                                   GRALLOC_USAGE_PROTECTED)
    };

    // verify that passthrough mask is within the platform mask