Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
28b0724a
Commit
28b0724a
authored
Jan 02, 2003
by
Dave Jones
Committed by
Dave Jones
Jan 02, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[AGP] VIA KT400 AGP 3.0 aperture size decoding.
parent
4f052b71
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
11 deletions
+26
-11
drivers/char/agp/agp.h
drivers/char/agp/agp.h
+1
-0
drivers/char/agp/via-kt400.c
drivers/char/agp/via-kt400.c
+25
-11
No files found.
drivers/char/agp/agp.h
View file @
28b0724a
...
@@ -294,6 +294,7 @@ struct agp_bridge_data {
...
@@ -294,6 +294,7 @@ struct agp_bridge_data {
#define VIA_ATTBASE 0x88
#define VIA_ATTBASE 0x88
/* VIA KT400 */
/* VIA KT400 */
#define VIA_AGP3_APSIZE 0x94
#define VIA_AGPSEL 0xfd
#define VIA_AGPSEL 0xfd
/* SiS registers */
/* SiS registers */
...
...
drivers/char/agp/via-kt400.c
View file @
28b0724a
...
@@ -14,10 +14,22 @@
...
@@ -14,10 +14,22 @@
#include <linux/agp_backend.h>
#include <linux/agp_backend.h>
#include "agp.h"
#include "agp.h"
static
int
agp_try_unsupported
__initdata
=
0
;
static
int
via_fetch_size
(
void
)
static
int
via_fetch_size
(
void
)
{
{
int
i
;
u8
temp
;
struct
aper_size_info_32
*
values
;
values
=
A_SIZE_32
(
agp_bridge
.
aperture_sizes
);
pci_read_config_byte
(
agp_bridge
.
dev
,
VIA_AGP3_APSIZE
,
&
temp
);
for
(
i
=
0
;
i
<
agp_bridge
.
num_aperture_sizes
;
i
++
)
{
if
(
temp
==
values
[
i
].
size_value
)
{
agp_bridge
.
previous_size
=
agp_bridge
.
current_size
=
(
void
*
)
(
values
+
i
);
agp_bridge
.
aperture_size_idx
=
i
;
return
values
[
i
].
size
;
}
}
return
0
;
return
0
;
}
}
...
@@ -41,15 +53,18 @@ static unsigned long via_mask_memory(unsigned long addr, int type)
...
@@ -41,15 +53,18 @@ static unsigned long via_mask_memory(unsigned long addr, int type)
return
addr
|
agp_bridge
.
masks
[
0
].
mask
;
return
addr
|
agp_bridge
.
masks
[
0
].
mask
;
}
}
static
struct
aper_size_info_
8
via_generic_sizes
[
7
]
=
static
struct
aper_size_info_
32
via_generic_sizes
[
11
]
=
{
{
{
256
,
65536
,
6
,
0
},
{
4
,
1024
,
0
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
|
1
<<
4
|
1
<<
3
|
1
<<
2
|
1
<<
1
|
1
<<
0
},
{
128
,
32768
,
5
,
128
},
{
8
,
2048
,
1
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
|
1
<<
4
|
1
<<
3
|
1
<<
2
|
1
<<
1
},
{
64
,
16384
,
4
,
192
},
{
16
,
4096
,
2
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
|
1
<<
4
|
1
<<
3
|
1
<<
2
},
{
32
,
8192
,
3
,
224
},
{
32
,
8192
,
3
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
|
1
<<
4
|
1
<<
3
},
{
16
,
4096
,
2
,
240
},
{
64
,
16384
,
4
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
|
1
<<
4
},
{
8
,
2048
,
1
,
248
},
{
128
,
32768
,
5
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
|
1
<<
5
},
{
4
,
1024
,
0
,
252
}
{
256
,
65536
,
6
,
1
<<
11
|
1
<<
10
|
1
<<
9
|
1
<<
8
},
{
512
,
131072
,
7
,
1
<<
11
|
1
<<
10
|
1
<<
9
},
{
1024
,
262144
,
8
,
1
<<
11
|
1
<<
10
},
{
2048
,
524288
,
9
,
1
<<
11
}
/* 2GB <- Max supported */
};
};
static
struct
gatt_mask
via_generic_masks
[]
=
static
struct
gatt_mask
via_generic_masks
[]
=
...
@@ -158,7 +173,6 @@ static void __exit agp_via_cleanup(void)
...
@@ -158,7 +173,6 @@ static void __exit agp_via_cleanup(void)
module_init
(
agp_via_init
);
module_init
(
agp_via_init
);
module_exit
(
agp_via_cleanup
);
module_exit
(
agp_via_cleanup
);
MODULE_PARM
(
agp_try_unsupported
,
"1i"
);
MODULE_AUTHOR
(
"Dave Jones <davej@codemonkey.org.uk>"
);
MODULE_AUTHOR
(
"Dave Jones <davej@codemonkey.org.uk>"
);
MODULE_LICENSE
(
"GPL and additional rights"
);
MODULE_LICENSE
(
"GPL and additional rights"
);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment