linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
To: Vidya Sagar <vidyas@nvidia.com>
Cc: jingoohan1@gmail.com, gustavo.pimentel@synopsys.com,
	bhelgaas@google.com, Jisheng.Zhang@synaptics.com,
	thierry.reding@gmail.com, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, kthota@nvidia.com,
	mmaddireddy@nvidia.com, sagar.tv@gmail.com
Subject: Re: [PATCH V4 1/2] PCI: dwc: Add API support to de-initialize host
Date: Tue, 18 Jun 2019 10:36:57 +0100	[thread overview]
Message-ID: <20190618093657.GA30711@e121166-lin.cambridge.arm.com> (raw)
In-Reply-To: <07c3dd04-cfd0-2d52-5917-25d0e40ad00b@nvidia.com>

On Tue, Jun 18, 2019 at 10:19:14AM +0530, Vidya Sagar wrote:

[...]

> Sorry for pinging again. Please let me know if these patches need to
> be sent again.

No problem. We can merge the code as-is even though I have a couple
of questions.

1) What about dbi2 interfaces (what an horrible name it is :() ? It
   is true that it is probably best to export just what we need.
2) It is not related to this patch but I fail to see the reasoning
   behind the __ in __dw_pci_read_dbi(), there is no no-underscore
   equivalent so its definition is somewhat questionable, maybe
   we should clean-it up (for dbi2 alike).

Lorenzo

> Thanks,
> Vidya Sagar
> 
> > 
> > > 
> > > > > 
> > > > > > 
> > > > > > > 
> > > > > > > Thanks,
> > > > > > > Lorenzo
> > > > > > > 
> > > > > > > > diff --git a/drivers/pci/controller/dwc/pcie-designware-host.c b/drivers/pci/controller/dwc/pcie-designware-host.c
> > > > > > > > index 77db32529319..d069e4290180 100644
> > > > > > > > --- a/drivers/pci/controller/dwc/pcie-designware-host.c
> > > > > > > > +++ b/drivers/pci/controller/dwc/pcie-designware-host.c
> > > > > > > > @@ -496,6 +496,14 @@ int dw_pcie_host_init(struct pcie_port *pp)
> > > > > > > >       return ret;
> > > > > > > >   }
> > > > > > > > +void dw_pcie_host_deinit(struct pcie_port *pp)
> > > > > > > > +{
> > > > > > > > +    pci_stop_root_bus(pp->root_bus);
> > > > > > > > +    pci_remove_root_bus(pp->root_bus);
> > > > > > > > +    if (pci_msi_enabled() && !pp->ops->msi_host_init)
> > > > > > > > +        dw_pcie_free_msi(pp);
> > > > > > > > +}
> > > > > > > > +
> > > > > > > >   static int dw_pcie_access_other_conf(struct pcie_port *pp, struct pci_bus *bus,
> > > > > > > >                        u32 devfn, int where, int size, u32 *val,
> > > > > > > >                        bool write)
> > > > > > > > diff --git a/drivers/pci/controller/dwc/pcie-designware.h b/drivers/pci/controller/dwc/pcie-designware.h
> > > > > > > > index deab426affd3..4f48ec78c7b9 100644
> > > > > > > > --- a/drivers/pci/controller/dwc/pcie-designware.h
> > > > > > > > +++ b/drivers/pci/controller/dwc/pcie-designware.h
> > > > > > > > @@ -348,6 +348,7 @@ void dw_pcie_msi_init(struct pcie_port *pp);
> > > > > > > >   void dw_pcie_free_msi(struct pcie_port *pp);
> > > > > > > >   void dw_pcie_setup_rc(struct pcie_port *pp);
> > > > > > > >   int dw_pcie_host_init(struct pcie_port *pp);
> > > > > > > > +void dw_pcie_host_deinit(struct pcie_port *pp);
> > > > > > > >   int dw_pcie_allocate_domains(struct pcie_port *pp);
> > > > > > > >   #else
> > > > > > > >   static inline irqreturn_t dw_handle_msi_irq(struct pcie_port *pp)
> > > > > > > > @@ -372,6 +373,10 @@ static inline int dw_pcie_host_init(struct pcie_port *pp)
> > > > > > > >       return 0;
> > > > > > > >   }
> > > > > > > > +static inline void dw_pcie_host_deinit(struct pcie_port *pp)
> > > > > > > > +{
> > > > > > > > +}
> > > > > > > > +
> > > > > > > >   static inline int dw_pcie_allocate_domains(struct pcie_port *pp)
> > > > > > > >   {
> > > > > > > >       return 0;
> > > > > > > > -- 
> > > > > > > > 2.17.1
> > > > > > > > 
> > > > > > 
> > > > > 
> > > > 
> > > 
> > 
> 

  reply	other threads:[~2019-06-18  9:37 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-02 17:04 [PATCH V4 1/2] PCI: dwc: Add API support to de-initialize host Vidya Sagar
2019-05-02 17:04 ` [PATCH V4 2/2] PCI: dwc: Export APIs to support .remove() implementation Vidya Sagar
2019-05-03 11:23 ` [PATCH V4 1/2] PCI: dwc: Add API support to de-initialize host Lorenzo Pieralisi
2019-05-07  5:49   ` Vidya Sagar
2019-05-07  6:55     ` Vidya Sagar
2019-05-27 11:09       ` Vidya Sagar
2019-06-07 13:13         ` Vidya Sagar
2019-06-13 18:24           ` Vidya Sagar
2019-06-18  4:49             ` Vidya Sagar
2019-06-18  9:36               ` Lorenzo Pieralisi [this message]
2019-06-18 10:51                 ` Vidya Sagar
2019-06-18 14:28                   ` Lorenzo Pieralisi
2019-06-19  5:11                     ` Kishon Vijay Abraham I
2019-06-20 16:52                       ` Lorenzo Pieralisi
2019-06-21  5:33                         ` Vidya Sagar

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=20190618093657.GA30711@e121166-lin.cambridge.arm.com \
    --to=lorenzo.pieralisi@arm.com \
    --cc=Jisheng.Zhang@synaptics.com \
    --cc=bhelgaas@google.com \
    --cc=gustavo.pimentel@synopsys.com \
    --cc=jingoohan1@gmail.com \
    --cc=kthota@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=mmaddireddy@nvidia.com \
    --cc=sagar.tv@gmail.com \
    --cc=thierry.reding@gmail.com \
    --cc=vidyas@nvidia.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).