Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp626091pxu; Thu, 7 Jan 2021 13:52:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJwgQvs+mzgf+3+7rdBi4Z9Dz9m/iuezbR0nnEOUyIDd7l34uzKFYAE7vAkBogDAoC1a5Mur X-Received: by 2002:a17:907:1182:: with SMTP id uz2mr619561ejb.183.1610056358348; Thu, 07 Jan 2021 13:52:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610056358; cv=none; d=google.com; s=arc-20160816; b=vO97Lt18WC7E0feVIKW5VjRkQFsak0fmnghB2qZOZJvzKkyG8bcc0veWymf6504efI H4sBgV7Gafc6Wi7WTLuuqpPbsd5PuIMcMwhdUkVhcOa8VLWh73lt/2C+i+VtAClXP8SY 9hQ5l4mF8AFWgbqgdzwDgV0ew3uzhUZbbAkrnarykjsXUw+LKt/kNraaWrIgoliifZen xOOqAXIdQD+pkc1LJHgT0nfV/bPsJ4wxU/n0tFT7po+SxcZhABpuip2s3y1QRD3ICom3 XPXg6JtH16SxQa9ojByamUbJUYUD8iqjTqp7zmtH1ggyhUeIMxhEzGsZPcPpOti0jqgC wWUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=UTTy0WEJkMO0H2XumjV4y9QZB0fFUlY6gs6jKFnkPCs=; b=WXtdDAQP2yDQ3r3kAa12ayRA4c8IigT+THB8PFCguLL6xCEx9qnKbmEoGw7zaG9bci FmJbP1F7pzbuZQWOKbmEWi6bhdIGhagV1NwShbo9FHccbCzMBngwYhxoNZR42rg5IeGD CTXQJ7MMpcVtM55XejsL3/vMWeSzD05w5fwyt2hWREd5QRkz4oqHlo343qYcg9LRBDn3 0Vtdx7osKXXVYQoDbIoYH/XRhn81zmqkLmKIpLv3BRdsHBLiwi0EWyKRqjo25Ubh/J97 oXIEMnwFIMvAkj6xYKE4xu1qepWwTFfVVgjV6YNllZZsPm4Wp2dmPy0q4OuslN4omq4R gt0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=UgSAXxRc; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ca23si869532edb.262.2021.01.07.13.52.15; Thu, 07 Jan 2021 13:52:38 -0800 (PST) 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; dkim=pass header.i=@chromium.org header.s=google header.b=UgSAXxRc; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728075AbhAGVuE (ORCPT + 99 others); Thu, 7 Jan 2021 16:50:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40718 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728024AbhAGVuD (ORCPT ); Thu, 7 Jan 2021 16:50:03 -0500 Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8E24EC0612F6 for ; Thu, 7 Jan 2021 13:49:23 -0800 (PST) Received: by mail-pj1-x1036.google.com with SMTP id j13so4875071pjz.3 for ; Thu, 07 Jan 2021 13:49:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=UTTy0WEJkMO0H2XumjV4y9QZB0fFUlY6gs6jKFnkPCs=; b=UgSAXxRcqgWDyOOtEvj9pyh3d/6tivv5BUeekYoFX9DpvpDSdK5CDcjpGyaOlBwMFK nSzen8slLXit0KPM6i7GnXZXh1ZjrfZKfAmcyvgw/vV5upbdruwILeYp8xm533pQMB2c 06qd9EgZCg7V3/GYV0mSRPxfP68Bxoj4ACUx0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=UTTy0WEJkMO0H2XumjV4y9QZB0fFUlY6gs6jKFnkPCs=; b=ruZCHF7qssQYBB/DpG8fWyKbTqdHSEIBE+QrGSatxbKoRVEGxlmiBGZIbBspV/wIYf Ou+Mb8gMpNUDnNmbutO0a3TxCrv4hwb5QAWX1S6z3nBMJcqc5KHgCTk36j9HjVHjpm4N ZhKGrfvqa/xYYA1jBPOXzIwOatncyt1Og4vxr9Zov/vBnMTqxPKEJxe0h0+vAEIW/d5r RufumShI8Z3kE6pxWGLuJXUG7SgNoZwx/5r6xH/l3yeZo03XybEAyi5BiOVl1MIYNX8J 4CziLl8/X4xeb577yA8CmLHAxzTx1h7pWBwTm9euPI+s0UT6Hi+xOZ1dh7Nle2G/iSSi 9pvg== X-Gm-Message-State: AOAM532qqfq7iGPAPqqFpDsmTZ6WxW0lK6OUbP1BMfKKICg8wSeHGG7P ZYD3fF/9RusPEeCYWtmama5WHw== X-Received: by 2002:a17:90a:67ce:: with SMTP id g14mr473825pjm.33.1610056163137; Thu, 07 Jan 2021 13:49:23 -0800 (PST) Received: from www.outflux.net (smtp.outflux.net. [198.145.64.163]) by smtp.gmail.com with ESMTPSA id p187sm6618865pfp.60.2021.01.07.13.49.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Jan 2021 13:49:22 -0800 (PST) Date: Thu, 7 Jan 2021 13:49:21 -0800 From: Kees Cook To: Alexander Lobakin Cc: Thomas Bogendoerfer , Arnd Bergmann , Nathan Chancellor , Nick Desaulniers , Fangrui Song , Huacai Chen , Pei Huang , Jiaxun Yang , Sami Tolvanen , Ingo Molnar , Ralf Baechle , Corey Minyard , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, stable@vger.kernel.org, clang-built-linux@googlegroups.com Subject: Re: [PATCH v4 mips-next 5/7] MIPS: vmlinux.lds.S: explicitly declare .got table Message-ID: <202101071349.260EC64@keescook> References: <20210107123331.354075-1-alobakin@pm.me> <20210107132010.463129-1-alobakin@pm.me> <20210107132010.463129-2-alobakin@pm.me> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210107132010.463129-2-alobakin@pm.me> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 07, 2021 at 01:20:49PM +0000, Alexander Lobakin wrote: > LLVM stack generates GOT table when building the kernel: > > ld.lld: warning: :(.got) is being placed in '.got' > > According to the debug assertions, it's not zero-sized and thus > can't be handled the same way as .rel.dyn (like it's done for x86). > Use the ARM/ARM64 path here and place it at the end of .text section. > > Reported-by: Nathan Chancellor > Signed-off-by: Alexander Lobakin Reviewed-by: Kees Cook -- Kees Cook