From: Sean Anderson Date: Tue, 4 Feb 2020 09:10:32 -0500 Subject: [PATCH v2] cmd: Ensure sf operates on spi flash In-Reply-To: References: <65962791-e8ca-ac64-9bc0-1de8f19d94d2@gmail.com> Message-ID: <3cade2c1-7d74-4afb-93ec-54037d210a7e@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 2/4/20 5:49 AM, Bin Meng wrote: > Hi Sean, > > On Mon, Jan 20, 2020 at 7:13 AM Sean Anderson wrote: >> >> Currently, the sf command will probe anything attached to an spi bus, regardless >> of whether it is UCLASS_SPI_FLASH. This came up when testing the mmc_spi driver, > > Did you do something like: > > => sf probe 1 0 sf probe 0, but yes. I forgot that my spi bus 0 had the SD card on it not the spi flash. I feel like this sort of thing should be caught by u-boot to prevent the user from almost certainly causing a segfault. --Sean