Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp1310216pxy; Fri, 23 Apr 2021 05:23:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzCqGgVznv7xz/bZUIyMhhRnxuH1LelMYi7+K9LKnmiw9wvZHEA2gVL/eEnF9pZm0Aw3546 X-Received: by 2002:a05:6402:214:: with SMTP id t20mr4186204edv.229.1619180636818; Fri, 23 Apr 2021 05:23:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619180636; cv=none; d=google.com; s=arc-20160816; b=c2dLm7pveGA+3BYOHQZUdRITS891GnJ9CnU9C7oGlQrVwbSbBqoJOa/1qpQQxiTDBc U//w8wcrl0H448wkzef1CuqoGL8i3xspysWobgqrdkQuWhq0T538Or6GGmAEmL8/1BDu IlgPxosfjgrmJ0uQf8Z5EmFxI610dHe3QdZOl27/ahYDy/X3KcDO34veVxD6SDOOFHMo z79iZvXx9m5mLWLq6MN6Jtz7ojrdSdHEaLZBTksEVlf0bGOWz/+9dFq6+DMijKTFcigz 4YeeoMl47Gci3HAIZO0b3ycXe4VqGevRnhIR1w+YKzE5uku/LVYAR27I2b3dv4szE2Em xlzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=p1WjU3pGmLtVjU0FMASa3YYlXUtrtZFnrdYwTgmC7Ug=; b=Lkz11vg0pheSNW4bgyM7JHSoScUNRnDvLD3Bal4NCZMA2BBRKxGXQd3QrfG8KVFemC xu+Ust9lXhGBakGmcQ0vH8BDeWeiS3ho7OvwsmAn2vHi4E8zcrDOgmnG+P1EQTanHxFG 9F1/Mq0aIszfbV3zwepBgI8bHWs3+IG0KFEWR68MLArjTSvh8XPpMLB+Hb5I+KxAYdC8 Ne0/ZBr2rgR6eRQcgK+L8/Jj/nQxFQjQxW8Q02iAZSaoednim2Nx7o25JZGUH+DurNDU NOn5/Rw3JhJowo+24yUcKFpybOXVgdb+IeTq5HSVIapZIs/LvsaSD91lamttuXzhBLPx aR5Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d14si5602684edk.117.2021.04.23.05.23.33; Fri, 23 Apr 2021 05:23:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242273AbhDWMXL (ORCPT + 99 others); Fri, 23 Apr 2021 08:23:11 -0400 Received: from elvis.franken.de ([193.175.24.41]:38486 "EHLO elvis.franken.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229479AbhDWMXK (ORCPT ); Fri, 23 Apr 2021 08:23:10 -0400 Received: from uucp (helo=alpha) by elvis.franken.de with local-bsmtp (Exim 3.36 #1) id 1lZupM-00019R-03; Fri, 23 Apr 2021 14:22:32 +0200 Received: by alpha.franken.de (Postfix, from userid 1000) id D1468C0B3B; Fri, 23 Apr 2021 13:51:40 +0200 (CEST) Date: Fri, 23 Apr 2021 13:51:40 +0200 From: Thomas Bogendoerfer To: Sudip Mukherjee Cc: linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, Romain Naour Subject: Re: [PATCH v4] mips: Do not include hi and lo in clobber list for R6 Message-ID: <20210423115140.GD8582@alpha.franken.de> References: <20210420211210.702980-1-sudipm.mukherjee@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20210420211210.702980-1-sudipm.mukherjee@gmail.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 20, 2021 at 10:12:10PM +0100, Sudip Mukherjee wrote: > From: Romain Naour > > >From [1] > "GCC 10 (PR 91233) won't silently allow registers that are not > architecturally available to be present in the clobber list anymore, > resulting in build failure for mips*r6 targets in form of: > ... > .../sysdep.h:146:2: error: the register ‘lo’ cannot be clobbered in ‘asm’ for the current target > 146 | __asm__ volatile ( \ > | ^~~~~~~ > > This is because base R6 ISA doesn't define hi and lo registers w/o DSP > extension. This patch provides the alternative clobber list for r6 targets > that won't include those registers." > > Since kernel 5.4 and mips support for generic vDSO [2], the kernel fail to > build for mips r6 cpus with gcc 10 for the same reason as glibc. > > [1] https://sourceware.org/git/?p=glibc.git;a=commit;h=020b2a97bb15f807c0482f0faee2184ed05bcad8 > [2] '24640f233b46 ("mips: Add support for generic vDSO")' > > Signed-off-by: Romain Naour > Signed-off-by: Sudip Mukherjee > --- > > v4: [sudip] added macro VDSO_SYSCALL_CLOBBERS and fix checkpatch errors with commit message. > v3 Avoid duplicate code (Maciej W. Rozycki) > v2 use MIPS_ISA_REV instead of __mips_isa_rev (Alexander Lobakin) > > I have reused the original patch by Romain and have retained his s-o-b > and author name as he is the original author of this patch. I have just > added the macro. Build tested with gcc-10.3.1 and gcc-9.3.0. > > arch/mips/include/asm/vdso/gettimeofday.h | 26 ++++++++++++++++++----- > 1 file changed, 21 insertions(+), 5 deletions(-) applied to mips-next. Thomas. -- Crap can work. Given enough thrust pigs will fly, but it's not necessarily a good idea. [ RFC1925, 2.3 ]