All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: "Cheng, Xuzhou" <Xuzhou.Cheng@windriver.com>,
	Bin Meng <bmeng.cn@gmail.com>
Cc: "Peter Maydell" <peter.maydell@linaro.org>,
	"QEMU Developers" <qemu-devel@nongnu.org>,
	"Alistair Francis" <alistair@alistair23.me>,
	"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
	"Jean-Christophe Dubois" <jcd@tribudubois.net>,
	qemu-arm <qemu-arm@nongnu.org>
Subject: Re: [PATCH] hw/ssi: imx_spi: Improve chip select handling
Date: Wed, 8 Sep 2021 09:52:50 -0700	[thread overview]
Message-ID: <8b86d434-a2e6-8122-0a88-dc9a15fbfe87@roeck-us.net> (raw)
In-Reply-To: <PH0PR11MB5205AE78D6C5DFFFA767183B97D49@PH0PR11MB5205.namprd11.prod.outlook.com>

On 9/8/21 2:05 AM, Cheng, Xuzhou wrote:
> Thanks Bin added me into this loop.
> 
> Hi, Guenter
> 
> I am interested in your patch and the issue what you found. I want to reproduce your issue on Linux, but I failed, the spi-nor of sabrelite on Linux does not work.
> 
> Could you share your Linux kernel version? It would be great if you can share the detailed steps to reproduce.
> 
> My test record:
> Linux version: https://github.com/torvalds/linux, the last commit is ac08b1c68d1b1ed3cebb218fc3ea2c07484eb07d.
> Linux configuration: imx_v6_v7_defconfig.
> 
> QEMU command:
> qemu-system-arm -nographic -M sabrelite -smp 4 -m 1G -serial null -serial /dev/pts/50 -kernel zImage -initrd rootfs.ext4 -append "root=/dev/ram rdinit=sbin/init" -dtb imx6q-sabrelite.dtb -net nic -net tap,ifname=tap_xcheng,script=no -drive file=flash.sabre,format=raw,if=mtd
> 
> Logs: there are same logs when I apply your patch or not apply. So I don't understand what this patch fixes, maybe I missed something? :(...
> 
> # cat /proc/mtd
> dev:    size   erasesize  name
> mtd0: 00200000 00001000 "spi0.0"
> # ls /dev/mtd*
> /dev/mtd0       /dev/mtd0ro     /dev/mtdblock0
> # echo "01234567899876543210" > test
> # dd if=test of=/dev/mtd0  /* flash.sabre is empty */
> 0+1 records in
> 0+1 records out
> # dd if=/dev/mtd0 of=test_out
> 4096+0 records in
> 4096+0 records out
> # cat test_out             /* test_out is empty */
> 

It is a flash. I don't think dd erases the flash, so unless your flash.sabre
is all-ones you probably won't see the overwritten data.

Guenter


  reply	other threads:[~2021-09-08 16:53 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-08  1:34 [PATCH] hw/ssi: imx_spi: Improve chip select handling Guenter Roeck
2021-09-02 15:58 ` Peter Maydell
2021-09-02 16:09   ` Guenter Roeck
2021-09-02 19:29     ` Peter Maydell
2021-09-04 17:13       ` Guenter Roeck
2021-09-04 23:06         ` Bin Meng
2021-09-04 23:19           ` Philippe Mathieu-Daudé
2021-09-05  2:08             ` Guenter Roeck
2021-09-08  6:29               ` Bin Meng
2021-09-08  6:31                 ` Bin Meng
2021-09-08  9:05                   ` Cheng, Xuzhou
2021-09-08 16:52                     ` Guenter Roeck [this message]
2021-09-16 10:21                       ` Cheng, Xuzhou
2021-09-16 14:21                         ` Guenter Roeck
2021-09-18  3:09                           ` Cheng, Xuzhou
2021-09-18  4:19                             ` Guenter Roeck
2021-09-26  2:49                               ` Bin Meng
2021-10-01 13:04                                 ` Guenter Roeck
2021-09-05  2:05           ` Guenter Roeck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8b86d434-a2e6-8122-0a88-dc9a15fbfe87@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=Xuzhou.Cheng@windriver.com \
    --cc=alistair@alistair23.me \
    --cc=bmeng.cn@gmail.com \
    --cc=f4bug@amsat.org \
    --cc=jcd@tribudubois.net \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.