Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp3123524rwb; Sun, 30 Jul 2023 00:12:28 -0700 (PDT) X-Google-Smtp-Source: APBJJlH6cXd22MHoMRaHZyPLjx4TVz7EpUhP0RT0FBlNuvxjaLK8KfPsbG3gvU8jt4zIF/uryig9 X-Received: by 2002:a05:6a20:938f:b0:131:1943:c858 with SMTP id x15-20020a056a20938f00b001311943c858mr7175104pzh.14.1690701147707; Sun, 30 Jul 2023 00:12:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690701147; cv=none; d=google.com; s=arc-20160816; b=IdDOrDfC+Ml1jk27hm4fQ4sw8KO0YGOQbfzLO4Rbd/dzUjk3Rcp/4W4eiPSyNe8rF5 edI8ELhnrwZeyX3GLPczYlfTqd+auK/A2qR2lSekP3UD6rV0hgoOxjRYsuZ/dUzL4rAz 6ZjKC77gFMhd1On1k7UDtEKJXpbJfZiM47y7l4iBQ4X1+lB1K2uJ+QFPcb2GqJU2RSTJ 82WTI4zPeqkKbPHrfwlwuw2LGpRwD4uMJt512W1SYhg3RoBZUiwgU2H17gfGYN9KKIBc 5LTuPTOId01JdlpyCbY756rnnNKqQRUGQQblYAfBuVtW3Zr9nqYSqfn9Wj4WTQEDc0FX B9xA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:ui-outboundreport:content-transfer-encoding :mime-version:user-agent:references:in-reply-to:date:cc:to:from :subject:message-id:dkim-signature; bh=xKUtly/uoEbJTqoq5S8s8l6F6bHBKHIp7prc4cPJz+4=; fh=MI111mJvlFgDDZD/u5HKolrfyzeutLzSvsioUFBZpXs=; b=o2vnOfAzKq/rpuyn37WxAvtD8uU7VHBrDK73wIID7Z9CEKuYm2NeNeHjg8FnKbRF4k ErY/lcbVvjQYETIlipy2R4KmmCsBD2KsAuHJ0mDwIkPd/B09a5xVMCs/AeLPFoVbpLl6 aBITqYSRAiayuDD5XMXhT/RgF0Uf5S2fBNzubuLCrCE3bJxEsZMQld1bAqzvQVksuVr0 FcC3sosY1k9jD9nO+Qno7sfOuQ33lzkVmXrvJaWk7xuireKOa/44KP6jmc4EAOhDd9dN WG+RA966qtXRjVlODjg2+/etJadaUhPFyrXQ7y2hmulvQiLBd2mPbSRDE4p564j+HXwg rLkw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.de header.s=s31663417 header.b=hGp8czQD; 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=gmx.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q12-20020a63e94c000000b0054fd670e85fsi5440924pgj.233.2023.07.30.00.12.15; Sun, 30 Jul 2023 00:12:27 -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=@gmx.de header.s=s31663417 header.b=hGp8czQD; 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=gmx.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229577AbjG3Fyv (ORCPT + 99 others); Sun, 30 Jul 2023 01:54:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44556 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229379AbjG3Fyt (ORCPT ); Sun, 30 Jul 2023 01:54:49 -0400 Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B87AA10E4 for ; Sat, 29 Jul 2023 22:54:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1690696481; x=1691301281; i=efault@gmx.de; bh=+hma6MdQ9WjJtS6MXE0P8zhJzFVSGULWBJ7mYhsoyUo=; h=X-UI-Sender-Class:Subject:From:To:Cc:Date:In-Reply-To:References; b=hGp8czQDDApUhXnd2s1LjQ7NdPHfSikuHyQaUEBbHCl9wEnOjbSE4y+hd3q07mlxsP+ozI+ h4Ayokq0EYdhbovtVs5kczgg1wW7Ako0AynsHEYI4pxqg64vDRzDYkyuStfGZafPYnPtlITQK 71vWy1CwGxHdPWvkYowpIwPl7m7LJTFXVcnODzvmDq+iE+NR6FYeKhHlz/T+oxEq+co06cDYT bbB81+6Ws8uw/QlTOgrcZ6YfxLdFG9rEzVq276sw9NTdkVj7I2Rv6io1zhwzSvducI7QnjRSS at7wem0Ocpl/FbpT9iN5/TaFxMN9rQUZrUasOll9aaCsUGPoVVJA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from homer.fritz.box ([185.221.149.208]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1N5GDv-1pgNdt3PAj-011991; Sun, 30 Jul 2023 07:54:40 +0200 Message-ID: <069dd40aa71e634b414d07039d72467d051fb486.camel@gmx.de> Subject: Re: arm64: perf test 26 rpi4 oops From: Mike Galbraith To: Will Deacon Cc: lkml , Mark Rutland Date: Sun, 30 Jul 2023 07:54:40 +0200 In-Reply-To: <20230728141852.GA21718@willie-the-truck> References: <20230728141852.GA21718@willie-the-truck> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:KSFeMMS+ugFubzoh4Z6xWJEuQ8yBvtbIUI1D53bYhmQhhTKVJN1 1Tzfuv3uziW5spWdCTqmBX+IqqV8BEvRTb2EOMPcNu97iTJ6D2b7MLrLecDUqsy4NjNydJB abGA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qx+d/d1pFa0vvzkDwgjQX/pqzLoE8iMczQq71ZPJ 8oLqtCkw6OA1sNA3mx2cqcimO60= X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,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 On Fri, 2023-07-28 at 15:18 +0100, Will Deacon wrote: > > Looking at this quickly with Mark, the most likely explanation is that > a bogus kernel address is being passed as the source pointer to > copy_to_user(). On a whim, are you able to revert 4c91c07c93bb ("mm: > vmalloc: convert vread() to vread_iter()") and see if the issue persists= ? If > not, maybe you can try the commit before? Ok, did that. Neither helped, I had to revert 2e1c0170771e 6.1.42 clean 6.2.16 not so clean [ 180.564427] __vm_enough_memory: pid: 1935, comm: objdump, no enough mem= ory for the allocation [ 180.564445] __vm_enough_memory: pid: 1935, comm: objdump, no enough mem= ory for the allocation 6.4.7 oops +Revert-mm-vmalloc-convert-vread-to-vread_iter.patch oops +Revert-iov_iter-add-copy_page_to_iter_nofault.patch oops +Revert-fs-proc-kcore-convert-read_kcore-to-read_kcore_iter.patch oops +Revert-fs-proc-kcore-avoid-bounce-buffer-for-ktext-data.patch back to= 6.2 induced alloc failures [ 48.718233] __vm_enough_memory: pid: 1747, comm: objdump, not enough me= mory for the allocation [ 48.718264] __vm_enough_memory: pid: 1747, comm: objdump, not enough me= mory for the allocation 6.4.7 plus only arm64 revert (sorta) of e025ab842ec3 does the same [ 37.587688] Unhandled KCORE type: 0 [ 37.611042] __vm_enough_memory: pid: 1736, comm: objdump, not enough me= mory for the allocation [ 37.611073] __vm_enough_memory: pid: 1736, comm: objdump, not enough me= mory for the allocation =2D-- a/fs/proc/kcore.c +++ b/fs/proc/kcore.c @@ -554,6 +554,8 @@ static ssize_t read_kcore_iter(struct ki fallthrough; case KCORE_VMEMMAP: case KCORE_TEXT: + if (!kern_addr_valid(start)) + goto invalid_addr; /* * We use _copy_to_iter() to bypass usermode hardening * which would otherwise prevent this operation. @@ -563,6 +565,7 @@ static ssize_t read_kcore_iter(struct ki goto out; } break; +invalid_addr: default: pr_warn_once("Unhandled KCORE type: %d\n", m->type); if (iov_iter_zero(tsz, iter) !=3D tsz) {