From patchwork Tue Jan 10 11:15:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Zijlstra X-Patchwork-Id: 41415 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp2697683wrt; Tue, 10 Jan 2023 03:48:08 -0800 (PST) X-Google-Smtp-Source: AMrXdXuPtIK6VFIP+u2WFuVBmDDmg1CqOugNuzd7Km67NFQ10HB2/+qDvFp1NIuVCzF5B2/6vbKO X-Received: by 2002:a17:902:c10d:b0:186:8568:be7e with SMTP id 13-20020a170902c10d00b001868568be7emr74980545pli.15.1673351287904; Tue, 10 Jan 2023 03:48:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673351287; cv=none; d=google.com; s=arc-20160816; b=s/9hwEUqogKoyUgCdrHjDPdSpD/ZpSzutwPEi4RbW15zmJGK8UEa9snGVfbe3iyXBt SPlOeLu0UcBvapfK9cabfQ78Y9M3A+ETCQz+6CnHIbTuk7tOOWpzoWZ9iOKZR9KoWRxP WXKp9twcHbNIBxwEDCYf3YhpoORxHr+P+VBs4vw89ur7pRgdWAVCNTP+xsAB2h1K+ZM1 07+Qi1V5nq21lNunUpK1+IkNJAneCA7vIBZFYi8uYHCnPHinjr9yNIQadK2zPrZG4OZx MAm1p2IBMP74Ov6kn7uxmrvuqj6Kc+Sjtcttp8UypWm3P51XqJDyrMLh0sRZIizxW369 dJiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:to:from:date:dkim-signature; bh=LE4aoLbLilXnZV5T992f4wACX7I/Nfap/jSdsHEVTyA=; b=dA9wYiO6lKqd0Ypsoh/tbNWcUs9PtfFMQd4l/JnriGtEoZ0aH9tOPRMuZZfgKXEj42 Aqa6/7YXZzglj+6SvdLqvu6uskdWn72fFaeg8mmxwEAKtxT626RMhUX0gCzyn+jCHW/D 0KW4axBcP8kDA+qc0/pfT7rtTK+O4g9M2dlUi1PAorFXzbRvnUw4qWWY+q7RM19i10A8 ng8fNIne4RXBuw9tEaa++1ycKYbo1/nuv1NorZN4M28XO8gXEu5cZi6O8hphpeKuONZZ yFm3mUR39tuIrVCc84+5MqrNxbrn5Tx88zl2DkAMEVcJ24nDGBU9ILSDQhk1Okl5uCPu nNRA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=EHa5TH8P; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x5-20020a170902ec8500b001930d8a834esi11888307plg.303.2023.01.10.03.47.55; Tue, 10 Jan 2023 03:48:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=EHa5TH8P; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232535AbjAJLQk (ORCPT + 99 others); Tue, 10 Jan 2023 06:16:40 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54226 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232978AbjAJLPx (ORCPT ); Tue, 10 Jan 2023 06:15:53 -0500 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8D2DC1401D for ; Tue, 10 Jan 2023 03:15:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Type:MIME-Version:Message-ID: Subject:To:From:Date:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:In-Reply-To:References; bh=LE4aoLbLilXnZV5T992f4wACX7I/Nfap/jSdsHEVTyA=; b=EHa5TH8PV0WlrdxsvCA1d0mUch L1TyiuJlthwlNT79BsPtO/+5wiI5GvlTHBOFfo8h8/tgYGxJO+RipKRZbpGhkkpExvuNjFTr3GQat Z3am1FMzHfTBh6Vfl2uePihVv2cDJmKzSpnIr/G3un6GEz7lax7URU0O4YVVF1FULZ3H8DNu1oGt0 YbCkzY1Qas1Kwi65MLv+1+wAr+5QROUAJJ9ZZUMP8/9P1+BCatJ7mZa8xDlXq8ZUImvkjmLlO/LqW hCByYNY8h3ieuZtvABIl4j++RZNRmYek3bUitZg0q+tYkLyFnCpSvA17jrgE+yjT5Tux4AHjdDg7u x6mwh9xg==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1pFCbN-0036xL-2l; Tue, 10 Jan 2023 11:15:34 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 761E0300033; Tue, 10 Jan 2023 12:15:40 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 519EB2C539AFD; Tue, 10 Jan 2023 12:15:40 +0100 (CET) Date: Tue, 10 Jan 2023 12:15:40 +0100 From: Peter Zijlstra To: x86@kernel.org, linux-kernel@vger.kernel.org Subject: x86/boot: Avoid using Intel mnemonics in AT&T syntax asm Message-ID: MIME-Version: 1.0 Content-Disposition: inline X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1754636000015953714?= X-GMAIL-MSGID: =?utf-8?q?1754636000015953714?= With 'GNU assembler (GNU Binutils for Debian) 2.39.90.20221231' the build now reports: arch/x86/realmode/rm/../../boot/bioscall.S: Assembler messages: arch/x86/realmode/rm/../../boot/bioscall.S:35: Warning: found `movsd'; assuming `movsl' was meant arch/x86/realmode/rm/../../boot/bioscall.S:70: Warning: found `movsd'; assuming `movsl' was meant arch/x86/boot/bioscall.S: Assembler messages: arch/x86/boot/bioscall.S:35: Warning: found `movsd'; assuming `movsl' was meant arch/x86/boot/bioscall.S:70: Warning: found `movsd'; assuming `movsl' was meant Which is due to: PR gas/29525 Note that with the dropped CMPSD and MOVSD Intel Syntax string insn templates taking operands, mixed IsString/non-IsString template groups (with memory operands) cannot occur anymore. With that maybe_adjust_templates() becomes unnecessary (and is hence being removed). More details: https://sourceware.org/bugzilla/show_bug.cgi?id=29525 Fixes: 7a734e7dd93b ("x86, setup: "glove box" BIOS calls -- infrastructure") Signed-off-by: Peter Zijlstra (Intel) Acked-by: Borislav Petkov (AMD) Acked-by: H. Peter Anvin (Intel) --- arch/x86/boot/bioscall.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/arch/x86/boot/bioscall.S +++ b/arch/x86/boot/bioscall.S @@ -32,7 +32,7 @@ movw %dx, %si movw %sp, %di movw $11, %cx - rep; movsd + rep; movsl /* Pop full state from the stack */ popal @@ -67,7 +67,7 @@ jz 4f movw %sp, %si movw $11, %cx - rep; movsd + rep; movsl 4: addw $44, %sp /* Restore state and return */