From: Jeff Garzik <jeff@garzik.org>
To: Dave Airlie <airlied@linux.ie>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm: remove pci domain local copy (02/07)
Date: Sat, 22 Jul 2006 12:34:26 -0400 [thread overview]
Message-ID: <44C25392.5000508@garzik.org> (raw)
In-Reply-To: <11535827131612-git-send-email-airlied@linux.ie>
Dave Airlie wrote:
> Just call a function to retrieve the pci domain, this isn't exactly
> hotpath code.
>
> Signed-off-by: Dave Airlie <airlied@linux.ie>
> (cherry picked from 01852d755753bbfcd5434c55d4d7375580f8338f commit)
> ---
> drivers/char/drm/drmP.h | 10 +++++++++-
> drivers/char/drm/drm_ioctl.c | 4 ++--
> drivers/char/drm/drm_irq.c | 2 +-
> 3 files changed, 12 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/char/drm/drmP.h b/drivers/char/drm/drmP.h
> index 5c8f245..4dd28e1 100644
> --- a/drivers/char/drm/drmP.h
> +++ b/drivers/char/drm/drmP.h
> @@ -711,7 +711,6 @@ typedef struct drm_device {
> drm_agp_head_t *agp; /**< AGP data */
>
> struct pci_dev *pdev; /**< PCI device structure */
> - int pci_domain; /**< PCI bus domain number */
> #ifdef __alpha__
> struct pci_controller *hose;
> #endif
> @@ -733,6 +732,15 @@ static __inline__ int drm_core_check_fea
I would presume that hose goes away too?
> +static inline int drm_get_pci_domain(struct drm_device *dev)
> +{
> +#ifdef __alpha__
> + return dev->hose->bus->number;
> +#else
> + return 0;
> +#endif
> +}
Please use the always-present pci_domain_nr() rather than inventing a
DRM-specific function that does the same thing.
Jeff
next prev parent reply other threads:[~2006-07-22 16:34 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-22 15:38 [RFC] GPU device layer patchset (00/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] drm: remove local copies of pci bus/slot/func (01/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] drm: remove pci domain local copy (02/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] gpu: Initial GPU layer addition. (03/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] gpu/radeon: add a radeon lowlevel GPU driver (04/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] gpu/radeonfb: add GPU support to radeonfb (05/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] gpu/drm: Add GPU layer support to generic DRM (06/07) Dave Airlie
2006-07-22 15:38 ` [PATCH] drm/gpu/radeon: Add radeon DRM support to use GPU layer (07/07) Dave Airlie
2006-07-22 19:54 ` [PATCH] gpu: Initial GPU layer addition. (03/07) Jesse Barnes
2006-07-22 21:04 ` Nix
2006-07-23 20:04 ` Luca
2006-07-22 16:34 ` Jeff Garzik [this message]
2006-07-22 16:53 ` [PATCH] drm: remove pci domain local copy (02/07) Dave Airlie
2006-07-22 16:35 ` [RFC] GPU device layer patchset (00/07) Jeff Garzik
2006-07-22 17:00 ` Dave Airlie
2006-07-31 12:42 ` Pavel Machek
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=44C25392.5000508@garzik.org \
--to=jeff@garzik.org \
--cc=airlied@linux.ie \
--cc=linux-kernel@vger.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