From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (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 8844436AB41 for ; Fri, 30 Jan 2026 10:44:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769769883; cv=none; b=sJOhj8I/ySFGZ9FCBiNaJyOzER5MHkqWsUWKh9s8ETzSAadbYS8dtn2lWJvC+JiDps+7/ut1sMjt84XGQY0M2bztX3xPSy0v/cY/If/DneTf0lhuw6vWcSuP0MaBS9I1ZtX39lxbeXLoKprYdOYNK87E6Ko4cTbgJUluPxbXNWg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769769883; c=relaxed/simple; bh=UkqzJuJSnuN7H0m3EWp/Ondn1y+Z0aKMJnexqBz9nNY=; h=From:Subject:Date:Message-Id:MIME-Version:Content-Type:To:Cc; b=ujsQ8u1j1SY1+f5AG7j5hhv8ouV22ZbbPoqsYynDJNKiOyzXRltPdjlXCc8GAbkzu4qaCHu3gjI2UnUlhZY7lNY5udSl5QpyOWfRS/aWIBrW2+MAy2PlmIjVYMg5Lo8WteMNZ7gOjd5pQ6vze/hsPRYQjKx+TCv7q6GivCsdn2o= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=dxD2tAoJ; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=EclKDsPz; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="dxD2tAoJ"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="EclKDsPz" Received: from pps.filterd (m0279868.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 60U3VZaF995891 for ; Fri, 30 Jan 2026 10:44:40 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to; s=qcppdkim1; bh=KMlzmANYZGozYGIY4q6ueI QTYz67Z+A+DviLOBx8XzU=; b=dxD2tAoJt4G2h8AaaRt1eXpcuJ8ejheZHkRNVu Px5ucY5XWLzZ48HIZK8C7GaeUTkc71k71W1a/CdeBoNaUoIQjbPDiSNUerjGaE0/ oTQwoAsgFACL7gIiPH31gFZmePrOBgXa/BM4/JopllhSN5AeQ6ni+bU2ly0LLvuK RlXpaDEjY8tch5Tic16T5/BdbFS+u7Y2N1Cq47NPXoidXtosEPMVqVsONnkeh6m/ 98LR5FkatABISP8Uiy275dxW7VjET+jkG6HQ/ZzC0Ilqf3qlo693GauAKNsfrcdD vtwxXYohxH77KRf/6WdK1U22JRgmiUokIvGPxYh9KYgf/pIg== Received: from mail-pl1-f198.google.com (mail-pl1-f198.google.com [209.85.214.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4c0bvvjsm5-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Fri, 30 Jan 2026 10:44:40 +0000 (GMT) Received: by mail-pl1-f198.google.com with SMTP id d9443c01a7336-2a0bae9acd4so15727075ad.3 for ; Fri, 30 Jan 2026 02:44:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1769769879; x=1770374679; darn=vger.kernel.org; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:from:to:cc:subject:date:message-id:reply-to; bh=KMlzmANYZGozYGIY4q6ueIQTYz67Z+A+DviLOBx8XzU=; b=EclKDsPzMESYAkFj4xm6T+4n9D8O6QIDnyDKq5LQCxPIODtNjBx/QDDxcGrhhIifH+ fBwsBZyH0go7s6pLQfR6WRCYuE+S2ZhgBJpfTwRq2w9FmM4LXFojUNiL135SWVSTNsC7 UM9LiJjunZ9ejiQkxRjl0Hzz9UOMB9jWqMzpTP1hgyB0fnTCox/GS7LGnsClSMUMUZ2d rdT8DaGD7giXS2fDyvEdDmL6ILW58uCFfoN2AmNRitqX9xp7js1v3uE+k4vyj5Q3C7OQ lipw5x519jyKDQB7ZtYj0WooBk3ToCEBa1dd98CyLFA2nT/cxJm9pF1l2zRP10V1qbsH kWbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1769769879; x=1770374679; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=KMlzmANYZGozYGIY4q6ueIQTYz67Z+A+DviLOBx8XzU=; b=rFh8uUUsUtRuRUEA8daLdfhPxHZH3Zkjx92hP1KCInYsEDnmACFnpAUx6Vt1rcSkcb peARr9j+qOoBmlZTvkDXxZQfihjqHm91Rype1P5AD2kGszeiNF/hC2OPpV8ktfSgLTAP CxGGeqqWxTs7Ak+RMXOe3KyzIFdN/OGop3XtmJJB+Q+Tx8nGc5J5ioN1YUOKnB63iSUJ Gndr/0RmVqm35uZaPTYtlgOPXebTi4MMKZoMuVfqBhg4qS3Q5ZjhF2LnHZelKrCSmZn/ 2b9hQWBcSWEMWYuEnBlA9SzkzSQedRkiUgPgk+5tUIZt0IZeXxeN3y3T8M7StSSGmzNS IKPg== X-Forwarded-Encrypted: i=1; AJvYcCWF8od6lWd91pVEFQEjd4Nbikrh6MoOf8t05LI759TBTkH9v2YsoKVJMS7OmdRYMdQupyhI3fgR6JXypXI=@vger.kernel.org X-Gm-Message-State: AOJu0YzTwni1FUFqTvyOxPlgfpAm8RBSzn3+z6ESqOQLma0kk21SnR4M 4sAROx6uKVb7NRL0qc1yK9tfpOBPnG2bl/B+PQlWd7NuctyzzJMtpg3sAqAK+Xd2JBrdkesMH6x HcfLu5MGrcbafWVZ83kBLZoOp7WUDNCcF7HMjZ2zbJ7y/s1y5ObBXLlQ7kPI7P8LJTu4= X-Gm-Gg: AZuq6aK8kllP45g04d3Q3XOXSsrhx4ANZX8gcvJWsBjnbJhAOs96p1retiPN2FlVDES cp/M9EHlXetcwrdVhTpHp3N4FbySPZm9St/eSZEyFp6dLtOXwBdTXODmPn+8+aw2IE4VhiD4OBu iZauMsztbUsS9wZgLyeElRrw7vmjIFL0T5Zbsw4XODNNOvxfVXrJnc+usd/Gu7h7lH+7IPfougU ynYZaDAfFinLgwJTrTHxBOrnvSZilDKM3i19NPR7mxnTQTGGc5xIdV7/IRmzbzw+JTPJ5Ly+w/k Vxoay3pru9BiJFM0wwJGAFAE5XcXTCArYmcIjNQGBOYWGO4xdoWv+cZJrl0yVOotg2TENKQ8+oH xLgCH4oBRZccnVRNVvqSdykxccmnS4InzxqCBgWs3/o8x974HNl8zM9r8OmA35PXDytLtG+x/6b YfK03OTvu14vXdlUMgBgowQNpiD3UTmhOFuvkwmA+S/62p X-Received: by 2002:a17:903:2345:b0:2a0:d629:903f with SMTP id d9443c01a7336-2a8d9593702mr16601885ad.9.1769769879221; Fri, 30 Jan 2026 02:44:39 -0800 (PST) X-Received: by 2002:a17:903:2345:b0:2a0:d629:903f with SMTP id d9443c01a7336-2a8d9593702mr16601685ad.9.1769769878692; Fri, 30 Jan 2026 02:44:38 -0800 (PST) Received: from hu-kathirav-blr.qualcomm.com (blr-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com. [103.229.18.19]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2a88b5d92a9sm71231465ad.69.2026.01.30.02.44.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Jan 2026 02:44:38 -0800 (PST) From: Kathiravan Thirumoorthy Subject: [PATCH v6 0/5] Add support to read the watchdog bootstatus from IMEM Date: Fri, 30 Jan 2026 16:14:29 +0530 Message-Id: <20260130-wdt_reset_reason-v6-0-417ab789cd97@oss.qualcomm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAI2LfGkC/x2MQQqAIBAAvyJ7TtgEE/pKREittRcNNyqQ/p51G ZjDTAGhzCTQqwKZThZOsUrXKJg3H1fSvFQHg8Zi16K+lmPKJPTRS4raeesDOTToLNRszxT4/pf D+DwvxhNAemIAAAA= X-Change-ID: 20250610-wdt_reset_reason-7a5afe702075 To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Wim Van Sebroeck , Guenter Roeck , Rajendra Nayak Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, Kathiravan Thirumoorthy X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1769769874; l=3151; i=kathiravan.thirumoorthy@oss.qualcomm.com; s=20230906; h=from:subject:message-id; bh=UkqzJuJSnuN7H0m3EWp/Ondn1y+Z0aKMJnexqBz9nNY=; b=s/6iFWuKQHil5X08wCG+FNnWw1QVoBzYEHXsjtJin80TYyoCkFZ5hxZV9G7A7nzz9WrcSIDqM y8F8qFWh6v4DYUvkRcngJTf2gd7/ma11X1WrmgOSeHMd58i+uYb3Mxw X-Developer-Key: i=kathiravan.thirumoorthy@oss.qualcomm.com; a=ed25519; pk=xWsR7pL6ch+vdZ9MoFGEaP61JUaRf0XaZYWztbQsIiM= X-Authority-Analysis: v=2.4 cv=ZdEQ98VA c=1 sm=1 tr=0 ts=697c8b98 cx=c_pps a=MTSHoo12Qbhz2p7MsH1ifg==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=IkcTkHD0fZMA:10 a=vUbySO9Y5rIA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=VwQbUJbxAAAA:8 a=EUspDBNiAAAA:8 a=3xu3cfvniY9m67ySxx8A:9 a=QEXdDO2ut3YA:10 a=GvdueXVYPmCkWapjIL-Q:22 X-Proofpoint-GUID: KIiyE0N2XhZrBv6G9rzpsv41DAmmtcva X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMTMwMDA4NyBTYWx0ZWRfX0JqWn0RZPO7t XMdnbpYm0Ig1wn8TV32G/r4pAO/36mUx+/Eau/ZVqXsgAPcCipY4T14NIlNxcPhd2AYC5oFY45m hSVtAp6cR9wwzVG7mW4kzxdVad7d8H4aPlu4C6lrVhtVc8R+7BS3+G50H03dUrKbe/TreH4UnNQ 1/qXiwKDIPRs2dtYndnZ7+3rOFET3oIG2NugJjQIItYIrFSYJAwHoQ/zgYbnSDG27FynEO2G/uF 9wa6tuXD9Xdz5HKpdejUZu4NoLcQeqiOHTHk+aT8VpH7I+mwFtuQQgDSYup/YMXDE0FXplvaV2I Wwz2I342LveBUha8b4E2TuDDN0KrFaBF/ZJziQsXznTeWteWRUz8mT/Uw3d0VvX3Biej0DVIQYK r7ylnqnts6EOtNk2ec17Zx59oimWiYQmH51s1egKJdok9MmW3XNpYf/UyIzlQOJsmd+e+ylNwsR 0mD75BZyhGwR0tMTX/Q== X-Proofpoint-ORIG-GUID: KIiyE0N2XhZrBv6G9rzpsv41DAmmtcva X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-01-30_01,2026-01-29_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 clxscore=1015 phishscore=0 spamscore=0 suspectscore=0 malwarescore=0 bulkscore=0 lowpriorityscore=0 priorityscore=1501 impostorscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2601150000 definitions=main-2601300087 In Qualcomm IPQ SoCs, if the system is rebooted due to the watchdog timeout, there is no way to identify it. Current approach of checking the EXPIRED_STATUS in WDT_STS is not working. To achieve this, if the system is rebooted due to watchdog timeout, the information is captured in the IMEM by the bootloader (along with other reason codes as well). This series attempts to address this by adding the support to read the IMEM and populate the information via bootstatus sysfs file. With the CONFIG_WATCHDOG_SYSFS enabled, user can extract the information as below: cat /sys/devices/platform/soc@0/f410000.watchdog/watchdog/watchdog0/bootstatus 32 Signed-off-by: Kathiravan Thirumoorthy --- Changes in v6: - Moved the IMEM compatible from qcom,imem to sram binding - Updated the 'sram' property in watchdog binding to point to SRAM region and update the watchdog driver accordingly - Dropped the Konrad's R-b tag in 2/5 Changes in v5: - Rename property 'qcom,imem' to 'sram' - Use dev_err_probe instead of dev_err - Link to v4: https://lore.kernel.org/linux-arm-msm/20250519-wdt_reset_reason-v4-0-d59d21275c75@oss.qualcomm.com/ Changes in v4: - Kept only the WDIOF_CARDRESET and dropped other codes (Guenter) - Renamed qcom_wdt_get_restart_reason() to qcom_wdt_get_bootstatus() - Dropped the device data and describe the required information in the DT (Konrad) - Link to v3: https://lore.kernel.org/linux-arm-msm/20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com/ Changes in v3: - Picked up the relevant tags - Dropped the fallback compatible handling - Split the driver changes into 2. Introduce the device data in one and extend the same in another for the use case - Link to v2: https://lore.kernel.org/linux-arm-msm/20250416-wdt_reset_reason-v2-0-c65bba312914@oss.qualcomm.com/ Changes in v2: - Dropped the RFC tag - Reworked the driver changes to use the syscon API - Link to v1: https://lore.kernel.org/linux-arm-msm/20250408-wdt_reset_reason-v1-0-e6ec30c2c926@oss.qualcomm.com/ Signed-off-by: Kathiravan Thirumoorthy --- Kathiravan Thirumoorthy (5): dt-bindings: sram: describe the IPQ5424 IMEM as mmio-sram arm64: dts: qcom: ipq5424: Add the IMEM node dt-bindings: watchdog: qcom-wdt: Document sram property watchdog: qcom: add support to get the bootstatus from IMEM arm64: dts: qcom: ipq5424: add support to get watchdog bootstatus from IMEM .../devicetree/bindings/sram/qcom,imem.yaml | 1 - Documentation/devicetree/bindings/sram/sram.yaml | 1 + .../devicetree/bindings/watchdog/qcom-wdt.yaml | 6 +++ arch/arm64/boot/dts/qcom/ipq5424.dtsi | 14 +++++++ drivers/watchdog/qcom-wdt.c | 43 +++++++++++++++++++++- 5 files changed, 62 insertions(+), 3 deletions(-) --- base-commit: 33a647c659ffa5bdb94abc345c8c86768ff96215 change-id: 20250610-wdt_reset_reason-7a5afe702075 Best regards, -- Kathiravan Thirumoorthy