]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
py: test: Fix number of controller calculation
authorMichal Simek <michal.simek@xilinx.com>
Thu, 21 Dec 2017 12:44:04 +0000 (13:44 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Thu, 4 Jan 2018 15:19:13 +0000 (16:19 +0100)
Array looks like this.
['sdhci@ff160000:', '0', '(SD)', 'sdhci@ff170000:', '1', '(SD)']
It means it is necessary to divide by 3 to get number of controllers.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
test/py/tests/test_mmc.py

index 4316971c5bca440330cc719bda4fbb3b20dcef9d..b050577f3efdca6429ed385b88d8dc2503ffae44 100644 (file)
@@ -22,7 +22,7 @@ def test_mmc_list(u_boot_console):
 
     global devices
     global controllers
-    controllers = len(array) / 2
+    controllers = len(array) / 3
     for x in range(0, controllers):
         y = x * 2
         devices[x] = {}