From patchwork Wed May 16 15:42:18 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 914706 X-Patchwork-Delegate: agraf@suse.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=google.com header.i=@google.com header.b="Xap3ghXh"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 40mJk00wwQz9s33 for ; Thu, 17 May 2018 01:48:08 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id CA41BC21FC0; Wed, 16 May 2018 15:46:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id CCA22C21F47; Wed, 16 May 2018 15:43:52 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 70C77C21F95; Wed, 16 May 2018 15:42:57 +0000 (UTC) Received: from mail-it0-f68.google.com (mail-it0-f68.google.com [209.85.214.68]) by lists.denx.de (Postfix) with ESMTPS id 16C82C21FD1 for ; Wed, 16 May 2018 15:42:47 +0000 (UTC) Received: by mail-it0-f68.google.com with SMTP id j186-v6so3072268ita.5 for ; Wed, 16 May 2018 08:42:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=Z4tbC/ZttgsaQtYaDPYHcsq/uoHXxybDvkSeluJbvgE=; b=Xap3ghXhLHKuAnxfj0i7YKkeLp432aE1bN7xR6cG9uZqiQ6EcSrtKnLUMiMhucLNEn zNpmqxrZWaL0G0B3/rfdiuydJv9hPuyJxgz/4wqiLiKekfr+Ic6mI/RYdWh/mV1ku5kE tIX5H5gVOW0IdhqEz/HSWfeu0o1JmibRCWWdCaVgOVhAF/TdrQwZhSMa/N8awKaty0E7 obqatgtNYlDuYNxX9l+wFlOe/vQRNaOIWJt2hL97v2cexS+g/4lOi/eT+fkVwMSEBf6N 2DC2ALP6pEgcTkWyANaNFiOEiPm9RDn07kd2yXb2+5GcexIWcVx3JgNtRnW07p5wiokU 6r3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=Z4tbC/ZttgsaQtYaDPYHcsq/uoHXxybDvkSeluJbvgE=; b=mv3fXXhCdHwqu24HsiILRX2BLiy76W3Lvjde78IPpmpFsiVJ2w0tMR25Rl8wsR5fNV gdkI1gbqtc4omd8N1O4CFPcBpzfajCEdMy0iT8zMD83B8ZjCjUxQJgXeXOm9+Aaa8yyr iFFgR0wWJp3WuDcEkZNpY78pSjofBcaOIF2oLA0Gv7Yq716qp7n6fos9BpdwCawp4e9l +Qh0MGN4kNSita7rTHnrg8CVmiiXwSofCGN3fFt1lvE0XNpZNMOYsKC8lgq79ueAX9Ar dmnygPSnn/Zc5D9/5na1N/Mb+VAAZeJQ4znGsL8/Qk2ZymwJwzf6gZ0vayUxdBok1DEr Gujg== X-Gm-Message-State: ALKqPwetYEmYlLo2Vk2Pskzldw+khogXx+8PlUO50sIFrcGCIl2cRpct Iwl8AHF5BmqrmD+hI+5uyUMnFA== X-Google-Smtp-Source: AB8JxZokUAB0FceeS5SbLRVZcUTyqYg54ZlJi5h1QC7Te7FYyKFJiTJ6s+4L3Vs0s6IU6tAm1pRc4A== X-Received: by 2002:a24:ca87:: with SMTP id k129-v6mr1525699itg.140.1526485365681; Wed, 16 May 2018 08:42:45 -0700 (PDT) Received: from kiwi.bld.corp.google.com ([100.67.80.24]) by smtp.gmail.com with ESMTPSA id n89-v6sm2690832ioo.45.2018.05.16.08.42.44 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 16 May 2018 08:42:45 -0700 (PDT) Received: by kiwi.bld.corp.google.com (Postfix, from userid 121222) id 52CC2140474; Wed, 16 May 2018 09:42:44 -0600 (MDT) From: Simon Glass To: U-Boot Mailing List Date: Wed, 16 May 2018 09:42:18 -0600 Message-Id: <20180516154233.21457-2-sjg@chromium.org> X-Mailer: git-send-email 2.17.0.441.gb46fe60e1d-goog In-Reply-To: <20180516154233.21457-1-sjg@chromium.org> References: <20180516154233.21457-1-sjg@chromium.org> Cc: Andy Shevchenko , Heinrich Schuchardt , Alexander Graf Subject: [U-Boot] [PATCH v4 01/16] efi: Init the 'rows' and 'cols' variables X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" The current code causes a compiler error on gcc 4.8.4 as used by sandbox on Ubuntu 14.04, which is fairly recent. Init these variables to fix the problem. Signed-off-by: Simon Glass --- Changes in v4: - Move the fix to query_console_serial() Changes in v3: - Add new patch to init the 'rows' and 'cols' variables Changes in v2: None lib/efi_loader/efi_console.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/efi_loader/efi_console.c b/lib/efi_loader/efi_console.c index d777db8a3ed..001f68df0a7 100644 --- a/lib/efi_loader/efi_console.c +++ b/lib/efi_loader/efi_console.c @@ -185,8 +185,11 @@ static int query_console_serial(int *rows, int *cols) return -1; /* Read {depth,rows,cols} */ - if (term_read_reply(n, 3, 't')) + if (term_read_reply(n, 3, 't')) { + *rows = -1; + *cols = -1; return -1; + } *cols = n[2]; *rows = n[1];