Fix CpuThrottlingWaiter cat failures

Some devices can return multiple CPUs directories
on the same line when running ls to list the CPUs
on the device.

e.g.

/sys/devices/system/cpu/cpu0/cpufreq /sys/devices/system/cpu/cpu3/cpufreq
/sys/devices/system/cpu/cpu1/cpufreq /sys/devices/system/cpu/cpu4/cpufreq

CpuThrottlingWaiter splits the ls output by line
and feeds this into a cat command to get the
frequency to check if any cores are throttled.

e.g.

cat /sys/devices/system/cpu/cpu1/cpufreq /sys/devices/system/cpu/cpu4/cpufreq/cpuinfo_max_freq

When the cat command fails (trying to cat the
cpufreq directory), CpuThrottlingWaiter assumes
the device is throttled. And then does this until
it times out.

Fix this by telling the ls command to only output
one directory per line.

Change-Id: I27197d6ab8eb8767bb6903f197c5a650b3f26392
diff --git a/src/com/android/tradefed/targetprep/CpuThrottlingWaiter.java b/src/com/android/tradefed/targetprep/CpuThrottlingWaiter.java
index 06ba6c3..a9aae9d 100644
--- a/src/com/android/tradefed/targetprep/CpuThrottlingWaiter.java
+++ b/src/com/android/tradefed/targetprep/CpuThrottlingWaiter.java
@@ -116,7 +116,7 @@
     protected Map<String, String> getCpuMaxFreqs(ITestDevice device)
             throws DeviceNotAvailableException {
         Map<String, String> ret = new HashMap<>();
-        String result = device.executeShellCommand("ls -d /sys/devices/system/cpu/cpu*/cpufreq");
+        String result = device.executeShellCommand("ls -1 -d /sys/devices/system/cpu/cpu*/cpufreq");
         String[] lines = result.split("\r?\n");
         List<String> cpuPaths = new ArrayList<>();
         for (String line : lines) {