Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
80d597b0
Commit
80d597b0
authored
Jun 30, 2006
by
Juha Yrjola
Browse files
Options
Browse Files
Download
Plain Diff
Merge 65.200.49.170:linux-omap
parents
d43f67c3
e7f9337e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
arch/arm/mach-omap2/gpmc.c
arch/arm/mach-omap2/gpmc.c
+9
-1
include/asm-arm/arch-omap/gpmc.h
include/asm-arm/arch-omap/gpmc.h
+3
-1
No files found.
arch/arm/mach-omap2/gpmc.c
View file @
80d597b0
...
...
@@ -88,6 +88,13 @@ unsigned int gpmc_ns_to_ticks(unsigned int time_ns)
return
(
time_ns
*
1000
+
tick_ps
-
1
)
/
tick_ps
;
}
unsigned
int
gpmc_round_ns_to_ticks
(
unsigned
int
time_ns
)
{
unsigned
long
ticks
=
gpmc_ns_to_ticks
(
time_ns
);
return
ticks
*
gpmc_get_fclk_period
()
/
1000
;
}
#ifdef DEBUG
static
int
set_gpmc_timing_reg
(
int
cs
,
int
reg
,
int
st_bit
,
int
end_bit
,
int
time
,
const
char
*
name
)
...
...
@@ -141,7 +148,7 @@ int gpmc_cs_calc_divider(int cs, unsigned int sync_clk)
div
=
l
/
gpmc_get_fclk_period
();
if
(
div
>
4
)
return
-
1
;
if
(
div
<
0
)
if
(
div
<
=
0
)
div
=
1
;
return
div
;
...
...
@@ -183,6 +190,7 @@ int gpmc_cs_set_timings(int cs, const struct gpmc_timings *t)
l
=
gpmc_cs_read_reg
(
cs
,
GPMC_CS_CONFIG1
);
l
&=
~
0x03
;
l
|=
(
div
-
1
);
gpmc_cs_write_reg
(
cs
,
GPMC_CS_CONFIG1
,
l
);
return
0
;
}
...
...
include/asm-arm/arch-omap/gpmc.h
View file @
80d597b0
...
...
@@ -23,9 +23,10 @@
#define GPMC_CS_NAND_DATA 0x24
#define GPMC_CONFIG1_WRAPBURST_SUPP (1 << 31)
#define GPMC_CONFIG1_READMULTIPLE_SUPP (1 <<
2
0)
#define GPMC_CONFIG1_READMULTIPLE_SUPP (1 <<
3
0)
#define GPMC_CONFIG1_READTYPE_ASYNC (0 << 29)
#define GPMC_CONFIG1_READTYPE_SYNC (1 << 29)
#define GPMC_CONFIG1_WRITEMULTIPLE_SUPP (1 << 28)
#define GPMC_CONFIG1_WRITETYPE_ASYNC (0 << 27)
#define GPMC_CONFIG1_WRITETYPE_SYNC (1 << 27)
#define GPMC_CONFIG1_CLKACTIVATIONTIME(val) ((val & 3) << 25)
...
...
@@ -80,6 +81,7 @@ struct gpmc_timings {
};
extern
unsigned
int
gpmc_ns_to_ticks
(
unsigned
int
time_ns
);
extern
unsigned
int
gpmc_round_ns_to_ticks
(
unsigned
int
time_ns
);
extern
void
gpmc_cs_write_reg
(
int
cs
,
int
idx
,
u32
val
);
extern
u32
gpmc_cs_read_reg
(
int
cs
,
int
idx
);
...
...
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