Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 80574C433EF for ; Tue, 14 Sep 2021 18:28:51 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 716B260F58 for ; Tue, 14 Sep 2021 18:28:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 716B260F58 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E21D382C7D; Tue, 14 Sep 2021 20:28:47 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1631644128; bh=ydX2mbiXMLyLxFldSo+dBhL04djit0Nz2Li0W2C16k0=; h=From:To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From; b=qGiYVFdgCiLLk2PWNIJS+ePAUl29S4o4SXJGEiTCnQHJC3rVwlb05hlFzPuBo2rcm UGoKaoCZYKWeO46g+rqaEnlhpzk9VZO+7MGKqcItFSoe8WBc7yiU/ePiMnN/DzTL3e BX2v9ZHVk/bBBYMouOfY+KC1Ii6L9V1ugUUBYMmayhon/4QbLwDHDhKo7nPrmS4Y9g joI+aPNp9EXwzxTkI9x6Dg7sLsD2Xi5XseTM9O7DBEhWG6f0B9BDJGOM0Hx5IhzL58 zKeLp5yWDFpxBgw53Noaje838m9VWxO3ROg/h/FxykKq3PNmUmtjNmGGAg/h4HUj9k wJhSrc0H1qhpQ== Received: from tr.lan (ip-89-176-112-137.net.upcbroadband.cz [89.176.112.137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 37A9982039; Tue, 14 Sep 2021 20:28:45 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1631644126; bh=ydX2mbiXMLyLxFldSo+dBhL04djit0Nz2Li0W2C16k0=; h=From:To:Cc:Subject:Date:From; b=lqxqUahp0W631stChv4JYpyQJGGsjGGpNvrMM/jVxmHyCzKSEjYw1y9QvPhXGw89O Lyo0Z44uu/SWHiGcDMSUj0uqjqy+iEmx+k0nrAXCLOc6+gWqtvIBogwnkv65s/W11N ww7up6TUpM8j7IGx1P9hv0ZhgThVpw6aXS++TmkmvnBuAB3duYKKYCUl6rHNvPS/8l xhMka6LXVaZpqo81Oe3qNncLYpm4AiFV4WkSD7b57hk6nRu0GFmkFq9gXJukWPaSdr GEwD7fHv11OXtC17csr+7IQEnaZN3CJjQfH5XY8lgrd8Af8rLR9xoINY1qaWYxZTnj wgpIMl+Ev/WIQ== From: Marek Vasut To: u-boot@lists.denx.de Cc: Marek Vasut , Aleksandar Gerasimovski , Andreas Biessmann , Eugen Hristev , Michal Simek , Patrice Chotard , Patrick Delaunay , Peng Fan , Siew Chin Lim , Tom Rini , Valentin Longchamp , Vignesh Raghavendra Subject: [RFC][PATCH] mtd: spi: Set CONFIG_SF_DEFAULT_MODE default to 0 Date: Tue, 14 Sep 2021 20:28:24 +0200 Message-Id: <20210914182824.139667-1-marex@denx.de> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Before e2e95e5e254 ("spi: Update speed/mode on change") most systems silently defaulted to SF bus mode 0. Now the mode is always updated, which causes breakage. It seems most SF which are used as boot media operate in bus mode 0, so switch that as the default. This should fix booting at least on Altera SoCFPGA, ST STM32, Xilinx ZynqMP, NXP iMX and Rockchip SoCs, which recently ran into trouble with mode 3. Marvell Kirkwood and Xilinx microblaze need to be checked as those might need mode 3. Signed-off-by: Marek Vasut Cc: Aleksandar Gerasimovski Cc: Andreas Biessmann Cc: Eugen Hristev Cc: Michal Simek Cc: Patrice Chotard Cc: Patrick Delaunay Cc: Peng Fan Cc: Siew Chin Lim Cc: Tom Rini Cc: Valentin Longchamp Cc: Vignesh Raghavendra --- drivers/mtd/spi/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/spi/Kconfig b/drivers/mtd/spi/Kconfig index b2291f72905..f03fe05e333 100644 --- a/drivers/mtd/spi/Kconfig +++ b/drivers/mtd/spi/Kconfig @@ -57,7 +57,7 @@ config SF_DEFAULT_CS config SF_DEFAULT_MODE hex "SPI Flash default mode (see include/spi.h)" depends on SPI_FLASH || DM_SPI_FLASH - default 3 + default 0 help The default mode may be provided by the platform to handle the common case when only a single serial -- 2.33.0