Received: by 2002:ab2:6a05:0:b0:1f8:1780:a4ed with SMTP id w5csp2033358lqo; Mon, 13 May 2024 06:13:08 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVMVg6VrHyZz/EPLA0dTI7lcO6Td1EygEaXa/o51IMlj/ZbZFOOKgcyX/ciu7HvtYl2WLtIiSsIWu6Ci5l0hCBNyAvjOsg7mz4Hg5p7BQ== X-Google-Smtp-Source: AGHT+IFZi0Hd0vsmY8JauOcanEiBgMVjnkHLtHkdUNDbW04kvXu4MlD1w3t15wt3hJSKyQdsqyWa X-Received: by 2002:a17:90a:5502:b0:2ac:40c8:1ed3 with SMTP id 98e67ed59e1d1-2b6cc342957mr7890321a91.5.1715605988667; Mon, 13 May 2024 06:13:08 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715605988; cv=pass; d=google.com; s=arc-20160816; b=0Lbfqglt/FDjvxVYmMYFngj9LvPiw2LOw8KYER5zaZaYs+K9a+zp6d+TPQbZIZ8qqD RtqTEAhX/y+MYmzb8xnVSHQTBwPmGC3U/c9iTNFCpyJ9iAjD0zRUk9FReOAY0pCb71uy d5SOLAj2NHm2Dr8IHfBNFybJ78Wtn+RjPuTXBFset9q4JLF803pBuuqlkAlCyvlj/8BJ g65XaLjt8VnDYlaOLv1aicNTLLJqaTsQQatbnBQcHZtuY4YDFl5zhKv1jNVLjAZ9RKhc vOa1gMj1wtNhe44Nt2kII/yK2eMD2HxHGEC2P2ZBBD+5Jg2sViEkWSmFMTWldf60pDDF m5Tg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=sdYuaBFPSp+zIyDKL2Lix71i/tZ+jK3fWyV6sL7/xTc=; fh=hSWDlW6wxvNNfqI5QDYd/EzyOvOcfWglhIkJzsBjtf0=; b=tOPzB6rXKqkbZuQOC3IPTkLoIt+ZOSKNP0HRWdHloIJbYGLQ3dmyK+vykmdcxN0RKk QH1wZSreHKSmkHBD7w16A0J8eOyX/mq9WSHajTfuewctT4GN4yFEa9uA8z+lbvFp4F3u Z7OlaA4wd4Tx8lT8OiUACqZvsoJ+l9hHW9RS7M3JA2MDDw4cCX1cIFyCwbLGdAw4Gw38 En+gc3cru7s7jDjGeWCBOx4mbS6LbocToudTJAHBD/YkvcC2oEHrKNv+CEfny+WrXu4Y 2ZOXOtFIJsb1bjuDlkm30bLcUyVOoWTNUUmqVNQGYkvglq4IqSLgdWC8bEGIaKVA+Ydq 43Bw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huaweicloud.com); spf=pass (google.com: domain of linux-kernel+bounces-177611-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-177611-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2b67168a410si9304261a91.170.2024.05.13.06.13.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 May 2024 06:13:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-177611-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huaweicloud.com); spf=pass (google.com: domain of linux-kernel+bounces-177611-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-177611-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id DDA53B236EA for ; Mon, 13 May 2024 13:11:59 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EC3BB1514E9; Mon, 13 May 2024 13:11:51 +0000 (UTC) Received: from frasgout12.his.huawei.com (frasgout12.his.huawei.com [14.137.139.154]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0E0A81509BA; Mon, 13 May 2024 13:11:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=14.137.139.154 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715605911; cv=none; b=pVNXQP1pydHIA/DYo7rbDGL8Mp0qE9iuvOx1xv4ZyQhLwPnv4xbq2TcfYFjTq4Qaq7NSiW/g1POP/aVBmrYxUDQx51tEa3iFIbP8qGiKW4JQXLWiyjt9yyKicH+PPt6n9uC4GDBuWno6YhZIYUtKqqeSXVNsJqYKt7vl78vIhqA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715605911; c=relaxed/simple; bh=X65G6pvRWIYGrSvOefH5o342aNX3aFIt2fxYbtFpp9I=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=KJcjONIEvss1fdyoIkDLdovPJbwOno5KIW8pCqKZk6GNUcvBxulz2srScEm+4uafH7qMmDFU5UJ68Trcc+s/+2QPcC7JE5Q+QumH/dRkukUc4FSrww9jlYMrIFtlMpAbddXNMA2lNl2NWbfOnuA+zNtXDQIphujHlNvQRCK/OoE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com; spf=pass smtp.mailfrom=huaweicloud.com; arc=none smtp.client-ip=14.137.139.154 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=huaweicloud.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huaweicloud.com Received: from mail.maildlp.com (unknown [172.18.186.29]) by frasgout12.his.huawei.com (SkyGuard) with ESMTP id 4VdK8D3GkWz9v7JW; Mon, 13 May 2024 20:50:04 +0800 (CST) Received: from mail02.huawei.com (unknown [7.182.16.27]) by mail.maildlp.com (Postfix) with ESMTP id CC88B140428; Mon, 13 May 2024 21:11:37 +0800 (CST) Received: from huaweicloud.com (unknown [10.204.63.22]) by APP2 (Coremail) with SMTP id GxC2BwC38SV9EUJmnBMTCA--.48417S2; Mon, 13 May 2024 14:11:37 +0100 (CET) From: Roberto Sassu To: richard@nod.at, anton.ivanov@cambridgegreys.com, johannes@sipsolutions.net, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, hpa@zytor.com Cc: x86@kernel.org, linux-um@lists.infradead.org, linux-kernel@vger.kernel.org, zohar@linux.ibm.com, linux-integrity@vger.kernel.org, keescook@chromium.org, Roberto Sassu Subject: [PATCH v2] x86: um: vdso: Disable UBSAN instrumentation Date: Mon, 13 May 2024 15:10:24 +0200 Message-Id: <20240513131024.1309073-1-roberto.sassu@huaweicloud.com> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID:GxC2BwC38SV9EUJmnBMTCA--.48417S2 X-Coremail-Antispam: 1UD129KBjvdXoW7JFy5AF45XFykAF13ArWxtFb_yoWDZrbEkF WIqFZ3G34a9397A3y5GFWYvF97Cwn7Arn3u3y3uF13tay5Xas7GFsrG343Xw4rJF9F9FWU WF93ZFWUXw4jkjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUb28YFVCjjxCrM7AC8VAFwI0_Gr0_Xr1l1xkIjI8I6I8E6xAIw20E Y4v20xvaj40_Wr0E3s1l1IIY67AEw4v_Jr0_Jr4l8cAvFVAK0II2c7xJM28CjxkF64kEwV A0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVWUJVWUCwA2z4x0Y4vE2Ix0cI8IcVCY1x02 67AKxVW8JVWxJwA2z4x0Y4vEx4A2jsIE14v26r4j6F4UM28EF7xvwVC2z280aVCY1x0267 AKxVW8JVW8Jr1le2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2 j2WlYx0E2Ix0cI8IcVAFwI0_JrI_JrylYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7x kEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwACI402YVCY1x02628vn2kIc2xKxwCF04k20xvY 0x0EwIxGrwCFx2IqxVCFs4IE7xkEbVWUJVW8JwC20s026c02F40E14v26r1j6r18MI8I3I 0E7480Y4vE14v26r106r1rMI8E67AF67kF1VAFwI0_Jw0_GFylIxkGc2Ij64vIr41lIxAI cVC0I7IYx2IY67AKxVWUJVWUCwCI42IY6xIIjxv20xvEc7CjxVAFwI0_Gr0_Cr1lIxAIcV CF04k26cxKx2IYs7xG6rWUJVWrZr1UMIIF0xvEx4A2jsIE14v26r1j6r4UMIIF0xvEx4A2 jsIEc7CjxVAFwI0_Gr0_Gr1UYxBIdaVFxhVjvjDU0xZFpf9x07UQzVbUUUUU= X-CM-SenderInfo: purev21wro2thvvxqx5xdzvxpfor3voofrz/1tbiAgACBF1jj5lAMQADse From: Roberto Sassu The UBSAN instrumentation cannot work in the vDSO since it is executing in userspace, so disable it in the Makefile. Fixes the build failures such as: CALL scripts/checksyscalls.sh VDSO arch/x86/um/vdso/vdso.so.dbg arch/x86/um/vdso/vdso.so.dbg: undefined symbols found Signed-off-by: Roberto Sassu --- arch/x86/um/vdso/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/x86/um/vdso/Makefile b/arch/x86/um/vdso/Makefile index b86d634730b2..ca79c0de582e 100644 --- a/arch/x86/um/vdso/Makefile +++ b/arch/x86/um/vdso/Makefile @@ -3,8 +3,10 @@ # Building vDSO images for x86. # -# do not instrument on vdso because KASAN is not compatible with user mode +# do not instrument on vdso because KASAN/UBSAN are not compatible with user +# mode KASAN_SANITIZE := n +UBSAN_SANITIZE := n # Prevents link failures: __sanitizer_cov_trace_pc() is not linked in. KCOV_INSTRUMENT := n -- 2.34.1