From patchwork Fri May 2 13:17:49 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kathiravan Thirumoorthy X-Patchwork-Id: 886922 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 6ED84255224 for ; Fri, 2 May 2025 13:18:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191895; cv=none; b=QuiYCqTER9oPebyx/1RUyF7ILRI8m229VSueHY65DWco2W9y6ZwsvnSprpoQt7ZSERQ4b8UBA6RZ5Oyk3a7Yhgw8wMDG5LzIzqUzfpgeex5kjRfSKIHVwUU4nqRxSbrUsfMR4iaxpn8WV+NXBUllPMhlAD7W06y+4q3PRTJwTi4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191895; c=relaxed/simple; bh=kuc3nwD+lVGfX59PAIq28QGYc+7HorB/Mg6Kws2foiI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=t5oZmHOUw7m1j1fWiFupd+OW368FLFF5H8SslG+w/DZOTY+vBQ3i8KKeIy7TDcPaKhqnzEN4wh61p0NrwII0RtLDl4Cpbwc4ce2cFEg5ZVijzaVAPDCGQEKcbyac+rFQzOgmQpyAmOs8KjobA5QucoEQRx4xTDk88RFB/WjC4OE= 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=hX6FvctS; arc=none smtp.client-ip=205.220.168.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="hX6FvctS" Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 5421NLC6023378 for ; Fri, 2 May 2025 13:18:13 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= TfFYMVQSeb9gxCMqpC9gyzIMAiB8t0Jg4Tc03ZwPL/4=; b=hX6FvctSasNVQeC+ lxcAGA6/d9Gt/YUfsyatXcCFxanOPNSakQ/CNzfQF3y1jbF4gpPUR+16HcENIv8W 8eee+JyBFaw8AjtFfckxKLflTUiOmpjlwVOVUgwzJnFn2gExI7tB6cHwbYTwYIzH W/z23wkQkQSflDGClIc9nZx8eVmahhK9VJ+S78NtnGpeSW8B6PMEqRCutMBK8mgL M1+cAusyS9pTmsZiuRPE9gkAXiHLKANvSLptbi4BGn8+xWrpsu2Nug91Dah77MUP svb+sFsE3zMnj6YVdlC47xMFeequpgQC+9rjG2+cToK5bsuiDUuzeXq6IpOPzf8v 4OIBUA== Received: from mail-pf1-f200.google.com (mail-pf1-f200.google.com [209.85.210.200]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 46b6u80dh3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 02 May 2025 13:18:13 +0000 (GMT) Received: by mail-pf1-f200.google.com with SMTP id d2e1a72fcca58-736c7df9b6cso2964277b3a.3 for ; Fri, 02 May 2025 06:18:13 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1746191893; x=1746796693; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=TfFYMVQSeb9gxCMqpC9gyzIMAiB8t0Jg4Tc03ZwPL/4=; b=AHYYtCGihpBG6RjHMgoB8sTJ08Rk55zxAbmVAC7GfmUAvx1HWUY4evhZ/aOblvurrG 2bgmSH7jotxNYMc1FCzfJnqVZ+9u8c6kg/a3BhwDMcKR7C/1H2uOrjP/15wdq3Q4so3Y 8tzeW3JCL19nKx1Qg6LxCrgOErHdW0jPGK0ulDuYgHcmMPNpt9pzk4nWLxy+606CMpkM 0HQFpLz8MzPKVGxxTYYsO72RrtJSOYj5EmmClMAvNAXp8M2Az3dkQDFf6e+81F1dynhn 1atukIyNph3ZoRZAXgbKqZhWG81lO59mEx62Bq/oobjLNlkTiZriZq3E8nSxF/MfdLuW 0JNA== X-Forwarded-Encrypted: i=1; AJvYcCXOq+z+4BEn+D/PwC5fyWQdoqdUtr77On/f/0PsMqN6oBJw5zkKhAdLK0RBeD6dPasI2eHhNg15GgAsSSgJ6A==@vger.kernel.org X-Gm-Message-State: AOJu0YzNOCnzq9dlXjJA6yxDgU2005IVT9e1verTkH0HYWpUaVhp8qwH ezLcJSUEIBgk/o8SzLIQuLK4m8T8m/jb4jpQ5zkcXV6jCVY0Q+9aFKXwenwzqlYidNCEFGvZuwF uHIfJGAUOO3/ZziHqSgu8sNtIq8qsMuwVLePf9dIH7xehmv6daMBWLkRV7WmVxjZNhA== X-Gm-Gg: ASbGnctRW4R1zop5IyT4MXaOLBmY1s5dQm6yP6DkekyIvHCGKG+YRanNQixBG14QbNE AGGa2unOBD3iFi/cK0iZiZMjqgk5u1sXjYy6aTK37hPiUIFYOrF545aRlmlZuxDScrnyrM59iuQ APB13dvrcFBtt3aBdmDEFftVsXhhUJmh2MfQlR9VbYfE4eXlrB+8lq1aoGIJwUT53R/Xssa9sfb Is9wfIhGpSE63gCPzZiLAOXige+ssFhz02MIHrjyqqBNd5ubg9jpO5s8iaT/38LUZGaxpdyU9nx u1LzIkst4Q3yyA3X8x7p2/lOUlnVOjkZ8jtPII56mEgZTwcXlIL1K9J5qVpyfX4G2DbI611X5sb 0JjpLFjUPyBTss9la/G71DzFXen4p1ULiEIDzNbJ4FX6P4E0= X-Received: by 2002:a05:6a20:9e46:b0:201:b65:81ab with SMTP id adf61e73a8af0-20cdee3caf9mr4468314637.23.1746191892770; Fri, 02 May 2025 06:18:12 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHfmJNczsGnet4Gkz0D0Mrc+1uQYNYpgTJdD3D/OrH8RLj2AReOWrjWS6ngfsAJXui1vi/DFg== X-Received: by 2002:a05:6a20:9e46:b0:201:b65:81ab with SMTP id adf61e73a8af0-20cdee3caf9mr4468279637.23.1746191892405; Fri, 02 May 2025 06:18:12 -0700 (PDT) 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 d2e1a72fcca58-74058dbb939sm1525886b3a.61.2025.05.02.06.18.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 May 2025 06:18:11 -0700 (PDT) From: Kathiravan Thirumoorthy Date: Fri, 02 May 2025 18:47:49 +0530 Subject: [PATCH v3 1/4] dt-bindings: sram: qcom,imem: Document IPQ5424 compatible Precedence: bulk X-Mailing-List: linux-watchdog@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250502-wdt_reset_reason-v3-1-b2dc7ace38ca@oss.qualcomm.com> References: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> In-Reply-To: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Wim Van Sebroeck , Guenter Roeck , bod.linux@nxsw.ie 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=1746191883; l=904; i=kathiravan.thirumoorthy@oss.qualcomm.com; s=20230906; h=from:subject:message-id; bh=kuc3nwD+lVGfX59PAIq28QGYc+7HorB/Mg6Kws2foiI=; b=/sHHOupQearhAFVBllGVOZfEFzBNF22HDoTAgH7WYVaI4fX3X44JA5y5wxWgp6h3W6sUcd+l9 uOliBBckz3YA/anqCFFTVYGYMufOfv/Wf1ruq4/P7npCMWEPH+SR3Vc X-Developer-Key: i=kathiravan.thirumoorthy@oss.qualcomm.com; a=ed25519; pk=xWsR7pL6ch+vdZ9MoFGEaP61JUaRf0XaZYWztbQsIiM= X-Authority-Analysis: v=2.4 cv=Ldc86ifi c=1 sm=1 tr=0 ts=6814c615 cx=c_pps a=mDZGXZTwRPZaeRUbqKGCBw==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=IkcTkHD0fZMA:10 a=dt9VzEwgFbYA:10 a=VwQbUJbxAAAA:8 a=EUspDBNiAAAA:8 a=7sp3e_VSdAcdU5CosJ0A:9 a=QEXdDO2ut3YA:10 a=zc0IvFSfCIW2DFIPzwfm:22 X-Proofpoint-GUID: wnVXQied8PxpUl3475gaSHYSOeiaGxZ7 X-Proofpoint-ORIG-GUID: wnVXQied8PxpUl3475gaSHYSOeiaGxZ7 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNTAyMDEwNSBTYWx0ZWRfX2TktQz8M635s AIYNpGrL64A4a1VR/tKzeGazHln2zQoQ532LoK4X3VhpzjG9gUZxfDodTGGP1cKlkomSS4vdIXM /tl0x3nnUAru43ispl5z1optbps1H99psI4DTY9kREbFfP0d9Y9iG2JvijarCnLh1gtBjOTdx3F YbvEcsJ+cCDCywB+oFv0FFyOIkvRAdfghu1qvOnpfNmJPUHWsXSC3ef3qGnyUhCocJZFvLAzLVI HBQGijzkNimU2cfqzFZ5CbR5ALvTwlAtv/1CS/hVtfoHULnQIXe7cHOkqTwMM9REUsnEia8JdoN fCHlvumPTDNAm3xsMBB4kCefmNzMqTMp2yUPUeUpNAvoNLPT04XisNfuKVXyIiqZZNPuC5Z4S3v 78oNfY4FTDdMetQQtZGt8evt1MM/JVksxjF3nytDpS9wfB3opHeT0JX9hYSJp/uFuZsBSXS0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-05-02_01,2025-04-30_01,2025-02-21_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 priorityscore=1501 phishscore=0 impostorscore=0 clxscore=1015 spamscore=0 bulkscore=0 mlxlogscore=948 malwarescore=0 mlxscore=0 suspectscore=0 adultscore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2504070000 definitions=main-2505020105 Add compatible for Qualcomm's IPQ5424 IMEM. Acked-by: Rob Herring (Arm) Signed-off-by: Kathiravan Thirumoorthy --- Changes in v3: - Picked up the A-b tag --- Documentation/devicetree/bindings/sram/qcom,imem.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/sram/qcom,imem.yaml b/Documentation/devicetree/bindings/sram/qcom,imem.yaml index 2711f90d9664b70fcd1e2f7e2dfd3386ed5c1952..dec1b1ee924cf1386f559eb262ea864f2788c165 100644 --- a/Documentation/devicetree/bindings/sram/qcom,imem.yaml +++ b/Documentation/devicetree/bindings/sram/qcom,imem.yaml @@ -18,6 +18,7 @@ properties: items: - enum: - qcom,apq8064-imem + - qcom,ipq5424-imem - qcom,msm8226-imem - qcom,msm8974-imem - qcom,msm8976-imem From patchwork Fri May 2 13:17:50 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kathiravan Thirumoorthy X-Patchwork-Id: 887133 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 8CDFE253938 for ; Fri, 2 May 2025 13:18:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191899; cv=none; b=S70CAcErXZcIjIuMKkCKSqcZ22h3hnNbLP8BCC4S5WARvZ1ge/AiqxRndq5Bb0ESkxG85LPBNhueTR9Sth6hNai1BnWDEi/YMU3rST4HDqpdBIF+9Ppgx33O5YYnG9GKNgdWDoviVRXafNHXjIrOSEXRfxNfq/toAmRwY6M3FaM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191899; c=relaxed/simple; bh=QSvt6ky/pJ8+VntHnwTRnuK5ob78/so6X2MfYNDfB8g=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=uAhUFaM3PeEblKHrzQM4HAjmA0+AwSqtDaQ9PCHf8RjNaOMjnDsd+v0bTFRs7AYZOjXVdvmKWCQ8r1oOWOwad+wuoN2yQKXhNCDbehPTqZ4USHzMjhAzp6pJ4Qgidb+Qbim5dR0ZRhyf0OrfloovFbVBC1UTJf8vpT9XymKBKB0= 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=FnXJzSlf; arc=none smtp.client-ip=205.220.168.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="FnXJzSlf" Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 5421N6Il023012 for ; Fri, 2 May 2025 13:18:18 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= L6s4iQJFnCYwc8Njw/Q7Od3/r3Tk3o0yQdVDAkClWD0=; b=FnXJzSlfLY34wiIg dQGkI/aUCoZ4pYufIcjFEsEM+NhNNkZKfhkRI6Z0YClsupcsRKUAwiAgbF7d1V1r HcmTO77h/IGBz2BMChQzt1ixMFGz+QWUzjOxbgsNRLWM7BceLyPezxF/m9rtvmLG MglEZRJ99jvCYTdjoBqDcHsI+1nq2syzstgEAxRAUB0ALn5K92pIQV7R8tVVDIHU Psd7f8PT8AV/hw26LgYhooBfGHU/Sfli0IPVxRWQdcZaI6CEZd9y/xhmzP6eU2qC Xv6rRSKHmeZOj5I/1gCa9M1VG+N/Ino1F4MgKp46spdS9Gzi1qCyG6BxNRmxBn9R oBcaXw== Received: from mail-pf1-f200.google.com (mail-pf1-f200.google.com [209.85.210.200]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 46b6u80dha-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 02 May 2025 13:18:17 +0000 (GMT) Received: by mail-pf1-f200.google.com with SMTP id d2e1a72fcca58-736b22717f1so1789284b3a.1 for ; Fri, 02 May 2025 06:18:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1746191897; x=1746796697; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=L6s4iQJFnCYwc8Njw/Q7Od3/r3Tk3o0yQdVDAkClWD0=; b=rBFA/g/zj5xx/qtGQmWomjGBffU1aQEQxpbH0zbKzl3x97c+9VFJXW7TIAdEKKv1y6 rxp7r+jfjgoYdjpfTldXsYjnoMNse2HZEYAyrd6JziMvMSiV0153GfmUiyxORTTJfiKs /KBGSnzNgI0kGGfA15X+A7T3iDeJ9Uodrqk0GfppFmqosJhVsi5XLqeby5Oy85HS7R1I qhINidul+1GF/C6ONNAFW1UK2rll8uTkgbhsjA3cq1rBKTLxwPWyWTs86GKFVu8kiWfj K+Q6/EfH35t+UHXhlFc2ceqiqLs7RsM3TZhBGWxVhQtJTflSajueEuBCUMtQskHkODsa frEA== X-Forwarded-Encrypted: i=1; AJvYcCX2aOKa5WK/hEOXhZVBiWDroKj4rUcy8x2q/fV+TXIA+D53sbexxk2IWqmJay3+oLe9WZDs5M9F4ydQqVJJXQ==@vger.kernel.org X-Gm-Message-State: AOJu0YzLTLoHR/JU/iGicdf92CfSAGwmxBvKM6KFO1MH1Fx8cVygS9Rf imEDoAS167kWyq2IHJ/ynJ9GCHpOZF/E21jNXAZSE4igPhNE1R5dsYgqVaMyfa75HjkkUyrEW2b mtFF45pwqm7YWjLuY9M9K4CB1aHlcvreNUF1gsCcZxNMNhbW0odf4j5dVnGIGMBdAtg== X-Gm-Gg: ASbGnctK4TM/Xu6T5/sOcJkUikGco9y/rWfLnC3rVxOkIXYmV/vaF9NiAI2BSo6KobB fYBdsSj4eoVsrHbK/1DGN/jbFPEVuwJEN9fc8xs3+OJyiOToYyJD6VrBiRUsMDtwvn+Wrvxzb8K 7l11jl1Fl1NZdiXMSbTxztKbAIBVGkusZv2q1EIpFE+xAmt91Va1Nt2umsF16AdXfpqHUBy1fiq DSaD6XCLNYLo6ZOQ0aGDBuglm/XKDjLzG0JaeMMTu6mWmIYVynQVMGiJh/7hGUR7nJ5iEgOwC17 zUOTSbpS16r0oFuA2mVBnQNgLD9qM4ZsjmlYYUyS21NREy2EF1UZvOMAVdgm64QlRQ2LBl+qb85 ri0tfd4kkq/LQCHqlFyUwn0LRvJBaOPVJBN6TblVBit1P32A= X-Received: by 2002:a05:6a21:3a4a:b0:20a:942:47e9 with SMTP id adf61e73a8af0-20ccbf32889mr4746738637.6.1746191897079; Fri, 02 May 2025 06:18:17 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHykiWgu6P5RWv+jpbrr8/w1EyzW13LNrNIfl/vAhCwU7yGp6LARSRGjcAThyA0Tgaw5qEwyQ== X-Received: by 2002:a05:6a21:3a4a:b0:20a:942:47e9 with SMTP id adf61e73a8af0-20ccbf32889mr4746681637.6.1746191896626; Fri, 02 May 2025 06:18:16 -0700 (PDT) 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 d2e1a72fcca58-74058dbb939sm1525886b3a.61.2025.05.02.06.18.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 May 2025 06:18:15 -0700 (PDT) From: Kathiravan Thirumoorthy Date: Fri, 02 May 2025 18:47:50 +0530 Subject: [PATCH v3 2/4] arm64: dts: qcom: ipq5424: Add the IMEM node Precedence: bulk X-Mailing-List: linux-watchdog@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250502-wdt_reset_reason-v3-2-b2dc7ace38ca@oss.qualcomm.com> References: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> In-Reply-To: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Wim Van Sebroeck , Guenter Roeck , bod.linux@nxsw.ie Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, Kathiravan Thirumoorthy , Konrad Dybcio X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1746191883; l=1449; i=kathiravan.thirumoorthy@oss.qualcomm.com; s=20230906; h=from:subject:message-id; bh=QSvt6ky/pJ8+VntHnwTRnuK5ob78/so6X2MfYNDfB8g=; b=d3E799PB6j36wxzktWjKR4doHuuJ6ScVx0OfTufOffofpFC5S7yVcCULFdN6gsES1++Dc9cHO 1XP9nlVvbcEB74cREnucq8d8i1rxwvoZDAJdtjIbt2gKxvMNw0I8rpU X-Developer-Key: i=kathiravan.thirumoorthy@oss.qualcomm.com; a=ed25519; pk=xWsR7pL6ch+vdZ9MoFGEaP61JUaRf0XaZYWztbQsIiM= X-Authority-Analysis: v=2.4 cv=Ldc86ifi c=1 sm=1 tr=0 ts=6814c619 cx=c_pps a=mDZGXZTwRPZaeRUbqKGCBw==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=IkcTkHD0fZMA:10 a=dt9VzEwgFbYA:10 a=EUspDBNiAAAA:8 a=QDJorwyCwNfNgOuVDpwA:9 a=QEXdDO2ut3YA:10 a=zc0IvFSfCIW2DFIPzwfm:22 X-Proofpoint-GUID: ehgaR71aKZlbdez5g-l8IdPCn6WN7FkU X-Proofpoint-ORIG-GUID: ehgaR71aKZlbdez5g-l8IdPCn6WN7FkU X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNTAyMDEwNSBTYWx0ZWRfXxpsFRbMsdXI0 2wn6enuMETT2qrLpyI4VW5E+DcT1Khn10AtW8NXIRfXiQR6CnxhrLRzu2awqgMAClKSLmzUeN2/ yNxEtUGhtYP6x4qR8YWxsPULFHpw7GWtCiqIxfRSxaERkpNBQUpNLcrIq5weBU/Tl/rUUPsdOWf GEwb2vL/suVUOtwHbhfqOvyQ1tPDt+BLiR/gPELpsAzK4GjveyDmwLL5zg6CYivkcBErlvXrYpe xC+stIADIyW0a5qVxKjO+0bQVgfKZTNLNmVr2r1TqUgdHD5W2rN+7g1ke7MLKEXYSagAixrlw3h HV0k4wEOwv3dYoMuGZp1eHHo0s+qdsxNGMuZ0nPxhKbsSIpcaZnRqm67Qy6AaYklOK9DPyriS5x lG7JI7oREmYB6En/X7yYACg/FTkzjYmr+3a5/vREpm735FJlUGujnL/MTOdD8HcL2HtdX8XK X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-05-02_01,2025-04-30_01,2025-02-21_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 priorityscore=1501 phishscore=0 impostorscore=0 clxscore=1015 spamscore=0 bulkscore=0 mlxlogscore=928 malwarescore=0 mlxscore=0 suspectscore=0 adultscore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2504070000 definitions=main-2505020105 Add the IMEM node to the device tree to extract debugging information like system restart reason, which is populated via IMEM. Define the IMEM region to enable this functionality. As described, overall IMEM region is 112KB but only initial 4KB is accessible by all masters in the SoC. Reviewed-by: Konrad Dybcio Signed-off-by: Kathiravan Thirumoorthy --- Changes in v3: - Picked up the R-b tag Changes in v2: - Describe the entire IMEM region in the node - Explicitly call out that initial 4K only accessible by all masters in the commit message --- arch/arm64/boot/dts/qcom/ipq5424.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/ipq5424.dtsi b/arch/arm64/boot/dts/qcom/ipq5424.dtsi index 5d6ed2172b1bb0a57c593f121f387ec917f42419..4f18ea79502738c2b9cb4b13e8eb4ac4ddd89adf 100644 --- a/arch/arm64/boot/dts/qcom/ipq5424.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq5424.dtsi @@ -486,6 +486,15 @@ ssphy_0: phy@7d000 { status = "disabled"; }; + sram@8600000 { + compatible = "qcom,ipq5424-imem", "syscon", "simple-mfd"; + reg = <0 0x08600000 0 0x1c000>; + ranges = <0 0 0x08600000 0x1c000>; + + #address-cells = <1>; + #size-cells = <1>; + }; + usb3: usb3@8a00000 { compatible = "qcom,ipq5424-dwc3", "qcom,dwc3"; reg = <0 0x08af8800 0 0x400>; From patchwork Fri May 2 13:17:51 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kathiravan Thirumoorthy X-Patchwork-Id: 886921 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 BD444254AF5 for ; Fri, 2 May 2025 13:18:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191904; cv=none; b=bIZ3y1Y/Thi6NkVl5h+FpKRsZLFX9URPZhTGBWazAWgmnx3yEeX4eV1A/4zpZzrKFAl7lRq6lAP7zq2X2GQpAlbxoyu6/p4JSnLrFkw5hIGWdLFxuInwuidRYoRQBmS9cKkENCEbOtqcMwBbmU5pG9B2AkrSzs9R75h8/ZUEags= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191904; c=relaxed/simple; bh=gwpUMbBpXzu5+reB0WmgsbjcDWnkBung9x+HZPAYJk4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=XBm0QPUI9eNRtnnhDylo36UMAToSiUvoryz0Z2XR7mWayEom1MPqLriiBJi1R3P0R8DdBmnB2yrvOBP8VtlC8t2KBQAnfnqncElut15fap+QTG7nIqK5aTjny1VAqjR0G3ZhNc/N4mM/rYClv51ALnu9L35eg8Jsd+zZTqmHvHw= 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=ELlXN9VT; arc=none smtp.client-ip=205.220.168.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="ELlXN9VT" Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 542D7Q8L016237 for ; Fri, 2 May 2025 13:18:22 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= 9vMvxizaT1xk4hie5Ubnws/xgswa1U+KGaDbkTzMKa0=; b=ELlXN9VTgH1/iTNv llV6kjC8VOW8N77AUJN1F8Rl0HWEqwvK0PQ3j3jvFqXlLBh1gG8rAzC4+O5YnFly u26TfYGxj8qplo2GVYowE6z5YOGvcBV/rosF6LD4UEj1fIsaPKMos502zsmwoOSg NJHnHiRa1FxHelydFsA39OG/L4DHzg+NBgGWjJ1vBqzVSj4TuZqYKYfI7EEHYyhj 2Ft2ddLFfcI/7OVhwEN6KPYz0WXtIULKlntMnLk/R51VFeNNmnEJvoeVRDbWMGHn OHorjxKAzb0KpIdWvSUjDUBZs2OofMvRt7VJfLUeQaPiftLMAhkW5JrHwO2RotPe d5QDkw== Received: from mail-pg1-f197.google.com (mail-pg1-f197.google.com [209.85.215.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 46b6u4gepu-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 02 May 2025 13:18:21 +0000 (GMT) Received: by mail-pg1-f197.google.com with SMTP id 41be03b00d2f7-b1b2fa98c39so2122957a12.2 for ; Fri, 02 May 2025 06:18:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1746191901; x=1746796701; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9vMvxizaT1xk4hie5Ubnws/xgswa1U+KGaDbkTzMKa0=; b=XG095xcXlN1kWUTlio103qSvYJ+4dcFIuPMEUQ1+iG7WJm1bBhi8/bOLTR+MjrMBA6 iTp6sodH717EwPwLyklFF9euL4rZwW0wGl+0q/F2yOFw93ZfjpPGjyFgX/L+idal+b8K qC1uaUM9VskPiGTvjYo1fxyn0Qtoqu/QL6RaADD+gN0lRRMt2sMFLJDvUVAB8WDNfQqg L+WCFgB3YgpeObJVIObpnLDBNeoQJDomFnLBtnsmV+0CBnU4Jnz5aOv4UmD7q2xVxmhu qGOoXboEaXR1D7j5/YO1h2MSe1fCq3RSwg79g6RdaK9rCKgz3q9DNTygaZTItQycvaZY ed1w== X-Forwarded-Encrypted: i=1; AJvYcCXUVld6cjA0IK4/hkaSZcZAQCGwuUaUXCCeBQzsSSW0d+5i6nzMAyR/pGYOXl5k6ew1X6+0ubk7Byt0wTD1cg==@vger.kernel.org X-Gm-Message-State: AOJu0YykiNMQVWXDLOxJaYM26pUqbw9Idey+xJbjR01BHoRXdKo+Pfwb hFVK7bskWP52V+9ArafFL43fsIIPG6qfisFuX4vkDOUAZWvT05YZjGCchgPnRIH1u28oDEa95mq wlPi5bXDNEG1/2v/H+kmU5hL5sy1ru1xOpmzQzo1juXyjqBmAJ4DVImIyZcD+GF7UgA== X-Gm-Gg: ASbGncukIR8BFjOGpcgy80TOfCAmFBX+CM8aOg6NL8fawxEkzperYspL/P7ZDuWB5CX HXDYcey/rDGLQbRTwRCOvI7BfBGkekxwoFIf3LvMJ6owMHITG1cR4t+W3z+cKdqRapZKSBkd17p Tx775wUTiy5zdrIiTGhkXvv+Ec3CZAUPOwfvA4zWBZNYe+cOyt8dnieyHroS1RfbvWIPYox/zO/ ArQ3prvm+RA0R5j8Pd0SW8uoiNA09bV+cE5Bh5WBR50hTho5ryuzAaxlz6yKHHFe8/uCusmqUWK DLbOpnpcPM9UfN5NvzbEmyT/MQQR337ur50SNfhfnd122+mgV7vCgEWKBdAPRrCFojiMAcAc4px b0DOFl7nsBEGyRZfJk8qhkueqS8imt2zE56HwZE3EFJPmZ/o= X-Received: by 2002:a05:6a21:1786:b0:1f5:8e39:9470 with SMTP id adf61e73a8af0-20cdfcfc862mr4645079637.31.1746191901009; Fri, 02 May 2025 06:18:21 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF3vWB64AN3R+aqhJiA646DNNY2YvW+T/GKptK3r5zllmEiCgaz3jFKpQSKdxiGPuXwx1gfIQ== X-Received: by 2002:a05:6a21:1786:b0:1f5:8e39:9470 with SMTP id adf61e73a8af0-20cdfcfc862mr4645043637.31.1746191900671; Fri, 02 May 2025 06:18:20 -0700 (PDT) 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 d2e1a72fcca58-74058dbb939sm1525886b3a.61.2025.05.02.06.18.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 May 2025 06:18:20 -0700 (PDT) From: Kathiravan Thirumoorthy Date: Fri, 02 May 2025 18:47:51 +0530 Subject: [PATCH v3 3/4] watchdog: qcom: introduce the device data for IPQ5424 watchdog device Precedence: bulk X-Mailing-List: linux-watchdog@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250502-wdt_reset_reason-v3-3-b2dc7ace38ca@oss.qualcomm.com> References: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> In-Reply-To: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Wim Van Sebroeck , Guenter Roeck , bod.linux@nxsw.ie 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=1746191883; l=1548; i=kathiravan.thirumoorthy@oss.qualcomm.com; s=20230906; h=from:subject:message-id; bh=gwpUMbBpXzu5+reB0WmgsbjcDWnkBung9x+HZPAYJk4=; b=QADu0rUVoDu09hkso28bhGRBNTAXFfxP7Jw8a5UPLjcywek9SbOlxtIcL9OL651RyGZyqZuF1 N/6HmcsbNCQAKIAVsjdaIssoRQ+FufXH5ZhXlR3+kHlahB0KOjDy4cI X-Developer-Key: i=kathiravan.thirumoorthy@oss.qualcomm.com; a=ed25519; pk=xWsR7pL6ch+vdZ9MoFGEaP61JUaRf0XaZYWztbQsIiM= X-Proofpoint-ORIG-GUID: cF497wJvK-Cbz8RylMWXQQ45x8laBwkh X-Authority-Analysis: v=2.4 cv=Yaq95xRf c=1 sm=1 tr=0 ts=6814c61d cx=c_pps a=rz3CxIlbcmazkYymdCej/Q==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=IkcTkHD0fZMA:10 a=dt9VzEwgFbYA:10 a=EUspDBNiAAAA:8 a=rRLmAKjRkRCCZZ2CrwwA:9 a=QEXdDO2ut3YA:10 a=bFCP_H2QrGi7Okbo017w:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNTAyMDEwNSBTYWx0ZWRfX9HgHUcp7f8zj B06lv+6Yst9Xx+2mLBraTKmL4bIiTktWAHhCdRn94MFwSisdt3zONofqj2iISTerL7eYUYIfNlQ tt58LmcpJWSGzGy24CfEl+qzCqJCeKlr/BE48VRdP+XcrSPjHdzSnZ5/tEyU/Eo6/v9IOdzhXts t5e4eydZpSOg1UrddJuzk2iSrJgwg+vpDjXBPSOvDNso3SZuwLy3bWqcR9vpIfTXOeUaHbFAlOJ 4IEXZAJ7uQexuCL9WB2WKqbZslL7d/p43jwBer0RlbdkG/J9ctistn/5ppauRqNVqQox43Dqfhi hbPOfW0EJC5W8r7nWXutkjJmPnWnT0l7Xznepr8W4GhltkCYvgqjhQZw3bp8JKzrzvpvIXGZ2dW 510Zey8mnx3ZhD23qycsA+0U+GZRUkecT5OZKoX0TlHZzd3G3WXZGb05YmSMHXjNFDZIWSLC X-Proofpoint-GUID: cF497wJvK-Cbz8RylMWXQQ45x8laBwkh X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-05-02_01,2025-04-30_01,2025-02-21_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 phishscore=0 clxscore=1015 suspectscore=0 bulkscore=0 mlxlogscore=999 malwarescore=0 mlxscore=0 priorityscore=1501 spamscore=0 lowpriorityscore=0 adultscore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2504070000 definitions=main-2505020105 To retrieve the restart reason from IMEM, certain device specific data like IMEM compatible to lookup, location of IMEM to read, etc should be defined. To achieve that, introduce the separate device data for IPQ5424 and add the required details subsequently. Signed-off-by: Kathiravan Thirumoorthy Reviewed-by: Guenter Roeck --- Changes in v3: - New patch --- drivers/watchdog/qcom-wdt.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/watchdog/qcom-wdt.c b/drivers/watchdog/qcom-wdt.c index 006f9c61aa64fd2b4ee9db493aeb54c8fafac818..dfaac5995c84c1f377023e6e62770c5548528a4c 100644 --- a/drivers/watchdog/qcom-wdt.c +++ b/drivers/watchdog/qcom-wdt.c @@ -181,6 +181,12 @@ static const struct qcom_wdt_match_data match_data_apcs_tmr = { .max_tick_count = 0x10000000U, }; +static const struct qcom_wdt_match_data match_data_ipq5424 = { + .offset = reg_offset_data_kpss, + .pretimeout = true, + .max_tick_count = 0xFFFFFU, +}; + static const struct qcom_wdt_match_data match_data_kpss = { .offset = reg_offset_data_kpss, .pretimeout = true, @@ -322,6 +328,7 @@ static const struct dev_pm_ops qcom_wdt_pm_ops = { }; static const struct of_device_id qcom_wdt_of_table[] = { + { .compatible = "qcom,apss-wdt-ipq5424", .data = &match_data_ipq5424 }, { .compatible = "qcom,kpss-timer", .data = &match_data_apcs_tmr }, { .compatible = "qcom,scss-timer", .data = &match_data_apcs_tmr }, { .compatible = "qcom,kpss-wdt", .data = &match_data_kpss }, From patchwork Fri May 2 13:17:52 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kathiravan Thirumoorthy X-Patchwork-Id: 887132 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 E9484255F5C for ; Fri, 2 May 2025 13:18:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191908; cv=none; b=Kwry0mGX3nABIyvWEkY0vRcyHz6QR6gCFtfhFTIrlHE4FQk5xZAprtg+zkXc1tD1znGbegMST3uv7wkU213xAs42QD8GyFE+V70Mmy7ZBExGEtU67pL85bIca747RShia7G50KVl6SVRfHx5HG+3M2EOf0WApq5Ed5CZL9biGq0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1746191908; c=relaxed/simple; bh=X/UXMHXf/RhMlrDKgR4/ge5TpOg8I3dflZnq+YhC0gg=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=uWH8EFEd0vsTLD5GWGdrRZC2XP+VwTSdAJOtgfdNt12CyTuJbxSEjfqLV0+Vbo8XNgWjfNpe8Kc8Q3a7ecZS/lXAGMXgO8oVwUcnBMqf//pOAxk8UxFMtqo2wJhh3wtYQ+y81Vbby8HQwaKjBTklamAy3koo3qh5vw/Y3vkX5EA= 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=fq2bSkYM; arc=none smtp.client-ip=205.220.168.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="fq2bSkYM" Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 542DBSww017711 for ; Fri, 2 May 2025 13:18:26 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= slRaTmGfvy9G5pnb2zsQsGNa8ozzrVBB4Ulmgs5zT0c=; b=fq2bSkYMyE5XOc2C sruvyiDJRJnK5lXHhgziF+2AWu7zpi4mlShNh+gsO/YM557etnfUgbqGMspxBePa 71xcMskhUJRWwaBdYUvsiGWUj6duBmFwGs7iLhqTdkqa8Piwi5hA8IveD3bes7x4 GRZ6GnuAZNx7C44hUnW0fKSSI0FNlM8U8Oa9TualmZj8herJ0NlZ7fpbtVYN/Orq 856V/ciu02h84Xia1L9M4oV1gKhfEX8bwgZHMQ2+m5nPfX+Yv1wq/w6u3QJZOQJq Wvm6y2KcK4sJBfGtMxGyaiWDgpFJFErTcbco3GlkJ8tnAlTfVSuxhIMFn8uJOuz4 HU3/mA== Received: from mail-pf1-f200.google.com (mail-pf1-f200.google.com [209.85.210.200]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 46b6u78dt3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 02 May 2025 13:18:25 +0000 (GMT) Received: by mail-pf1-f200.google.com with SMTP id d2e1a72fcca58-73917303082so1539200b3a.3 for ; Fri, 02 May 2025 06:18:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1746191905; x=1746796705; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=slRaTmGfvy9G5pnb2zsQsGNa8ozzrVBB4Ulmgs5zT0c=; b=ogw/xdJ7Z2FvJtXR/YNr7oqWH4RUonnCaPR1q2epaUOTgzHa1Z57Iq+250uHQoNlzD Vgi1DSru+1QlQQH4LXBBsvVvNYe4VG/sNSBD26e1e5vK/in/kn0i4ZuMGK0L2o9BojEs 4HecXPFlED9k0bcsPji4HB3OIN8PzVuEc4t8L5X+IAo+U5v9sE0GX86pxvy70lkPT9fI TfGp3UF8DBBvI8Rsji4jM/xTmVWbFW2bGbz/K0NZzba8Ae+bBdXozRMuC4m83NcmlTQL /hO9RL/qV6T1FJH7pLzfBif6J5Hj1lsYmY3aEZ1ymsnudR0MxeyrFEhU8bWAw5v+YX8Y PdBQ== X-Forwarded-Encrypted: i=1; AJvYcCWisdub29M0yb+JuS4P05iOYigHguCeIe7Z8Wh2rJx5ibuCmRLKeR9GhmOYDiTOLXbn/Jqo2PREv4TznDgJOA==@vger.kernel.org X-Gm-Message-State: AOJu0YylNy7qQfgXPOeWP0zz0ES+apTG6/KzbceuY4co51Z8tszp43pp tLJmly8T2OV50KweJ3179zK0nfeDtjA1zjrvXduC+iNlIa8v+hYGYJf9JtyryqCs0oHl/3T9rU6 WnivJSNTyaiRz/D+XAurTD0nOud75LS9DXAl0J9ztB2seqdCPzbcdj8oJyIO11g+6BQ== X-Gm-Gg: ASbGncssK8e9L+ZOoU543kvSesWUNm20gzci8tYMUIKEL3c65SUw+rXei4TRxxSm1T8 N0g1Hw+VzzjtjZGAB4mAW04+wpbOWit2Oyuq1pkUJjkUobV6jc1h4ELsjIl4e8mWvS+JA0SnkG0 oKeMfXXhULHfG+qsMv6DGMmwuUsIyzMZu4OtrbgbVaF5cUHVti0/deAy1LWbvUEV41ds/6Q9wwy iWI2WiB18DnZMWv2G1soPpom2DHH4evZonGz3M3g3LVOhB/7hFwXEtvYqOY4NOFyFDopFcBn+sF xEqKMsEotz05YH863L+5vkRPWTytmtxnHpA6RJD0MOwZqpg93NXGhhg57fHsIgCjyAYyJ/aBY5H 7xuWOlDLbd2wWdqzevOrxniEkuAYC4PnlSPucbqYyq6YSsy8= X-Received: by 2002:a05:6a21:a4c1:b0:1f5:7d57:8309 with SMTP id adf61e73a8af0-20cded42f75mr4269950637.21.1746191905038; Fri, 02 May 2025 06:18:25 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHIFfSud8d4mhQtZmSV13r5D5SAuSAGajEnvH4vksJceLIMOcleS8DtsqVRRObuGzRFbXdvnQ== X-Received: by 2002:a05:6a21:a4c1:b0:1f5:7d57:8309 with SMTP id adf61e73a8af0-20cded42f75mr4269912637.21.1746191904673; Fri, 02 May 2025 06:18:24 -0700 (PDT) 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 d2e1a72fcca58-74058dbb939sm1525886b3a.61.2025.05.02.06.18.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 May 2025 06:18:24 -0700 (PDT) From: Kathiravan Thirumoorthy Date: Fri, 02 May 2025 18:47:52 +0530 Subject: [PATCH v3 4/4] watchdog: qcom: add support to read the restart reason from IMEM Precedence: bulk X-Mailing-List: linux-watchdog@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250502-wdt_reset_reason-v3-4-b2dc7ace38ca@oss.qualcomm.com> References: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> In-Reply-To: <20250502-wdt_reset_reason-v3-0-b2dc7ace38ca@oss.qualcomm.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Wim Van Sebroeck , Guenter Roeck , bod.linux@nxsw.ie 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=1746191883; l=3927; i=kathiravan.thirumoorthy@oss.qualcomm.com; s=20230906; h=from:subject:message-id; bh=X/UXMHXf/RhMlrDKgR4/ge5TpOg8I3dflZnq+YhC0gg=; b=mat02aZTLGdQNdCaBVC5tsHJnRdKr/A8cgsxGVrffovzn5TYZj1m196gCiS+pmpV/7Lm7akLK +6a9BrRnogFCzDFNO43HFJOq6dSKkWmVH1Tx5Pl8FAlmjil6oY1ehtD X-Developer-Key: i=kathiravan.thirumoorthy@oss.qualcomm.com; a=ed25519; pk=xWsR7pL6ch+vdZ9MoFGEaP61JUaRf0XaZYWztbQsIiM= X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNTAyMDEwNSBTYWx0ZWRfX1TlrjoWl3dKj g+kwlW3tTPWiuesaAzAdjsBPmdy/j91qxJ5Ny0q7K7NzSrronx792q/asYtjJF9D5y7ZTBIk7P0 ZSnXD5a8H3+G9Hu1PH2zHeF6dLN2/owJljAifwUgTLKP/yxctAlDwdkcEDtWQDAX/tUCb3EzNad Cet/Fnx0fvXmnmbHLZDOL/IcICA3ch09hMuKrGaKW5gy87Bsj/zqZTjtryZucSsQesLzhbSgl3x BBQHThFO2JQ4y+p8R61eIGHFW8l44COTYGE9aecfDdeExcNgWL7XOhATVuiclX/r8B3tow8tH+p IUWt5lLLIFprlEgswb+6WdYFkidWPi/UiVYirQbY4kEd8JY66n89nZ0ierF0jBy6aMwl9VUckZA wuq+8Ynvib7vK4cpujAlT3oV/Xhsy1FwQmqy1qjAeIEZ47NE/CUiOLq5U8HaxwCleCb4Wv+7 X-Proofpoint-GUID: PGSnNVZLZtuRKSNaqMCjAKqQYD5pcocg X-Proofpoint-ORIG-GUID: PGSnNVZLZtuRKSNaqMCjAKqQYD5pcocg X-Authority-Analysis: v=2.4 cv=b6Wy4sGx c=1 sm=1 tr=0 ts=6814c622 cx=c_pps a=mDZGXZTwRPZaeRUbqKGCBw==:117 a=Ou0eQOY4+eZoSc0qltEV5Q==:17 a=IkcTkHD0fZMA:10 a=dt9VzEwgFbYA:10 a=EUspDBNiAAAA:8 a=sQLmF_3sjJ1lx0YqgBUA:9 a=QEXdDO2ut3YA:10 a=zc0IvFSfCIW2DFIPzwfm:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-05-02_01,2025-04-30_01,2025-02-21_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 mlxlogscore=999 impostorscore=0 bulkscore=0 phishscore=0 spamscore=0 priorityscore=1501 clxscore=1015 adultscore=0 suspectscore=0 mlxscore=0 malwarescore=0 classifier=spam authscore=0 authtc=n/a authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2504070000 definitions=main-2505020105 When the system boots up after a watchdog reset, the EXPIRED_STATUS bit in the WDT_STS register is cleared. To identify if the system was restarted due to WDT expiry, XBL update the information in the IMEM region. Update the driver to read the restart reason from IMEM and populate the bootstatus accordingly. 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 For backward compatibility, keep the EXPIRED_STATUS bit check. Add a new function qcom_wdt_get_restart_reason() to read the restart reason from IMEM. Signed-off-by: Kathiravan Thirumoorthy --- Changes in v3: - Split the introduction of device data into separate patch - s/bootloaders/XBL - for clarity of which bootloader is involved - Mention the sysfs path on to extract this information - s/compatible/imem_compatible in the device data structure to avoid the confusion / better naming Changes in v2: - Use the syscon API to access the IMEM region - Handle the error cases returned by qcom_wdt_get_restart_reason - Define device specific data to retrieve the IMEM compatible, offset and the value for non secure WDT, which allows to extend the support for other SoCs --- drivers/watchdog/qcom-wdt.c | 40 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/drivers/watchdog/qcom-wdt.c b/drivers/watchdog/qcom-wdt.c index dfaac5995c84c1f377023e6e62770c5548528a4c..f2cb8bfdf53a5090bcfff6ea3a23005b629ef948 100644 --- a/drivers/watchdog/qcom-wdt.c +++ b/drivers/watchdog/qcom-wdt.c @@ -7,9 +7,11 @@ #include #include #include +#include #include #include #include +#include #include enum wdt_reg { @@ -42,6 +44,9 @@ struct qcom_wdt_match_data { const u32 *offset; bool pretimeout; u32 max_tick_count; + const char *imem_compatible; + unsigned int restart_reason_offset; + unsigned int non_secure_wdt_val; }; struct qcom_wdt { @@ -185,6 +190,9 @@ static const struct qcom_wdt_match_data match_data_ipq5424 = { .offset = reg_offset_data_kpss, .pretimeout = true, .max_tick_count = 0xFFFFFU, + .imem_compatible = "qcom,ipq5424-imem", + .restart_reason_offset = 0x7b0, + .non_secure_wdt_val = 0x5, }; static const struct qcom_wdt_match_data match_data_kpss = { @@ -193,6 +201,29 @@ static const struct qcom_wdt_match_data match_data_kpss = { .max_tick_count = 0xFFFFFU, }; +static int qcom_wdt_get_restart_reason(struct qcom_wdt *wdt, + const struct qcom_wdt_match_data *data) +{ + struct regmap *imem; + unsigned int val; + int ret; + + imem = syscon_regmap_lookup_by_compatible(data->imem_compatible); + if (IS_ERR(imem)) + return PTR_ERR(imem); + + ret = regmap_read(imem, data->restart_reason_offset, &val); + if (ret) { + dev_err(wdt->wdd.parent, "failed to read the restart reason info\n"); + return ret; + } + + if (val == data->non_secure_wdt_val) + wdt->wdd.bootstatus = WDIOF_CARDRESET; + + return 0; +} + static int qcom_wdt_probe(struct platform_device *pdev) { struct device *dev = &pdev->dev; @@ -273,8 +304,13 @@ static int qcom_wdt_probe(struct platform_device *pdev) wdt->wdd.parent = dev; wdt->layout = data->offset; - if (readl(wdt_addr(wdt, WDT_STS)) & 1) - wdt->wdd.bootstatus = WDIOF_CARDRESET; + ret = qcom_wdt_get_restart_reason(wdt, data); + if (ret == -ENODEV) { + if (readl(wdt_addr(wdt, WDT_STS)) & 1) + wdt->wdd.bootstatus = WDIOF_CARDRESET; + } else if (ret) { + return ret; + } /* * If 'timeout-sec' unspecified in devicetree, assume a 30 second