From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3CF55C43334 for ; Mon, 13 Jun 2022 11:23:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ueLj8yMzblrmHVZjkrMYiKGFg1tw4dOdeFFBaoCcCAY=; b=21T5ecAuSyyLY5 Rr2xk8oV1lPSmoNLy43rQ5Q2u+YyTU21csZB2HzJNXG/Z72j9hPgeQeLv/3WEFjcVrARrlrHC1MZd uX2D8iTYRCKJFuyj5AcH0Z0gFQ4yvFXaEtAe9nZn+12uJo/reNKXH1bOb5B+NuzmYMpxwLcSRT1nm pNqkJ1Di92zRxJ3xKkb/poDyfkjF3I/drRCfrpUhopGja6Y7fmsVOKEALuLBzwJ9XhYysvMZe1YCp 485Y++9dpH1iA1BJcNw4P5nGi88qOGy1ilShRXvXGf6aM9/+ywLWOdJBzWDNsHW5YXDC+HiF9M47N t/RTgghUJ26rlf8P8TwA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o0i97-003BCk-Ta; Mon, 13 Jun 2022 11:22:14 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:32c8:5054:ff:fe00:142]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o0i1g-0036DB-9b for linux-arm-kernel@lists.infradead.org; Mon, 13 Jun 2022 11:14:33 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=74UX7MWPYAaIblRMnIERw/k0jzzIxCFbAdKIQkmHh8I=; b=Z7AyPWON+EVR26AMxKjCiZ1zRp so/WmMmBjYRf1iowFiQ+fN7Y3ZMMl6YEFFlsIpKbwEfUNYBwuoPAu7qr77415PyebY7OPdQCOozQ5 VoAAEh0zdR63YjNnpmf4S3jIws/U5ZCUUC9Gsc89dAC4T3V8uJdIvkMMJSDpUrBSwgRBX2u1gJdYH x1QMfwp6kX19tCHRWYKjPXsGcsqysfdj9ocgSC1DBWcbvnGqGSd8Df84U3ZCBIOnx75Fwmllyo8hf fJOXqCRkqnU0SXXu9S2o9njpnrQyzdxg6fa5deOqmQzkrS3vaqeCGNqGui79DPjiJqzMAk/e86KjE Agc/xT0A==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:32846) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1o0hzJ-0001g6-4V; Mon, 13 Jun 2022 12:12:05 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1o0hzG-0006VI-8u; Mon, 13 Jun 2022 12:12:02 +0100 Date: Mon, 13 Jun 2022 12:12:02 +0100 From: "Russell King (Oracle)" To: Stefan Wahren Cc: Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Shubham Bansal , bpf@vger.kernel.org, jpalus@fastmail.com, regressions@lists.linux.dev, Linux ARM Subject: Re: [BUG] null pointer dereference when loading bpf_preload on Raspberry Pi Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220613_041432_383480_60F1DF25 X-CRM114-Status: GOOD ( 15.92 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Mon, Jun 13, 2022 at 12:22:47AM +0200, Stefan Wahren wrote: > It would be nice to get a hint, how to narrow down or which commit might > trigger this issue. The standard way? git bisect? So it happens on 5.18.0 and 5.18.3. Presumably it didn't happen with 5.17? I've tried to trace the code but failed - skel_map_create() doesn't seem to feature anywhere obvious in my kernels. It looks to me like some BPF code is being loaded by the bpf_reload module and is being run. I'm guessing that the BPF code is calling bpf_sys_bpf, but as I can't find skel_map_create() that's all it is, a guess. It looks like copy_from_bpfptr() which calls copy_from_sockptr_offset() is passing in a source pointer of 0x0048. I'm guessing this is the value of the pointer that is passed into bpf_sys_bpf() - that's another guess, there's no information on that in the backtraces. So, there's really not much to go on here to debug the oops as the kernel has printed... I'd say its pretty much undebuggable from just the kernel oops. Maybe someone on the bpf list will have a better idea. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last! _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel