Re: [PATCH v3 2/3] openrisc: Add pci bus support

From: Guenter Roeck
Date: Fri Jul 29 2022 - 02:10:46 EST


On 7/28/22 22:50, Stafford Horne wrote:
On Thu, Jul 28, 2022 at 08:37:28PM -0700, Guenter Roeck wrote:
On Mon, Jul 25, 2022 at 11:07:36AM +0900, Stafford Horne wrote:
This patch adds required definitions to allow for PCI buses on OpenRISC.
This is being tested on the OpenRISC QEMU virt platform which is in
development.

OpenRISC does not have IO ports so we keep the definition of
IO_SPACE_LIMIT and PIO_RESERVED to be 0.

Note, since commit 66bcd06099bb ("parport_pc: Also enable driver for PCI
systems") all platforms that support PCI also need to support parallel
port. We add a generic header to support compiling parallel port
drivers, though they generally will not work as they require IO ports.

Signed-off-by: Stafford Horne <shorne@xxxxxxxxx>

This patch results in

Building openrisc:allmodconfig ... failed
--------------
Error log:
drivers/video/fbdev/riva/fbdev.c: In function 'rivafb_probe':
drivers/video/fbdev/riva/fbdev.c:2062:42: error:
passing argument 1 of 'iounmap' discards 'volatile' qualifier from pointer target type

drivers/video/fbdev/nvidia/nvidia.c: In function 'nvidiafb_probe':
drivers/video/fbdev/nvidia/nvidia.c:1414:20: error:
passing argument 1 of 'iounmap' discards 'volatile' qualifier from pointer target type

drivers/scsi/aic7xxx/aic7xxx_osm.c: In function 'ahc_platform_free':
drivers/scsi/aic7xxx/aic7xxx_osm.c:1231:41: error:
passing argument 1 of 'iounmap' discards 'volatile' qualifier from pointer target type

... and so on.

Prior to this patch, the code was not enabled because it depends on PCI.

Hi Guenter,

Thanks for reporting this.

It's interesting, I don't get this on the openrisc/for-next branch.


Hmm, weird. I see it all over the place. Complete log is at
https://kerneltests.org/builders/next-openrisc-next/builds/1880/steps/buildcommand/logs/stdio
if you are interested.

BTW, do you turn off WERROR on the allmodconfig config? I get many warnings
such as the below, but I haven't looked into it much yet:


No, I don't. Disabling it would defeat its purpose.

fs/exec.c: In function 'shift_arg_pages':
fs/exec.c:687:27: error: 'tlb' is used uninitialized [-Werror=uninitialized]
687 | struct mmu_gather tlb;
| ^~~


I don't see that in next-20220728. I tried with gcc-11.2 and 11.3.
Which compiler do you use ?

Thanks,
Guenter

I will try to see what is going on in linux-next.

-Stafford