u-boot/drivers
Marek Behún 3fc92a215b ddr: marvell: a38x: fix SPLIT_OUT_MIX state decision
This is a cleaned up and fixed version of a patch
  mv_ddr: a380: fix SPLIT_OUT_MIX state decision

  in each pattern cycle the bus state can be changed
  in order to avoide it, need to back to the same bus state on each
  pattern cycle
by
  Moti Boskula <motib@marvell.com>

The original patch is not in Marvell's mv-ddr-marvell repository. It was
gives to us by Marvell to fix an issues with DDR training on some
boards, but it cannot be applied as is to mv-ddr-marvell, because it is
a very dirty draft patch that would certainly break other things, mainly
DDR4 training code in mv-ddr-marvell, since it changes common functions.

I have cleaned up the patch and removed stuff that seemed unnecessary
(when removed, it still fixed things). Note that I don't understand
completely what the code does exactly, since I haven't studied the DDR
training code extensively (and I suspect that no one besides some few
people in Marvell understand the code completely).

Anyway after the cleanup the patch still fixes isssues with DDR training
on the failing boards.

There was also a problem with the original patch on some of the Allied
Telesis' x530 boards, reported by Chris Packham. I have asked Chris to
send me some logs, and managed to fix it:
- if you look at the change, you'll notice that it introduces
  subtraction of cur_start_win[] and cur_end_win[] members, depending on
  a bit set in the current_byte_status variable
- the original patch subtracted cur_start_win[] if either
  BYTE_SPLIT_OUT_MIX or BYTE_HOMOGENEOUS_SPLIT_OUT bits were set, but
  subtracted cur_end_win[] only if the first one (BYTE_SPLIT_OUT_MIX)
  was set
- from Chris Packham logs I discovered that the x530 board where the
  original patch introduced DDR training failure, only the
  BYTE_HOMOGENEOUS_SPLIT_OUT bit was set, and on our boards where the
  patch is needed only the BYTE_SPLIT_OUT_MIX is set in the
  current_byte_status variable
- this led me to the hypothesis that both cur_start_win[] and
  cur_end_win[] should be subtracted only if BYTE_SPLIT_OUT_MIX bit is
  set, the BYTE_HOMOGENEOUS_SPLIT_OUT bit shouldn't be considered at all
- this hypothesis also gains credibility when considering the commit
  title ("fix SPLIT_OUT_MIX state decision")

Hopefully this will fix things without breaking anything else.

