Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1370519 > unrolled thread

Re: [PATCH v2 03/15] MIPS: PCI: Compatibility with ARM-like PCI host drivers

Started byPaul Burton <paul.burton@imgtec.com>
First post2016-04-04 12:10 +0200
Last post2016-04-04 12:10 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH v2 03/15] MIPS: PCI: Compatibility with ARM-like PCI host  drivers Paul Burton <paul.burton@imgtec.com> - 2016-04-04 12:10 +0200

#1370519 — Re: [PATCH v2 03/15] MIPS: PCI: Compatibility with ARM-like PCI host drivers

FromPaul Burton <paul.burton@imgtec.com>
Date2016-04-04 12:10 +0200
SubjectRe: [PATCH v2 03/15] MIPS: PCI: Compatibility with ARM-like PCI host drivers
Message-ID<rk9Ck-1sf-41@gated-at.bofh.it>
On Tue, Mar 29, 2016 at 04:19:44PM -0700, Florian Fainelli wrote:
> Le 03/02/2016 03:30, Paul Burton a écrit :
> > Introduce support for struct hw_pci & the associated pci_common_init_dev
> > function as used by the PCI drivers written for ARM platforms under
> > drivers/pci. This is in preparation for reusing the xilinx-pcie driver
> > on the MIPS Boston board.
> > 
> > Platforms that make use of this more generic code will need to select
> > CONFIG_MIPS_GENERIC_PCI. Platforms which don't will continue to work as
> > they have, with the intent that PCI drivers be migrated towards struct
> > hw_pci & drivers/pci/ over time.
> > 
> > Signed-off-by: Paul Burton <paul.burton@imgtec.com>
> > ---
> 
> [snip]
> 
> > +		if (hw->preinit)
> > +			hw->preinit();
> > +
> > +		ret = hw->setup(i, &ctl->sysdata);
> > +		if (ret < 0) {
> 
> This needs to be ret <= 0 to be compliant with what ARM PCI host
> controllers do, which is return 1 in case they could get hw->setup to
> finish with success, and 0 or negative if they could not, see
> arch/arm/kernel/bios32.c.
> -- 
> Florian

Hi Florian,

Just an FYI, the pcie-xilinx driver I wrote this for has since been
converted away from the ARM-like pci_common_init_dev & struct hw_pci to
use only functions provided by the core PCI subsystem[1]. As a result
I've stopped using this patch & don't plan to continue work on it.
Perhaps it would be cleanest to do a similar conversion for the driver
you're using?

[1] https://patchwork.ozlabs.org/patch/581967/ & the rest of the series

Thanks,
    Paul

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web