From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 765E3606A31A for ; Wed, 2 Dec 2026 09:06:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=rfc1149.net header.i=@rfc1149.net header.a=rsa-sha256 header.s=smtp header.b=b8NzGzDj Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1xYgHP-0007h9-Kk; Wed, 02 Dec 2026 04:05:35 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xYgHN-0007c1-3k; Wed, 02 Dec 2026 04:05:33 -0500 Received: from zoidberg.rfc1149.net ([195.154.227.159]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1xYgHL-0007xJ-3g; Wed, 02 Dec 2026 04:05:32 -0500 Received: from 127.0.0.1 (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange secp256r1 server-signature RSA-PSS (2048 bits) server-digest SHA256) (Client did not present a certificate) by zoidberg.rfc1149.net (Postfix) with ESMTPSA id A18F280022; Wed, 02 Dec 2026 10:05:19 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=rfc1149.net; s=smtp; t=1796202319; bh=dZ3dF7ZDLCI3GucZb29Xf09KP5NEc1T4zU6ykHZdYDw=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=b8NzGzDjojhJW+w7UVjKlFNHYZXB5P7geYd0/YAAzBnZY8rNPMcnMs5WH5AfAShDR rYlg3hIejfRFI6G03vpNkigb59ahVcvq5QMKFVv0yaoTX5+h0MQkfI2dg5tfyM1Sl0 c25Hf537mdIfhtF+ExXZTxHLUG/fsjL7Tfv1RwPaXVSVen9Fa0x1+1/yvjV4ZLphOW xXiptpk4PhGXbK6A65xqM6OZW19KqTm6mqXnZgDNL+lr31qC111+Uy1s6dOtBA2p6K HMRn4N9RlUCunt4IeuMTkmu7Sqp+AYrcKjpA5i6TcAqDGb10eH5nDDixmByZqbV/b2 8/yo9HWxL7RWw== From: Samuel Tardieu To: ~mohammadodeh Cc: qemu-devel@nongnu.org, Alexandre Iooss , Pierrick Bouvier , Peter Maydell , Paolo Bonzini , Alistair Francis , Kevin Wolf , Hanna Reitz , Fabiano Rosas , Laurent Vivier , Philippe =?utf-8?Q?Mathieu-Daud=C3=A9?= , Markus Armbruster , =?utf-8?Q?C=C3=A9dric?= Le Goater , Bernhard Beschow , Gaurav Sharma , Jan Kiszka , Bin Meng , Shameer Kolothum , Jamin Lin , =?utf-8?Q?Marc-Andr=C3=A9?= Lureau , qemu-arm@nongnu.org, qemu-block@nongnu.org Subject: Re: [PATCH qemu 2/3] hw/ssi: Add STM32L4x5 QuadSPI controller In-Reply-To: <179449578952.8382.2790865629085512841-2@git.sr.ht> References: <179449578952.8382.2790865629085512841-2@git.sr.ht> User-Agent: mu4e 1.14.4; emacs 31.1 Date: Wed, 02 Dec 2026 10:05:18 +0100 Message-ID: <87zeuocasx.fsf@rfc1149.net> X-Archived-By: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=195.154.227.159; envelope-from=sam@rfc1149.net; helo=zoidberg.rfc1149.net X-Spam_score_int: -19 X-Spam_score: -2.0 X-Spam_bar: -- X-Spam_report: (-2.0 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_CSS=0.1 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-arm@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-arm-bounces+qemu-arm=archiver.kernel.org@nongnu.org X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_PASS,SPF_PASS autolearn=no autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 ~mohammadodeh writes: > Model the STM32L4x5 QuadSPI controller indirect read and write modes. > Wire its clock, interrupt, and SSI bus into the STM32L4x5 SoC. > > Automatic polling, memory-mapped mode, and DMA are not implemented. Hi. While you check that the clock is properly connected at device realization time, you don't check that it's enabled before performing an operation on the peripheral. I've done some tests on real hardware (a b-l475e-iot01a board), and when the clock is disabled: - QSPI registers reads return 0 (tried with CR, DCR, and SR) - QSPI registers write are ignored (tried with DCR) - A JEDEC-ID command was ignored Enabling the clock again restores the content of the registers, and a 64 byte SFDP read stalled on a full FIFO survives the clock off/on sequence and can be completed afterwards. It means that turning the clock off doesn't reset any internal state, it just "suspends" the peripheral and returns 0 on read. Sam -- Samuel Tardieu