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
b04b564b
Commit
b04b564b
authored
Dec 07, 2002
by
Richard Henderson
Committed by
Richard Henderson
Dec 07, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ALPHA] Clean up Ivan's patch (ChangeSet 1.456.18.11) for the
Alcor buggy window.
parent
f5c7e83a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
24 deletions
+23
-24
arch/alpha/kernel/core_cia.c
arch/alpha/kernel/core_cia.c
+19
-24
include/asm-alpha/core_cia.h
include/asm-alpha/core_cia.h
+4
-0
No files found.
arch/alpha/kernel/core_cia.c
View file @
b04b564b
...
...
@@ -336,7 +336,7 @@ cia_pci_tbi_try2(struct pci_controller *hose,
}
static
inline
void
cia_prepare_tbia_workaround
(
int
cia_rev
,
int
is_pyxis
)
cia_prepare_tbia_workaround
(
int
window
)
{
unsigned
long
*
ppte
,
pte
;
long
i
;
...
...
@@ -348,20 +348,10 @@ cia_prepare_tbia_workaround(int cia_rev, int is_pyxis)
for
(
i
=
0
;
i
<
CIA_BROKEN_TBIA_SIZE
/
sizeof
(
unsigned
long
);
++
i
)
ppte
[
i
]
=
pte
;
if
(
is_pyxis
||
cia_rev
!=
1
)
{
/* We can use W1 for SG on PYXIS/CIA rev 2. */
*
(
vip
)
CIA_IOC_PCI_W1_BASE
=
CIA_BROKEN_TBIA_BASE
|
3
;
*
(
vip
)
CIA_IOC_PCI_W1_MASK
=
(
CIA_BROKEN_TBIA_SIZE
*
1024
-
1
)
&
0xfff00000
;
*
(
vip
)
CIA_IOC_PCI_T1_BASE
=
virt_to_phys
(
ppte
)
>>
2
;
}
else
{
/* CIA rev 1 can't use W1 or W2 for SG, apparently,
so use W3, which we made sure is not used for DAC. */
*
(
vip
)
CIA_IOC_PCI_W3_BASE
=
CIA_BROKEN_TBIA_BASE
|
3
;
*
(
vip
)
CIA_IOC_PCI_W3_MASK
=
(
CIA_BROKEN_TBIA_SIZE
*
1024
-
1
)
&
0xfff00000
;
*
(
vip
)
CIA_IOC_PCI_T3_BASE
=
virt_to_phys
(
ppte
)
>>
2
;
}
*
(
vip
)
CIA_IOC_PCI_Wn_BASE
(
window
)
=
CIA_BROKEN_TBIA_BASE
|
3
;
*
(
vip
)
CIA_IOC_PCI_Wn_MASK
(
window
)
=
(
CIA_BROKEN_TBIA_SIZE
*
1024
-
1
)
&
0xfff00000
;
*
(
vip
)
CIA_IOC_PCI_Tn_BASE
(
window
)
=
virt_to_phys
(
ppte
)
>>
2
;
}
static
void
__init
...
...
@@ -581,8 +571,7 @@ static void __init
do_init_arch
(
int
is_pyxis
)
{
struct
pci_controller
*
hose
;
int
temp
;
int
cia_rev
;
int
temp
,
cia_rev
,
tbia_window
;
cia_rev
=
*
(
vip
)
CIA_IOC_CIA_REV
&
CIA_REV_MASK
;
printk
(
"pci: cia revision %d%s
\n
"
,
...
...
@@ -712,12 +701,18 @@ do_init_arch(int is_pyxis)
elsewhere, we should not claim that we support DAC unless that
4GB covers all of physical memory.
Also, don't do DAC on CIA rev 1, it has other problems and is
unlikely to have more than 2GB of memory anyway, so direct is
fine.
*/
if
(
cia_rev
==
1
||
is_pyxis
||
max_low_pfn
>
(
0x100000000UL
>>
PAGE_SHIFT
))
{
On CIA rev 1, apparently W1 and W2 can't be used for SG.
At least, there are reports that it doesn't work for Alcor.
In that case, we have no choice but to use W3 for the TBIA
workaround, which means we can't use DAC at all. */
tbia_window
=
1
;
if
(
is_pyxis
)
{
*
(
vip
)
CIA_IOC_PCI_W3_BASE
=
0
;
}
else
if
(
cia_rev
==
1
)
{
*
(
vip
)
CIA_IOC_PCI_W1_BASE
=
0
;
tbia_window
=
3
;
}
else
if
(
max_low_pfn
>
(
0x100000000UL
>>
PAGE_SHIFT
))
{
*
(
vip
)
CIA_IOC_PCI_W3_BASE
=
0
;
}
else
{
*
(
vip
)
CIA_IOC_PCI_W3_BASE
=
0x00000000
|
1
|
8
;
...
...
@@ -729,7 +724,7 @@ do_init_arch(int is_pyxis)
}
/* Prepare workaround for apparently broken tbia. */
cia_prepare_tbia_workaround
(
cia_rev
,
is_pyxis
);
cia_prepare_tbia_workaround
(
tbia_window
);
}
void
__init
...
...
include/asm-alpha/core_cia.h
View file @
b04b564b
...
...
@@ -202,6 +202,10 @@
#define CIA_IOC_PCI_W3_MASK (IDENT_ADDR + 0x8760000740UL)
#define CIA_IOC_PCI_T3_BASE (IDENT_ADDR + 0x8760000780UL)
#define CIA_IOC_PCI_Wn_BASE(N) (IDENT_ADDR + 0x8760000400UL + (N)*0x100)
#define CIA_IOC_PCI_Wn_MASK(N) (IDENT_ADDR + 0x8760000440UL + (N)*0x100)
#define CIA_IOC_PCI_Tn_BASE(N) (IDENT_ADDR + 0x8760000480UL + (N)*0x100)
#define CIA_IOC_PCI_W_DAC (IDENT_ADDR + 0x87600007C0UL)
/*
...
...
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