Signed-off-by: Marek Behún <marek.behun@nic.cz>
Reviewed-by: Stefan Roese <sr@denx.de>
Tested-by: Chris Packham <judge.packham@gmail.com>
2022-01-14 11:39:15 +01:00
..
adc dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
ata scsi: ceva: rename the resource name to match the linux kernel one 2021-11-09 17:18:23 +05:30
axi WS cleanup: remove trailing empty lines 2021-09-30 08:08:56 -04:00
bios_emulator pci: Drop DM_PCI check from bios_emul 2021-08-05 19:46:35 -04:00
block Prepare v2022.01-rc4 2021-12-20 17:12:04 -05:00
bootcount bootcount: add a new driver with syscon as backend 2021-08-22 11:04:52 +02:00
bus bus: ti-sysc: change in a normal driver 2021-03-22 19:23:27 +13:00
button dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
cache cache: sifive: Fix -Wint-to-pointer-cast warning 2021-10-20 10:59:09 +08:00
clk treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
core dm: core: Switch order of pinctrl and power domain calls 2022-01-13 09:13:41 -07:00
cpu sandbox: correct cpu nodes 2021-09-25 09:46:15 -06:00
crypto crypto: aspeed: Add AST2600 ACRY support 2021-11-17 17:05:00 -05:00
ddr ddr: marvell: a38x: fix SPLIT_OUT_MIX state decision 2022-01-14 11:39:15 +01:00
demo demo: migrate uclass to livetree 2021-10-05 08:50:15 -04:00
dfu dfu: newline after updating 2021-11-07 18:36:56 +01:00
dma treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
fastboot fastboot: fix partition name truncation in environment lookup 2021-10-12 16:48:38 -04:00
firmware Prepare v2022.01-rc3 2021-11-29 12:00:57 -05:00
fpga arm: socfpga: arria10: Enable double peripheral RBF configuration 2021-12-17 12:58:01 +08:00
gpio Convert CONFIG_KIRKWOOD_GPIO to Kconfig 2021-12-27 16:20:19 -05:00
hwspinlock treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
i2c Convert CONFIG_SYS_IMMR to Kconfig 2021-12-27 08:41:38 -05:00
input Convert CONFIG_KEYBOARD to Kconfig 2021-12-05 09:26:26 -07:00
iommu iommu: Add Apple DART driver 2021-10-31 08:46:44 -04:00
led dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
mailbox treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
memory keystone2: Move CONFIG_AEMIF_CNTRL_BASE out of CONFIG namespace 2021-09-27 21:38:34 -04:00
misc treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
mmc mmc: dwmmc: return a proper error code when busy 2022-01-12 09:56:40 +09:00
mtd mtd: nand: pxa3xx: use marvell, prefix for custom DT properties 2022-01-14 07:47:57 +01:00
mux treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
net drivers/net/fec_mxc.c: Fix spelling of "resetting". 2022-01-13 07:57:49 -05:00
nvme Revert "nvme: Enable FUA" 2021-11-18 20:18:34 -05:00
pch treewide: Simply conditions with the new OF_REAL 2021-09-25 09:46:15 -06:00
pci arm: mvebu: a38x: serdes: Move non-serdes PCIe code to pci_mvebu.c 2022-01-14 07:47:57 +01:00
pci_endpoint dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
phy treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
pinctrl pinctrl: stmfx: define LOG_CATEGORY 2021-11-30 11:20:34 +01:00
power - disable CONFIG_NET_RANDOM_ETHADDR when unnecessary on amlogic based configs 2022-01-09 07:56:31 -05:00
pwm exynos: pwm: Deal with a PWM at 100% 2021-11-09 11:57:22 +09:00
qe configs: fsl: migrate FMAN/QE specific defines to Kconfig 2021-11-09 17:18:23 +05:30
ram ram: stm32mp1: remove __maybe_unused on stm32mp1_ddr_setup 2021-11-30 16:43:28 +01:00
reboot-mode reboot-mode: migrate uclass to livetree 2021-10-05 08:50:15 -04:00
remoteproc remoteproc: migrate uclass to livetree 2021-10-05 08:50:15 -04:00
reset treewide: invaild -> invalid 2022-01-13 07:57:49 -05:00
rng Kconfig: Remove all default n/no options 2021-08-31 17:47:49 -04:00
rtc rtc: ds1337: fix compatible string typo 2021-11-11 19:02:44 -05:00
scsi sata: Rename SATA_SUPPORT to SATA 2021-09-04 12:26:02 -04:00
serial fdt: Drop SPL_BUILD macro 2022-01-13 09:13:41 -07:00
smem dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
soc soc: xilinx: versal: Add soc_xilinx_versal driver 2021-08-26 08:08:11 +02:00
sound dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
spi - disable CONFIG_NET_RANDOM_ETHADDR when unnecessary on amlogic based configs 2022-01-09 07:56:31 -05:00
spmi spmi: msm: add arbiter version 5 support 2021-10-31 08:46:44 -04:00
sysinfo sysinfo: rcar3: Add Renesas R-Car Gen3 sysinfo driver 2021-07-20 23:33:54 +02:00
sysreset sysreset: watchdog: watchdog cannot power off 2021-12-26 06:49:14 +01:00
tee tee: optee: remove unused duplicated login Id macros 2021-11-23 13:53:03 -05:00
thermal WS cleanup: remove SPACE(s) followed by TAB 2021-09-30 09:08:16 -04:00
timer Finish conversion of CONFIG_SYS_CLK_FREQ to Kconfig 2021-12-27 16:20:18 -05:00
tpm tis: fix tpm_tis_remove() 2021-11-30 14:11:05 +02:00
ufs dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
usb drivers/usb/gadget/dwc2_udc_otg.c: Fix spelling of "resetting". 2022-01-13 07:57:50 -05:00
video - disable CONFIG_NET_RANDOM_ETHADDR when unnecessary on amlogic based configs 2022-01-09 07:56:31 -05:00
virtio pci: Drop DM_PCI 2021-09-13 18:23:13 -04:00
w1 arm: Remove zmx25 board and ARCH_MX25 2021-10-01 21:08:18 -04:00
w1-eeprom dm: define LOG_CATEGORY for all uclass 2021-07-06 10:38:03 -06:00
watchdog watchdog: Add a driver for the Apple watchdog 2022-01-13 06:55:46 +01:00
xen WS cleanup: remove trailing empty lines 2021-09-30 08:08:56 -04:00
Kconfig iommu: Add IOMMU uclass 2021-10-31 08:46:44 -04:00
Makefile iommu: Add IOMMU uclass 2021-10-31 08:46:44 -04:00