Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp1972259rwp; Thu, 13 Jul 2023 21:20:51 -0700 (PDT) X-Google-Smtp-Source: APBJJlFKlTZmbnos3ypq9mATS5ghuXF2oqumxA+EoDLwJ1Om8yOZprdV23jDdlWHjchpJd44AY94 X-Received: by 2002:a05:6830:198:b0:6b7:319d:281e with SMTP id q24-20020a056830019800b006b7319d281emr4364643ota.19.1689308450889; Thu, 13 Jul 2023 21:20:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689308450; cv=none; d=google.com; s=arc-20160816; b=W6Mp4r0M3p63SLVJFa1IbdnSdC6aFfMbFWkoCiM3tWzptcsjf85lwhjxotEE4/QDEH UXKBwz/D5racSFCbSbCjfC/hwFn0R0GG4M8lgqjcmlpdmCQWQabKVZxSeN4OdaAKro52 WdIFRmxJsLCO3IztR3vQTDugLg8Epyc7nVxykiveRyej6aN8AuIUgmJN9rgpLPuPz6Kh 2IWx+mKKruCsgi2ZkvD4w9iYLHTmeXFynZXbOAyNzH7eewfet1Ma+KSb0KxV8zkzuh/D KWGEFcVAjpbEssL97p48kwDSzm315zOmFM18qwxHd05ohuZZu3RgmumfANvWhbE+p9af 1TnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:reply-to :from:references:cc:to:content-language:subject:user-agent :mime-version:date:message-id; bh=OqcQX+7f3qZ3qaUZc/1jcIds2fxTvO0o86hitwVbsfM=; fh=SJO2MXbSw8xe6BYF3HK5CTkmx8RtdAp9LVg9ELsp65k=; b=VVpEeeBvMHgF6heQSJFKUG3yCijST6Im6+PplY4uZBW5FnqfimL7Y00A4DLtwKm0d+ AiF30hfYbkHLdrS4BTSuLW09C6bgdVAFo8P0+8vwJ5Sw1IY66MaSa4uItZSvL+/fOqg3 N4JY0va+9gZSb7UOtWn7qryueKvfoq1rgbBTIpX2UhJgCzeyF4TCJqB6kW73L+pLYfQH 1Cx81HxDjYtT7ivQjROZH0obbamMsTPyfeGS7SEdSGJsrvJmC6ytoIVIMFjtviQsqcK1 /bd9jHf9q57xtvS6bhuJ4ZMpSv2GLl1RRUheexlkZl8wgGVOuOnvl2MMaQXFdQ8pwizX TG7w== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u190-20020a6385c7000000b0055c92ce92c8si1924890pgd.736.2023.07.13.21.20.38; Thu, 13 Jul 2023 21:20:50 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234826AbjGNDoV (ORCPT + 99 others); Thu, 13 Jul 2023 23:44:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50766 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234854AbjGNDoS (ORCPT ); Thu, 13 Jul 2023 23:44:18 -0400 Received: from wp530.webpack.hosteurope.de (wp530.webpack.hosteurope.de [80.237.130.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9995626B2 for ; Thu, 13 Jul 2023 20:44:16 -0700 (PDT) Received: from [2a02:8108:8980:2478:8cde:aa2c:f324:937e]; authenticated by wp530.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) id 1qK9iy-00066l-8O; Fri, 14 Jul 2023 05:44:08 +0200 Message-ID: <55a3bbb1-5b3c-f454-b529-8ee9944cc67c@leemhuis.info> Date: Fri, 14 Jul 2023 05:44:07 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: radeon.ko/i586: BUG: kernel NULL pointer dereference, address: 00000004 Content-Language: en-US, de-DE To: Bagas Sanjaya , Taketo Kabe Cc: Alex Deucher , =?UTF-8?Q?Christian_K=c3=b6nig?= , "Pan, Xinhui" , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "H. Peter Anvin" , Linux Kernel Mailing List , Linux Regressions , Linux AMDGPU , Steven Rostedt References: <5f8d4aa5-3b23-8965-57e3-a28bd9aa8e87@gmail.com> <20230713231250.35488431@rorschach.local.home> From: "Linux regression tracking (Thorsten Leemhuis)" Reply-To: Linux regressions mailing list In-Reply-To: <20230713231250.35488431@rorschach.local.home> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-bounce-key: webpack.hosteurope.de;regressions@leemhuis.info;1689306256;12710a42; X-HE-SMSGID: 1qK9iy-00066l-8O X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_BLOCKED,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 14.07.23 05:12, Steven Rostedt wrote: > On Fri, 14 Jul 2023 09:50:17 +0700 > Bagas Sanjaya wrote: > >> I notice a regression report on Bugzilla [1]. Quoting from it: >> >> >> See Bugzilla for the full thread and attached patches that fixes >> this regression. >> >> Later, when bisecting, the reporter got better kernel trace: >> >>> [ 469.825305] BUG: kernel NULL pointer dereference, address: 00000004 >>> [ 469.830502] #PF: supervisor read access in kernel mode >>> [ 469.830502] #PF: error_code(0x0000) - not-present page >>> [ 469.830502] *pde = 00000000 >>> [ 469.830502] Oops: 0000 [#1] PREEMPT SMP >>> [ 469.830502] CPU: 0 PID: 365 Comm: systemd-udevd Not tainted 5.14.0-221.el9.v1.i586 #1 > > This is a 5.14 kernel right? And a vendor kernel that from the sound of the version number might be heavily patched. But apparently the reporter later bisected this on a newer kernel (Bagas, would have been good if this had been mentioned in your earlier mail): https://bugzilla.kernel.org/show_bug.cgi?id=217669#c5 ``` I succeeded to bisect down the regressing commit found in kernel-5.18.0-rc2: b39181f7c690 (refs/bisect/bad) ftrace: Add FTRACE_MCOUNT_MAX_OFFSET to avoid adding weak function This at a glance does not relate to drm/kms code. The attached patch effectively reverts the commit for 32bit. This fixed the problem on kernel-5.18.0, but not enough for kernel-6.4.3 ``` That being said: That commit is not in 5.18, as Steve noticed: >> #regzbot introduced: b39181f7c6907d https://bugzilla.kernel.org/show_bug.cgi?id=217669 >> #regzbot title: FTRACE_MCOUNT_MAX_OFFSET causes kernel NULL pointer dereference and virtual console (tty1) freeze > That commit was added in 5.19. > > So I'm confused about why it's mentioned. Was it backported? Taketo Kabe, could you please help to clean this confusion up? Did you mean 5.19 in https://bugzilla.kernel.org/show_bug.cgi?id=217669#c5 ? And BTW: did you really use a vanilla kernel for your bisection? TWIMC, there is also https://bugzilla.kernel.org/show_bug.cgi?id=217669#c6 : ``` Attached patch sort of fixes the problem; it does not panic and KMS console works, but printk is triggered 4 times on radeon.ko load and when VGA connector is plugged in. I am sort of at loss now; I need advice from people which knows better. --- ./drivers/gpu/drm/drm_internal.h.rd 2023-06-25 21:35:27.506967450 +0900 +++ ./drivers/gpu/drm/drm_internal.h.rd 2023-06-25 21:36:34.758055363 +0900 @@ -99,6 +99,10 @@ u64 drm_vblank_count(struct drm_device * /* drm_vblank_work.c */ static inline void drm_vblank_flush_worker(struct drm_vblank_crtc *vblank) { + if (!vblank->worker) { + printk(KERN_WARNING "%s: vblank->worker NULL? returning\n", __func__); + return; + } kthread_flush_worker(vblank->worker); } ``` Ciao, Thorsten