From: "Songxiaowei (Kirin_DRV)" <songxiaowei@hisilicon.com>
To: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Cc: Wangbinghui <wangbinghui@hisilicon.com>,
"bhelgaas@google.com" <bhelgaas@google.com>,
"robh+dt@kernel.org" <robh+dt@kernel.org>,
"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"andy.shevchenko@gmail.com" <andy.shevchenko@gmail.com>,
Kongfei <kongfei@hisilicon.com>,
"chenyao (F)" <chenyao11@huawei.com>
Subject: 答复: [PATCH v7 1/1] PCI: kirin: Add MSI support
Date: Thu, 12 Jul 2018 01:00:25 +0000 [thread overview]
Message-ID: <99B4C6BADD9E3241B25E52B02BA737C5412D982C@dggema525-mbx.china.huawei.com> (raw)
In-Reply-To: <20180711113323.GA17546@red-moon>
Hi Lorenzo,
Thanks a lot.
Best Regards,
Xiaowei Song.
> -----邮件原件-----
> 发件人: Lorenzo Pieralisi [mailto:lorenzo.pieralisi@arm.com]
> 发送时间: 2018年7月11日 19:33
> 收件人: Songxiaowei (Kirin_DRV) <songxiaowei@hisilicon.com>
> 抄送: Wangbinghui <wangbinghui@hisilicon.com>; bhelgaas@google.com;
> robh+dt@kernel.org; linux-pci@vger.kernel.org; linux-kernel@vger.kernel.org;
> Suzhuangluan <suzhuangluan@hisilicon.com>; andy.shevchenko@gmail.com;
> Kongfei <kongfei@hisilicon.com>; chenyao (F) <chenyao11@huawei.com>
> 主题: Re: [PATCH v7 1/1] PCI: kirin: Add MSI support
>
> On Wed, Jul 11, 2018 at 04:09:46PM +0800, Xiaowei Song wrote:
> > Add support for MSI
> >
> > Signed-off-by: Xiaowei Song <songxiaowei@hisilicon.com>
> > Signed-off-by: Yao Chen <chenyao11@huawei.com>
> > ---
> > drivers/pci/dwc/pcie-kirin.c | 28 ++++++++++++++++++++++++++++
> > 1 file changed, 28 insertions(+)
>
> Applied to pci/dwc for v4.19, thanks.
>
> Lorenzo
>
> > diff --git a/drivers/pci/dwc/pcie-kirin.c
> > b/drivers/pci/dwc/pcie-kirin.c index d2970a009eb5..5352e0c3be82
> 100644
> > --- a/drivers/pci/dwc/pcie-kirin.c
> > +++ b/drivers/pci/dwc/pcie-kirin.c
> > @@ -430,6 +430,9 @@ static int kirin_pcie_host_init(struct pcie_port
> > *pp) {
> > kirin_pcie_establish_link(pp);
> >
> > + if (IS_ENABLED(CONFIG_PCI_MSI))
> > + dw_pcie_msi_init(pp);
> > +
> > return 0;
> > }
> >
> > @@ -445,9 +448,34 @@ static const struct dw_pcie_host_ops
> kirin_pcie_host_ops = {
> > .host_init = kirin_pcie_host_init,
> > };
> >
> > +static int kirin_pcie_add_msi(struct dw_pcie *pci,
> > + struct platform_device *pdev)
> > +{
> > + int irq;
> > +
> > + if (IS_ENABLED(CONFIG_PCI_MSI)) {
> > + irq = platform_get_irq(pdev, 0);
> > + if (irq < 0) {
> > + dev_err(&pdev->dev,
> > + "failed to get MSI IRQ (%d)\n", irq);
> > + return irq;
> > + }
> > +
> > + pci->pp.msi_irq = irq;
> > + }
> > +
> > + return 0;
> > +}
> > +
> > static int __init kirin_add_pcie_port(struct dw_pcie *pci,
> > struct platform_device *pdev) {
> > + int ret;
> > +
> > + ret = kirin_pcie_add_msi(pci, pdev);
> > + if (ret)
> > + return ret;
> > +
> > pci->pp.ops = &kirin_pcie_host_ops;
> >
> > return dw_pcie_host_init(&pci->pp);
> > --
> > 2.11.GIT
> >
prev parent reply other threads:[~2018-07-12 1:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-11 8:09 [PATCH v7 0/1] PCI: kirin: Add MSI support Xiaowei Song
2018-07-11 8:09 ` [PATCH v7 1/1] " Xiaowei Song
2018-07-11 9:30 ` Andy Shevchenko
2018-07-11 9:42 ` 答复: " Songxiaowei (Kirin_DRV)
2018-07-11 11:33 ` Lorenzo Pieralisi
2018-07-12 1:00 ` Songxiaowei (Kirin_DRV) [this message]
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=99B4C6BADD9E3241B25E52B02BA737C5412D982C@dggema525-mbx.china.huawei.com \
--to=songxiaowei@hisilicon.com \
--cc=andy.shevchenko@gmail.com \
--cc=bhelgaas@google.com \
--cc=chenyao11@huawei.com \
--cc=kongfei@hisilicon.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lorenzo.pieralisi@arm.com \
--cc=robh+dt@kernel.org \
--cc=wangbinghui@hisilicon.com \
/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).