Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp3036915imm; Sun, 24 Jun 2018 09:59:51 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKTdhllw/oHu9YkzfG9/k7dfHI13W35RWPMzHQIvuQq2+lUptperH3qD4O+tuHak31ibrJX X-Received: by 2002:a65:43c9:: with SMTP id n9-v6mr7872497pgp.399.1529859591929; Sun, 24 Jun 2018 09:59:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529859591; cv=none; d=google.com; s=arc-20160816; b=ad/o0Dw9IrB/utkZwY8oWM9DHsW+dmco1kjLa8N3L+zaNOPyUkE25eo6kEr4DgRiBs RrFlX5Td5q0Na+dxtHRuszET8+pbN9/i6bGTywnx5SbgKUthlx9i2RdeJSfeIy8YKLOc Ox+bHarh9Lzdcor3JduVPyQi0gtnu1dW1DostBoKfaacPhsKvPqnLTHprAR7TYzX2EEm 2GlmmIkIJy3ntmAzdLV6+Os29Fxcy0AHeL9SkvN6xG/TXuyrJsFuPsXTAlgJFbv6RLsK LazPE/kuqK0CgH8dIEMr1hvhb44op37FmUninogzJ72GPnpZHXoU5e+wJKDbP7vfkv0x i9ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:user-agent:cc:to :references:in-reply-to:from:subject:content-transfer-encoding :mime-version:dmarc-filter:dkim-signature:dkim-signature :arc-authentication-results; bh=Z1XpCXVXKj+HI+CXm3ONGecWJh3oLpzHTyq0IaqIhwM=; b=x2rAGtoGA/ExhriJhOrrWxUo0d77meKiKBRT764MorJ9SSioaJyz+r/Z5yehJv+uHd cY3etcU3w3Gg+vwTuDoqFOTaBUcHwfVrQZCWBmJJVAg5hDlWgtapUyyFsyT9pHkBo5Oi hBhnqc1sp/ARet4wJnE78StK+/654hbx5kR26bu+tVv2jtDOViKI1fmRNOZF4ZF5owtT ae64n7/d+YAW1l72XetrA7EpN0o31AaN9Os/twrE39l3ZAYq34SjU65HxJV3TazXXPG2 EgMjibzjIQoO+AdVqfbQbBuO8Q5wcYV9T2+n7GPIBlQOgSPPSxeLBdr0FIK5+YjH6hKo tNOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=bg7bMBMh; dkim=pass header.i=@codeaurora.org header.s=default header.b=LSgHpMLd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a26-v6si11535261pfn.281.2018.06.24.09.59.37; Sun, 24 Jun 2018 09:59:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=bg7bMBMh; dkim=pass header.i=@codeaurora.org header.s=default header.b=LSgHpMLd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752179AbeFXQ6x (ORCPT + 99 others); Sun, 24 Jun 2018 12:58:53 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:38130 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751603AbeFXQ6v (ORCPT ); Sun, 24 Jun 2018 12:58:51 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id C890E60711; Sun, 24 Jun 2018 16:58:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1529859530; bh=ceNb/ji0GcVL2PZK1Ta9XZiMVvPTG4o6L7k24rW7K20=; h=Subject:From:In-Reply-To:References:To:Cc:Date:From; b=bg7bMBMhPerhV4J/vRlk0YhJJn92H9egbJVQdYgxV/R4JCoeDxCAndk8GhsKeh1v/ 5UvPU4muaSXC+0xHZMSIwiLYlMG+DV99fJxJy0Zf45oLhoYiJFgeHzC1IQJcMs9iuV OQC4FFUjPhVzmof5TfGLZ/7uUEcgkT3kBNsjoHh4= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.9 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,MISSING_DATE,MISSING_MID,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from potku.adurom.net (88-114-240-52.elisa-laajakaista.fi [88.114.240.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: kvalo@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 968A760712; Sun, 24 Jun 2018 16:58:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1529859529; bh=ceNb/ji0GcVL2PZK1Ta9XZiMVvPTG4o6L7k24rW7K20=; h=Subject:From:In-Reply-To:References:To:Cc:From; b=LSgHpMLd/soDGqAAouksWA/66MsrphhtNDX6Lq1k40ZMY3ZxkGudT2Bf5p5wE/cer Gtkzazr68/dP9gT87SlM9D9zDJlZFiEKrY4uzkiuF3wL72KE7Lq8YB7bO6Iegsl2Bb /YLRTCkmjITVJLSZiLXP4AuQx0n+qh4/rjVfdsIQ= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 968A760712 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=kvalo@codeaurora.org Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [V2] brcmfmac: stop watchdog before detach and free everything From: Kalle Valo In-Reply-To: <20180530090633.GA15390@panicking> References: <20180530090633.GA15390@panicking> To: Michael Trimarchi Cc: Arend van Spriel , Franky Lin , Hante Meuleman , Chi-Hsien Lin , Wright Feng , "David S. Miller" , Pieter-Paul Giesberts , Ian Molton , linux-wireless@vger.kernel.org, brcm80211-dev-list.pdl@broadcom.com, brcm80211-dev-list@cypress.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org User-Agent: pwcli/0.0.0-git (https://github.com/kvalo/pwcli/) Python/2.7.12 Message-Id: <20180624165850.C890E60711@smtp.codeaurora.org> Date: Sun, 24 Jun 2018 16:58:50 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Michael Trimarchi wrote: > Using built-in in kernel image without a firmware in filesystem > or in the kernel image can lead to a kernel NULL pointer deference. > Watchdog need to be stopped in brcmf_sdio_remove > > The system is going down NOW! > [ 1348.110759] Unable to handle kernel NULL pointer dereference at virtual address 000002f8 > Sent SIGTERM to all processes > [ 1348.121412] Mem abort info: > [ 1348.126962] ESR = 0x96000004 > [ 1348.130023] Exception class = DABT (current EL), IL = 32 bits > [ 1348.135948] SET = 0, FnV = 0 > [ 1348.138997] EA = 0, S1PTW = 0 > [ 1348.142154] Data abort info: > [ 1348.145045] ISV = 0, ISS = 0x00000004 > [ 1348.148884] CM = 0, WnR = 0 > [ 1348.151861] user pgtable: 4k pages, 48-bit VAs, pgdp = (____ptrval____) > [ 1348.158475] [00000000000002f8] pgd=0000000000000000 > [ 1348.163364] Internal error: Oops: 96000004 [#1] PREEMPT SMP > [ 1348.168927] Modules linked in: ipv6 > [ 1348.172421] CPU: 3 PID: 1421 Comm: brcmf_wdog/mmc0 Not tainted 4.17.0-rc5-next-20180517 #18 > [ 1348.180757] Hardware name: Amarula A64-Relic (DT) > [ 1348.185455] pstate: 60000005 (nZCv daif -PAN -UAO) > [ 1348.190251] pc : brcmf_sdiod_freezer_count+0x0/0x20 > [ 1348.195124] lr : brcmf_sdio_watchdog_thread+0x64/0x290 > [ 1348.200253] sp : ffff00000b85be30 > [ 1348.203561] x29: ffff00000b85be30 x28: 0000000000000000 > [ 1348.208868] x27: ffff00000b6cb918 x26: ffff80003b990638 > [ 1348.214176] x25: ffff0000087b1a20 x24: ffff80003b94f800 > [ 1348.219483] x23: ffff000008e620c8 x22: ffff000008f0b660 > [ 1348.224790] x21: ffff000008c6a858 x20: 00000000fffffe00 > [ 1348.230097] x19: ffff80003b94f800 x18: 0000000000000001 > [ 1348.235404] x17: 0000ffffab2e8a74 x16: ffff0000080d7de8 > [ 1348.240711] x15: 0000000000000000 x14: 0000000000000400 > [ 1348.246018] x13: 0000000000000400 x12: 0000000000000001 > [ 1348.251324] x11: 00000000000002c4 x10: 0000000000000a10 > [ 1348.256631] x9 : ffff00000b85bc40 x8 : ffff80003be11870 > [ 1348.261937] x7 : ffff80003dfc7308 x6 : 000000078ff08b55 > [ 1348.267243] x5 : 00000139e1058400 x4 : 0000000000000000 > [ 1348.272550] x3 : dead000000000100 x2 : 958f2788d6618100 > [ 1348.277856] x1 : 00000000fffffe00 x0 : 0000000000000000 > > Signed-off-by: Michael Trimarchi > Acked-by: Arend van Spriel > Tested-by: Andy Shevchenko Patch applied to wireless-drivers.git, thanks. 373c83a801f1 brcmfmac: stop watchdog before detach and free everything -- https://patchwork.kernel.org/patch/10437931/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches