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
109b44a8
Commit
109b44a8
authored
Aug 15, 2009
by
Paul Mundt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sh: Convert SH-2 to new cacheflush interface.
Signed-off-by:
Paul Mundt
<
lethal@linux-sh.org
>
parent
37443ef3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
3 deletions
+16
-3
arch/sh/mm/cache-sh2.c
arch/sh/mm/cache-sh2.c
+10
-3
arch/sh/mm/cache.c
arch/sh/mm/cache.c
+6
-0
No files found.
arch/sh/mm/cache-sh2.c
View file @
109b44a8
...
...
@@ -16,7 +16,7 @@
#include <asm/cacheflush.h>
#include <asm/io.h>
void
__flush_wback_region
(
void
*
start
,
int
size
)
static
void
sh2
__flush_wback_region
(
void
*
start
,
int
size
)
{
unsigned
long
v
;
unsigned
long
begin
,
end
;
...
...
@@ -37,7 +37,7 @@ void __flush_wback_region(void *start, int size)
}
}
void
__flush_purge_region
(
void
*
start
,
int
size
)
static
void
sh2
__flush_purge_region
(
void
*
start
,
int
size
)
{
unsigned
long
v
;
unsigned
long
begin
,
end
;
...
...
@@ -51,7 +51,7 @@ void __flush_purge_region(void *start, int size)
CACHE_OC_ADDRESS_ARRAY
|
(
v
&
0x00000ff0
)
|
0x00000008
);
}
void
__flush_invalidate_region
(
void
*
start
,
int
size
)
static
void
sh2
__flush_invalidate_region
(
void
*
start
,
int
size
)
{
#ifdef CONFIG_CACHE_WRITEBACK
/*
...
...
@@ -82,3 +82,10 @@ void __flush_invalidate_region(void *start, int size)
CACHE_OC_ADDRESS_ARRAY
|
(
v
&
0x00000ff0
)
|
0x00000008
);
#endif
}
void
__init
sh2_cache_init
(
void
)
{
__flush_wback_region
=
sh2__flush_wback_region
;
__flush_purge_region
=
sh2__flush_purge_region
;
__flush_invalidate_region
=
sh2__flush_invalidate_region
;
}
arch/sh/mm/cache.c
View file @
109b44a8
...
...
@@ -244,6 +244,12 @@ void __init cpu_cache_init(void)
__flush_purge_region
=
noop__flush_region
;
__flush_invalidate_region
=
noop__flush_region
;
if
(
boot_cpu_data
.
family
==
CPU_FAMILY_SH2
)
{
extern
void
__weak
sh2_cache_init
(
void
);
sh2_cache_init
();
}
if
((
boot_cpu_data
.
family
==
CPU_FAMILY_SH4
)
||
(
boot_cpu_data
.
family
==
CPU_FAMILY_SH4A
)
||
(
boot_cpu_data
.
family
==
CPU_FAMILY_SH4AL_DSP
))
{
...
...
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