From: Christoph Hellwig <hch@infradead.org>
To: Nirmal Patel <nirmal.patel@linux.intel.com>
Cc: Jon Derrick <jonathan.derrick@intel.com>, linux-pci@vger.kernel.org
Subject: Re: [PATCH v2 1/2] PCI: vmd: Trigger secondary bus reset
Date: Wed, 21 Jul 2021 06:45:55 +0100 [thread overview]
Message-ID: <YPe0k1bkj7v33vrM@infradead.org> (raw)
In-Reply-To: <20210720205009.111806-2-nirmal.patel@linux.intel.com>
On Tue, Jul 20, 2021 at 01:50:08PM -0700, Nirmal Patel wrote:
> +#define PCI_HEADER_TYPE_MASK 0x7f
> +#define PCI_CLASS_BRIDGE_PCI 0x0604
Please use the existing definitions from pci_regs.h / pci_ids.h.
>
> +#define DEVICE_SPACE (8 * 4096)
> +#define VMD_DEVICE_BASE(vmd, device) ((vmd)->cfgbar + (device) * DEVICE_SPACE)
> +#define VMD_FUNCTION_BASE(vmd, device, fn) ((vmd)->cfgbar + (device) * (DEVICE_SPACE + (fn*4096)))
Plase turn thos into readable inline functions and avoid the overly long
lines.
> + /*
> + * Subdevice config space may or many not be mapped linearly using 4k config
> + * space.
> + */
Please avoid the overly long line, especially in a comment.
next prev parent reply other threads:[~2021-07-21 5:46 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-20 20:50 [PATCH v2 0/2] Issue secondary bus reset and domain window reset Nirmal Patel
2021-07-20 20:50 ` [PATCH v2 1/2] PCI: vmd: Trigger secondary bus reset Nirmal Patel
2021-07-20 22:33 ` Bjorn Helgaas
2021-07-22 18:39 ` Patel, Nirmal
2021-07-21 5:45 ` Christoph Hellwig [this message]
2021-07-22 18:45 ` Patel, Nirmal
2021-07-21 8:50 ` Pali Rohár
2021-07-22 18:44 ` Patel, Nirmal
2021-07-22 19:11 ` Bjorn Helgaas
2021-07-20 20:50 ` [PATCH v2 2/2] PCI: vmd: Issue vmd domain window reset Nirmal Patel
2021-07-20 22:42 ` Bjorn Helgaas
2021-07-22 18:47 ` Patel, Nirmal
2021-07-22 19:04 ` Bjorn Helgaas
2021-07-20 21:25 ` [PATCH v2 0/2] Issue secondary bus reset and " Patel, Nirmal
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=YPe0k1bkj7v33vrM@infradead.org \
--to=hch@infradead.org \
--cc=jonathan.derrick@intel.com \
--cc=linux-pci@vger.kernel.org \
--cc=nirmal.patel@linux.intel.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).