Merge "Fix implicit-fallthrough warnings."
authorTreehugger Robot <treehugger-gerrit@google.com>
Sat, 20 Oct 2018 04:45:15 +0000 (04:45 +0000)
committerGerrit Code Review <noreply-gerritcodereview@google.com>
Sat, 20 Oct 2018 04:45:15 +0000 (04:45 +0000)
audio/common/all-versions/default/service/android.hardware.audio@2.0-service.rc
graphics/composer/2.2/default/android.hardware.graphics.composer@2.2-service.rc
graphics/composer/2.2/vts/functional/VtsHalGraphicsComposerV2_2TargetTest.cpp
keymaster/4.0/support/Keymaster.cpp

index 8217b946dc96a3b42e458a5026898f03ca17261c..6e91bccb3c147108057731994c7242090cc2e3c0 100644 (file)
@@ -2,7 +2,8 @@ service vendor.audio-hal-2-0 /vendor/bin/hw/android.hardware.audio@2.0-service
     class hal
     user audioserver
     # media gid needed for /dev/fm (radio) and for /data/misc/media (tee)
-    group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct
+    group audio camera drmrpc inet media mediadrm net_bt net_bt_admin net_bw_acct wakelock
+    capabilities BLOCK_SUSPEND
     ioprio rt 4
     writepid /dev/cpuset/foreground/tasks /dev/stune/foreground/tasks
     # audioflinger restarts itself when it loses connection with the hal
index a41d902cc91bd7c21bb6c8867740549084487718..efe6dadbc2403d41dadc0741699318c98bc25e83 100644 (file)
@@ -4,3 +4,4 @@ service vendor.hwcomposer-2-2 /vendor/bin/hw/android.hardware.graphics.composer@
     group graphics drmrpc
     capabilities SYS_NICE
     onrestart restart surfaceflinger
+    writepid /dev/cpuset/system-background/tasks
index 23bf5583bdea8fae068d584c12b0ac660409ec39..951e874e9275262256eaaf32ed53afafee2abb88 100644 (file)
 
 #include <VtsHalHidlTargetTestBase.h>
 #include <android-base/logging.h>
-#include <android/hardware/graphics/mapper/2.1/IMapper.h>
+#include <android/hardware/graphics/mapper/2.0/IMapper.h>
 #include <composer-vts/2.1/GraphicsComposerCallback.h>
 #include <composer-vts/2.1/TestCommandReader.h>
 #include <composer-vts/2.2/ComposerVts.h>
-#include <mapper-vts/2.1/MapperVts.h>
+#include <mapper-vts/2.0/MapperVts.h>
 
 namespace android {
 namespace hardware {
@@ -40,8 +40,8 @@ using android::hardware::graphics::common::V1_1::Dataspace;
 using android::hardware::graphics::common::V1_1::PixelFormat;
 using android::hardware::graphics::common::V1_1::RenderIntent;
 using android::hardware::graphics::composer::V2_2::IComposerClient;
-using android::hardware::graphics::mapper::V2_1::IMapper;
-using android::hardware::graphics::mapper::V2_1::vts::Gralloc;
+using android::hardware::graphics::mapper::V2_0::IMapper;
+using android::hardware::graphics::mapper::V2_0::vts::Gralloc;
 using GrallocError = android::hardware::graphics::mapper::V2_0::Error;
 
 // Test environment for graphics.composer
@@ -136,7 +136,7 @@ class GraphicsComposerHidlCommandTest : public GraphicsComposerHidlTest {
         info.width = 64;
         info.height = 64;
         info.layerCount = 1;
-        info.format = PixelFormat::RGBA_8888;
+        info.format = static_cast<common::V1_0::PixelFormat>(PixelFormat::RGBA_8888);
         info.usage =
             static_cast<uint64_t>(BufferUsage::CPU_WRITE_OFTEN | BufferUsage::CPU_READ_OFTEN);
 
@@ -280,7 +280,7 @@ TEST_F(GraphicsComposerHidlTest, setReadbackBuffer) {
     info.height = mComposerClient->getDisplayAttribute(mPrimaryDisplay, config,
                                                        IComposerClient::Attribute::HEIGHT);
     info.layerCount = 1;
-    info.format = pixelFormat;
+    info.format = static_cast<common::V1_0::PixelFormat>(pixelFormat);
     // BufferUsage::COMPOSER_OUTPUT is missing
     info.usage = static_cast<uint64_t>(BufferUsage::COMPOSER_OVERLAY | BufferUsage::CPU_READ_OFTEN);
 
index 444298b5bbb624ba1abab0c4bd1082ccf739a4bc..9325cc069972a9094dc29ce3ac55f96f56e9bb3e 100644 (file)
@@ -164,10 +164,10 @@ static void computeHmac(const Keymaster::KeymasterSet& keymasters,
                     sharingCheck = curSharingCheck;
                     firstKeymaster = false;
                 }
-                CHECK(curSharingCheck == sharingCheck)
-                    << "HMAC computation failed for " << *keymaster  //
-                    << " Expected: " << sharingCheck                 //
-                    << " got: " << curSharingCheck;
+                if (curSharingCheck != sharingCheck)
+                    LOG(WARNING) << "HMAC computation failed for " << *keymaster  //
+                                 << " Expected: " << sharingCheck                 //
+                                 << " got: " << curSharingCheck;
             });
         CHECK(rc.isOk()) << "Failed to communicate with " << *keymaster
                          << " error: " << rc.description();