* [U-Boot] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol
@ 2018-07-25 0:02 Andre Przywara
2018-07-25 7:39 ` Maxime Ripard
2018-08-13 10:29 ` [U-Boot] [linux-sunxi] " Jagan Teki
0 siblings, 2 replies; 5+ messages in thread
From: Andre Przywara @ 2018-07-25 0:02 UTC (permalink / raw)
To: u-boot
"default" lines in Kconfig are processed in order, the first hit will
stop considering subsequent lines. In the case of the DRAM_ODT_EN symbol
that means that everything following the first two lines will never be
checked:
------------
config DRAM_ODT_EN
bool "sunxi dram odt enable"
default n if !MACH_SUN8I_A23
default y if MACH_SUN8I_A23
default y if MACH_SUN8I_R40
default y if MACH_SUN50I
------------
Assuming that the "default y" for the A64 and the R40 were a deliberate
choice, fix the Kconfig stanza to take this into account.
Also remove the now redundant lines from the respective defconfigs.
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
Hi,
I would be grateful if people could test this and find out whether
enabling ODT works reliably.
Thanks!
Andre.
arch/arm/mach-sunxi/Kconfig | 2 +-
configs/Bananapi_M2_Ultra_defconfig | 1 -
configs/amarula_a64_relic_defconfig | 1 -
configs/bananapi_m2_berry_defconfig | 1 -
configs/sopine_baseboard_defconfig | 1 -
5 files changed, 1 insertion(+), 5 deletions(-)
diff --git a/arch/arm/mach-sunxi/Kconfig b/arch/arm/mach-sunxi/Kconfig
index 678e33dd40..7ff0347e20 100644
--- a/arch/arm/mach-sunxi/Kconfig
+++ b/arch/arm/mach-sunxi/Kconfig
@@ -405,10 +405,10 @@ config DRAM_ZQ
config DRAM_ODT_EN
bool "sunxi dram odt enable"
- default n if !MACH_SUN8I_A23
default y if MACH_SUN8I_A23
default y if MACH_SUN8I_R40
default y if MACH_SUN50I
+ default n
---help---
Select this to enable dram odt (on die termination).
diff --git a/configs/Bananapi_M2_Ultra_defconfig b/configs/Bananapi_M2_Ultra_defconfig
index edcbb16cf6..914ca09708 100644
--- a/configs/Bananapi_M2_Ultra_defconfig
+++ b/configs/Bananapi_M2_Ultra_defconfig
@@ -4,7 +4,6 @@ CONFIG_SPL=y
CONFIG_MACH_SUN8I_R40=y
CONFIG_DRAM_CLK=576
CONFIG_DRAM_ZQ=3881979
-CONFIG_DRAM_ODT_EN=y
CONFIG_MMC0_CD_PIN="PH13"
CONFIG_MMC_SUNXI_SLOT_EXTRA=2
CONFIG_DEFAULT_DEVICE_TREE="sun8i-r40-bananapi-m2-ultra"
diff --git a/configs/amarula_a64_relic_defconfig b/configs/amarula_a64_relic_defconfig
index b72cbfabc6..9ab4c0c1de 100644
--- a/configs/amarula_a64_relic_defconfig
+++ b/configs/amarula_a64_relic_defconfig
@@ -3,7 +3,6 @@ CONFIG_ARCH_SUNXI=y
CONFIG_SPL=y
CONFIG_MACH_SUN50I=y
CONFIG_RESERVE_ALLWINNER_BOOT0_HEADER=y
-CONFIG_DRAM_ODT_EN=y
CONFIG_MMC_SUNXI_SLOT_EXTRA=2
# CONFIG_VIDEO_DE2 is not set
CONFIG_DEFAULT_DEVICE_TREE="sun50i-a64-amarula-relic"
diff --git a/configs/bananapi_m2_berry_defconfig b/configs/bananapi_m2_berry_defconfig
index 9d75108d04..0ebb1c38da 100644
--- a/configs/bananapi_m2_berry_defconfig
+++ b/configs/bananapi_m2_berry_defconfig
@@ -4,7 +4,6 @@ CONFIG_SPL=y
CONFIG_MACH_SUN8I_R40=y
CONFIG_DRAM_CLK=576
CONFIG_DRAM_ZQ=3881979
-CONFIG_DRAM_ODT_EN=y
CONFIG_MMC0_CD_PIN="PH13"
CONFIG_DEFAULT_DEVICE_TREE="sun8i-v40-bananapi-m2-berry"
# CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set
diff --git a/configs/sopine_baseboard_defconfig b/configs/sopine_baseboard_defconfig
index c79c111b5d..1d0b3fbbc7 100644
--- a/configs/sopine_baseboard_defconfig
+++ b/configs/sopine_baseboard_defconfig
@@ -6,7 +6,6 @@ CONFIG_RESERVE_ALLWINNER_BOOT0_HEADER=y
CONFIG_SUNXI_DRAM_LPDDR3_STOCK=y
CONFIG_DRAM_CLK=552
CONFIG_DRAM_ZQ=3881949
-CONFIG_DRAM_ODT_EN=y
CONFIG_MMC0_CD_PIN=""
CONFIG_MMC_SUNXI_SLOT_EXTRA=2
CONFIG_SPL_SPI_SUNXI=y
--
2.14.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [U-Boot] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol
2018-07-25 0:02 [U-Boot] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol Andre Przywara
@ 2018-07-25 7:39 ` Maxime Ripard
2018-08-13 10:29 ` [U-Boot] [linux-sunxi] " Jagan Teki
1 sibling, 0 replies; 5+ messages in thread
From: Maxime Ripard @ 2018-07-25 7:39 UTC (permalink / raw)
To: u-boot
On Wed, Jul 25, 2018 at 01:02:31AM +0100, Andre Przywara wrote:
> "default" lines in Kconfig are processed in order, the first hit will
> stop considering subsequent lines. In the case of the DRAM_ODT_EN symbol
> that means that everything following the first two lines will never be
> checked:
> ------------
> config DRAM_ODT_EN
> bool "sunxi dram odt enable"
> default n if !MACH_SUN8I_A23
> default y if MACH_SUN8I_A23
> default y if MACH_SUN8I_R40
> default y if MACH_SUN50I
> ------------
>
> Assuming that the "default y" for the A64 and the R40 were a deliberate
> choice, fix the Kconfig stanza to take this into account.
> Also remove the now redundant lines from the respective defconfigs.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> ---
> Hi,
>
> I would be grateful if people could test this and find out whether
> enabling ODT works reliably.
>
> Thanks!
> Andre.
>
> arch/arm/mach-sunxi/Kconfig | 2 +-
> configs/Bananapi_M2_Ultra_defconfig | 1 -
> configs/amarula_a64_relic_defconfig | 1 -
> configs/bananapi_m2_berry_defconfig | 1 -
> configs/sopine_baseboard_defconfig | 1 -
> 5 files changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/arch/arm/mach-sunxi/Kconfig b/arch/arm/mach-sunxi/Kconfig
> index 678e33dd40..7ff0347e20 100644
> --- a/arch/arm/mach-sunxi/Kconfig
> +++ b/arch/arm/mach-sunxi/Kconfig
> @@ -405,10 +405,10 @@ config DRAM_ZQ
>
> config DRAM_ODT_EN
> bool "sunxi dram odt enable"
> - default n if !MACH_SUN8I_A23
> default y if MACH_SUN8I_A23
> default y if MACH_SUN8I_R40
> default y if MACH_SUN50I
> + default n
I think this is the default's default, so there's no need to set it
explicitly. Otherwise,
Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>
Maxime
--
Maxime Ripard, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180725/59340850/attachment.sig>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] [linux-sunxi] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol
2018-07-25 0:02 [U-Boot] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol Andre Przywara
2018-07-25 7:39 ` Maxime Ripard
@ 2018-08-13 10:29 ` Jagan Teki
2018-08-13 10:55 ` Chen-Yu Tsai
1 sibling, 1 reply; 5+ messages in thread
From: Jagan Teki @ 2018-08-13 10:29 UTC (permalink / raw)
To: u-boot
On Wed, Jul 25, 2018 at 5:32 AM, Andre Przywara <andre.przywara@arm.com> wrote:
> "default" lines in Kconfig are processed in order, the first hit will
> stop considering subsequent lines. In the case of the DRAM_ODT_EN symbol
> that means that everything following the first two lines will never be
> checked:
> ------------
> config DRAM_ODT_EN
> bool "sunxi dram odt enable"
> default n if !MACH_SUN8I_A23
> default y if MACH_SUN8I_A23
> default y if MACH_SUN8I_R40
> default y if MACH_SUN50I
> ------------
>
> Assuming that the "default y" for the A64 and the R40 were a deliberate
> choice, fix the Kconfig stanza to take this into account.
> Also remove the now redundant lines from the respective defconfigs.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> ---
Tested-by: Jagan Teki <jagan@amarulasolutions.com> # A64, R40
Can someone confirm A23?
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] [linux-sunxi] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol
2018-08-13 10:29 ` [U-Boot] [linux-sunxi] " Jagan Teki
@ 2018-08-13 10:55 ` Chen-Yu Tsai
2018-08-13 11:19 ` Jagan Teki
0 siblings, 1 reply; 5+ messages in thread
From: Chen-Yu Tsai @ 2018-08-13 10:55 UTC (permalink / raw)
To: u-boot
On Mon, Aug 13, 2018 at 6:29 PM, Jagan Teki <jagan@amarulasolutions.com> wrote:
> On Wed, Jul 25, 2018 at 5:32 AM, Andre Przywara <andre.przywara@arm.com> wrote:
>> "default" lines in Kconfig are processed in order, the first hit will
>> stop considering subsequent lines. In the case of the DRAM_ODT_EN symbol
>> that means that everything following the first two lines will never be
>> checked:
>> ------------
>> config DRAM_ODT_EN
>> bool "sunxi dram odt enable"
>> default n if !MACH_SUN8I_A23
>> default y if MACH_SUN8I_A23
>> default y if MACH_SUN8I_R40
>> default y if MACH_SUN50I
>> ------------
>>
>> Assuming that the "default y" for the A64 and the R40 were a deliberate
>> choice, fix the Kconfig stanza to take this into account.
>> Also remove the now redundant lines from the respective defconfigs.
>>
>> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
>> ---
>
> Tested-by: Jagan Teki <jagan@amarulasolutions.com> # A64, R40
>
> Can someone confirm A23?
Tested-by: Chen-Yu Tsai <wens@csie.org> # A23
^ permalink raw reply [flat|nested] 5+ messages in thread
* [U-Boot] [linux-sunxi] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol
2018-08-13 10:55 ` Chen-Yu Tsai
@ 2018-08-13 11:19 ` Jagan Teki
0 siblings, 0 replies; 5+ messages in thread
From: Jagan Teki @ 2018-08-13 11:19 UTC (permalink / raw)
To: u-boot
On Mon, Aug 13, 2018 at 4:25 PM, Chen-Yu Tsai <wens@csie.org> wrote:
> On Mon, Aug 13, 2018 at 6:29 PM, Jagan Teki <jagan@amarulasolutions.com> wrote:
>> On Wed, Jul 25, 2018 at 5:32 AM, Andre Przywara <andre.przywara@arm.com> wrote:
>>> "default" lines in Kconfig are processed in order, the first hit will
>>> stop considering subsequent lines. In the case of the DRAM_ODT_EN symbol
>>> that means that everything following the first two lines will never be
>>> checked:
>>> ------------
>>> config DRAM_ODT_EN
>>> bool "sunxi dram odt enable"
>>> default n if !MACH_SUN8I_A23
>>> default y if MACH_SUN8I_A23
>>> default y if MACH_SUN8I_R40
>>> default y if MACH_SUN50I
>>> ------------
>>>
>>> Assuming that the "default y" for the A64 and the R40 were a deliberate
>>> choice, fix the Kconfig stanza to take this into account.
>>> Also remove the now redundant lines from the respective defconfigs.
>>>
>>> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
>>> ---
>>
>> Tested-by: Jagan Teki <jagan@amarulasolutions.com> # A64, R40
>>
>> Can someone confirm A23?
>
> Tested-by: Chen-Yu Tsai <wens@csie.org> # A23
Removed 'default n' and
Applied to u-boot-sunxi/master
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-08-13 11:19 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-25 0:02 [U-Boot] [PATCH] sunxi: A64: fix default DRAM_ODT_EN symbol Andre Przywara
2018-07-25 7:39 ` Maxime Ripard
2018-08-13 10:29 ` [U-Boot] [linux-sunxi] " Jagan Teki
2018-08-13 10:55 ` Chen-Yu Tsai
2018-08-13 11:19 ` Jagan Teki
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.