From: Ondrej Zary <linux@rainbow-software.org>
To: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: "nouveau@lists.freedesktop.org" <nouveau@lists.freedesktop.org>,
Kernel development list <linux-kernel@vger.kernel.org>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>
Subject: Re: AGP cards in PCI mode (fake slots like AGPro, AGP Express, AGI, AGX, XGP)
Date: Mon, 14 Sep 2015 00:01:55 +0200 [thread overview]
Message-ID: <201509140001.55580.linux@rainbow-software.org> (raw)
In-Reply-To: <CAKb7UvjyEzWbCAcResVTyqVg=o25c6=42xDAQQ2GgDTJ=_bH3g@mail.gmail.com>
On Sunday 13 September 2015 21:12:25 Ilia Mirkin wrote:
> On Sun, Sep 13, 2015 at 2:57 PM, Ondrej Zary <linux@rainbow-software.org> wrote:
> > Hello,
> > I have a PC Chips A31G board with AGPro slot and found that nouveau does
> > not work properly with it. Console works but reverts to software mode,
> > X11 hangs with mouse cursor only.
> >
> > The slot is physically AGP 1.5V but is wired to PCI bus as the chipset
> > (SiS 761) does not support AGP cards. To further complicate things, the
> > chipset has AGP capability - but only for the integrated video. You can
> > see that in the lspci output below - the AGP card is on bus 0 and SiS
> > card on bus 1 (AGP bus behind the AGP bridge). The SiS card is not used
> > (can be disabled in BIOS but it does not improve things - as the AGP
> > capability of the host bridge remains active).
>
> I believe we can handle it with a blacklist. If the chipset just
> doesn't support AGP at all, we should just set agpmode=0 irrespective
> of the card plugged in, right?
>
> Shouldn't the agpgart know about this and not even allow any setting
> at all? This is where we get the idea to set 8x AGP from. See
> drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c for details.
The chipset does not support AGP slot but supports AGP for the integrated
video. So it shouldn't be completely disabled.
> The alternative is to add to nvkm_device_agp_quirks, and just add
> something that matches just the host bridge vendor/device, ignoring
> the chip.
Something like this?
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
index 814cb51..385a90f 100644
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
@@ -35,6 +35,8 @@ static const struct nvkm_device_agp_quirk
nvkm_device_agp_quirks[] = {
/* VIA Apollo PRO133x / GeForce FX 5600 Ultra - fdo#20341 */
{ PCI_VENDOR_ID_VIA, 0x0691, PCI_VENDOR_ID_NVIDIA, 0x0311, 2 },
+ /* SiS 761 does not support AGP cards, use PCI mode */
+ { PCI_VENDOR_ID_SI, 0x0761, PCI_ANY_ID, PCI_ANY_ID, 0 },
{},
};
@@ -137,8 +139,10 @@ nvkm_agp_ctor(struct nvkm_pci *pci)
while (quirk->hostbridge_vendor) {
if (info.device->vendor == quirk->hostbridge_vendor &&
info.device->device == quirk->hostbridge_device &&
- pci->pdev->vendor == quirk->chip_vendor &&
- pci->pdev->device == quirk->chip_device) {
+ (quirk->chip_vendor == (u16)PCI_ANY_ID ||
+ pci->pdev->vendor == quirk->chip_vendor) &&
+ (quirk->chip_device == (u16)PCI_ANY_ID ||
+ pci->pdev->device == quirk->chip_device)) {
nvkm_info(subdev, "forcing default agp mode to %dX, "
"use NvAGP=<mode> to override\n",
quirk->mode);
--
Ondrej Zary
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
WARNING: multiple messages have this Message-ID (diff)
From: Ondrej Zary <linux@rainbow-software.org>
To: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: "nouveau@lists.freedesktop.org" <nouveau@lists.freedesktop.org>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>,
Kernel development list <linux-kernel@vger.kernel.org>
Subject: Re: AGP cards in PCI mode (fake slots like AGPro, AGP Express, AGI, AGX, XGP)
Date: Mon, 14 Sep 2015 00:01:55 +0200 [thread overview]
Message-ID: <201509140001.55580.linux@rainbow-software.org> (raw)
In-Reply-To: <CAKb7UvjyEzWbCAcResVTyqVg=o25c6=42xDAQQ2GgDTJ=_bH3g@mail.gmail.com>
On Sunday 13 September 2015 21:12:25 Ilia Mirkin wrote:
> On Sun, Sep 13, 2015 at 2:57 PM, Ondrej Zary <linux@rainbow-software.org> wrote:
> > Hello,
> > I have a PC Chips A31G board with AGPro slot and found that nouveau does
> > not work properly with it. Console works but reverts to software mode,
> > X11 hangs with mouse cursor only.
> >
> > The slot is physically AGP 1.5V but is wired to PCI bus as the chipset
> > (SiS 761) does not support AGP cards. To further complicate things, the
> > chipset has AGP capability - but only for the integrated video. You can
> > see that in the lspci output below - the AGP card is on bus 0 and SiS
> > card on bus 1 (AGP bus behind the AGP bridge). The SiS card is not used
> > (can be disabled in BIOS but it does not improve things - as the AGP
> > capability of the host bridge remains active).
>
> I believe we can handle it with a blacklist. If the chipset just
> doesn't support AGP at all, we should just set agpmode=0 irrespective
> of the card plugged in, right?
>
> Shouldn't the agpgart know about this and not even allow any setting
> at all? This is where we get the idea to set 8x AGP from. See
> drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c for details.
The chipset does not support AGP slot but supports AGP for the integrated
video. So it shouldn't be completely disabled.
> The alternative is to add to nvkm_device_agp_quirks, and just add
> something that matches just the host bridge vendor/device, ignoring
> the chip.
Something like this?
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
index 814cb51..385a90f 100644
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/pci/agp.c
@@ -35,6 +35,8 @@ static const struct nvkm_device_agp_quirk
nvkm_device_agp_quirks[] = {
/* VIA Apollo PRO133x / GeForce FX 5600 Ultra - fdo#20341 */
{ PCI_VENDOR_ID_VIA, 0x0691, PCI_VENDOR_ID_NVIDIA, 0x0311, 2 },
+ /* SiS 761 does not support AGP cards, use PCI mode */
+ { PCI_VENDOR_ID_SI, 0x0761, PCI_ANY_ID, PCI_ANY_ID, 0 },
{},
};
@@ -137,8 +139,10 @@ nvkm_agp_ctor(struct nvkm_pci *pci)
while (quirk->hostbridge_vendor) {
if (info.device->vendor == quirk->hostbridge_vendor &&
info.device->device == quirk->hostbridge_device &&
- pci->pdev->vendor == quirk->chip_vendor &&
- pci->pdev->device == quirk->chip_device) {
+ (quirk->chip_vendor == (u16)PCI_ANY_ID ||
+ pci->pdev->vendor == quirk->chip_vendor) &&
+ (quirk->chip_device == (u16)PCI_ANY_ID ||
+ pci->pdev->device == quirk->chip_device)) {
nvkm_info(subdev, "forcing default agp mode to %dX, "
"use NvAGP=<mode> to override\n",
quirk->mode);
--
Ondrej Zary
next prev parent reply other threads:[~2015-09-13 22:01 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-13 18:57 AGP cards in PCI mode (fake slots like AGPro, AGP Express, AGI, AGX, XGP) Ondrej Zary
[not found] ` <201509132057.30674.linux-ZCIryABCsrmttCpgsWEBFmD2FQJk+8+b@public.gmane.org>
2015-09-13 19:12 ` Ilia Mirkin
2015-09-13 19:12 ` Ilia Mirkin
2015-09-13 22:01 ` Ondrej Zary [this message]
2015-09-13 22:01 ` Ondrej Zary
[not found] ` <201509140001.55580.linux-ZCIryABCsrmttCpgsWEBFmD2FQJk+8+b@public.gmane.org>
2015-09-13 22:17 ` Ilia Mirkin
2015-09-13 22:17 ` Ilia Mirkin
2015-09-14 2:31 ` Alex Deucher
2015-09-14 2:31 ` Alex Deucher
2015-09-15 12:43 ` Ondrej Zary
2015-09-15 12:43 ` Ondrej Zary
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=201509140001.55580.linux@rainbow-software.org \
--to=linux@rainbow-software.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=imirkin@alum.mit.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=nouveau@lists.freedesktop.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.