Return-path: Received: from wolverine02.qualcomm.com ([199.106.114.251]:52503 "EHLO wolverine02.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753397Ab2CFP5h (ORCPT ); Tue, 6 Mar 2012 10:57:37 -0500 Message-ID: <4F5633E5.7040507@qca.qualcomm.com> (sfid-20120306_165744_407303_920066B0) Date: Tue, 6 Mar 2012 17:57:25 +0200 From: Kalle Valo MIME-Version: 1.0 To: Vasanthakumar Thiagarajan CC: , Subject: Re: [PATCH] ath6kl: Fix kernel panic while receiving fwlog during boot References: <1331024980-1632-1-git-send-email-vthiagar@qca.qualcomm.com> In-Reply-To: <1331024980-1632-1-git-send-email-vthiagar@qca.qualcomm.com> Content-Type: text/plain; charset="ISO-8859-1" Sender: linux-wireless-owner@vger.kernel.org List-ID: On 03/06/2012 11:09 AM, Vasanthakumar Thiagarajan wrote: > "ath6kl: Defer wiphy and netdev registration till the end of ath6kl_core_init()" > causes kernel panic by accessing the unallocated debug resources during > boot time. To fix this, split the debug initialization funtion into two, > one initializes the debug resource and the other takes care of debugfs > initialization. When this issue shows up the kernel crash dump would > look like > > ath6kl_debug_fwlog_event+0x9c/0x10a > [] register_lock_class+0x57/0x288 > [] ? trace_hardirqs_on+0xb/0xd > [] ? ath6kl_debug_fwlog_event+0x9c/0x10a > [] __lock_acquire+0x96/0xbe5 > [] ? alarmtimer_suspend+0x80/0x127 > [] ? vprintk+0x394/0x3b1 > [] ? ath6kl_debug_fwlog_event+0x9c/0x10a > [] lock_acquire+0xda/0xf9 > [] ? ath6kl_debug_fwlog_event+0x9c/0x10a > [] _raw_spin_lock+0x28/0x58 > [] ? ath6kl_debug_fwlog_event+0x9c/0x10a > [] ath6kl_debug_fwlog_event+0x9c/0x10a > [] ath6kl_wmi_control_rx+0x69d/0xb50 [ath6kl_core] > [] ? ath6kl_rx+0x3c/0x839 [ath6kl_core] > [] ath6kl_rx+0xb8/0x839 [ath6kl_core] > [] ? local_clock+0x2d/0x4e > [] ? _local_bh_enable_ip+0x94/0x98 > [] ? ath6kl_alloc_amsdu_rxbuf+0xb7/0xb7 > [] ath6kl_htc_rxmsg_pending_handler+0x891/0x988 [ath6kl_core] > [] ? ath6kl_refill_amsdu_rxbufs+0x89/0x92 > [] ? aggr_timeout+0xed/0xed [ath6kl_core] > [] ? ath6kl_alloc_amsdu_rxbuf+0xb7/0xb7 > [] ? ath6kl_tx_complete+0x376/0x376 [ath6kl_core] > [] ath6kl_hif_intr_bh_handler+0xf7/0x33e > [] ? mmc_host_disable+0x15/0x3a > [] ath6kl_sdio_irq_handler+0x3c/0x90 [ath6kl_sdio] > [] sdio_irq_thread+0xb6/0x29c > [] ? sdio_claim_irq+0x1cb/0x1cb > [] kthread+0x67/0x6c > [] ? __init_kthread_worker+0x42/0x42 > [] kernel_thread_helper+0x6/0xd > BUG: unable to handle kernel NULL pointer dereference at > EIP: [] ath6kl_debug_fwlog_event+0xa7/0x10a > > Reported-by: Kalle Valo > Signed-off-by: Vasanthakumar Thiagarajan Thanks, applied with these changes: kvalo: rename new function to ath6kl_debug_init_fs() and add a comment why it's needed Kalle