From patchwork Tue Aug 6 21:53:59 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 170682 Delivered-To: patches@linaro.org Received: by 2002:ac9:2daa:0:0:0:0:0 with SMTP id g42csp5959384oce; Tue, 6 Aug 2019 14:54:03 -0700 (PDT) X-Received: by 2002:aa7:9afc:: with SMTP id y28mr5786349pfp.252.1565128442924; Tue, 06 Aug 2019 14:54:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565128442; cv=none; d=google.com; s=arc-20160816; b=U4GLRl8SfYGCzmlUouUpDmrnLxAcLXXWfqO0fJO/wZTcWvv4vvDds5TOXJ/pNAvC+o zzZOvpdkeRwu8gvoRAqicnQ2j+cbOf9mS62iZSc7TYoflRluk4+yNohceAicT241P9LM Ljw835wmHyXIb9LXbNhiS4isdmM479B8Yvy9MjAy232XdNQQewGYRj0JLRlLGmCkd+9g PI+b8far3t0+YUhfZEeB7nwJiVzt9+18BMXQ8W5cmic/y9RHuf9ey/RSNb+9Wqwpr5MC SKMcoxiKKJ5eKVo3iYBkANnq71ZrSit3BVVo00HLm9OLPU45DMcH87jI7CsoqeKHOx82 jwoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:dkim-signature; bh=eWaKjxoAGQw11OSfPqLDSqGsWOzufZMAEuwufMytCuE=; b=0hHX2qEGX8K2zsoEWcqvSVzZ/m+Ys1arSzDG4Ll1H4yUGLJv9VhLh3TWuQtkE1XPMs hL08R8C/2o9OtPmY5TBjEQId4yi2/vuinezUAlY5MRq7SbW3U9d0RW9dCavBAdSvy3GB 6sRhCfLCv+wuCN4MpVT/HWMbDstrrh50LFtI8zW17Ioqqdj3Vwxw9izhH/iWs4aRGDjf AbjNEyK/RgyGrD95rWSWUl7G0rXSQk4z2mhDS8srJlCQ1NAqbBJS8kotctNt5EhdYisv W7meHZ039Agfr5wQhCIm1QDArETQGreMk0yT9c7iJQ0UNxWAwsswKw8jtXYVhiSuZvGp bqFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Y/+IfmNP"; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id d5sor105322292plr.38.2019.08.06.14.54.02 for (Google Transport Security); Tue, 06 Aug 2019 14:54:02 -0700 (PDT) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Y/+IfmNP"; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=eWaKjxoAGQw11OSfPqLDSqGsWOzufZMAEuwufMytCuE=; b=Y/+IfmNPzQ1/qSAAMyteQb3CC0jItk1TYFTcVKY7+fv27FW6jEB+8XLUFbU8ixxwBN xjaBKF3XMhFfmaykrQiGKRcJ/CQKS7+M62AQnsWZv9Hp8QRaELGnlpLA6X4zdglR1F2Q OPjmi+PozUn7hECz27u7koJC6c1MjOW8tz0p5ohLj7f63D8EjveBRpULChNp83f7p0ko yw3P+l8Kvq13dF4gf/Y0pVCFXlbtYPknzRF9QQuLAmor5NjLCes7G36tGwx2t91MWbDH u3Y8nYCAsEGIAdRlqlt90gmjp0pi121+Iq2DZEiLmtDvMGpXlT406tUcDavhs/BW4jU2 nxJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=eWaKjxoAGQw11OSfPqLDSqGsWOzufZMAEuwufMytCuE=; b=l9+XdDLYKtG3u0i55qx/2ScrjZCdfEz4qFOTSBGGyuofztYvoPxakcyZJjekYBcWcD 2WbaeJEu++7/22AMRIL0SAm2rz9xQX6Kzr8Co5XGjrs7VBBhELlEr7VKy99pEdRnVpJJ FtsNAROWRevO9z4LFJnxWdTvIcWAmG4NBMOpBCF+UkjVQeJAmfDfQYMovOl05gKotqOg Sbtt6xXVCppwQ2cJ79ANiEANrJjq1jW8j1+y0PBmQdt45keAoA8tkFjwLILggK5LMbkg 0v1bRGA1CntBvh3ZdCAB3vnAzJWl+DA8KfnGjYMcvQNmjPUvhdA/qq3tMcoIlO0iZMJh Yd6w== X-Gm-Message-State: APjAAAUPkFrHHlvlSltc602z3FWX1cGi0wR/k9sLLF8nnnh0GTMKlY0p C2JmCqa6zBvVGnj6glNkQeqYDy3k X-Google-Smtp-Source: APXvYqxdpWiObqZ/qTVMIZLAZQoM8bqNwiFzGAAnzN56Vydx1/dNlKcmMQh7c3voDThY7Prbr+eWLQ== X-Received: by 2002:a17:902:9b94:: with SMTP id y20mr5168124plp.260.1565128442418; Tue, 06 Aug 2019 14:54:02 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([2601:1c2:680:1319:692:26ff:feda:3a81]) by smtp.gmail.com with ESMTPSA id v27sm120896225pgn.76.2019.08.06.14.54.01 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Tue, 06 Aug 2019 14:54:01 -0700 (PDT) From: John Stultz To: Nicolas Dechense Cc: John Stultz , Bjorn Andersson , Amit Pundir Subject: [PATCH] QcomModulePkg: Fastboot: Add extend Fastboot menu to UART interface Date: Tue, 6 Aug 2019 21:53:59 +0000 Message-Id: <20190806215359.31641-1-john.stultz@linaro.org> X-Mailer: git-send-email 2.17.1 We can already somewhat control the fastboot menu over the serial UART, as up and down changes action mode. However, there's no way to select the mode over the UART. So add some feedback over the UART as to the current mode and use SCAN_RIGHT as the selection option (equivalent to the power button). UNTESTED! Cc: Bjorn Andersson Cc: Amit Pundir Cc: Nicolas Dechense Signed-off-by: John Stultz --- QcomModulePkg/Library/BootLib/FastbootMenu.c | 2 ++ QcomModulePkg/Library/BootLib/MenuKeysDetection.c | 1 + 2 files changed, 3 insertions(+) -- 2.17.1 diff --git a/QcomModulePkg/Library/BootLib/FastbootMenu.c b/QcomModulePkg/Library/BootLib/FastbootMenu.c index 1d095efe4..7004f76f3 100644 --- a/QcomModulePkg/Library/BootLib/FastbootMenu.c +++ b/QcomModulePkg/Library/BootLib/FastbootMenu.c @@ -175,6 +175,8 @@ UpdateFastbootOptionItem (UINT32 OptionItem, UINT32 *pLocation) return EFI_OUT_OF_RESOURCES; } + DEBUG ((EFI_D_INFO, "Fastboot Action (Press to select): %s\n", mFastbootOptionTitle[OptionItem].Msg)); + SetMenuMsgInfo (FastbootLineInfo, "__________", COMMON_FACTOR, mFastbootOptionTitle[OptionItem].FgColor, mFastbootOptionTitle[OptionItem].BgColor, LINEATION, Location, diff --git a/QcomModulePkg/Library/BootLib/MenuKeysDetection.c b/QcomModulePkg/Library/BootLib/MenuKeysDetection.c index 42e79eb6f..45843bb12 100644 --- a/QcomModulePkg/Library/BootLib/MenuKeysDetection.c +++ b/QcomModulePkg/Library/BootLib/MenuKeysDetection.c @@ -397,6 +397,7 @@ MenuKeysHandler (IN EFI_EVENT Event, IN VOID *Context) if (MenuPagesAction[MenuInfo->Info.MenuType].Down_Action_Func != NULL) MenuPagesAction[MenuInfo->Info.MenuType].Down_Action_Func (MenuInfo); break; + case SCAN_RIGHT: case SCAN_SUSPEND: if (MenuPagesAction[MenuInfo->Info.MenuType].Enter_Action_Func != NULL) MenuPagesAction[MenuInfo->Info.MenuType].Enter_Action_Func (MenuInfo);