From patchwork Mon Jun 26 14:59:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 697018 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9BA41EB64DA for ; Mon, 26 Jun 2023 15:00:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229663AbjFZPAJ (ORCPT ); Mon, 26 Jun 2023 11:00:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60532 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229922AbjFZPAI (ORCPT ); Mon, 26 Jun 2023 11:00:08 -0400 Received: from mail-wr1-x430.google.com (mail-wr1-x430.google.com [IPv6:2a00:1450:4864:20::430]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9890D10A for ; Mon, 26 Jun 2023 08:00:05 -0700 (PDT) Received: by mail-wr1-x430.google.com with SMTP id ffacd0b85a97d-3112c11fdc9so2906404f8f.3 for ; Mon, 26 Jun 2023 08:00:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1687791604; x=1690383604; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=ysbiVMlRUPpmijvxEgiqELqD4pocrI8KujWeqKckrNk=; b=rxS+vi8VhGBDXLjpUQcsEhtzPnyVlg1GpEc72GOwk1v07t5i1xxdc4FvqFuJPThvnc 6tw0DaAPUYNCpOVkWW1maSwwu4be/ugnVKpuYrQtw7mYqtLCRnLYstsXEGgz1/zG0R6i JrEPstX17B7jx2V/aJbePsMziYnB+26omlQ0wbAABSllNmOIo44VDPFrOR+Dra9XQHZE PblvkvD/5/bogBc6PrYgJ1x3bahrGFlEhPBmlX8hhMbxhDpRtrQ8vYrqtxzwFJ98UoUx zfBycvUU0ukCpc2xTKq4M7932LqCa9ob01W3o3QVpFn7Bs/RLthho8a6Rg1EisyGfkI2 lrww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687791604; x=1690383604; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ysbiVMlRUPpmijvxEgiqELqD4pocrI8KujWeqKckrNk=; b=IC+Xc/ZEM9tHpSTi6x9AVX6at/HhmQrRtEoJupkrgo8jvUCjez16fA391it7OFV43T MXB7Y48RziIgoGx39sqhYK+zrijVH11QVK/5SY/hxEOxPlV73sJuPQh8FQC06qhKhZEr 6iOfMRFQgDcgSqQdBspXjsVIBsGoF3IzSGWnKn5VV1KphdbKN6sfEAF2lj/a9lb7I4Do nVF5MRDDK4z1ut9FYRc6OFYUKEDplIzsO3408xHBXXEeEvfKyjyBg6yWsq8eQNgHuWQO 4lSysait5mR47vtlKffImz/5yd7MzX9eHjUr+20oFp18E/rOJa2j1Uv0IO8d2d1OJX71 zK9A== X-Gm-Message-State: AC+VfDxNDv4dZvNaQ4fNyCf5SsvcVuh8/5v/yTbuq/KfvhQxkcXt2cg9 bWr2ZlOQGDu0bniLLlmPaiPpkw== X-Google-Smtp-Source: ACHHUZ7udFgKBee119WAQc9HfTv87IIlEp5QgIr91900E3CZgGj828TfAtq4gdInkQIw8Q/mNE+WyQ== X-Received: by 2002:a5d:4ad0:0:b0:313:f98a:1fd3 with SMTP id y16-20020a5d4ad0000000b00313f98a1fd3mr29021wrs.27.1687791603958; Mon, 26 Jun 2023 08:00:03 -0700 (PDT) Received: from krzk-bin.. ([178.197.219.26]) by smtp.gmail.com with ESMTPSA id m16-20020a5d6250000000b003068f5cca8csm7585484wrv.94.2023.06.26.08.00.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Jun 2023 08:00:03 -0700 (PDT) From: Krzysztof Kozlowski To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bhupesh Sharma , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Krzysztof Kozlowski , Manivannan Sadhasivam , Luca Weiss Subject: [PATCH v2] arm64: dts: qcom: sm8350: fix BAM DMA crash and reboot Date: Mon, 26 Jun 2023 16:59:59 +0200 Message-Id: <20230626145959.646747-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org SM8350 HDK and MTP boards were silently dying and rebooting during BAM DMA probe, probably during reading BAM_REVISION register: [ 1.574304] vreg_bob: Setting 3008000-3960000uV [ 1.576918] bam-dFormat: Log Type - Time(microsec) - Message - Optional Info Log Type: B - Since Boot(Power On Reset), D - Delta, S - Statistic S - QC_IMAGE_VERSION_STRING=BOOT.MXF.1.0-00637.1-LAHAINA-1 S - IMAGE_VARIANT_STRING=SocLahainaLAA S - OEM_IMAGE_VERSION_STRING=crm-ubuntu77 S - Boot Interface: UFS It seems that BAM DMA is not yet operational, thus mark it as failed and disable also QCE because it won't work without BAM DMA. Fixes: f1040a7fe8f0 ("arm64: dts: qcom: sm8350: Add Crypto Engine support") Signed-off-by: Krzysztof Kozlowski --- Changes in v2: 1. Disable the nodes instead of failing the probe. Due to this change, no Reviewed/Tested tags. Cc: Manivannan Sadhasivam Cc: Luca Weiss --- arch/arm64/boot/dts/qcom/sm8350.dtsi | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8350.dtsi b/arch/arm64/boot/dts/qcom/sm8350.dtsi index 88ef478cb5cc..ec451c616f3e 100644 --- a/arch/arm64/boot/dts/qcom/sm8350.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8350.dtsi @@ -1744,6 +1744,8 @@ cryptobam: dma-controller@1dc4000 { qcom,controlled-remotely; iommus = <&apps_smmu 0x594 0x0011>, <&apps_smmu 0x596 0x0011>; + /* FIXME: Probing BAM DMA causes some abort and system hang */ + status = "fail"; }; crypto: crypto@1dfa000 { @@ -1755,6 +1757,8 @@ crypto: crypto@1dfa000 { <&apps_smmu 0x596 0x0011>; interconnects = <&aggre2_noc MASTER_CRYPTO 0 &mc_virt SLAVE_EBI1 0>; interconnect-names = "memory"; + /* FIXME: dependency BAM DMA is disabled */ + status = "disabled"; }; ipa: ipa@1e40000 {