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
6413a4ba
Commit
6413a4ba
authored
Feb 09, 2009
by
Kevin Hilman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
davinci: PSC: finalize decoupling of PSC and MUX settings
Signed-off-by:
Kevin Hilman
<
khilman@deeprootsystems.com
>
parent
22d7d0d3
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
22 additions
and
53 deletions
+22
-53
arch/arm/mach-davinci/board-dm644x-evm.c
arch/arm/mach-davinci/board-dm644x-evm.c
+1
-0
arch/arm/mach-davinci/board-sffsdr.c
arch/arm/mach-davinci/board-sffsdr.c
+6
-1
arch/arm/mach-davinci/clock.c
arch/arm/mach-davinci/clock.c
+0
-1
arch/arm/mach-davinci/devices.c
arch/arm/mach-davinci/devices.c
+12
-0
arch/arm/mach-davinci/include/mach/hardware.h
arch/arm/mach-davinci/include/mach/hardware.h
+3
-0
arch/arm/mach-davinci/include/mach/psc.h
arch/arm/mach-davinci/include/mach/psc.h
+0
-1
arch/arm/mach-davinci/psc.c
arch/arm/mach-davinci/psc.c
+0
-50
No files found.
arch/arm/mach-davinci/board-dm644x-evm.c
View file @
6413a4ba
...
...
@@ -573,6 +573,7 @@ static struct davinci_i2c_platform_data i2c_pdata = {
static
void
__init
evm_init_i2c
(
void
)
{
davinci_cfg_reg
(
DM644X_I2C
);
davinci_init_i2c
(
&
i2c_pdata
);
i2c_add_driver
(
&
dm6446evm_msp_driver
);
i2c_register_board_info
(
1
,
i2c_info
,
ARRAY_SIZE
(
i2c_info
));
...
...
arch/arm/mach-davinci/board-sffsdr.c
View file @
6413a4ba
...
...
@@ -52,6 +52,7 @@
#include <mach/i2c.h>
#include <mach/serial.h>
#include <mach/psc.h>
#include <mach/mux.h>
#define DAVINCI_ASYNC_EMIF_CONTROL_BASE 0x01e00000
#define DAVINCI_ASYNC_EMIF_DATA_CE0_BASE 0x02000000
...
...
@@ -132,6 +133,7 @@ static struct davinci_i2c_platform_data i2c_pdata = {
static
void
__init
sffsdr_init_i2c
(
void
)
{
davinci_cfg_reg
(
DM644X_I2C
);
davinci_init_i2c
(
&
i2c_pdata
);
i2c_register_board_info
(
1
,
i2c_info
,
ARRAY_SIZE
(
i2c_info
));
}
...
...
@@ -152,13 +154,16 @@ static void __init davinci_sffsdr_map_io(void)
static
__init
void
davinci_sffsdr_init
(
void
)
{
davinci_psc_init
();
platform_add_devices
(
davinci_sffsdr_devices
,
ARRAY_SIZE
(
davinci_sffsdr_devices
));
sffsdr_init_i2c
();
davinci_serial_init
(
&
uart_config
);
davinci_init_emac
(
davinci_sffsdr_mac_addr
);
setup_usb
(
0
,
0
);
/* We support only peripheral mode. */
/* mux VLYNQ pins */
davinci_cfg_reg
(
DM644X_VLYNQEN
);
davinci_cfg_reg
(
DM644X_VLYNQWD
);
}
static
int
davinci_cpmac_eth_setup
(
char
*
str
)
...
...
arch/arm/mach-davinci/clock.c
View file @
6413a4ba
...
...
@@ -377,7 +377,6 @@ int __init davinci_clk_init(struct clk *clocks[])
struct
clk
*
clkp
;
int
i
=
0
;
davinci_psc_init
();
while
((
clkp
=
clocks
[
i
++
]))
{
if
(
clkp
->
pll_data
)
clk_pll_init
(
clkp
);
...
...
arch/arm/mach-davinci/devices.c
View file @
6413a4ba
...
...
@@ -190,6 +190,18 @@ void __init davinci_setup_mmc(int module, struct davinci_mmc_config *config)
/* enable RX EDMA */
davinci_cfg_reg
(
DM355_EVT26_MMC0_RX
);
}
else
if
(
cpu_is_davinci_dm644x
())
{
/* REVISIT: should this be in board-init code? */
void
__iomem
*
base
=
IO_ADDRESS
(
DAVINCI_SYSTEM_MODULE_BASE
);
/* Power-on 3.3V IO cells */
__raw_writel
(
0
,
base
+
DM64XX_VDD3P3V_PWDN
);
/*Set up the pull regiter for MMC */
davinci_cfg_reg
(
DM644X_MSTK
);
}
pdev
=
&
davinci_mmcsd0_device
;
clockname
=
cpu_is_davinci_dm355
()
?
"mmcsd0"
:
"mmcsd"
;
break
;
...
...
arch/arm/mach-davinci/include/mach/hardware.h
View file @
6413a4ba
...
...
@@ -21,4 +21,7 @@
*/
#define DAVINCI_SYSTEM_MODULE_BASE 0x01C40000
/* System control register offsets */
#define DM64XX_VDD3P3V_PWDN 0x48
#endif
/* __ASM_ARCH_HARDWARE_H */
arch/arm/mach-davinci/include/mach/psc.h
View file @
6413a4ba
...
...
@@ -116,7 +116,6 @@
#define DM646X_LPSC_TIMER1 35
#define DM646X_LPSC_ARM_INTC 45
extern
void
davinci_psc_init
(
void
);
extern
void
davinci_psc_config
(
unsigned
int
domain
,
unsigned
int
id
,
char
enable
);
...
...
arch/arm/mach-davinci/psc.c
View file @
6413a4ba
...
...
@@ -39,41 +39,6 @@
#define MDSTAT 0x800
#define MDCTL 0xA00
/* System control register offsets */
#define VDD3P3V_PWDN 0x48
static
void
(
*
davinci_psc_mux
)(
unsigned
int
id
);
static
void
dm6446_psc_mux
(
unsigned
int
id
)
{
void
__iomem
*
base
=
IO_ADDRESS
(
DAVINCI_SYSTEM_MODULE_BASE
);
switch
(
id
)
{
case
DAVINCI_LPSC_MMC_SD
:
/* VDD power manupulations are done in U-Boot for CPMAC
* so applies to MMC as well
*/
/*Set up the pull regiter for MMC */
__raw_writel
(
0
,
base
+
VDD3P3V_PWDN
);
davinci_cfg_reg
(
DM644X_MSTK
);
break
;
case
DAVINCI_LPSC_I2C
:
davinci_cfg_reg
(
DM644X_I2C
);
break
;
case
DAVINCI_LPSC_VLYNQ
:
davinci_cfg_reg
(
DM644X_VLYNQEN
);
davinci_cfg_reg
(
DM644X_VLYNQWD
);
break
;
default:
break
;
}
}
static
void
nop_psc_mux
(
unsigned
int
id
)
{
/* nothing */
}
/* Enable or disable a PSC domain */
void
davinci_psc_config
(
unsigned
int
domain
,
unsigned
int
id
,
char
enable
)
{
...
...
@@ -125,19 +90,4 @@ void davinci_psc_config(unsigned int domain, unsigned int id, char enable)
do
{
mdstat
=
__raw_readl
(
psc_base
+
MDSTAT
+
4
*
id
);
}
while
(
!
((
mdstat
&
0x0000001F
)
==
mdstat_mask
));
if
(
enable
)
davinci_psc_mux
(
id
);
}
void
__init
davinci_psc_init
(
void
)
{
if
(
cpu_is_davinci_dm644x
()
||
cpu_is_davinci_dm646x
())
{
davinci_psc_mux
=
dm6446_psc_mux
;
}
else
if
(
cpu_is_davinci_dm355
())
{
davinci_psc_mux
=
nop_psc_mux
;
}
else
{
pr_err
(
"PSC: no PSC mux hooks for this CPU
\n
"
);
davinci_psc_mux
=
nop_psc_mux
;
}
}
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