From owner-svn-src-head@freebsd.org Tue Mar 17 12:16:28 2020 Return-Path: Delivered-To: svn-src-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 67955264325 for ; Tue, 17 Mar 2020 12:16:28 +0000 (UTC) (envelope-from junchoon@dec.sakura.ne.jp) Received: from dec.sakura.ne.jp (dec.sakura.ne.jp [210.188.226.8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 48hXG05lqRz4YxW for ; Tue, 17 Mar 2020 12:16:24 +0000 (UTC) (envelope-from junchoon@dec.sakura.ne.jp) Received: from kalamity.joker.local (124-18-96-116.dz.commufa.jp [124.18.96.116]) (authenticated bits=0) by dec.sakura.ne.jp (8.15.2/8.15.2/[SAKURA-WEB]/20080708) with ESMTPA id 02HCGF34070017; Tue, 17 Mar 2020 21:16:15 +0900 (JST) (envelope-from junchoon@dec.sakura.ne.jp) Date: Tue, 17 Mar 2020 21:16:14 +0900 From: Tomoaki AOKI To: Toomas Soome Cc: svn-src-head@freebsd.org Subject: Re: svn commit: r358989 - in head/stand/efi: libefi loader loader/arch/arm loader/arch/arm64 Message-Id: <20200317211614.bbe1b18a32d7863941fffbe8@dec.sakura.ne.jp> In-Reply-To: <746EE981-536F-49AD-9B76-F9F103ECB1F9@me.com> References: <20200316001745.07df62f72d647b924b657d86@dec.sakura.ne.jp> <746EE981-536F-49AD-9B76-F9F103ECB1F9@me.com> Reply-To: junchoon@dec.sakura.ne.jp Organization: Junchoon corps X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.1) Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 48hXG05lqRz4YxW X-Spamd-Bar: +++++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of junchoon@dec.sakura.ne.jp has no SPF policy when checking 210.188.226.8) smtp.mailfrom=junchoon@dec.sakura.ne.jp X-Spamd-Result: default: False [5.18 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; HAS_REPLYTO(0.00)[junchoon@dec.sakura.ne.jp]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; REPLYTO_ADDR_EQ_FROM(0.00)[]; HAS_ORG_HEADER(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; FREEMAIL_TO(0.00)[me.com]; RECEIVED_SPAMHAUS_PBL(0.00)[116.96.18.124.khpj7ygk5idzvmvt5x4ziurxhy.zen.dq.spamhaus.net : 127.0.0.10]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:9370, ipnet:210.188.224.0/19, country:JP]; MIME_TRACE(0.00)[0:+]; MID_RHS_MATCH_FROM(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(1.78)[ipnet: 210.188.224.0/19(4.95), asn: 9370(3.93), country: JP(0.04)]; DMARC_NA(0.00)[sakura.ne.jp]; AUTH_NA(1.00)[]; NEURAL_SPAM_MEDIUM(1.00)[1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(1.00)[1.000,0]; R_SPF_NA(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Mar 2020 12:16:28 -0000 Hi! Thanks for your respond. Unfortunately, no. I'm running on ThinkPad P52, which has no com connector installed. No USB serial interface connected. `efi-show -g global -v ConOut` on loader prompt shows global NV,BS,RS ConOut = PciRoot(0,0)/Pci((0x1,oxo)/Pci(0x0,0x0)/AcpiAdr(0x80010100) Moreover, my previous idea didn't help. Neither console="vidconsole" console="eficonsole" console="efi_console" nor console="efi" in /boot/loader.conf works. Defining / undefining TERM_EMU on build are untested. Is there any setting for /boot/loader.conf to control the behavior? Regards. On Mon, 16 Mar 2020 08:26:56 +0200 Toomas Soome wrote: > Hi! > > This means, your system has UART serial device 〓 you can check this from loader prompt: efi-show -g global -v ConOut or with efivar from running system. This w ould trigger efi console driver to use TERM_EMU, which can be turned off by user and doing that would cause ESC sequences to be passed directly to console. Might that be true in your case? > > rgds, > toomas > > > On 15. Mar 2020, at 17:17, Tomoaki AOKI wrote: > > > > Hi. > > > > This broke loader menu display on efifb. At least on amd64. > > ESC sequences without ESC character are shown. > > Key input (at least 1, 2 and enter) works OK. > > I suspect outputs for SIO is sent to efifb and ESC codes are ignored. > > > > Reverting this fixes the issue. > > > > Not tried (not enough time for now as I'm mainly using stable/12), > > but possibly calling efi_cons_probe() from efi_cons_init() would be > > needed, as ome codes are moved from the latter to the former. > > > > > >> Author: tsoome > >> Date: Sat Mar 14 06:36:03 2020 > >> New Revision: 358989 > >> URL: https://svnweb.freebsd.org/changeset/base/358989 > >> > >> Log: > >> loader: add comconsole implementation on top of SIO protocol > >> > >> Provide comconsole on top of SIO for arm platforms (x86 does use bios > > version). > >> > >> Added: > >> head/stand/efi/loader/efiserialio.c (contents, props changed) > >> Modified: > >> head/stand/efi/libefi/efi_console.c > >> head/stand/efi/loader/arch/arm/Makefile.inc > >> head/stand/efi/loader/arch/arm64/Makefile.inc > >> head/stand/efi/loader/conf.c > >> head/stand/efi/loader/main.c > >> > >> Modified: head/stand/efi/libefi/efi_console.c > >> ============================================================================== > >> --- head/stand/efi/libefi/efi_console.c Sat Mar 14 05:57:22 > > 2020 (r358988) > >> +++ head/stand/efi/libefi/efi_console.c > > Sat Mar 14 06:36:03 2020 (r358989) > >> @@ -377,9 +377,22 @@ efi_cons_respond(void *s __unused, const void *buf __u > >> { > >> } > >> > >> +/* > >> + * Set up conin/conout/coninex to make sure we have input ready. > >> + */ > >> static void > >> efi_cons_probe(struct console *cp) > >> { > >> + EFI_STATUS status; > >> + > >> + conout = ST->ConOut; > >> + conin = ST->ConIn; > >> + > >> + status = BS->OpenProtocol(ST->ConsoleInHandle, > > &simple_input_ex_guid, > >> + (void **)&coninex, IH, NULL, > > EFI_OPEN_PROTOCOL_GET_PROTOCOL); > >> + if (status != EFI_SUCCESS) > >> + coninex = NULL; > >> + > >> cp->c_flags |= C_PRESENTIN | C_PRESENTOUT; > >> } > >> > >> @@ -889,15 +902,7 @@ efi_cons_init(int arg) > >> if (conin != NULL) > >> return (0); > >> > >> - conout = ST->ConOut; > >> - conin = ST->ConIn; > >> - > >> conout->EnableCursor(conout, TRUE); > >> - status = BS->OpenProtocol(ST->ConsoleInHandle, > > &simple_input_ex_guid, > >> - (void **)&coninex, IH, NULL, > > EFI_OPEN_PROTOCOL_GET_PROTOCOL); > >> - if (status != EFI_SUCCESS) > >> - coninex = NULL; > >> - > >> if (efi_cons_update_mode()) > >> return (0); > >> > >> > >> Modified: head/stand/efi/loader/arch/arm/Makefile.inc > >> ============================================================================== > >> --- head/stand/efi/loader/arch/arm/Makefile.inc Sat Mar 14 > > 05:57:22 2020 (r358988) > >> +++ head/stand/efi/loader/arch/arm/Makefile.inc Sat Mar 14 06:36:03 > > 2020 (r358989) > >> @@ -1,6 +1,7 @@ > >> # $FreeBSD$ > >> > >> SRCS+= exec.c \ > >> + efiserialio.c \ > >> start.S > >> > >> HAVE_FDT=yes > > > > (Snip) > > > >> @@ -930,7 +936,6 @@ main(int argc, CHAR16 *argv[]) > >> if (!has_kbd && (howto & RB_PROBE)) > >> howto |= RB_SERIAL | RB_MULTIPLE; > >> howto &= ~RB_PROBE; > >> - uhowto = parse_uefi_con_out(); > >> > >> /* > >> * Read additional environment variables from the boot device's > > > > -- > > Tomoaki AOKI > > -- Tomoaki AOKI