Received: by 2002:ab2:7903:0:b0:1fb:b500:807b with SMTP id a3csp955503lqj; Mon, 3 Jun 2024 06:15:03 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUeQl9FfoZ8L9dghnlvuLQNxLRSuCGk4C4CUofMdrT+0LOQ7ME01Pv1xzBms0gkTx/LaBni3kBwZCLoG/f+F2a8leCIEKtAKOFn8ayUQg== X-Google-Smtp-Source: AGHT+IF62olbD8rNm4FU0OeJJsXw77+BpKJMe2GWUm7Oz0x09L71m2OLt5K634H6Asp4o7L4dL9a X-Received: by 2002:ac8:58d6:0:b0:43a:b5e9:7d6 with SMTP id d75a77b69052e-43ff525123cmr115100051cf.22.1717420503621; Mon, 03 Jun 2024 06:15:03 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717420503; cv=pass; d=google.com; s=arc-20160816; b=BJKQ5zV7LHS0+rlg0esCBdMJfTdTMVCtyFPAjDVgJ1YJ6JZGouJJHzPC5bp/p/yzxt yfHQdshrQlM/A4By9qlU2XN5A/nYksQSiQLuz+OeYVOtYHT9Kx1f2OqYolxZbP78muut wUJzyfDxYxTAj4AAOQ6LILGR3WnpgbXdcifyMvPL6AnDF9AK+l26HgeHHuxqm7EDKveN gaREQBjBYCzWZczeRqmneq5pUjGVChBATHXBDx9J0b8iBJsX+5qaEHIgqihRK6qPKx2O +VR05OhzACWxLKyKbBwkFm32hCM7KFvVGGJ38qpfrYCsynXz43pFYpjLuDVEcMe7vfgI 6wcg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=date:message-id:user-agent:cc:to:references:in-reply-to:from :subject:content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature; bh=ajxqbOIlQf4ZCBIRR/erADUL9o2yEbHEZf5ZNM2up2w=; fh=q0pWxAdL0cyDcfHi0eFkTCBsBNeBmItsjEnoI8WnNeM=; b=ewYRft06+YcGVTUmVFR7Sp/+602qo6ywCZYAPHr7DR+kLjY4EQCXKqnTyBvfDIvfZx F92prBKP6jZROe2IcjyQOFBb5KlbWKIuJJ/9SLv/6H9PgR4kJCMds+KUqPmviQyepyc9 f1cCvn92Qtio2jvlg84iE37n0WTDwMoKaWsVzwgBlj34hl6hqX9w+kLts3dBMJHyr3LG cT4deoMN/FxU66eLxnUq/zUTqClDRlKHTACJmztJdqrawCvf4YhVGJH4Snng0lEDEIHW P+Nh1ReitWJojDPZzjqDw+w7YqFHOL1lX5aHuGPUbZSdorrjIjXH2oIV5RD/zdQljUJ5 eU8Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ggo1yQBk; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-wireless+bounces-8423-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-8423-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id d75a77b69052e-43ff25803ddsi83520851cf.492.2024.06.03.06.15.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 03 Jun 2024 06:15:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-8423-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ggo1yQBk; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-wireless+bounces-8423-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-8423-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 309C31C21A77 for ; Mon, 3 Jun 2024 13:14:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1A27312CD9D; Mon, 3 Jun 2024 13:14:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ggo1yQBk" X-Original-To: linux-wireless@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EA43C1272A7 for ; Mon, 3 Jun 2024 13:14:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717420454; cv=none; b=Qyohas2PX02Up9ythFsStTwG/fQZFc53WifClF6Tz/f1/dxDmAWATUkR0E8eOctzspzU3rSksERHlY24p18SoEQERXGeE3R0QxQ+thrQSOXTyjeqwVIvaeScbYA9+p+ZT4l7Dniv4vnPZ1kbS6cBv3U2ubWBvorMEelhJ9ybS6k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717420454; c=relaxed/simple; bh=WW6dGlXKLeOoL1hqzQ1d1JJ/1RgcIKTS3/T/1bLcvQQ=; h=Content-Type:MIME-Version:Subject:From:In-Reply-To:References:To: Cc:Message-ID:Date; b=rSZabSZ89mN2jgmDCtTf89AqDJ0v5fUtvJ3DSuGnWBqyPkfYWA/dEOGanNsvSuZNzylsPGlXRNnsysb2yq+bIxS4OXtNmHnTaqoRU/iWL0f6znTx+Kh6S4WX0f1Hw1dA1QdtqMyWXOMrQGgx5mbcxnyMusFOKA+5oE47faoq2Qo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ggo1yQBk; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 89381C2BD10; Mon, 3 Jun 2024 13:14:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1717420453; bh=WW6dGlXKLeOoL1hqzQ1d1JJ/1RgcIKTS3/T/1bLcvQQ=; h=Subject:From:In-Reply-To:References:To:Cc:Date:From; b=ggo1yQBkBMceBtsQBu1YGjyZi0AGqHJaMcrf+mTYNlEzR04198TBXrArF9DxoeDMd 553N7gp2NhMJNhNZmEsyQgu+9ccRC3P4wsFeX5STZe+h3kE5ZixBX0urb7uZxpvG89 ZKpf7YpSPfaDb65KkyOVTSBECLqqXxnq4e+7ugA4oMGGGHEhYvlwSscmqmcaKcXMd0 PdyZ2oRUOY+o2PvAKshOBwPLU5aQQSiZ+j+zTXGx6a+evbd9Bllxn05+WL8fWlEYgO f/ms3yz995os8/qun7PI8KR/ls86qSx58DgiuieNEtlhVkRmwoSZ1qk42qpVVgdl4M HrzKP3IrQz9TA== Content-Type: text/plain; charset="utf-8" Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [PATCH] wifi: ath12k: add panic handler From: Kalle Valo In-Reply-To: <20240529021533.10861-1-quic_bqiang@quicinc.com> References: <20240529021533.10861-1-quic_bqiang@quicinc.com> To: Baochen Qiang Cc: , , User-Agent: pwcli/0.1.1-git (https://github.com/kvalo/pwcli/) Python/3.11.2 Message-ID: <171742045096.1515473.13427996557283949873.kvalo@kernel.org> Date: Mon, 3 Jun 2024 13:14:12 +0000 (UTC) Baochen Qiang wrote: > Currently for ath12k PCI devices, firmware could be running in one of > several execution environments, e.g., PBL, SBL and mission mode etc. Among > which PBL is the only stage where PCIe link negotiation could happen. So > normally firmware runs in PBL in order to be enumerated during system reboot. > > However it might not work in kernel crash scenario: ath12k target is not > found after warm reboot from kernel crash. This is because when kernel crashes, > ath12k host does nothing to firmware. And during warm reboot, WLAN power > is sustained. So firmware is likely to keep running in mission mode throughout > the bootup process. As a result PCIe link is not established and thus target > not enumerated. > > So add a handler in panic notification list for ath12k. When kernel crashes, > this handler gets called and tries to reset target to PBL state. Then PCIe > link negotiation could happen and target gets enumerated. > > This change applies to all PCI devices including WCN7850 and QCN9274. > > Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4 > > Signed-off-by: Baochen Qiang > Acked-by: Jeff Johnson > Signed-off-by: Kalle Valo Patch applied to ath-next branch of ath.git, thanks. 809055628bce wifi: ath12k: add panic handler -- https://patchwork.kernel.org/project/linux-wireless/patch/20240529021533.10861-1-quic_bqiang@quicinc.com/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches