2002-12-10 18:34:04

by Margit Schubert-While

[permalink] [raw]
Subject: 2.4.20 AGP for I845 wrong ?

From drivers/char/agp/agpgart_be.c
4554,4559
{ PCI_DEVICE_ID_INTEL_845_G_0,
PCI_VENDOR_ID_INTEL,
INTEL_I845_G,
"Intel",
"i845G",
intel_830mp_setup },

Surely this is wrong or ?
Should be "intel_845_setup", I think.

Which might explain funny messages in th X/DRI/DRM log.

For info, the Intel M/B D845PESV(L) reports as a "G" -
00:00.0 Host bridge: Intel Corp. 82845G/GL [Brookdale-G] Chipset Host
Bridge (rev 02)
00:01.0 PCI bridge: Intel Corp. 82845G/GL [Brookdale-G] Chipset AGP Bridge
(rev 02)

Also in drivers/char/drm/drm_agpsupport.h, the switch statement at 262 is
missing the
cases for INTEL_I830_M, INTEL_I845_G.

Margit


2002-12-11 12:00:03

by Nicolas ASPERT

[permalink] [raw]
Subject: Re: 2.4.20 AGP for I845 wrong ?

diff -ru linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h linux-2.5.51/drivers/char/drm/drm_agpsupport.h
--- linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h Tue Dec 10 03:45:39 2002
+++ linux-2.5.51/drivers/char/drm/drm_agpsupport.h Wed Dec 11 12:55:08 2002
@@ -271,10 +271,12 @@
#if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
case INTEL_I820: head->chipset = "Intel i820"; break;
#endif
+ case INTEL_I830_M: head->chipset = "Intel i830M"; break;
case INTEL_I840: head->chipset = "Intel i840"; break;
#if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
case INTEL_I845: head->chipset = "Intel i845"; break;
#endif
+ case INTEL_I845: head->chipset = "Intel i845G"; break;
case INTEL_I850: head->chipset = "Intel i850"; break;
case INTEL_460GX: head->chipset = "Intel 460GX"; break;


Attachments:
intelchipset-id-2.4.21-pre1.diff (848.00 B)
intelchipset-id-2.5.51.diff (854.00 B)
Download all attachments

2002-12-11 12:09:13

by Nicolas ASPERT

[permalink] [raw]
Subject: Re: 2.4.20 AGP for I845 wrong ?

diff -ru linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h linux-2.5.51/drivers/char/drm/drm_agpsupport.h
--- linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h Tue Dec 10 03:45:39 2002
+++ linux-2.5.51/drivers/char/drm/drm_agpsupport.h Wed Dec 11 12:55:08 2002
@@ -271,10 +271,12 @@
#if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
case INTEL_I820: head->chipset = "Intel i820"; break;
#endif
+ case INTEL_I830_M: head->chipset = "Intel i830M"; break;
case INTEL_I840: head->chipset = "Intel i840"; break;
#if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
case INTEL_I845: head->chipset = "Intel i845"; break;
#endif
+ case INTEL_I845_G: head->chipset = "Intel i845G"; break;
case INTEL_I850: head->chipset = "Intel i850"; break;
case INTEL_460GX: head->chipset = "Intel 460GX"; break;


Attachments:
intelchipset-id-2.5.51.diff (856.00 B)

2002-12-11 12:15:24

by Dave Jones

[permalink] [raw]
Subject: Re: 2.4.20 AGP for I845 wrong ?

On Wed, Dec 11, 2002 at 01:07:45PM +0100, Nicolas ASPERT wrote:
> IIRC, the 845G is a "new" version of the 830MP chipset (it had been
> added by Abraham vd Merwe & Graeme Fisher some months ago), but acts
> basically just as the 830MP. Therefore the entry is correct.... Or maybe
> if it gets confusing adding a comment would not hurt...

I'll check the chipset docs when I get time, and add a comment if
necessary. No-one seems to be complaining that it isn't working,
so I'm inclined to believe your diagnosis is correct.

