-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] V2021.10 nvec paz00 #1
Conversation
drivers/i2c/tegra_nvec.c
Outdated
@@ -410,7 +411,7 @@ static int nvec_probe(struct udevice *dev) | |||
{ | |||
struct nvec_t *nvec = dev_get_priv(dev); | |||
const void *blob = gd->fdt_blob; | |||
int node = dev->node.of_offset; | |||
int node = dev->node_.of_offset; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably be deleted (can be squashed with the later patch).
drivers/i2c/tegra_nvec.c
Outdated
@@ -425,7 +421,7 @@ static int nvec_probe(struct udevice *dev) | |||
|
|||
debug("NVEC initialization...\n"); | |||
|
|||
if (nvec_decode_fdt(blob, node, nvec_data)) { | |||
if (nvec_decode_fdt(nvec_data) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing bracket, will fix...
It fails to build from source, I will revisit in the next days. I need to recover a known good and tested version... |
Sources were updated. May you rebase your PR please? |
Sure, I hope to update this over the week-end. |
ea9b2ac
to
6edacb5
Compare
Lot of PCI and PCIe controllers are using standard Config Address for PCI Configuration Mechanism #1 or its extended version. So add PCI_CONF1_ADDRESS() and PCI_CONF1_EXT_ADDRESS() macros into U-Boot's pci.h header file which can be suitable for most PCI and PCIe controller drivers. Drivers do not have to invent their own macros and can use these new U-Boot macros. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI gt64120 driver uses standard format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_ADDRESS() and remove old custom driver address macros. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI mpc85xx driver uses extended format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_EXT_ADDRESS(). Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI msc01 driver uses standard format of Config Address for PCI Configuration Mechanism #1 but with cleared Enable bit. So use new U-Boot macro PCI_CONF1_ADDRESS() with clearing PCI_CONF1_ENABLE bit and remove old custom driver address macros. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI mvebu driver uses extended format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_EXT_ADDRESS() and remove old custom driver address macros. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI tegra driver uses extended format of Config Address for PCI Configuration Mechanism #1 but with cleared Enable bit. So use new U-Boot macro PCI_CONF1_EXT_ADDRESS() with clearing PCI_CONF1_ENABLE bit and remove old custom driver address function. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI fsl driver uses extended format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_EXT_ADDRESS(). Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI mediatek driver uses extended format of Config Address for PCI Configuration Mechanism #1 but with cleared Enable bit. So use new U-Boot macro PCI_CONF1_EXT_ADDRESS() with clearing PCI_CONF1_ENABLE bit and remove old custom driver address macros. Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
PCI sh7780 driver uses standard format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_ADDRESS(). Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
x86 platform uses standard format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_ADDRESS(). Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
mcf5445x platform uses standard format of Config Address for PCI Configuration Mechanism #1. So use new U-Boot macro PCI_CONF1_ADDRESS(). Signed-off-by: Pali Rohár <pali@kernel.org> Reviewed-by: Simon Glass <sjg@chromium.org>
sh7751 platform uses standard format of Config Address for PCI Configuration Mechanism #1. Commit 72c2f4a ("pci: sh7751: Convert to DM and DT probing") which did conversion of PCI sh7751 driver to DM, broke access to config space as that commit somehow swapped device and function bits in config address. Fix all these issues by using new U-Boot macro PCI_CONF1_ADDRESS() which calculates Config Address correctly. Also remove nonsense function sh7751_pci_addr_valid() which was introduced in commit 72c2f4a ("pci: sh7751: Convert to DM and DT probing") probably due to workarounded issues with mixing/swapping device and function bits of config address which probably resulted in non-working access to some devices. With correct composing of config address there should not be such issue anymore. Signed-off-by: Pali Rohár <pali@kernel.org> Fixes: 72c2f4a ("pci: sh7751: Convert to DM and DT probing") Cc: Marek Vasut <marek.vasut+renesas@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Add device-tree and config for Tegra20 QEMU. Link: https://github.com/grate-driver/tegra2_qemu Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
On popular request make the display driver from T20 work on T30 as well. Turned out to be quite straight forward. However a few notes about some things encountered during porting: Of course the T30 device tree was completely missing host1x as well as PWM support but it turns out this can simply be copied from T20. The only trouble compiling the Tegra video driver for T30 had to do with some hard-coded PWM pin muxing for T20 which is quite ugly anyway. On T30 this gets handled by a board specific complete pin muxing table. The older Chromium U-Boot 2011.06 which to my knowledge was the only prior attempt at enabling a display driver for T30 for whatever reason got some clocking stuff mixed up. Turns out at least for a single display controller T20 and T30 can be clocked quite similar. Enjoy. Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Jonas Schwöbel <jonasschwoebel@yahoo.de> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
This patch adds support for correct work with backup gpt without excessive log spam. Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Board derives from Ventana board Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Board derives from Cardhu board Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Antoni Aloy Torrens <aaloytorrens@gmail.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Tested-by: Andreas Westman Dorcsak <hedmoo@yahoo.com> Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
Rebase your changes please. |
Adopted version of nvec driver from linux kernel with keyboard support only. Signed-off-by: Andrey Danin <danindrey@mail.ru> [squashed, forward ported, and cleaned up] Signed-off-by: Marc Dietrich <marvin24@gmx.de>
Adopted version of nvec keyboard driver from linux kernel. Signed-off-by: Andrey Danin <danindrey@mail.ru> [squashed, forward ported, and cleaned up] Signed-off-by: Marc Dietrich <marvin24@gmx.de>
Signed-off-by: Andrey Danin <danindrey@mail.ru> [squashed, forward ported, and cleaned up] Signed-off-by: Marc Dietrich <marvin24@gmx.de>
Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
e8ecf7b
to
3a63e25
Compare
The nvec fork for paz00 is currently maintained at I've rebased from grate until then. |
3a63e25
to
ad0aff9
Compare
There are three different kinds of EEPROM possibly present on boards. 1. 1byte address. For those we should avoid 2byte address in order not to rewrite the data. Second byte of the address can potentially be interpreted as the data to write. 2. 2byte address with defined behaviour. When we try to use 1byte address they just return "FF FF FF FF ... FF" 3. 2byte address with undefined behaviour (for instance, 24LC32AI). When we try to use 1byte address, then their internal read pointer is changed to some value. Subsequential reads may be broken. To gracefully handle both case #1 and case u-boot#3 we read all required data from EEPROM at once (about 80 bytes). So either all the data is valid or we fallback to 2byte address. Cc: Nishanth Menon <nm@ti.com> Fixes: a58147c ("board: ti: common: board_detect: Do 1byte address checks first.") Reference: https://lore.kernel.org/all/CAJs94Ebdd4foOjhGFu9Bop0v=B1US9neDLxfhgcY23ukgLzFOQ@mail.gmail.com/ Signed-off-by: Matwey V. Kornilov <matwey.kornilov@gmail.com> Acked-by: Nishanth Menon <nm@ti.com>
Closing as I've submitted a new PR with a new base branch |
This is a rebase of my tree from 2021.10 nvec paz00 driver.
Known not to work is EFI boot on tegra20 (works for tegra124).
please review.