diff mbox

[Branch,~linaro-validation/lava-dispatcher/trunk] Rev 209: add support for installing android binary drivers

Message ID 20120130175713.11573.64266.launchpad@ackee.canonical.com
State Accepted
Headers show

Commit Message

Paul Larson Jan. 30, 2012, 5:57 p.m. UTC
Merge authors:
  Paul Larson <paul.larson@linaro.org>
Related merge proposals:
  https://code.launchpad.net/~pwlars/lava-dispatcher/android-install-binaries/+merge/90366
  proposed by: Paul Larson (pwlars)
  review: Approve - Yongqin Liu (liuyq0307)
------------------------------------------------------------
revno: 209 [merge]
committer: Paul Larson <paul.larson@linaro.org>
branch nick: lava-dispatcher
timestamp: Mon 2012-01-30 11:47:06 -0600
message:
  add support for installing android binary drivers
added:
  lava_dispatcher/actions/android_install_binaries.py
modified:
  lava_dispatcher/default-config/lava-dispatcher/device-types/panda.conf


--
lp:lava-dispatcher
https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk

You are subscribed to branch lp:lava-dispatcher.
To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk/+edit-subscription
diff mbox

Patch

=== added file 'lava_dispatcher/actions/android_install_binaries.py'
--- lava_dispatcher/actions/android_install_binaries.py	1970-01-01 00:00:00 +0000
+++ lava_dispatcher/actions/android_install_binaries.py	2012-01-27 03:10:08 +0000
@@ -0,0 +1,40 @@ 
+# Copyright (C) 2012 Linaro Limited
+#
+# Author: Paul Larson <paul.larson@linaro.org>
+#
+# This file is part of LAVA Dispatcher.
+#
+# LAVA Dispatcher is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# LAVA Dispatcher is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, see <http://www.gnu.org/licenses>.
+
+import ConfigParser
+import logging
+from lava_dispatcher.actions import BaseAction
+from lava_dispatcher.client.master import _deploy_tarball_to_board
+
+
+class cmd_android_install_binaries(BaseAction):
+    def run(self):
+        try:
+            driver_tarball = self.client.device_option(
+                "android_binary_drivers")
+        except ConfigParser.NoOptionError:
+            logging.error("android_binary_drivers not defined in any config")
+            return
+
+        with self.client._master_session() as session:
+            session.run(
+                'mount /dev/disk/by-label/testrootfs /mnt/lava/system')
+            _deploy_tarball_to_board(
+                session, driver_tarball, '/mnt/lava/system', timeout=600)
+            session.run('umount /mnt/lava/system')

=== modified file 'lava_dispatcher/default-config/lava-dispatcher/device-types/panda.conf'
--- lava_dispatcher/default-config/lava-dispatcher/device-types/panda.conf	2012-01-18 17:12:47 +0000
+++ lava_dispatcher/default-config/lava-dispatcher/device-types/panda.conf	2012-01-27 03:10:08 +0000
@@ -16,3 +16,5 @@ 
     omapfb.vram=0:24M,1:24M mem=456M@0x80000000 mem=512M@0xA0000000 
     init=/init androidboot.console=ttyO2'",
     boot
+
+android_binary_drivers = http://192.168.1.21/LAVA_HTTP/android-binaries/panda-drivers.tgz