Build with arm64 configuration
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors. Since some header file has dependency on structure of architecture. I think it's not solution that it copies from arch/arm/... to arch/arm64/...
So i want to get advise at mailing. how can i solve it?
If my understanding is right, after enabled PCIe at bootloader, then it bridges at kernel. right?
I want to know exactly solution..
Best Regards,
Jaehoon Chung
Bjorn Helgaas
maintainerQuoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.
The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
Quoted 5 lines
Since some header file has dependency on structure of architecture. I think it's not solution that it copies from
arch/arm/... toarch/arm64/...So i want to get advise at mailing. how can i solve it?
If my understanding is right, after enabled PCIe at bootloader, then it bridges at kernel. right?
I don't know how to parse this question. Can you rephrase it?
Bjorn
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the pcie-designware.c and pci-exynos.c.
When pcie-designware.c is built, i found the below error message. drivers/pci/host/pcie-designware.c:74:52: warning: ˜struct pci_sys_data™ declared inside parameter list
static inline struct pcie_port *sys_to_pcie(struct pci_sys_data *sys)
^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included from include/uapi/linux/stddef.h:1:0,
from include/linux/stddef.h:4,
from ./include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/linux/smp.h:10,
from include/linux/irq.h:12,
from drivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function ˜sys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);
I found it's located at arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)
And i don't want to add #ifdef CONFIG_ARM64 into pcie-designware.c I think mailing should know the graceful solution.
If i can solve this problem, i will contribute for pci-exynos.c.
Best Regards,
Jaehoon Chung
Quoted 11 lines
Quoted 6 lines
Since some header file has dependency on structure of architecture. I think it's not solution that it copies from
arch/arm/... toarch/arm64/...So i want to get advise at mailing. how can i solve it?
If my understanding is right, after enabled PCIe at bootloader, then it bridges at kernel. right?I don't know how to parse this question. Can you rephrase it?
Bjorn
Bjorn Helgaas
maintainer[+cc Jingoo, Mohit]
Quoted 40 lines · Jaehoon Chung
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the
pcie-designware.candpci-exynos.c.When
pcie-designware.cis built, i found the below error message.drivers/pci/host/pcie-designware.c:74:52: warning: ˜struct pci_sys_data™ declared inside parameter list
static inline structpcie_port*sys_to_pcie(structpci_sys_data*sys)^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included frominclude/uapi/linux/stddef.h:1:0,
frominclude/linux/stddef.h:4,
from./include/uapi/linux/posix_types.h:4,
frominclude/uapi/linux/types.h:13,
frominclude/linux/types.h:5,
frominclude/linux/smp.h:10,
frominclude/linux/irq.h:12,
fromdrivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function ˜sys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);I found it's located at
arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)
Quoted 4 lines
And i don't want to add #ifdef
CONFIG_ARM64intopcie-designware.cI think mailing should know the graceful solution.If i can solve this problem, i will contribute for
pci-exynos.c.
Oh, I think pcie-designware.c and pci-exynos.c currently only work on arm, not on arm64. I don't know enough about them to know whether they could be made to work on arm64. But Jingoo and Mohit probably do.
Bjorn
Dear, Bjorn.
Quoted 46 lines · Bjorn Helgaas
[+cc Jingoo, Mohit]
Quoted 43 lines · Jaehoon Chung
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the
pcie-designware.candpci-exynos.c.When
pcie-designware.cis built, i found the below error message.drivers/pci/host/pcie-designware.c:74:52: warning: Ëstruct pci_sys_data⢠declared inside parameter list
static inline structpcie_port*sys_to_pcie(structpci_sys_data*sys)^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included frominclude/uapi/linux/stddef.h:1:0,
frominclude/linux/stddef.h:4,
from./include/uapi/linux/posix_types.h:4,
frominclude/uapi/linux/types.h:13,
frominclude/linux/types.h:5,
frominclude/linux/smp.h:10,
frominclude/linux/irq.h:12,
fromdrivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function Ësys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);I found it's located at
arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)And i don't want to add #ifdef
CONFIG_ARM64intopcie-designware.cI think mailing should know the graceful solution.
Quoted 6 lines
Quoted 1 line
If i can solve this problem, i will contribute for
pci-exynos.c.Oh, I think
pcie-designware.candpci-exynos.ccurrently only work on arm, not on arm64. I don't know enough about them to know whether they could be made to work on arm64. But Jingoo and Mohit probably do.
I'm checking the code..
If my understanding is right, pci_sys_data is just used to take data relevant to pice_port. So I think it can get from device-tree or other.
I don't exactly know why needs "pci_sys_data".
It seems to discuss about pcie (struct pci_sys_data and hw_pci) on arm64 at mailing..right? ([RFC 2/4] PCI: generic: Add support for ARM64 and MSI(x))
If need to work, i have interesting for contributing pcie on arm64.(pcie-designware.c and pci-exynos.c) But i need to gain the knowledge of pcie..
Best Regards,
Jaehoon Chung
Quoted 3 lines
Bjorn
Quoted 55 lines · Jaehoon Chung
Dear, Bjorn.
Quoted 52 lines · Bjorn Helgaas
[+cc Jingoo, Mohit]
Quoted 40 lines · Jaehoon Chung
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the
pcie-designware.candpci-exynos.c.When
pcie-designware.cis built, i found the below error message.drivers/pci/host/pcie-designware.c:74:52: warning: Ëstruct pci_sys_data⢠declared inside parameter list
static inline structpcie_port*sys_to_pcie(structpci_sys_data*sys)^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included frominclude/uapi/linux/stddef.h:1:0,
frominclude/linux/stddef.h:4,
from./include/uapi/linux/posix_types.h:4,
frominclude/uapi/linux/types.h:13,
frominclude/linux/types.h:5,
frominclude/linux/smp.h:10,
frominclude/linux/irq.h:12,
fromdrivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function Ësys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);I found it's located at
arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)Quoted 4 lines
And i don't want to add #ifdef
CONFIG_ARM64intopcie-designware.cI think mailing should know the graceful solution.If i can solve this problem, i will contribute for
pci-exynos.c.Oh, I think
pcie-designware.candpci-exynos.ccurrently only work on arm, not on arm64. I don't know enough about them to know whether they could be made to work on arm64. But Jingoo and Mohit probably do.
Jaehoon,
pci-exynos and pcie-designware need to be converted to the generic PCIe framework and then they will work on both arm and arm64. For an example of a driver that successfully works in both worlds look at pci-versatile.c.
Currently, PCI host bridges that work on arch/arm depend on pci_sys_data, like you have discovered. There is no reason to do that nowadays, and Lorenzo Pieralisi, Yijing Wang and others are trying to get rid of that structure from arch/arm.
Best regards,
Liviu
Quoted 24 lines
I'm checking the code..
If my understanding is right,pci_sys_datais just used to take data relevant topice_port. So I think it can get from device-tree or other.
I don't exactly know why needs "pci_sys_data".It seems to discuss about pcie (struct
pci_sys_dataandhw_pci) on arm64 at mailing..right? ([RFC 2/4] PCI: generic: Add support for ARM64 and MSI(x))If need to work, i have interesting for contributing pcie on arm64.(pcie-designware.c and
pci-exynos.c) But i need to gain the knowledge of pcie..Best Regards,
Jaehoon ChungQuoted 3 lines
Bjorn
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 8 lines
====================
| I would like to |
| fix the world, |
| but they're not |
| giving me the |
\ source code! /
---------------
¯\_(ツ)_/¯Dear, Liviu.
Quoted 57 lines · Liviu Dudau
Quoted 55 lines · Jaehoon Chung
Dear, Bjorn.
Quoted 52 lines · Bjorn Helgaas
[+cc Jingoo, Mohit]
Quoted 40 lines · Jaehoon Chung
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the
pcie-designware.candpci-exynos.c.When
pcie-designware.cis built, i found the below error message.drivers/pci/host/pcie-designware.c:74:52: warning: Ëstruct pci_sys_data⢠declared inside parameter list
static inline structpcie_port*sys_to_pcie(structpci_sys_data*sys)^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included frominclude/uapi/linux/stddef.h:1:0,
frominclude/linux/stddef.h:4,
from./include/uapi/linux/posix_types.h:4,
frominclude/uapi/linux/types.h:13,
frominclude/linux/types.h:5,
frominclude/linux/smp.h:10,
frominclude/linux/irq.h:12,
fromdrivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function Ësys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);I found it's located at
arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)Quoted 4 lines
And i don't want to add #ifdef
CONFIG_ARM64intopcie-designware.cI think mailing should know the graceful solution.If i can solve this problem, i will contribute for
pci-exynos.c.Oh, I think
pcie-designware.candpci-exynos.ccurrently only work on arm, not on arm64. I don't know enough about them to know whether they could be made to work on arm64. But Jingoo and Mohit probably do.
Quoted 5 lines
Jaehoon,
pci-exynos and pcie-designware need to be converted to the generic PCIe framework and then they will work on both arm and arm64. For an example of a driver that successfully works in both worlds look at
pci-versatile.c.
Thanks a lot! I'm looking at pci-versatile.c and comparing with pcie-designware and pci-exynos.
One question..
At pci-versatile.c, i found the resource_list_for_each_entry() into versatile_pci_parse_request_of_pci_ranges(). resource_list_for_each_entry needs two arguments, but it's passed three arguments.
It seems to want using "resource_list_for_each_entry_safe()", doesn't it? (+CC'd Rob Herring)
drivers/pci/host/pci-versatile.c +1 -1
@@ -80,7 +80,7 @@ static int versatile_pci_parse_request_of_pci_ranges(struct device *dev,if (err)return err; -resource_list_for_each_entry (win, res, list) { +resource_list_for_each_entry_safe (win, res, list) {struct resource *parent, *res = win->res;switch (resource_type (res)) {
Best Regards,
Jaehoon Chung
Quoted 33 lines
Currently, PCI host bridges that work on
arch/armdepend onpci_sys_data, like you have discovered. There is no reason to do that nowadays, and Lorenzo Pieralisi, Yijing Wang and others are trying to get rid of that structure fromarch/arm.Best regards,
LiviuQuoted 24 lines
I'm checking the code..
If my understanding is right,pci_sys_datais just used to take data relevant topice_port. So I think it can get from device-tree or other.
I don't exactly know why needs "pci_sys_data".It seems to discuss about pcie (struct
pci_sys_dataandhw_pci) on arm64 at mailing..right? ([RFC 2/4] PCI: generic: Add support for ARM64 and MSI(x))If need to work, i have interesting for contributing pcie on arm64.(pcie-designware.c and
pci-exynos.c) But i need to gain the knowledge of pcie..Best Regards,
Jaehoon ChungQuoted 3 lines
Bjorn
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 66 lines · Jaehoon Chung
Dear, Liviu.
Quoted 57 lines · Liviu Dudau
Quoted 55 lines · Jaehoon Chung
Dear, Bjorn.
Quoted 52 lines · Bjorn Helgaas
[+cc Jingoo, Mohit]
Quoted 40 lines · Jaehoon Chung
Dear, Bjorn.
Thanks for reply.
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · Jaehoon Chung
Hi,
I have a question for building arm64.
(Actually, i didn't have many knowledges for PCIe.)
When i built with arm64 configuration, then i always found the compiler errors.The kernel does build for arm64, so you'll have to be more specific about the problem you're seeing.
I built the
pcie-designware.candpci-exynos.c.When
pcie-designware.cis built, i found the below error message.drivers/pci/host/pcie-designware.c:74:52: warning: Ëstruct pci_sys_data⢠declared inside parameter list
static inline structpcie_port*sys_to_pcie(structpci_sys_data*sys)^
drivers/pci/host/pcie-designware.c:74:52: warning: its scope is only this definition or declaration, which is probably not what you want In file included frominclude/uapi/linux/stddef.h:1:0,
frominclude/linux/stddef.h:4,
from./include/uapi/linux/posix_types.h:4,
frominclude/uapi/linux/types.h:13,
frominclude/linux/types.h:5,
frominclude/linux/smp.h:10,
frominclude/linux/irq.h:12,
fromdrivers/pci/host/pcie-designware.c:14:drivers/pci/host/pcie-designware.c: In function Ësys_to_pcie":drivers/pci/host/pcie-designware.c:76:13: error: dereferencing pointer to incomplete type
BUG_ON(!sys->private_data);I found it's located at
arch/arm/include/asm/mach/pci.h.
It can't refer when do build for arm64.
So I think that i missed something..I have also searched the patches relevant to this at patchwork. Some patch have copied header files relevant to "pci" to "arch/arm64/include/". (This is not solution.)Quoted 4 lines
And i don't want to add #ifdef
CONFIG_ARM64intopcie-designware.cI think mailing should know the graceful solution.If i can solve this problem, i will contribute for
pci-exynos.c.Oh, I think
pcie-designware.candpci-exynos.ccurrently only work on arm, not on arm64. I don't know enough about them to know whether they could be made to work on arm64. But Jingoo and Mohit probably do.Quoted 5 lines
Jaehoon,
pci-exynos and pcie-designware need to be converted to the generic PCIe framework and then they will work on both arm and arm64. For an example of a driver that successfully works in both worlds look at
pci-versatile.c.
Quoted 6 lines
Thanks a lot! I'm looking at
pci-versatile.cand comparing with pcie-designware and pci-exynos.One question..
Atpci-versatile.c, i found theresource_list_for_each_entry()intoversatile_pci_parse_request_of_pci_ranges().resource_list_for_each_entryneeds two arguments, but it's passed three arguments.
It seems to want using "resource_list_for_each_entry_safe()", doesn't it? (+CC'd Rob Herring)
Yes, there is a patch already in the mailing lists from Yijing I belive.
Best regards,
Liviu
Quoted 55 lines
drivers/pci/host/pci-versatile.c +1
-1@@ -80,7 +80,7 @@ static int versatile_pci_parse_request_of_pci_ranges(struct device *dev,if (err)return err; -resource_list_for_each_entry (win, res, list) { +resource_list_for_each_entry_safe (win, res, list) {struct resource *parent, *res = win->res;switch (resource_type (res)) {Best Regards,
Jaehoon ChungQuoted 33 lines
Currently, PCI host bridges that work on
arch/armdepend onpci_sys_data, like you have discovered. There is no reason to do that nowadays, and Lorenzo Pieralisi, Yijing Wang and others are trying to get rid of that structure fromarch/arm.Best regards,
LiviuQuoted 24 lines
I'm checking the code..
If my understanding is right,pci_sys_datais just used to take data relevant topice_port. So I think it can get from device-tree or other.
I don't exactly know why needs "pci_sys_data".It seems to discuss about pcie (struct
pci_sys_dataandhw_pci) on arm64 at mailing..right? ([RFC 2/4] PCI: generic: Add support for ARM64 and MSI(x))If need to work, i have interesting for contributing pcie on arm64.(pcie-designware.c and
pci-exynos.c) But i need to gain the knowledge of pcie..Best Regards,
Jaehoon ChungQuoted 3 lines
Bjorn
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 8 lines
====================
| I would like to |
| fix the world, |
| but they're not |
| giving me the |
\ source code! /
---------------
¯\_(ツ)_/¯