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=-12.3 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 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 B367CC4338F for ; Sun, 15 Aug 2021 14:23:19 +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 B431C61101 for ; Sun, 15 Aug 2021 14:23:18 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org B431C61101 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=konsulko.com 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 6E38A817D3; Sun, 15 Aug 2021 16:23:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="IXfbHdyM"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 8D0DD81D6C; Sun, 15 Aug 2021 16:23:14 +0200 (CEST) Received: from mail-qt1-x82d.google.com (mail-qt1-x82d.google.com [IPv6:2607:f8b0:4864:20::82d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id B312F817D3 for ; Sun, 15 Aug 2021 16:23:07 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qt1-x82d.google.com with SMTP id d9so12247995qty.12 for ; Sun, 15 Aug 2021 07:23:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=TdsKfPHwJJ/PZKpcw1EYB6oZriJyB2PYEK4+l8bVDkk=; b=IXfbHdyMeHoirERTPqceEDJ76aVJUoF5UAxdjTlY5BGytFo8ZH68yaRs10T3oilBjX 0kHduwEBuQwtfrcW0Lo3tWrhIO81CemYx8qAN12ZArIdsM9phm68M7GOkD63exU3N+nn VUo4iveRU+XBD2w1J8k1b8lBjW2GNvXddVNrs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=TdsKfPHwJJ/PZKpcw1EYB6oZriJyB2PYEK4+l8bVDkk=; b=ZMjB1l/ky//bC+WfVSpzBrHEgcaiMTEGMfFQ3w3WT6xXNCGEQDaeSmicjKGyqyCDbj KMBeQhVPdfjcQiH9y1XUrtGMUoZlj1tvwAsne9f7rNcJhI2hLpSUIrSFCW256iW5DC6n kAUpX82uomP1aqCYp2FcpfULFQDq7KuHyLvY4BMsRyJasOz1AxK7xdyXZZMD6gGNWmSh qNbp61fzJNBT17+0B7wIkyGzrweyxUK63ZVDyKoC1sFYg0cKk3o5RuOMUS+SR1QbVBpX 0unzpTJlXzbnfLmyMr3v3Sw8/4eMCSrNIluXcvXaTbbDyMp/G5TEe02vtNrMBZIy9Gi8 dbzA== X-Gm-Message-State: AOAM531QOE0AekauPvOkphqJLt8nCGs0nuO3P5D/kJ8DsjV6PmIBropt nJfHrBTBrib4pymUxYnP5mT2FA== X-Google-Smtp-Source: ABdhPJz0tiv2DW6ar+Tc1MVvZDHuZxArTwJYcVcIY1K3e1CKMlalb9ir8k3lSJCvmXWO1Z/WAOh47g== X-Received: by 2002:ac8:4e8c:: with SMTP id 12mr9955200qtp.242.1629037386271; Sun, 15 Aug 2021 07:23:06 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b01-cbda-6085-4c50-20fd-dcb7.res6.spectrum.com. [2603:6081:7b01:cbda:6085:4c50:20fd:dcb7]) by smtp.gmail.com with ESMTPSA id b21sm3522713qte.38.2021.08.15.07.23.04 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sun, 15 Aug 2021 07:23:05 -0700 (PDT) Date: Sun, 15 Aug 2021 10:23:03 -0400 From: Tom Rini To: Pali =?iso-8859-1?Q?Roh=E1r?= Cc: Simon Glass , Stefan Roese , Masami Hiramatsu , Frank Wunderlich , Marek =?iso-8859-1?Q?Beh=FAn?= , U-Boot Mailing List Subject: Re: Broken CONFIG_SPL_SATA_SUPPORT=y Message-ID: <20210815142303.GJ858@bill-the-cat> References: <20210802212554.knnm6ndingwooz5k@pali> <20210802214322.GJ9379@bill-the-cat> <20210802215658.vcdxtx6u7tfsi3od@pali> <20210802221120.GM9379@bill-the-cat> <20210802223819.2xh6i6n5d7sxispl@pali> <20210802224648.GO9379@bill-the-cat> <20210802233353.xsqwyrfdkkdju2h2@pali> <20210803014007.GP9379@bill-the-cat> <20210815114826.ccai4fddhxuqjar2@pali> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="2NUUivEUh6/D4/qT" Content-Disposition: inline In-Reply-To: <20210815114826.ccai4fddhxuqjar2@pali> X-Clacks-Overhead: GNU Terry Pratchett User-Agent: Mutt/1.9.4 (2018-02-28) 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 --2NUUivEUh6/D4/qT Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Aug 15, 2021 at 01:48:26PM +0200, Pali Roh=E1r wrote: > On Monday 02 August 2021 21:40:07 Tom Rini wrote: > > OK, thanks. Then the right fix is to introduce whatever SPL_xxx symbols > > you need so that you can turn off what you don't want in SPL but leave > > it enabled in full U-Boot, and update the code to use > > CONFIG_IS_ENABLED(xxx). If you can do that part, I can iterate over > > converting everyone else that assumes what we have today is what it > > wants in SPL and non-SPL. >=20 > Hello Tom! Below is patch which adds SPL_AHCI_PCI symbol. I'm not sure > if this is correct approach but it looks like that it fixed that issue. > With this patch I can compile U-Boot with and also without enabling of > CONFIG_SPL_SATA_SUPPORT option. >=20 >=20 > diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig > index 0c1490a9f900..96c7c30375bd 100644 > --- a/drivers/ata/Kconfig > +++ b/drivers/ata/Kconfig > @@ -41,6 +41,12 @@ config AHCI_PCI > help > Enables support for the PCI-based AHCI controller. > =20 > +config SPL_AHCI_PCI > + bool "Support for PCI-based AHCI controller for SPL" > + depends on SPL > + depends on SPL_PCI > + depends on SPL_SATA_SUPPORT && DM_SCSI > + > config SATA_CEVA > bool "Ceva Sata controller" > depends on AHCI > diff --git a/drivers/ata/Makefile b/drivers/ata/Makefile > index 4811b2f82c4e..cd88131dcd13 100644 > --- a/drivers/ata/Makefile > +++ b/drivers/ata/Makefile > @@ -5,7 +5,7 @@ > =20 > obj-$(CONFIG_DWC_AHCI) +=3D dwc_ahci.o > obj-$(CONFIG_AHCI) +=3D ahci-uclass.o > -obj-$(CONFIG_AHCI_PCI) +=3D ahci-pci.o > +obj-$(CONFIG_$(SPL_)AHCI_PCI) +=3D ahci-pci.o > obj-$(CONFIG_SCSI_AHCI) +=3D ahci.o > obj-$(CONFIG_DWC_AHSATA) +=3D dwc_ahsata.o > obj-$(CONFIG_FSL_SATA) +=3D fsl_sata.o Looks right to me, please submit it as a proper patch, thanks! --=20 Tom --2NUUivEUh6/D4/qT Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmEZI0QACgkQFHw5/5Y0 tyzYNQwAnGfao7S0Awv8Umjo90EaaxBm1hHutU/zMMFlgb+l6Rj18eMvrRnqtHDD zHLV+iGFosAtkE9ycnN3TREOn/UQ621vpt5pFKoVP88GA7BGc6lAQZeQmggzRHD8 q3avHh+cAbCyC8BRxIwrd5CvZHPn7tXVVvy+lDGTZKyrbso9I82DRzaCqBNHkDlT Z/hNtEE3f9C/BUJ0TxJTJXvFg1uBMAB+LsNORPpkTm+rF9Zf2V85n14HtPtjN/zF Wl0blCaoz8ReBiJtnvZ6xv1WR3xaZlVK7OxJyJQziJacMzGAuMBL1xeO5j/on0gn S6obFb+z1JZ7cDYROFgomCMB3OeDIQd8J2k+4SK96lM9HO1lHGNhJliQN+MoWjit rV3WaTO+Hhh4cWj60/bNh+1kWMlZHBRu5f2wuCMeNoYYpLWBeZdMo9jtmuAniAJV zkB4etxa6NoqziBk2dAcy4O7ChPenFigrPYJxxZKi2JxSKfEg+YcdTGSZsiroofN sjYJZ1+2 =QTs8 -----END PGP SIGNATURE----- --2NUUivEUh6/D4/qT--