From ceb493f98db1adc59298f1cd0671cef4ef92bf47 Mon Sep 17 00:00:00 2001
From: Marc Bonnici <marc.bonnici@arm.com>
Date: Tue, 12 Dec 2017 10:26:29 +0000
Subject: [PATCH] utils/android: Change directory used for checking connection

Previously the root directory was used when checking for device
connection, on some devices this requires elevated permissions so now
use '/data/local/tmp' which should not have permission restrictions.
---
 devlib/utils/android.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/devlib/utils/android.py b/devlib/utils/android.py
index 0de6102..4668db0 100755
--- a/devlib/utils/android.py
+++ b/devlib/utils/android.py
@@ -351,7 +351,7 @@ def adb_disconnect(device):
 def _ping(device):
     _check_env()
     device_string = ' -s {}'.format(device) if device else ''
-    command = "adb{} shell \"ls / > /dev/null\"".format(device_string)
+    command = "adb{} shell \"ls /data/local/tmp > /dev/null\"".format(device_string)
     logger.debug(command)
     result = subprocess.call(command, stderr=subprocess.PIPE, shell=True)
     if not result: