Received: by 2002:a05:7412:b130:b0:e2:908c:2ebd with SMTP id az48csp2068968rdb; Mon, 20 Nov 2023 00:30:04 -0800 (PST) X-Google-Smtp-Source: AGHT+IEVdnk8tDFfweni8vBmIRg42eGBDYq8xV90+/IL0QOec1UqZBF7FYETEiYzU/q4U5TJE1D9 X-Received: by 2002:a17:903:4d:b0:1ce:5fa5:9056 with SMTP id l13-20020a170903004d00b001ce5fa59056mr10153092pla.3.1700469003933; Mon, 20 Nov 2023 00:30:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700469003; cv=none; d=google.com; s=arc-20160816; b=QQMsBtgYJGPtQo/Zdu1sCRuH77HaKomE2dgOhLCJfnZlaDf0/ql3uA+isG8vQUNT67 iGSQR/zQKSe/bF5TlASX+9XOo4kYUxSxJcNaz+0B+R7uHcoinGMaPFKwoFnBT2TEUSFB PlqUvUwh+zkDTkYxqhhT5ksIIWRU6FPSGYnBxQ545mxzs88SS5UPMf4+2I07uUdCBkIG kTbwUkNsPa9LWPpsTtbDPBmbXBw5cNYDIbl8o8AKWsUDeaGHLh8ozEMJRMxfjoYapcYP ACogya+unjtgBzKLt0az9BlkCm0QICQDPDcnSzVYHbymRzeKSh7HHbHnMBoOmvcQak+E LZgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:references:content-transfer-encoding :mime-version:cc:to:reply-to:from:subject:date:message-id :dkim-signature; bh=9xRxdPkNb9CdQ/Q6NXPFhnhrgqOozc2K2tKKVC/fkJg=; fh=ZmrMiEpHIU1k7ofC9Mf17QJwXuJU/u9JeCBYM5+79Y8=; b=b0B9UCH7oQP38rZ2UZtxLDfzJUH34SKZkrbDihqvKDWWz8yznKMPv30FLSWrtj54lC nwU4AeI9Kx9vrO+zn+d42Xw0qs1eZtcBpP6I+8GNpQSoRYk/YjX9yP3/R4c5UPTNlX0j dv7n9h+XKct3cYAUJEZe+Q4+FLy4RnjXd+AGSIb6RiF8CYtXMqAz1ABUMHo46x4iJNKw 06ZyPciMwD2+bVl1rXdQWJY/lZZklyq/ETUtLLqjgsFgLqR3AwjnECs6o3RXqHTZ4/20 No4OqyuwGz5r83HkVY4Rv2eevbvEySXnKgCqjmNEDE7/MbONFmqGpi1DSbAMwZ6hmpYo y8Bg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bigler.io header.s=20200409 header.b="B/H3/p95"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id j10-20020a17090276ca00b001bdca6456c3si7500735plt.46.2023.11.20.00.30.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Nov 2023 00:30:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@bigler.io header.s=20200409 header.b="B/H3/p95"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 32D75809FC8E; Mon, 20 Nov 2023 00:27:30 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232040AbjKTI1U (ORCPT + 99 others); Mon, 20 Nov 2023 03:27:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50028 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229635AbjKTI1T (ORCPT ); Mon, 20 Nov 2023 03:27:19 -0500 Received: from smtp-bc0c.mail.infomaniak.ch (smtp-bc0c.mail.infomaniak.ch [IPv6:2001:1600:4:17::bc0c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 264FDB9 for ; Mon, 20 Nov 2023 00:27:13 -0800 (PST) Received: from smtp-3-0000.mail.infomaniak.ch (unknown [10.4.36.107]) by smtp-3-3000.mail.infomaniak.ch (Postfix) with ESMTPS id 4SYgbg06tLzMq6V7; Mon, 20 Nov 2023 08:27:11 +0000 (UTC) Received: from unknown by smtp-3-0000.mail.infomaniak.ch (Postfix) with ESMTPA id 4SYgbf3Vgkz3W; Mon, 20 Nov 2023 09:27:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=bigler.io; s=20200409; t=1700468830; bh=hJY+0a7f7nMEG4eRpYQt92v8giqTHlccQnioHdPElB4=; h=Date:Subject:From:Reply-To:To:Cc:References:In-Reply-To:From; b=B/H3/p95yVi2IM+RHZ12uqxgevL1ibw0KOUL1IWgyYw6wM2e2wi0czH6+u2nkjlKk 8MnpqD3bdPAKA8V8ZhCPHRXEzLFktDSYjva5Y9B0p4cvx4IA1Xj1c0ARurFdm9Oznh CX9UYOtcHIIQU4WN8m6MeYiTSn0Meyhdn5qqjRmc= Message-ID: <86566391db9c5044f1a082bc8ec697a2@mail.infomaniak.com> Date: Mon, 20 Nov 2023 09:27:10 +0100 Subject: Re: spi: imx: Increase imx51 ecspi burst length fails on imx6dl and imx8mm From: linux@bigler.io Reply-To: linux@bigler.io To: Stefan Moring Cc: Linux regressions mailing list , Mark Brown , linux-kernel@vger.kernel.org, linux-spi@vger.kernel.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-WS-User-Origin: eyJpdiI6IkV3Mk5VdVY2d1h3dEFCTW1jQm16YXc9PSIsInZhbHVlIjoiTmlQSGxaQzR5OVg3ZDJycHZ5VUxodz09IiwibWFjIjoiMzMyNTdhZDkyYWVmYWVjZGQ2NmU4NDcwNGM5MmMyMDY4MjU2OTdiYjIwYWQwZjg0NjA0NDJmN2RlMWY1MmQ0MCIsInRhZyI6IiJ9 X-WS-User-Mbox: eyJpdiI6ImM5VDdoRWc5ZTBUMTNhcmplVDlOcGc9PSIsInZhbHVlIjoiaFlaUTNDVDZDT1RSN1dwTWF0MERudz09IiwibWFjIjoiNzJmNjRjYzI1NTdjMjI1NzA3ZTEzNTBhOGEwNzZmY2I2YjM5MmM3MzhmY2FmNWJkMDM0MTRkODA2NzVkMDJhNSIsInRhZyI6IiJ9 X-WS-Location: eJxzKUpMKykGAAfpAmU- X-Mailer: Infomaniak Workspace (1.3.596) References: <8a415902c751cdbb4b20ce76569216ed@mail.infomaniak.com> <2fcdd99eee9ee4f5d34fa1abab2f51bb@mail.infomaniak.com> In-Reply-To: X-Infomaniak-Routing: alpha X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Mon, 20 Nov 2023 00:27:30 -0800 (PST) Hi Stefan Thanks for analyzing the problem and sorry for the delay, I had to simplify= the code to a minimum so that I can send to you. Now I was able to use spidev. I have an environment with yocto kirstone 4.0.10. Load the spi-dma (imx-sdma 302c0000.dma-controller: loaded firmware 4.5), r= un the spi_imx and the spidev as kenelmodule. I run the code on a Toradex Verdin Development Board and use the imx8mm-ver= din-nonwifi-dev.dts To add the spidev I patched imx8mm-verdin.dtsi diff --git a/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi b/arch/arm64/= boot/dts/freescale/imx8mm-verdin.dtsi index 6f0811587142..262500940adc 100644 --- a/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi @@ -209,6 +209,15 @@ &ecspi2 { cs-gpios =3D <&gpio5 13 GPIO_ACTIVE_LOW>; pinctrl-names =3D "default"; pinctrl-0 =3D <&pinctrl_ecspi2>; + + spidev@0{ + compatible =3D "micron,spi-authenta"; + reg =3D <0>; + #address-cells =3D <1>; + #size-cells =3D <0>; + spi-max-frequency =3D <20000000>; + status =3D "okay"; + }; }; as a spidev test program I used=20 https://raw.githubusercontent.com/raspberrypi/linux/rpi-3.10.y/Documentatio= n/spi/spidev_test.c I changed the transmitted data diff --git a/recipes-spi/spidev/files/spidev_test.c b/recipes-spi/spidev/fi= les/spidev_test.c index 16feda9..6056ffd 100644 --- a/recipes-spi/spidev/files/spidev_test.c +++ b/recipes-spi/spidev/files/spidev_test.c @@ -39,13 +39,22 @@ static void transfer(int fd) { int ret; uint8_t tx[] =3D { - 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, - 0x40, 0x00, 0x00, 0x00, 0x00, 0x95, - 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, - 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, - 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, - 0xDE, 0xAD, 0xBE, 0xEF, 0xBA, 0xAD, - 0xF0, 0x0D, + 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, // 16 + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, // 32 + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x20, // 48 + 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, // 64 + 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, + 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10, // 80 + 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, + 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f, 0x20, // 96 + 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x28, + 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x20, // 112 + 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, // 127 }; uint8_t rx[ARRAY_SIZE(tx)] =3D {0, }; sending the content showed again the bad data spidev_test --device /dev/spidev1.0 --speed 20000000 --bpw 8 0x00,0x00,0x01, =20 0x00,0x00,0x00,0x02, 0x00,0x00,0x00,0x03, 0x00,0x00,0x00,0x04, I you need more information let me know. Best Regards Stefan Bigler Am 2023-11-19T08:52:54.000+01:00 hat Stefan Moring geschrieben: > Hi Stefan, >=20 > Can you maybe share me your test code? I can try to reproduce it tomorrow= . >=20 > Kind regards, >=20 > Stefan Moring