Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp2868472pxv; Mon, 12 Jul 2021 04:01:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzz/Q2Eh6pPctEeXbWf/BaPtggaOwiLskq2GmFgPEiXa1MICSM1fl8l39xtR5tBvdazdITo X-Received: by 2002:a05:6638:501:: with SMTP id i1mr35594473jar.67.1626087684019; Mon, 12 Jul 2021 04:01:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626087684; cv=none; d=google.com; s=arc-20160816; b=c/YgZTsRyCWiGqOiyqsL2gYPcreH6Um1Ic0MRsVuZr8mv67/3dLlUPqekAwIZ/N0T0 M6tQm/jQah5MIDPuZYMmVs4YuYEAto0BYvkjVY94uiU25kAMj1MVVwOUtGmXO6FbK8kP YD6ParBnQsZh65+hqcIWMPYZgj4Jns6WxD7valBpBQRCMAbGTrjFcgZGdydw7Y7e0/R/ LrEli0/8SQlW3Guc34mESVNklpVHaVBtQBwdiWtI7O0ixtzw6J3pjnblI/JmEnOxCuva PZrKtGcmK09oBPQz2TcrXBVLXcVHiuVq1eU+L5QFqu322YhN7sRvVuN2aLoB4XFxxi5c 9pbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=9QvgAnoI2kPhaZ/+n+bQkw4ACvsVb9pav6Lb/tlx3m8=; b=GwGXzsPdsW6IhVUatoY0eGDaB5EFbMKuadCXr8REkXqvNAF4wDasHGgo2+vvTyo9Bb 04k9a6jM/GgHnXYxgHd/btNg208EOlcqdo4n7AGl53xvjXb0cC0UcWFGazvIjc8qZrxr qhjpKXRrLwVwW4igzvAEVcVORWueaaQIS0nVRDutaNneca/2TL8phita+HCmRsxmoq3W /adP8aMKtOrEM5lU4T037ZLK+z8WVgUHkAKETZ3iAcgYEu5yh43C2aWohXPy74l5Su/I hNXNhg3z4/9jL90s9m2mgcpjxX24+gs9ko693lySYg0Dx4aVIuI41c7aUf55GPZ6SFT9 4C1w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=nS5X1ma7; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u11si21308028jau.121.2021.07.12.04.01.11; Mon, 12 Jul 2021 04:01:24 -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; dkim=pass header.i=@google.com header.s=20161025 header.b=nS5X1ma7; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237974AbhGLKGN (ORCPT + 99 others); Mon, 12 Jul 2021 06:06:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50472 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237894AbhGLKGI (ORCPT ); Mon, 12 Jul 2021 06:06:08 -0400 Received: from mail-ot1-x333.google.com (mail-ot1-x333.google.com [IPv6:2607:f8b0:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7289DC061788 for ; Mon, 12 Jul 2021 03:03:20 -0700 (PDT) Received: by mail-ot1-x333.google.com with SMTP id f93-20020a9d03e60000b02904b1f1d7c5f4so17515543otf.9 for ; Mon, 12 Jul 2021 03:03:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=9QvgAnoI2kPhaZ/+n+bQkw4ACvsVb9pav6Lb/tlx3m8=; b=nS5X1ma78tZUkAIXCfDp3a8xVJt/VvHEYep44ptY71kKl0YEHx+oBUtr6Zz1azRAr/ CcLqtFi3wFbu+j+TpshqXoh8MvviI8LJOus0njsV6RBuLthgADwE6tJ00hnZoc6rvkS4 nPT/pYipkn8urjIdRVIJcTp1fH65fctXLbFymE/KcAYXffQgdC4f2K9HHkeaFx5cAGHM CV9eVUdu+7ksEtwSsf6/Z12oH3ktaNVFK+08Et10h9vLBZU6OECiIHOsWZgKc2jH9ZUY sHvL34U9IZQ0xFndB3dSItRjerjJJxdRYEpys9yjeyYH8l5A5skJXsVC9ceR3cFfJbx3 nVtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=9QvgAnoI2kPhaZ/+n+bQkw4ACvsVb9pav6Lb/tlx3m8=; b=H6a1QG2PkLjhdf31UFJ7fZ/zqqTM/CsXk6zZSYogYa2e4N/Oll8Nfp5/1S+foiqXDW ocbS1hCzb54gwsx3DszctmzNk8AqRZfuqfvYgZngmJocnH4yb7oIvnnkaq0mKe1kAltV xM+SWAIDTdaWLbsw5yknNzrwA7epNA6rJc4wHApRsjvu6cXqfRncxNI8vzv0aCuer/FT JS9RH9Uv7E4f38SwuHR0cjln8aPcyYhER1YYiqw8LjdfqXjLU7stMzImC7DaIBWilxIW UuSkui1veiM4FLRyjCkxuSHuN8NWrjjn7PVNBc84pMWSpQ1t0lvUXnahNT1Jm1+gG/Xm uNHw== X-Gm-Message-State: AOAM531a6HUQxTjVLxGk+u/VtRH8RNemFqIBNNKWNDDRCfayrWqMqHjk YGhsmr4RtgEYuGN9ipRHICuLh05AlBdi20y72JuQeg== X-Received: by 2002:a9d:d04:: with SMTP id 4mr41889857oti.251.1626084199532; Mon, 12 Jul 2021 03:03:19 -0700 (PDT) MIME-Version: 1.0 References: <20210708144411.25467-1-mark.rutland@arm.com> <20210712095832.GA27643@willie-the-truck> In-Reply-To: <20210712095832.GA27643@willie-the-truck> From: Marco Elver Date: Mon, 12 Jul 2021 12:03:06 +0200 Message-ID: Subject: Re: [PATCH] kasan: fix build for CONFIG_KASAN_HW_TAGS To: Will Deacon Cc: Andrey Konovalov , Mark Rutland , Sam Tebbs , Robin Murphy , Andrew Morton , Linux ARM , LKML , Catalin Marinas , Dmitry Vyukov , Alexander Potapenko , Andrey Ryabinin Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 12 Jul 2021 at 11:58, Will Deacon wrote: > On Sat, Jul 10, 2021 at 09:16:14PM +0200, Andrey Konovalov wrote: > > On Thu, Jul 8, 2021 at 4:44 PM Mark Rutland wrote: > > > > > > When CONFIG_KASAN_HW_TAGS is selected, uses _RET_IP_, > > > but doesn't explicitly include where this is defined. > > > > > > We used to get this via a transitive include, but since commit: > > > > > > f39650de687e3576 ("kernel.h: split out panic and oops helpers") > > > > > > ... this is no longer the case, and so we get a build failure: > > > > > > | CC arch/arm64/mm/kasan_init.o > > > | In file included from arch/arm64/mm/kasan_init.c:10: > > > | ./include/linux/kasan.h: In function 'kasan_slab_free': > > > | ./include/linux/kasan.h:211:39: error: '_RET_IP_' undeclared (first use in this function) > > > | 211 | return __kasan_slab_free(s, object, _RET_IP_, init); > > > | | ^~~~~~~~ > > > | ./include/linux/kasan.h:211:39: note: each undeclared identifier is reported only once for each function it appears in > > > | ./include/linux/kasan.h: In function 'kasan_kfree_large': > > > | ./include/linux/kasan.h:219:28: error: '_RET_IP_' undeclared (first use in this function) > > > | 219 | __kasan_kfree_large(ptr, _RET_IP_); > > > | | ^~~~~~~~ > > > | ./include/linux/kasan.h: In function 'kasan_slab_free_mempool': > > > | ./include/linux/kasan.h:226:34: error: '_RET_IP_' undeclared (first use in this function) > > > | 226 | __kasan_slab_free_mempool(ptr, _RET_IP_); > > > | | ^~~~~~~~ > > > | ./include/linux/kasan.h: In function 'kasan_check_byte': > > > | ./include/linux/kasan.h:277:35: error: '_RET_IP_' undeclared (first use in this function) > > > | 277 | return __kasan_check_byte(addr, _RET_IP_); > > > | | ^~~~~~~~ > > > > > > Fix this by including explicitly. > > > > Hi Mark, > > > > Marco already sent a fix for this. It should be in the mm tree. > > (Although the link to it in the Andrew's notification email doesn't > > work. But they rarely do :) > > Do you have a link to the patch? I couldn't spot it in linux-next. https://lkml.kernel.org/r/20210705072716.2125074-1-elver@google.com ( https://lore.kernel.org/mm-commits/20210706204723.O1wZ2%25akpm@linux-foundation.org/ ) Looks like latest -mm is not yet reflected in -next.