From patchwork Thu May 30 10:50:24 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dave Pigott X-Patchwork-Id: 17291 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-yh0-f70.google.com (mail-yh0-f70.google.com [209.85.213.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id DE9FB25C6D for ; Thu, 30 May 2013 10:50:27 +0000 (UTC) Received: by mail-yh0-f70.google.com with SMTP id l109sf93340yhq.9 for ; Thu, 30 May 2013 03:50:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-beenthere:x-forwarded-to:x-forwarded-for:delivered-to :mime-version:x-launchpad-project:x-launchpad-branch :x-launchpad-message-rationale:x-launchpad-branch-revision-number :x-launchpad-notification-type:to:from:subject:message-id:date :reply-to:sender:errors-to:precedence:x-generated-by :x-launchpad-hash:x-gm-message-state:x-original-sender :x-original-authentication-results:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe :content-type; bh=W6KN85bHsVpML7CIIUL1KrXl83V6ygc/VzKiGJWgBtQ=; b=kfpN+Ae6fpNvsmMTd8LLin+7kYObN1U5InwHWHiAegNIYLJS2UqAzUYiAltgW8hvb+ UviPst3xzcjFzrNGb5lzW26kYQmqNwwMCVfMC6prabkRVMltXK484zSz989oKBY/1KhA rVVU1hmr11MMiPy1ORKE2XWtJsejD7jHGD0SIcjnWSv1oLjZr8jqFkhtSRfjgCnta+Yj MdklHXeYBy7Z5rz+HVk1TvefRnBldfIKaykn1vcqLFiN6Ho4RDRfxRXiDwoT97gYrKkW Lc0/ezwEXOPDqx2V+fag6R3aaL7cPPuyndZvCFh8gMyyKDjch70yYpUwP0mhoUI2CAlu uxvw== X-Received: by 10.224.59.205 with SMTP id m13mr3976188qah.7.1369911027492; Thu, 30 May 2013 03:50:27 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.58.172 with SMTP id s12ls319497qeq.18.gmail; Thu, 30 May 2013 03:50:27 -0700 (PDT) X-Received: by 10.52.28.171 with SMTP id c11mr4150696vdh.18.1369911027314; Thu, 30 May 2013 03:50:27 -0700 (PDT) Received: from mail-vc0-f171.google.com (mail-vc0-f171.google.com [209.85.220.171]) by mx.google.com with ESMTPS id ef7si24428981vdc.98.2013.05.30.03.50.27 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 30 May 2013 03:50:27 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.171 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.171; Received: by mail-vc0-f171.google.com with SMTP id m17so45954vca.16 for ; Thu, 30 May 2013 03:50:27 -0700 (PDT) X-Received: by 10.52.120.113 with SMTP id lb17mr4214284vdb.1.1369911026954; Thu, 30 May 2013 03:50:26 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.229.199 with SMTP id jj7csp3145vcb; Thu, 30 May 2013 03:50:26 -0700 (PDT) X-Received: by 10.194.220.97 with SMTP id pv1mr4101014wjc.25.1369911025691; Thu, 30 May 2013 03:50:25 -0700 (PDT) Received: from indium.canonical.com (indium.canonical.com. [91.189.90.7]) by mx.google.com with ESMTPS id hg10si7845687wib.86.2013.05.30.03.50.24 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 30 May 2013 03:50:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) client-ip=91.189.90.7; Received: from ackee.canonical.com ([91.189.89.26]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1Ui0R6-00034K-KY for ; Thu, 30 May 2013 10:50:24 +0000 Received: from ackee.canonical.com (localhost [127.0.0.1]) by ackee.canonical.com (Postfix) with ESMTP id 899F7E190B for ; Thu, 30 May 2013 10:50:24 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: lava-dispatcher X-Launchpad-Branch: ~linaro-validation/lava-dispatcher/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 616 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-validation/lava-dispatcher/trunk] Rev 616: Seperate function for entering bootloader. UEFI doesn't like the second CR which is added by send... Message-Id: <20130530105024.4399.55098.launchpad@ackee.canonical.com> Date: Thu, 30 May 2013 10:50:24 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: list X-Generated-By: Launchpad (canonical.com); Revision="16660"; Instance="launchpad-lazr.conf" X-Launchpad-Hash: 96ade5b48b9c00ec041ce39c87933d9a733f6abf X-Gm-Message-State: ALoCoQksYR7aXpamz4D8Uw8Ye371gByaVBOPgwoaVvEULv7BSMMMNn7QNkOdG/QNqpaINnpHAXUw X-Original-Sender: noreply@launchpad.net X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.171 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Merge authors: Dave Pigott (dpigott) Related merge proposals: https://code.launchpad.net/~dpigott/lava-dispatcher/fix-uefi-enter-bootloader/+merge/166478 proposed by: Dave Pigott (dpigott) review: Approve - Dave Pigott (dpigott) ------------------------------------------------------------ revno: 616 [merge] committer: dave.pigott@linaro.org branch nick: trunk timestamp: Thu 2013-05-30 11:40:22 +0100 message: Seperate function for entering bootloader. UEFI doesn't like the second CR which is added by sendline modified: lava_dispatcher/device/uefi.py --- 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 === modified file 'lava_dispatcher/device/uefi.py' --- lava_dispatcher/device/uefi.py 2013-05-29 13:43:42 +0000 +++ lava_dispatcher/device/uefi.py 2013-05-30 10:38:23 +0000 @@ -37,11 +37,11 @@ """ try: self._soft_reboot() - self._enter_bootloader() + self._enter_uefi() except: logging.exception("enter uefi failed") self._hard_reboot() - self._enter_bootloader() + self._enter_uefi() self.proc.expect(self.config.bootloader_prompt, timeout=300) for line in range(0, len(boot_cmds)): parts = re.match('^(?Psendline|expect)\s*(?P.*)', line) @@ -57,4 +57,11 @@ else: raise Exception("Unrecognised action in boot_cmds") + def _enter_uefi(self): + if self.proc.expect(self.config.interrupt_boot_prompt) != 0: + raise Exception("Failed to enter bootloader") + self.proc.send(self.config.interrupt_boot_command) + + + target_class = UEFITarget