> > Also in drivers/char/drm/drm_agpsupport.h, the switch statement at 262
> > is missing the
> > cases for INTEL_I830_M, INTEL_I845_G.
> That's true. It is also missing in 2.5.51.
> I attach two patches, one for 2.4.21-pre1 and one for 2.5.51 that should
> fix this.
> diff -ru linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h linux-2.5.51/drivers/char/drm/drm_agpsupport.h
> --- linux-2.5.51.clean/drivers/char/drm/drm_agpsupport.h Tue Dec 10 03:45:39 2002
> +++ linux-2.5.51/drivers/char/drm/drm_agpsupport.h Wed Dec 11 12:55:08 2002
> @@ -271,10 +271,12 @@
> #if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
> case INTEL_I820: head->chipset = "Intel i820"; break;
> #endif
> + case INTEL_I830_M: head->chipset = "Intel i830M"; break;
> case INTEL_I840: head->chipset = "Intel i840"; break;
> #if LINUX_VERSION_CODE >= 0x02040f /* KERNEL_VERSION(2,4,15) */
> case INTEL_I845: head->chipset = "Intel i845"; break;
> #endif
> + case INTEL_I845: head->chipset = "Intel i845G"; break;
> case INTEL_I850: head->chipset = "Intel i850"; break;
> case INTEL_460GX: head->chipset = "Intel 460GX"; break;

DRI folks, this seems like duplication given that this data is available
in agpgart. How about changing this to read whatever agpgart has set in
.chipset_name ?

Keeping these two lists in sync seems somewhat pointless.

Dave

--
| Dave Jones. http://www.codemonkey.org.uk
| SuSE Labs

2002-12-11 12:18:29

by Nicolas ASPERT

[permalink] [raw]
Subject: Re: 2.4.20 AGP for I845 wrong ?

Dave Jones wrote:

> I'll check the chipset docs when I get time, and add a comment if
> necessary. No-one seems to be complaining that it isn't working,
> so I'm inclined to believe your diagnosis is correct.
>

I found the thread of lkml containing the discussion about that ... here
is the link to the original mail :

http://marc.theaimsgroup.com/?l=linux-kernel&m=102122146829865&w=2

> DRI folks, this seems like duplication given that this data is available
> in agpgart. How about changing this to read whatever agpgart has set in
> .chipset_name ?
>

Sounds like a good idea to me ;-)

Best regards
Nicolas.
--
Nicolas Aspert Signal Processing Institute (ITS)
Swiss Federal Institute of Technology (EPFL)

2002-12-12 01:51:42

by David Dawes

[permalink] [raw]
Subject: Re: [Dri-devel] Re: 2.4.20 AGP for I845 wrong ?

On Wed, Dec 11, 2002 at 01:07:45PM +0100, Nicolas ASPERT wrote:
>Margit Schubert-While wrote:
>> From drivers/char/agp/agpgart_be.c
>> 4554,4559
>> { PCI_DEVICE_ID_INTEL_845_G_0,
>> PCI_VENDOR_ID_INTEL,
>> INTEL_I845_G,
>> "Intel",
>> "i845G",
>> intel_830mp_setup },
>>
>> Surely this is wrong or ?
>> Should be "intel_845_setup", I think.
>>
>
>IIRC, the 845G is a "new" version of the 830MP chipset (it had been
>added by Abraham vd Merwe & Graeme Fisher some months ago), but acts
>basically just as the 830MP. Therefore the entry is correct.... Or maybe
>if it gets confusing adding a comment would not hurt...

No, I think it should be intel_845_setup too, since the 845G docs on
Intel's public web site show that the behaviour is like the 845 when
the on-board graphics isn't enabled. I made that change in my
locally maintained version of the agpgart driver a little while ago,
but haven't had the opportunity to test it with an external AGP card
in an 845G box yet.

David
--
David Dawes
Release Engineer/Architect The XFree86 Project
http://www.XFree86.org/~dawes

2002-12-12 08:50:05

by Nicolas ASPERT

[permalink] [raw]
Subject: Re: [Dri-devel] Re: 2.4.20 AGP for I845 wrong ?

David Dawes wrote:

>
> No, I think it should be intel_845_setup too, since the 845G docs on
> Intel's public web site show that the behaviour is like the 845 when
> the on-board graphics isn't enabled. I made that change in my
> locally maintained version of the agpgart driver a little while ago,
> but haven't had the opportunity to test it with an external AGP card
> in an 845G box yet.

Damn, you're right. Now I got the docs from Intel (at the time were the
patch to support 845g was submitted, they were just not available yet),
and truly the specs are closer to the 845, so let's switch to
'intel_845_setup' to initialize the 845g. Not that it should change
things too much, but it will avoid further confusions....

Best regards.

Nicolas

PS: I hope the IBM annoyances for mails sent to lkml stopped...
--
Nicolas Aspert Signal Processing Institute (ITS)
Swiss Federal Institute of Technology (EPFL)

2002-12-20 15:00:51

by Margit Schubert-While

[permalink] [raw]
Subject: Re: 2.4.20 AGP for I845 wrong ?

DJ et al. I thought this had been cleared up on Dec 10 in this thread -

http://marc.theaimsgroup.com/?l=linux-kernel&m=103954588016915&w=2

Margit