linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Kishon Vijay Abraham I <kishon@ti.com>
Cc: Jyri Sarha <jyri.sarha@iki.fi>, Tomi Valkeinen <tomba@kernel.org>,
	Rob Herring <robh@kernel.org>,
	linux-pci@vger.kernel.org
Subject: PCI: keystone: ks_pcie_v3_65_add_bus()
Date: Tue, 24 May 2022 15:15:09 -0500	[thread overview]
Message-ID: <20220524201509.GA257154@bhelgaas> (raw)

Not sure whether anybody cares about the keystone driver any more.  It
seems basically unmaintained after 57e1d8206e48 ("MAINTAINERS: move
Murali Karicheri to credits") [1].

Anyway, ks_pcie_v3_65_add_bus() [2] looks unusual to me.  It's an
.add_bus() method that is called whenever we create a new PCI bus:

  ks_pcie_v3_65_add_bus(...)
  {
    ks_pcie_set_dbi_mode
    dw_pcie_writel_dbi(pci, PCI_BASE_ADDRESS_0, 1)
    dw_pcie_writel_dbi(pci, PCI_BASE_ADDRESS_0, SZ_4K - 1)
    ks_pcie_clear_dbi_mode(ks_pcie)
    dw_pcie_writel_dbi(pci, PCI_BASE_ADDRESS_0, ks_pcie->app.start)
  }

This seems like something that should be done when the Root Port is
enumerated, not when we set up its secondary bus.  Maybe somewhere in
ks_pcie_host_init() or ks_pcie_config_msi_irq()?

I don't think we should use .add_bus() unless it's actually something
related to adding a bus.

[1] https://git.kernel.org/linus/57e1d8206e48
[2] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/pci/controller/dwc/pci-keystone.c?id=v5.18#n452

             reply	other threads:[~2022-05-24 20:15 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-24 20:15 Bjorn Helgaas [this message]
2022-05-24 20:54 ` PCI: keystone: ks_pcie_v3_65_add_bus() Rob Herring

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=20220524201509.GA257154@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=jyri.sarha@iki.fi \
    --cc=kishon@ti.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=tomba@kernel.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).