From b52142004fbdfd6db0091ba7ae33c91e3b459034 Mon Sep 17 00:00:00 2001 From: Stefan Roese Date: Fri, 25 Jan 2019 11:52:42 +0100 Subject: pci: Add pci_get_devfn() to extract devfn from the fdt_pci_addr This function will be used by the Marvell Armada XP/38x PCIe driver, which is moved to DM right now. So let's extract the functionality from pci_uclass_child_post_bind() to make it available. Signed-off-by: Stefan Roese Reviewed-by: Simon Glass Reviewed-by: Bin Meng --- include/pci.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'include') diff --git a/include/pci.h b/include/pci.h index 785d7d28b7e..041f8e37476 100644 --- a/include/pci.h +++ b/include/pci.h @@ -1560,6 +1560,16 @@ struct dm_pci_emul_ops { int sandbox_pci_get_emul(struct udevice *bus, pci_dev_t find_devfn, struct udevice **containerp, struct udevice **emulp); +/** + * pci_get_devfn() - Extract the devfn from fdt_pci_addr of the device + * + * Get devfn from fdt_pci_addr of the specifified device + * + * @dev: PCI device + * @return devfn in bits 15...8 if found, -ENODEV if not found + */ +int pci_get_devfn(struct udevice *dev); + #endif /* CONFIG_DM_PCI */ /** -- cgit v1.2.3 From 94f453ea38f52750d8da63e3745b548a9ee06dd4 Mon Sep 17 00:00:00 2001 From: Stefan Roese Date: Fri, 25 Jan 2019 11:52:43 +0100 Subject: pci: pci_mvebu: Add DM_PCI support and move CONFIG_PCI_MVEBU to defconfig MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch adds DM_PCI support to the MVEBU PCIe driver. This is necessary, since all PCI drivers have to be moved to DM (driver model) until the v2019.07 release. To not break git bisect'ablility, this patch also moves CONFIG_PCI_MVEBU from config headers to the defconfig files. Signed-off-by: Stefan Roese Cc: Dirk Eibach Cc: Mario Six Cc: Chris Packham Cc: Phil Sutter Cc: Marek BehĂșn Cc: VlaoMao --- include/configs/clearfog.h | 1 - include/configs/controlcenterdc.h | 3 --- include/configs/db-88f6820-amc.h | 1 - include/configs/db-88f6820-gp.h | 1 - include/configs/db-mv784mp-gp.h | 1 - include/configs/ds414.h | 1 - include/configs/theadorable.h | 7 ------- include/configs/turris_omnia.h | 1 - include/configs/x530.h | 1 - 9 files changed, 17 deletions(-) (limited to 'include') diff --git a/include/configs/clearfog.h b/include/configs/clearfog.h index 77ab6caf52c..f9510826d7d 100644 --- a/include/configs/clearfog.h +++ b/include/configs/clearfog.h @@ -55,7 +55,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/controlcenterdc.h b/include/configs/controlcenterdc.h index b38cab11641..06c93c3e664 100644 --- a/include/configs/controlcenterdc.h +++ b/include/configs/controlcenterdc.h @@ -63,9 +63,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI -#define CONFIG_PCI_MVEBU -#define CONFIG_PCI_PNP #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/db-88f6820-amc.h b/include/configs/db-88f6820-amc.h index e68246cc0f4..626a406cff8 100644 --- a/include/configs/db-88f6820-amc.h +++ b/include/configs/db-88f6820-amc.h @@ -34,7 +34,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/db-88f6820-gp.h b/include/configs/db-88f6820-gp.h index 3900cbed2d7..1f328e97c54 100644 --- a/include/configs/db-88f6820-gp.h +++ b/include/configs/db-88f6820-gp.h @@ -59,7 +59,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/db-mv784mp-gp.h b/include/configs/db-mv784mp-gp.h index 8ad007cc491..6cba3269278 100644 --- a/include/configs/db-mv784mp-gp.h +++ b/include/configs/db-mv784mp-gp.h @@ -46,7 +46,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/ds414.h b/include/configs/ds414.h index b9b708ad41d..4ba050553a5 100644 --- a/include/configs/ds414.h +++ b/include/configs/ds414.h @@ -41,7 +41,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/theadorable.h b/include/configs/theadorable.h index 2526a000840..27c858013d7 100644 --- a/include/configs/theadorable.h +++ b/include/configs/theadorable.h @@ -62,13 +62,6 @@ #define CONFIG_SYS_SATA_MAX_DEVICE 1 #define CONFIG_LBA48 -/* PCIe support */ -#ifdef CONFIG_CMD_PCI -#ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU -#endif -#endif - /* Enable LCD and reserve 512KB from top of memory*/ #define CONFIG_SYS_MEM_TOP_HIDE 0x80000 diff --git a/include/configs/turris_omnia.h b/include/configs/turris_omnia.h index 598674c96e8..710b8991a4c 100644 --- a/include/configs/turris_omnia.h +++ b/include/configs/turris_omnia.h @@ -66,7 +66,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif diff --git a/include/configs/x530.h b/include/configs/x530.h index a1ef301d35e..a83d49ba356 100644 --- a/include/configs/x530.h +++ b/include/configs/x530.h @@ -75,7 +75,6 @@ /* PCIe support */ #ifndef CONFIG_SPL_BUILD -#define CONFIG_PCI_MVEBU #define CONFIG_PCI_SCAN_SHOW #endif -- cgit v1.2.3 From f18220919079eeb8e79f4791e152f1db073574a8 Mon Sep 17 00:00:00 2001 From: Stefan Roese Date: Wed, 30 Jan 2019 08:54:13 +0100 Subject: arm: mvebu: theadorable: Enable video / LCD support with the new DM driver With the new DM_VIDEO support in the Armada XP LCD driver, this patch adds the needed DT node for the LCD controller to the theadorable dts file. This DT property is not added to the Armada XP dtsi files, as this LCD feature is pretty unusual for this SoC and I personally know of no other board that uses this controller. This patch also enables CONFIG_BMP_16BPP/24BPP/32BPP, as the "old" bmp command supported these BMP files. Signed-off-by: Stefan Roese Reviewed-by: Anatolij Gustschin Acked-by: Anatolij Gustschin --- include/configs/theadorable.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include') diff --git a/include/configs/theadorable.h b/include/configs/theadorable.h index 27c858013d7..886456ec26e 100644 --- a/include/configs/theadorable.h +++ b/include/configs/theadorable.h @@ -65,6 +65,10 @@ /* Enable LCD and reserve 512KB from top of memory*/ #define CONFIG_SYS_MEM_TOP_HIDE 0x80000 +#define CONFIG_BMP_16BPP +#define CONFIG_BMP_24BPP +#define CONFIG_BMP_32BPP + /* FPGA programming support */ #define CONFIG_FPGA_STRATIX_V -- cgit v1.2.3