linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Ellerman <mpe@ellerman.id.au>
To: "Jason A. Donenfeld" <Jason@zx2c4.com>,
	benh@kernel.crashing.org, paulus@samba.org, aik@ozlabs.ru,
	linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org
Cc: "Jason A. Donenfeld" <Jason@zx2c4.com>
Subject: Re: [PATCH] powerpc: PCI does not require PowerNV
Date: Tue, 15 Jan 2019 21:31:02 +1100	[thread overview]
Message-ID: <87d0oyyzyx.fsf@concordia.ellerman.id.au> (raw)
In-Reply-To: <20190115004745.9996-1-Jason@zx2c4.com>

Hi Jason,

Thanks for the patch.

"Jason A. Donenfeld" <Jason@zx2c4.com> writes:
> Commit 0e759bd75285 moved around the declaration of pnv_npu2_init, but
> did not conditionalize it inside of the PCI pSeries driver. This meant
> that CONFIG_PCI && CONFIG_PPC_PSERIES && !CONFIG_PPC_POWERNV resulted
> in:
>
> powerpc64le-pc-linux-gnu-ld: arch/powerpc/platforms/pseries/pci.o: in function `pSeries_final_fixup':
> pci.c:(.init.text+0x1b0): undefined reference to `pnv_npu2_init'
>
> This commit therefore wraps that line in an ifdef, so that PCI works
> without PowerNV.
>
> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
> Fixes: 0e759bd75285 ("powerpc/powernv/npu: Move OPAL calls away from context manipulation")

I think this should actually be:

  Fixes: 3be2df00e299 ("powerpc/pseries/npu: Enable platform support")

Because that's the commit that added the call to pnv_npu2_init() in the
pseries code. Prior to that it was only called from powernv code.

I'll update the change log to reflect that, unless you disagree.

cheers

> diff --git a/arch/powerpc/platforms/pseries/pci.c b/arch/powerpc/platforms/pseries/pci.c
> index 7725825d887d..37a77e57893e 100644
> --- a/arch/powerpc/platforms/pseries/pci.c
> +++ b/arch/powerpc/platforms/pseries/pci.c
> @@ -264,7 +264,9 @@ void __init pSeries_final_fixup(void)
>  			if (!of_device_is_compatible(nvdn->parent,
>  						"ibm,power9-npu"))
>  				continue;
> +#ifdef CONFIG_PPC_POWERNV
>  			WARN_ON_ONCE(pnv_npu2_init(hose));
> +#endif
>  			break;
>  		}
>  	}
> -- 
> 2.20.1

  parent reply	other threads:[~2019-01-15 10:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-15  0:47 [PATCH] powerpc: PCI does not require PowerNV Jason A. Donenfeld
2019-01-15  4:43 ` Alexey Kardashevskiy
2019-01-15 10:31 ` Michael Ellerman [this message]
2019-01-17  0:27 ` Michael Ellerman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d0oyyzyx.fsf@concordia.ellerman.id.au \
    --to=mpe@ellerman.id.au \
    --cc=Jason@zx2c4.com \
    --cc=aik@ozlabs.ru \
    --cc=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).