From patchwork Tue May 9 14:57:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 91632 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2977529vqo; Tue, 9 May 2023 08:35:22 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5/bLXe63mRpIUzF49qiGQ72G3upO9UhkBcA9FB+zUdj/2uDcYNRL4zmIGbsGk4cQ/yvh33 X-Received: by 2002:a17:90a:fa92:b0:24e:225b:c1a1 with SMTP id cu18-20020a17090afa9200b0024e225bc1a1mr14625381pjb.32.1683646522050; Tue, 09 May 2023 08:35:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683646522; cv=none; d=google.com; s=arc-20160816; b=dhr7yDzcGGtXVKejvsuKY4HqGrl5oaGKUmOmfLN9Ysvoy1IhZJpa+it65JfJhWITEz tyfkZ3t1YO0Nti9IKrYqN5zYTU9jmhsPJ4Uz8NVC0ctA4PecT1sXV34eurlogEOLo3c+ 4J8sF0bYlc+Amvw/k+48ASlYqdLN7xcpm7Bc7UAq1Ud0IzOnbqWkMu8hGjeM2QVLvtR9 svO7o5pxVYOD8WkqAVG+Nh9CNQxgSDnle00+xje8ekl8P7gusbiux6ZPe7a+DDcDmd5+ 1dSjaWoKsxWmjJK1HyG2ThONYhefTvjN+W3q2r5JZW0EOi4J6GslM524l62NPOljOA2S uzTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=ARJHbR0XP6hsc9u2qnJXZgeZBpff6BaM65APFiCJYVo=; b=onKHgtGzvbZnn4L9wGfu3yyHk0fWMgFma2YhoBmCDlbahLZRLiqlvpPFo7sD70kNPx mh+TFDUtooPtTXeV1rQrGrJoLjQQhMZLanC+itKh/DIGGTIa3JG+4sXjQ4KJ0S2vHYDp dKpwCAEDTzPDIzIU1TgFaWui2FNcpmXkMJiKWNOE1lNdp2r1xcIVUHjGDGVOkFTe7fCZ KAh3DEBTGSIoeivE/Aop3rAQiMdvJS6l1xVPvtvEOVieKOkqC7t8mPJJ8FB5drIVm2MY dRo5gBv3n5kZOISfJ5AqHiIbqLdQW7t4w3YAb0tHRkJ0PL9D5pCqKmnF26uk+T4MBCBg 7MIQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dFY7jYTx; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id mz7-20020a17090b378700b0024e0eec665fsi15542675pjb.73.2023.05.09.08.35.06; Tue, 09 May 2023 08:35:22 -0700 (PDT) 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=@kernel.org header.s=k20201202 header.b=dFY7jYTx; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235972AbjEIO5s (ORCPT + 99 others); Tue, 9 May 2023 10:57:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229572AbjEIO5q (ORCPT ); Tue, 9 May 2023 10:57:46 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C68C835A3 for ; Tue, 9 May 2023 07:57:45 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 52F4D64702 for ; Tue, 9 May 2023 14:57:45 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1E47EC433D2; Tue, 9 May 2023 14:57:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1683644264; bh=8kpzffon4c7U76Nx4fRs+z+9nZ2f5EaWU4V5dVQ6n0Q=; h=From:To:Cc:Subject:Date:From; b=dFY7jYTxkQy1d+Wx7GQyxgjoLx5KR+hJo7zg/bSri2X5OiKl5IW9MWmOaTrXNBYIg 0Kc4YMwQkOxlpcfph8P0/BWy2Js9N5c9yClZcW5PyxEIAzhUmQqyW9U8n2LFtlglSI J0v3yNvOkhWEZbkoTUh6LjU3h5S4R4EeZbWaaXH1ZUQkmUfNwFh4eScSC98tFq6hbl REMLiZOS3AwgVri27469BI6aS9fVQFt2GrzUkERQnR7mu6VU7iHuijefB02PHBKlXZ k78UDiPbmlh0nJUzcLgK1fSmyrj1LeA1wa18MLmTANs+H+vNhRHhXiS6GUUh7gSQOK Ex2cruxneCCfg== From: Arnd Bergmann To: Andrey Ryabinin , Andrew Morton Cc: Arnd Bergmann , Alexander Potapenko , Andrey Konovalov , Dmitry Vyukov , Vincenzo Frascino , Marco Elver , kasan-dev@googlegroups.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/2] kasan: add kasan_tag_mismatch prototype Date: Tue, 9 May 2023 16:57:20 +0200 Message-Id: <20230509145735.9263-1-arnd@kernel.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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?1765431335671307813?= X-GMAIL-MSGID: =?utf-8?q?1765431335671307813?= From: Arnd Bergmann The kasan sw-tags implementation contains one function that is only called from assembler and has no prototype in a header. This causes a W=1 warning: mm/kasan/sw_tags.c:171:6: warning: no previous prototype for 'kasan_tag_mismatch' [-Wmissing-prototypes] 171 | void kasan_tag_mismatch(unsigned long addr, unsigned long access_info, Add a prototype in the local header to get a clean build. Signed-off-by: Arnd Bergmann --- mm/kasan/kasan.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mm/kasan/kasan.h b/mm/kasan/kasan.h index f5e4f5f2ba20..cd846ca34f44 100644 --- a/mm/kasan/kasan.h +++ b/mm/kasan/kasan.h @@ -646,4 +646,7 @@ void *__hwasan_memset(void *addr, int c, size_t len); void *__hwasan_memmove(void *dest, const void *src, size_t len); void *__hwasan_memcpy(void *dest, const void *src, size_t len); +void kasan_tag_mismatch(unsigned long addr, unsigned long access_info, + unsigned long ret_ip); + #endif /* __MM_KASAN_KASAN_H */