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
Kirill Smelkov
linux
Commits
a3fd869a
Commit
a3fd869a
authored
Jul 25, 2012
by
Paul Mundt
Browse files
Options
Browse Files
Download
Plain Diff
Merge branches 'sh/urgent' and 'sh/regulator' into sh-latest
parents
90eed7d8
89d71486
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
260 additions
and
17 deletions
+260
-17
arch/sh/boards/Kconfig
arch/sh/boards/Kconfig
+13
-0
arch/sh/boards/board-apsh4a3a.c
arch/sh/boards/board-apsh4a3a.c
+10
-0
arch/sh/boards/board-apsh4ad0a.c
arch/sh/boards/board-apsh4ad0a.c
+10
-0
arch/sh/boards/board-magicpanelr2.c
arch/sh/boards/board-magicpanelr2.c
+10
-0
arch/sh/boards/board-polaris.c
arch/sh/boards/board-polaris.c
+10
-0
arch/sh/boards/board-sh2007.c
arch/sh/boards/board-sh2007.c
+12
-0
arch/sh/boards/board-sh7757lcr.c
arch/sh/boards/board-sh7757lcr.c
+14
-0
arch/sh/boards/mach-ap325rxa/setup.c
arch/sh/boards/mach-ap325rxa/setup.c
+21
-0
arch/sh/boards/mach-ecovec24/setup.c
arch/sh/boards/mach-ecovec24/setup.c
+100
-17
arch/sh/boards/mach-kfr2r09/setup.c
arch/sh/boards/mach-kfr2r09/setup.c
+12
-0
arch/sh/boards/mach-migor/setup.c
arch/sh/boards/mach-migor/setup.c
+13
-0
arch/sh/boards/mach-rsk/setup.c
arch/sh/boards/mach-rsk/setup.c
+10
-0
arch/sh/boards/mach-sdk7786/setup.c
arch/sh/boards/mach-sdk7786/setup.c
+10
-0
arch/sh/boards/mach-se/7724/setup.c
arch/sh/boards/mach-se/7724/setup.c
+15
-0
No files found.
arch/sh/boards/Kconfig
View file @
a3fd869a
...
@@ -57,6 +57,7 @@ config SH_7724_SOLUTION_ENGINE
...
@@ -57,6 +57,7 @@ config SH_7724_SOLUTION_ENGINE
depends on CPU_SUBTYPE_SH7724
depends on CPU_SUBTYPE_SH7724
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select SND_SOC_AK4642 if SND_SIMPLE_CARD
select SND_SOC_AK4642 if SND_SIMPLE_CARD
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Select 7724 SolutionEngine if configuring for a Hitachi SH7724
Select 7724 SolutionEngine if configuring for a Hitachi SH7724
evaluation board.
evaluation board.
...
@@ -140,6 +141,7 @@ config SH_RSK
...
@@ -140,6 +141,7 @@ config SH_RSK
bool "Renesas Starter Kit"
bool "Renesas Starter Kit"
depends on CPU_SUBTYPE_SH7201 || CPU_SUBTYPE_SH7203 || \
depends on CPU_SUBTYPE_SH7201 || CPU_SUBTYPE_SH7203 || \
CPU_SUBTYPE_SH7264 || CPU_SUBTYPE_SH7269
CPU_SUBTYPE_SH7264 || CPU_SUBTYPE_SH7269
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Select this option if configuring for any of the RSK+ MCU
Select this option if configuring for any of the RSK+ MCU
evaluation platforms.
evaluation platforms.
...
@@ -159,6 +161,7 @@ config SH_SDK7786
...
@@ -159,6 +161,7 @@ config SH_SDK7786
select NO_IOPORT if !PCI
select NO_IOPORT if !PCI
select ARCH_WANT_OPTIONAL_GPIOLIB
select ARCH_WANT_OPTIONAL_GPIOLIB
select HAVE_SRAM_POOL
select HAVE_SRAM_POOL
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Select SDK7786 if configuring for a Renesas Technology Europe
Select SDK7786 if configuring for a Renesas Technology Europe
SH7786-65nm board.
SH7786-65nm board.
...
@@ -173,6 +176,7 @@ config SH_SH7757LCR
...
@@ -173,6 +176,7 @@ config SH_SH7757LCR
bool "SH7757LCR"
bool "SH7757LCR"
depends on CPU_SUBTYPE_SH7757
depends on CPU_SUBTYPE_SH7757
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select REGULATOR_FIXED_VOLTAGE if REGULATOR
config SH_SH7785LCR
config SH_SH7785LCR
bool "SH7785LCR"
bool "SH7785LCR"
...
@@ -206,6 +210,7 @@ config SH_MIGOR
...
@@ -206,6 +210,7 @@ config SH_MIGOR
bool "Migo-R"
bool "Migo-R"
depends on CPU_SUBTYPE_SH7722
depends on CPU_SUBTYPE_SH7722
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Select Migo-R if configuring for the SH7722 Migo-R platform
Select Migo-R if configuring for the SH7722 Migo-R platform
by Renesas System Solutions Asia Pte. Ltd.
by Renesas System Solutions Asia Pte. Ltd.
...
@@ -214,6 +219,7 @@ config SH_AP325RXA
...
@@ -214,6 +219,7 @@ config SH_AP325RXA
bool "AP-325RXA"
bool "AP-325RXA"
depends on CPU_SUBTYPE_SH7723
depends on CPU_SUBTYPE_SH7723
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Renesas "AP-325RXA" support.
Renesas "AP-325RXA" support.
Compatible with ALGO SYSTEM CO.,LTD. "AP-320A"
Compatible with ALGO SYSTEM CO.,LTD. "AP-320A"
...
@@ -222,6 +228,7 @@ config SH_KFR2R09
...
@@ -222,6 +228,7 @@ config SH_KFR2R09
bool "KFR2R09"
bool "KFR2R09"
depends on CPU_SUBTYPE_SH7724
depends on CPU_SUBTYPE_SH7724
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
"Kit For R2R for 2009" support.
"Kit For R2R for 2009" support.
...
@@ -230,6 +237,7 @@ config SH_ECOVEC
...
@@ -230,6 +237,7 @@ config SH_ECOVEC
depends on CPU_SUBTYPE_SH7724
depends on CPU_SUBTYPE_SH7724
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select SND_SOC_DA7210 if SND_SIMPLE_CARD
select SND_SOC_DA7210 if SND_SIMPLE_CARD
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Renesas "R0P7724LC0011/21RL (EcoVec)" support.
Renesas "R0P7724LC0011/21RL (EcoVec)" support.
...
@@ -305,6 +313,7 @@ config SH_MAGIC_PANEL_R2
...
@@ -305,6 +313,7 @@ config SH_MAGIC_PANEL_R2
bool "Magic Panel R2"
bool "Magic Panel R2"
depends on CPU_SUBTYPE_SH7720
depends on CPU_SUBTYPE_SH7720
select ARCH_REQUIRE_GPIOLIB
select ARCH_REQUIRE_GPIOLIB
select REGULATOR_FIXED_VOLTAGE if REGULATOR
help
help
Select Magic Panel R2 if configuring for Magic Panel R2.
Select Magic Panel R2 if configuring for Magic Panel R2.
...
@@ -316,6 +325,7 @@ config SH_CAYMAN
...
@@ -316,6 +325,7 @@ config SH_CAYMAN
config SH_POLARIS
config SH_POLARIS
bool "SMSC Polaris"
bool "SMSC Polaris"
select CPU_HAS_IPR_IRQ
select CPU_HAS_IPR_IRQ
select REGULATOR_FIXED_VOLTAGE if REGULATOR
depends on CPU_SUBTYPE_SH7709
depends on CPU_SUBTYPE_SH7709
help
help
Select if configuring for an SMSC Polaris development board
Select if configuring for an SMSC Polaris development board
...
@@ -323,6 +333,7 @@ config SH_POLARIS
...
@@ -323,6 +333,7 @@ config SH_POLARIS
config SH_SH2007
config SH_SH2007
bool "SH-2007 board"
bool "SH-2007 board"
select NO_IOPORT
select NO_IOPORT
select REGULATOR_FIXED_VOLTAGE if REGULATOR
depends on CPU_SUBTYPE_SH7780
depends on CPU_SUBTYPE_SH7780
help
help
SH-2007 is a single-board computer based around SH7780 chip
SH-2007 is a single-board computer based around SH7780 chip
...
@@ -334,6 +345,7 @@ config SH_SH2007
...
@@ -334,6 +345,7 @@ config SH_SH2007
config SH_APSH4A3A
config SH_APSH4A3A
bool "AP-SH4A-3A"
bool "AP-SH4A-3A"
select SH_ALPHA_BOARD
select SH_ALPHA_BOARD
select REGULATOR_FIXED_VOLTAGE if REGULATOR
depends on CPU_SUBTYPE_SH7785
depends on CPU_SUBTYPE_SH7785
help
help
Select AP-SH4A-3A if configuring for an ALPHAPROJECT AP-SH4A-3A.
Select AP-SH4A-3A if configuring for an ALPHAPROJECT AP-SH4A-3A.
...
@@ -342,6 +354,7 @@ config SH_APSH4AD0A
...
@@ -342,6 +354,7 @@ config SH_APSH4AD0A
bool "AP-SH4AD-0A"
bool "AP-SH4AD-0A"
select SH_ALPHA_BOARD
select SH_ALPHA_BOARD
select SYS_SUPPORTS_PCI
select SYS_SUPPORTS_PCI
select REGULATOR_FIXED_VOLTAGE if REGULATOR
depends on CPU_SUBTYPE_SH7786
depends on CPU_SUBTYPE_SH7786
help
help
Select AP-SH4AD-0A if configuring for an ALPHAPROJECT AP-SH4AD-0A.
Select AP-SH4AD-0A if configuring for an ALPHAPROJECT AP-SH4AD-0A.
...
...
arch/sh/boards/board-apsh4a3a.c
View file @
a3fd869a
...
@@ -13,6 +13,8 @@
...
@@ -13,6 +13,8 @@
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/io.h>
#include <linux/mtd/physmap.h>
#include <linux/mtd/physmap.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/irq.h>
#include <linux/irq.h>
#include <linux/clk.h>
#include <linux/clk.h>
...
@@ -66,6 +68,12 @@ static struct platform_device nor_flash_device = {
...
@@ -66,6 +68,12 @@ static struct platform_device nor_flash_device = {
.
resource
=
nor_flash_resources
,
.
resource
=
nor_flash_resources
,
};
};
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
static
struct
resource
smsc911x_resources
[]
=
{
static
struct
resource
smsc911x_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"smsc911x-memory"
,
.
name
=
"smsc911x-memory"
,
...
@@ -105,6 +113,8 @@ static struct platform_device *apsh4a3a_devices[] __initdata = {
...
@@ -105,6 +113,8 @@ static struct platform_device *apsh4a3a_devices[] __initdata = {
static
int
__init
apsh4a3a_devices_setup
(
void
)
static
int
__init
apsh4a3a_devices_setup
(
void
)
{
{
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
return
platform_add_devices
(
apsh4a3a_devices
,
return
platform_add_devices
(
apsh4a3a_devices
,
ARRAY_SIZE
(
apsh4a3a_devices
));
ARRAY_SIZE
(
apsh4a3a_devices
));
}
}
...
...
arch/sh/boards/board-apsh4ad0a.c
View file @
a3fd869a
...
@@ -12,12 +12,20 @@
...
@@ -12,12 +12,20 @@
#include <linux/init.h>
#include <linux/init.h>
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/io.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/irq.h>
#include <linux/irq.h>
#include <linux/clk.h>
#include <linux/clk.h>
#include <asm/machvec.h>
#include <asm/machvec.h>
#include <asm/sizes.h>
#include <asm/sizes.h>
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
static
struct
resource
smsc911x_resources
[]
=
{
static
struct
resource
smsc911x_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"smsc911x-memory"
,
.
name
=
"smsc911x-memory"
,
...
@@ -56,6 +64,8 @@ static struct platform_device *apsh4ad0a_devices[] __initdata = {
...
@@ -56,6 +64,8 @@ static struct platform_device *apsh4ad0a_devices[] __initdata = {
static
int
__init
apsh4ad0a_devices_setup
(
void
)
static
int
__init
apsh4ad0a_devices_setup
(
void
)
{
{
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
return
platform_add_devices
(
apsh4ad0a_devices
,
return
platform_add_devices
(
apsh4ad0a_devices
,
ARRAY_SIZE
(
apsh4ad0a_devices
));
ARRAY_SIZE
(
apsh4ad0a_devices
));
}
}
...
...
arch/sh/boards/board-magicpanelr2.c
View file @
a3fd869a
...
@@ -14,6 +14,8 @@
...
@@ -14,6 +14,8 @@
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/delay.h>
#include <linux/delay.h>
#include <linux/gpio.h>
#include <linux/gpio.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/partitions.h>
#include <linux/mtd/partitions.h>
...
@@ -24,6 +26,12 @@
...
@@ -24,6 +26,12 @@
#include <asm/heartbeat.h>
#include <asm/heartbeat.h>
#include <cpu/sh7720.h>
#include <cpu/sh7720.h>
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
#define LAN9115_READY (__raw_readl(0xA8000084UL) & 0x00000001UL)
#define LAN9115_READY (__raw_readl(0xA8000084UL) & 0x00000001UL)
/* Wait until reset finished. Timeout is 100ms. */
/* Wait until reset finished. Timeout is 100ms. */
...
@@ -348,6 +356,8 @@ static struct platform_device *mpr2_devices[] __initdata = {
...
@@ -348,6 +356,8 @@ static struct platform_device *mpr2_devices[] __initdata = {
static
int
__init
mpr2_devices_setup
(
void
)
static
int
__init
mpr2_devices_setup
(
void
)
{
{
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
return
platform_add_devices
(
mpr2_devices
,
ARRAY_SIZE
(
mpr2_devices
));
return
platform_add_devices
(
mpr2_devices
,
ARRAY_SIZE
(
mpr2_devices
));
}
}
device_initcall
(
mpr2_devices_setup
);
device_initcall
(
mpr2_devices_setup
);
...
...
arch/sh/boards/board-polaris.c
View file @
a3fd869a
...
@@ -9,6 +9,8 @@
...
@@ -9,6 +9,8 @@
#include <linux/interrupt.h>
#include <linux/interrupt.h>
#include <linux/irq.h>
#include <linux/irq.h>
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/io.h>
#include <linux/io.h>
#include <asm/irq.h>
#include <asm/irq.h>
...
@@ -22,6 +24,12 @@
...
@@ -22,6 +24,12 @@
#define AREA5_WAIT_CTRL (0x1C00)
#define AREA5_WAIT_CTRL (0x1C00)
#define WAIT_STATES_10 (0x7)
#define WAIT_STATES_10 (0x7)
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x.0"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x.0"
),
};
static
struct
resource
smsc911x_resources
[]
=
{
static
struct
resource
smsc911x_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"smsc911x-memory"
,
.
name
=
"smsc911x-memory"
,
...
@@ -88,6 +96,8 @@ static int __init polaris_initialise(void)
...
@@ -88,6 +96,8 @@ static int __init polaris_initialise(void)
printk
(
KERN_INFO
"Configuring Polaris external bus
\n
"
);
printk
(
KERN_INFO
"Configuring Polaris external bus
\n
"
);
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
/* Configure area 5 with 2 wait states */
/* Configure area 5 with 2 wait states */
wcr
=
__raw_readw
(
WCR2
);
wcr
=
__raw_readw
(
WCR2
);
wcr
&=
(
~
AREA5_WAIT_CTRL
);
wcr
&=
(
~
AREA5_WAIT_CTRL
);
...
...
arch/sh/boards/board-sh2007.c
View file @
a3fd869a
...
@@ -6,6 +6,8 @@
...
@@ -6,6 +6,8 @@
*/
*/
#include <linux/init.h>
#include <linux/init.h>
#include <linux/irq.h>
#include <linux/irq.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/ata_platform.h>
#include <linux/ata_platform.h>
...
@@ -13,6 +15,14 @@
...
@@ -13,6 +15,14 @@
#include <asm/machvec.h>
#include <asm/machvec.h>
#include <mach/sh2007.h>
#include <mach/sh2007.h>
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x.0"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x.0"
),
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x.1"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x.1"
),
};
struct
smsc911x_platform_config
smc911x_info
=
{
struct
smsc911x_platform_config
smc911x_info
=
{
.
flags
=
SMSC911X_USE_32BIT
,
.
flags
=
SMSC911X_USE_32BIT
,
.
irq_polarity
=
SMSC911X_IRQ_POLARITY_ACTIVE_LOW
,
.
irq_polarity
=
SMSC911X_IRQ_POLARITY_ACTIVE_LOW
,
...
@@ -98,6 +108,8 @@ static struct platform_device *sh2007_devices[] __initdata = {
...
@@ -98,6 +108,8 @@ static struct platform_device *sh2007_devices[] __initdata = {
static
int
__init
sh2007_io_init
(
void
)
static
int
__init
sh2007_io_init
(
void
)
{
{
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
platform_add_devices
(
sh2007_devices
,
ARRAY_SIZE
(
sh2007_devices
));
platform_add_devices
(
sh2007_devices
,
ARRAY_SIZE
(
sh2007_devices
));
return
0
;
return
0
;
}
}
...
...
arch/sh/boards/board-sh7757lcr.c
View file @
a3fd869a
...
@@ -12,6 +12,8 @@
...
@@ -12,6 +12,8 @@
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/gpio.h>
#include <linux/gpio.h>
#include <linux/irq.h>
#include <linux/irq.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/spi/spi.h>
#include <linux/spi/spi.h>
#include <linux/spi/flash.h>
#include <linux/spi/flash.h>
#include <linux/io.h>
#include <linux/io.h>
...
@@ -199,6 +201,15 @@ static struct platform_device sh7757_eth_giga1_device = {
...
@@ -199,6 +201,15 @@ static struct platform_device sh7757_eth_giga1_device = {
},
},
};
};
/* Fixed 3.3V regulator to be used by SDHI0, MMCIF */
static
struct
regulator_consumer_supply
fixed3v3_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mmcif.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mmcif.0"
),
};
/* SH_MMCIF */
/* SH_MMCIF */
static
struct
resource
sh_mmcif_resources
[]
=
{
static
struct
resource
sh_mmcif_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
...
@@ -329,6 +340,9 @@ static struct spi_board_info spi_board_info[] = {
...
@@ -329,6 +340,9 @@ static struct spi_board_info spi_board_info[] = {
static
int
__init
sh7757lcr_devices_setup
(
void
)
static
int
__init
sh7757lcr_devices_setup
(
void
)
{
{
regulator_register_always_on
(
0
,
"fixed-3.3V"
,
fixed3v3_power_consumers
,
ARRAY_SIZE
(
fixed3v3_power_consumers
),
3300000
);
/* RGMII (PTA) */
/* RGMII (PTA) */
gpio_request
(
GPIO_FN_ET0_MDC
,
NULL
);
gpio_request
(
GPIO_FN_ET0_MDC
,
NULL
);
gpio_request
(
GPIO_FN_ET0_MDIO
,
NULL
);
gpio_request
(
GPIO_FN_ET0_MDIO
,
NULL
);
...
...
arch/sh/boards/mach-ap325rxa/setup.c
View file @
a3fd869a
...
@@ -20,6 +20,8 @@
...
@@ -20,6 +20,8 @@
#include <linux/mtd/sh_flctl.h>
#include <linux/mtd/sh_flctl.h>
#include <linux/delay.h>
#include <linux/delay.h>
#include <linux/i2c.h>
#include <linux/i2c.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/gpio.h>
#include <linux/gpio.h>
#include <linux/videodev2.h>
#include <linux/videodev2.h>
...
@@ -34,6 +36,12 @@
...
@@ -34,6 +36,12 @@
#include <asm/suspend.h>
#include <asm/suspend.h>
#include <cpu/sh7723.h>
#include <cpu/sh7723.h>
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
static
struct
smsc911x_platform_config
smsc911x_config
=
{
static
struct
smsc911x_platform_config
smsc911x_config
=
{
.
phy_interface
=
PHY_INTERFACE_MODE_MII
,
.
phy_interface
=
PHY_INTERFACE_MODE_MII
,
.
irq_polarity
=
SMSC911X_IRQ_POLARITY_ACTIVE_LOW
,
.
irq_polarity
=
SMSC911X_IRQ_POLARITY_ACTIVE_LOW
,
...
@@ -423,6 +431,15 @@ static struct platform_device ceu_device = {
...
@@ -423,6 +431,15 @@ static struct platform_device ceu_device = {
},
},
};
};
/* Fixed 3.3V regulators to be used by SDHI0, SDHI1 */
static
struct
regulator_consumer_supply
fixed3v3_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.1"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.1"
),
};
static
struct
resource
sdhi0_cn3_resources
[]
=
{
static
struct
resource
sdhi0_cn3_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"SDHI0"
,
.
name
=
"SDHI0"
,
...
@@ -544,6 +561,10 @@ static int __init ap325rxa_devices_setup(void)
...
@@ -544,6 +561,10 @@ static int __init ap325rxa_devices_setup(void)
&
ap325rxa_sdram_leave_start
,
&
ap325rxa_sdram_leave_start
,
&
ap325rxa_sdram_leave_end
);
&
ap325rxa_sdram_leave_end
);
regulator_register_always_on
(
0
,
"fixed-3.3V"
,
fixed3v3_power_consumers
,
ARRAY_SIZE
(
fixed3v3_power_consumers
),
3300000
);
regulator_register_fixed
(
1
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
/* LD3 and LD4 LEDs */
/* LD3 and LD4 LEDs */
gpio_request
(
GPIO_PTX5
,
NULL
);
/* RUN */
gpio_request
(
GPIO_PTX5
,
NULL
);
/* RUN */
gpio_direction_output
(
GPIO_PTX5
,
1
);
gpio_direction_output
(
GPIO_PTX5
,
1
);
...
...
arch/sh/boards/mach-ecovec24/setup.c
View file @
a3fd869a
...
@@ -19,6 +19,8 @@
...
@@ -19,6 +19,8 @@
#include <linux/interrupt.h>
#include <linux/interrupt.h>
#include <linux/io.h>
#include <linux/io.h>
#include <linux/delay.h>
#include <linux/delay.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/usb/r8a66597.h>
#include <linux/usb/r8a66597.h>
#include <linux/usb/renesas_usbhs.h>
#include <linux/usb/renesas_usbhs.h>
#include <linux/i2c.h>
#include <linux/i2c.h>
...
@@ -518,10 +520,86 @@ static struct i2c_board_info ts_i2c_clients = {
...
@@ -518,10 +520,86 @@ static struct i2c_board_info ts_i2c_clients = {
.
irq
=
IRQ0
,
.
irq
=
IRQ0
,
};
};
static
struct
regulator_consumer_supply
cn12_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mmcif.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mmcif.0"
),
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.1"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.1"
),
};
static
struct
regulator_init_data
cn12_power_init_data
=
{
.
constraints
=
{
.
valid_ops_mask
=
REGULATOR_CHANGE_STATUS
,
},
.
num_consumer_supplies
=
ARRAY_SIZE
(
cn12_power_consumers
),
.
consumer_supplies
=
cn12_power_consumers
,
};
static
struct
fixed_voltage_config
cn12_power_info
=
{
.
supply_name
=
"CN12 SD/MMC Vdd"
,
.
microvolts
=
3300000
,
.
gpio
=
GPIO_PTB7
,
.
enable_high
=
1
,
.
init_data
=
&
cn12_power_init_data
,
};
static
struct
platform_device
cn12_power
=
{
.
name
=
"reg-fixed-voltage"
,
.
id
=
0
,
.
dev
=
{
.
platform_data
=
&
cn12_power_info
,
},
};
#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
/* SDHI0 */
/* SDHI0 */
static
struct
regulator_consumer_supply
sdhi0_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
};
static
struct
regulator_init_data
sdhi0_power_init_data
=
{
.
constraints
=
{
.
valid_ops_mask
=
REGULATOR_CHANGE_STATUS
,
},
.
num_consumer_supplies
=
ARRAY_SIZE
(
sdhi0_power_consumers
),
.
consumer_supplies
=
sdhi0_power_consumers
,
};
static
struct
fixed_voltage_config
sdhi0_power_info
=
{
.
supply_name
=
"CN11 SD/MMC Vdd"
,
.
microvolts
=
3300000
,
.
gpio
=
GPIO_PTB6
,
.
enable_high
=
1
,
.
init_data
=
&
sdhi0_power_init_data
,
};
static
struct
platform_device
sdhi0_power
=
{
.
name
=
"reg-fixed-voltage"
,
.
id
=
1
,
.
dev
=
{
.
platform_data
=
&
sdhi0_power_info
,
},
};
static
void
sdhi0_set_pwr
(
struct
platform_device
*
pdev
,
int
state
)
static
void
sdhi0_set_pwr
(
struct
platform_device
*
pdev
,
int
state
)
{
{
static
int
power_gpio
=
-
EINVAL
;
if
(
power_gpio
<
0
)
{
int
ret
=
gpio_request
(
GPIO_PTB6
,
NULL
);
if
(
!
ret
)
{
power_gpio
=
GPIO_PTB6
;
gpio_direction_output
(
power_gpio
,
0
);
}
}
/*
* Toggle the GPIO regardless, whether we managed to grab it above or
* the fixed regulator driver did.
*/
gpio_set_value
(
GPIO_PTB6
,
state
);
gpio_set_value
(
GPIO_PTB6
,
state
);
}
}
...
@@ -562,13 +640,27 @@ static struct platform_device sdhi0_device = {
...
@@ -562,13 +640,27 @@ static struct platform_device sdhi0_device = {
},
},
};
};
#if !defined(CONFIG_MMC_SH_MMCIF) && !defined(CONFIG_MMC_SH_MMCIF_MODULE)
static
void
cn12_set_pwr
(
struct
platform_device
*
pdev
,
int
state
)
/* SDHI1 */
static
void
sdhi1_set_pwr
(
struct
platform_device
*
pdev
,
int
state
)
{
{
static
int
power_gpio
=
-
EINVAL
;
if
(
power_gpio
<
0
)
{
int
ret
=
gpio_request
(
GPIO_PTB7
,
NULL
);
if
(
!
ret
)
{
power_gpio
=
GPIO_PTB7
;
gpio_direction_output
(
power_gpio
,
0
);
}
}
/*
* Toggle the GPIO regardless, whether we managed to grab it above or
* the fixed regulator driver did.
*/
gpio_set_value
(
GPIO_PTB7
,
state
);
gpio_set_value
(
GPIO_PTB7
,
state
);
}
}
#if !defined(CONFIG_MMC_SH_MMCIF) && !defined(CONFIG_MMC_SH_MMCIF_MODULE)
/* SDHI1 */
static
int
sdhi1_get_cd
(
struct
platform_device
*
pdev
)
static
int
sdhi1_get_cd
(
struct
platform_device
*
pdev
)
{
{
return
!
gpio_get_value
(
GPIO_PTW7
);
return
!
gpio_get_value
(
GPIO_PTW7
);
...
@@ -579,7 +671,7 @@ static struct sh_mobile_sdhi_info sdhi1_info = {
...
@@ -579,7 +671,7 @@ static struct sh_mobile_sdhi_info sdhi1_info = {
.
dma_slave_rx
=
SHDMA_SLAVE_SDHI1_RX
,
.
dma_slave_rx
=
SHDMA_SLAVE_SDHI1_RX
,
.
tmio_caps
=
MMC_CAP_SDIO_IRQ
|
MMC_CAP_POWER_OFF_CARD
|
.
tmio_caps
=
MMC_CAP_SDIO_IRQ
|
MMC_CAP_POWER_OFF_CARD
|
MMC_CAP_NEEDS_POLL
,
MMC_CAP_NEEDS_POLL
,
.
set_pwr
=
sdhi1
_set_pwr
,
.
set_pwr
=
cn12
_set_pwr
,
.
get_cd
=
sdhi1_get_cd
,
.
get_cd
=
sdhi1_get_cd
,
};
};
...
@@ -899,14 +991,9 @@ static struct platform_device vou_device = {
...
@@ -899,14 +991,9 @@ static struct platform_device vou_device = {
#if defined(CONFIG_MMC_SH_MMCIF) || defined(CONFIG_MMC_SH_MMCIF_MODULE)
#if defined(CONFIG_MMC_SH_MMCIF) || defined(CONFIG_MMC_SH_MMCIF_MODULE)
/* SH_MMCIF */
/* SH_MMCIF */
static
void
mmcif_set_pwr
(
struct
platform_device
*
pdev
,
int
state
)
{
gpio_set_value
(
GPIO_PTB7
,
state
);
}
static
void
mmcif_down_pwr
(
struct
platform_device
*
pdev
)
static
void
mmcif_down_pwr
(
struct
platform_device
*
pdev
)
{
{
gpio_set_value
(
GPIO_PTB7
,
0
);
cn12_set_pwr
(
pdev
,
0
);
}
}
static
struct
resource
sh_mmcif_resources
[]
=
{
static
struct
resource
sh_mmcif_resources
[]
=
{
...
@@ -929,7 +1016,7 @@ static struct resource sh_mmcif_resources[] = {
...
@@ -929,7 +1016,7 @@ static struct resource sh_mmcif_resources[] = {
};
};
static
struct
sh_mmcif_plat_data
sh_mmcif_plat
=
{
static
struct
sh_mmcif_plat_data
sh_mmcif_plat
=
{
.
set_pwr
=
mmcif
_set_pwr
,
.
set_pwr
=
cn12
_set_pwr
,
.
down_pwr
=
mmcif_down_pwr
,
.
down_pwr
=
mmcif_down_pwr
,
.
sup_pclk
=
0
,
/* SH7724: Max Pclk/2 */
.
sup_pclk
=
0
,
/* SH7724: Max Pclk/2 */
.
caps
=
MMC_CAP_4_BIT_DATA
|
.
caps
=
MMC_CAP_4_BIT_DATA
|
...
@@ -960,7 +1047,9 @@ static struct platform_device *ecovec_devices[] __initdata = {
...
@@ -960,7 +1047,9 @@ static struct platform_device *ecovec_devices[] __initdata = {
&
ceu0_device
,
&
ceu0_device
,
&
ceu1_device
,
&
ceu1_device
,
&
keysc_device
,
&
keysc_device
,
&
cn12_power
,
#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
#if defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
&
sdhi0_power
,
&
sdhi0_device
,
&
sdhi0_device
,
#if !defined(CONFIG_MMC_SH_MMCIF) && !defined(CONFIG_MMC_SH_MMCIF_MODULE)
#if !defined(CONFIG_MMC_SH_MMCIF) && !defined(CONFIG_MMC_SH_MMCIF_MODULE)
&
sdhi1_device
,
&
sdhi1_device
,
...
@@ -1258,8 +1347,6 @@ static int __init arch_setup(void)
...
@@ -1258,8 +1347,6 @@ static int __init arch_setup(void)
gpio_request
(
GPIO_FN_SDHI0D2
,
NULL
);
gpio_request
(
GPIO_FN_SDHI0D2
,
NULL
);
gpio_request
(
GPIO_FN_SDHI0D1
,
NULL
);
gpio_request
(
GPIO_FN_SDHI0D1
,
NULL
);
gpio_request
(
GPIO_FN_SDHI0D0
,
NULL
);
gpio_request
(
GPIO_FN_SDHI0D0
,
NULL
);
gpio_request
(
GPIO_PTB6
,
NULL
);
gpio_direction_output
(
GPIO_PTB6
,
0
);
#else
#else
/* enable MSIOF0 on CN11 (needs DS2.4 set to OFF) */
/* enable MSIOF0 on CN11 (needs DS2.4 set to OFF) */
gpio_request
(
GPIO_FN_MSIOF0_TXD
,
NULL
);
gpio_request
(
GPIO_FN_MSIOF0_TXD
,
NULL
);
...
@@ -1288,8 +1375,6 @@ static int __init arch_setup(void)
...
@@ -1288,8 +1375,6 @@ static int __init arch_setup(void)
gpio_request
(
GPIO_FN_MMC_D0
,
NULL
);
gpio_request
(
GPIO_FN_MMC_D0
,
NULL
);
gpio_request
(
GPIO_FN_MMC_CLK
,
NULL
);
gpio_request
(
GPIO_FN_MMC_CLK
,
NULL
);
gpio_request
(
GPIO_FN_MMC_CMD
,
NULL
);
gpio_request
(
GPIO_FN_MMC_CMD
,
NULL
);
gpio_request
(
GPIO_PTB7
,
NULL
);
gpio_direction_output
(
GPIO_PTB7
,
0
);
cn12_enabled
=
true
;
cn12_enabled
=
true
;
#elif defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
#elif defined(CONFIG_MMC_SDHI) || defined(CONFIG_MMC_SDHI_MODULE)
...
@@ -1301,8 +1386,6 @@ static int __init arch_setup(void)
...
@@ -1301,8 +1386,6 @@ static int __init arch_setup(void)
gpio_request
(
GPIO_FN_SDHI1D2
,
NULL
);
gpio_request
(
GPIO_FN_SDHI1D2
,
NULL
);
gpio_request
(
GPIO_FN_SDHI1D1
,
NULL
);
gpio_request
(
GPIO_FN_SDHI1D1
,
NULL
);
gpio_request
(
GPIO_FN_SDHI1D0
,
NULL
);
gpio_request
(
GPIO_FN_SDHI1D0
,
NULL
);
gpio_request
(
GPIO_PTB7
,
NULL
);
gpio_direction_output
(
GPIO_PTB7
,
0
);
/* Card-detect, used on CN12 with SDHI1 */
/* Card-detect, used on CN12 with SDHI1 */
gpio_request
(
GPIO_PTW7
,
NULL
);
gpio_request
(
GPIO_PTW7
,
NULL
);
...
...
arch/sh/boards/mach-kfr2r09/setup.c
View file @
a3fd869a
...
@@ -21,6 +21,8 @@
...
@@ -21,6 +21,8 @@
#include <linux/input.h>
#include <linux/input.h>
#include <linux/input/sh_keysc.h>
#include <linux/input/sh_keysc.h>
#include <linux/i2c.h>
#include <linux/i2c.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/usb/r8a66597.h>
#include <linux/usb/r8a66597.h>
#include <linux/videodev2.h>
#include <linux/videodev2.h>
#include <linux/sh_intc.h>
#include <linux/sh_intc.h>
...
@@ -341,6 +343,13 @@ static struct platform_device kfr2r09_camera = {
...
@@ -341,6 +343,13 @@ static struct platform_device kfr2r09_camera = {
},
},
};
};
/* Fixed 3.3V regulator to be used by SDHI0 */
static
struct
regulator_consumer_supply
fixed3v3_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
};
static
struct
resource
kfr2r09_sh_sdhi0_resources
[]
=
{
static
struct
resource
kfr2r09_sh_sdhi0_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"SDHI0"
,
.
name
=
"SDHI0"
,
...
@@ -523,6 +532,9 @@ static int __init kfr2r09_devices_setup(void)
...
@@ -523,6 +532,9 @@ static int __init kfr2r09_devices_setup(void)
&
kfr2r09_sdram_leave_start
,
&
kfr2r09_sdram_leave_start
,
&
kfr2r09_sdram_leave_end
);
&
kfr2r09_sdram_leave_end
);
regulator_register_always_on
(
0
,
"fixed-3.3V"
,
fixed3v3_power_consumers
,
ARRAY_SIZE
(
fixed3v3_power_consumers
),
3300000
);
/* enable SCIF1 serial port for YC401 console support */
/* enable SCIF1 serial port for YC401 console support */
gpio_request
(
GPIO_FN_SCIF1_RXD
,
NULL
);
gpio_request
(
GPIO_FN_SCIF1_RXD
,
NULL
);
gpio_request
(
GPIO_FN_SCIF1_TXD
,
NULL
);
gpio_request
(
GPIO_FN_SCIF1_TXD
,
NULL
);
...
...
arch/sh/boards/mach-migor/setup.c
View file @
a3fd869a
...
@@ -17,6 +17,8 @@
...
@@ -17,6 +17,8 @@
#include <linux/mtd/physmap.h>
#include <linux/mtd/physmap.h>
#include <linux/mtd/nand.h>
#include <linux/mtd/nand.h>
#include <linux/i2c.h>
#include <linux/i2c.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smc91x.h>
#include <linux/smc91x.h>
#include <linux/delay.h>
#include <linux/delay.h>
#include <linux/clk.h>
#include <linux/clk.h>
...
@@ -386,6 +388,13 @@ static struct platform_device migor_ceu_device = {
...
@@ -386,6 +388,13 @@ static struct platform_device migor_ceu_device = {
},
},
};
};
/* Fixed 3.3V regulator to be used by SDHI0 */
static
struct
regulator_consumer_supply
fixed3v3_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
};
static
struct
resource
sdhi_cn9_resources
[]
=
{
static
struct
resource
sdhi_cn9_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"SDHI"
,
.
name
=
"SDHI"
,
...
@@ -498,6 +507,10 @@ static int __init migor_devices_setup(void)
...
@@ -498,6 +507,10 @@ static int __init migor_devices_setup(void)
&
migor_sdram_enter_end
,
&
migor_sdram_enter_end
,
&
migor_sdram_leave_start
,
&
migor_sdram_leave_start
,
&
migor_sdram_leave_end
);
&
migor_sdram_leave_end
);
regulator_register_always_on
(
0
,
"fixed-3.3V"
,
fixed3v3_power_consumers
,
ARRAY_SIZE
(
fixed3v3_power_consumers
),
3300000
);
/* Let D11 LED show STATUS0 */
/* Let D11 LED show STATUS0 */
gpio_request
(
GPIO_FN_STATUS0
,
NULL
);
gpio_request
(
GPIO_FN_STATUS0
,
NULL
);
...
...
arch/sh/boards/mach-rsk/setup.c
View file @
a3fd869a
...
@@ -16,9 +16,17 @@
...
@@ -16,9 +16,17 @@
#include <linux/mtd/partitions.h>
#include <linux/mtd/partitions.h>
#include <linux/mtd/physmap.h>
#include <linux/mtd/physmap.h>
#include <linux/mtd/map.h>
#include <linux/mtd/map.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <asm/machvec.h>
#include <asm/machvec.h>
#include <asm/io.h>
#include <asm/io.h>
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
static
const
char
*
part_probes
[]
=
{
"cmdlinepart"
,
NULL
};
static
const
char
*
part_probes
[]
=
{
"cmdlinepart"
,
NULL
};
static
struct
mtd_partition
rsk_partitions
[]
=
{
static
struct
mtd_partition
rsk_partitions
[]
=
{
...
@@ -67,6 +75,8 @@ static struct platform_device *rsk_devices[] __initdata = {
...
@@ -67,6 +75,8 @@ static struct platform_device *rsk_devices[] __initdata = {
static
int
__init
rsk_devices_setup
(
void
)
static
int
__init
rsk_devices_setup
(
void
)
{
{
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
return
platform_add_devices
(
rsk_devices
,
return
platform_add_devices
(
rsk_devices
,
ARRAY_SIZE
(
rsk_devices
));
ARRAY_SIZE
(
rsk_devices
));
}
}
...
...
arch/sh/boards/mach-sdk7786/setup.c
View file @
a3fd869a
...
@@ -11,6 +11,8 @@
...
@@ -11,6 +11,8 @@
#include <linux/init.h>
#include <linux/init.h>
#include <linux/platform_device.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/io.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smsc911x.h>
#include <linux/smsc911x.h>
#include <linux/i2c.h>
#include <linux/i2c.h>
#include <linux/irq.h>
#include <linux/irq.h>
...
@@ -38,6 +40,12 @@ static struct platform_device heartbeat_device = {
...
@@ -38,6 +40,12 @@ static struct platform_device heartbeat_device = {
.
resource
=
&
heartbeat_resource
,
.
resource
=
&
heartbeat_resource
,
};
};
/* Dummy supplies, where voltage doesn't matter */
static
struct
regulator_consumer_supply
dummy_supplies
[]
=
{
REGULATOR_SUPPLY
(
"vddvario"
,
"smsc911x"
),
REGULATOR_SUPPLY
(
"vdd33a"
,
"smsc911x"
),
};
static
struct
resource
smsc911x_resources
[]
=
{
static
struct
resource
smsc911x_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"smsc911x-memory"
,
.
name
=
"smsc911x-memory"
,
...
@@ -236,6 +244,8 @@ static void __init sdk7786_setup(char **cmdline_p)
...
@@ -236,6 +244,8 @@ static void __init sdk7786_setup(char **cmdline_p)
{
{
pr_info
(
"Renesas Technology Europe SDK7786 support:
\n
"
);
pr_info
(
"Renesas Technology Europe SDK7786 support:
\n
"
);
regulator_register_fixed
(
0
,
dummy_supplies
,
ARRAY_SIZE
(
dummy_supplies
));
sdk7786_fpga_init
();
sdk7786_fpga_init
();
sdk7786_nmi_init
();
sdk7786_nmi_init
();
...
...
arch/sh/boards/mach-se/7724/setup.c
View file @
a3fd869a
...
@@ -18,6 +18,8 @@
...
@@ -18,6 +18,8 @@
#include <linux/mmc/sh_mobile_sdhi.h>
#include <linux/mmc/sh_mobile_sdhi.h>
#include <linux/mtd/physmap.h>
#include <linux/mtd/physmap.h>
#include <linux/delay.h>
#include <linux/delay.h>
#include <linux/regulator/fixed.h>
#include <linux/regulator/machine.h>
#include <linux/smc91x.h>
#include <linux/smc91x.h>
#include <linux/gpio.h>
#include <linux/gpio.h>
#include <linux/input.h>
#include <linux/input.h>
...
@@ -454,6 +456,15 @@ static struct platform_device sh7724_usb1_gadget_device = {
...
@@ -454,6 +456,15 @@ static struct platform_device sh7724_usb1_gadget_device = {
.
resource
=
sh7724_usb1_gadget_resources
,
.
resource
=
sh7724_usb1_gadget_resources
,
};
};
/* Fixed 3.3V regulator to be used by SDHI0, SDHI1 */
static
struct
regulator_consumer_supply
fixed3v3_power_consumers
[]
=
{
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.0"
),
REGULATOR_SUPPLY
(
"vmmc"
,
"sh_mobile_sdhi.1"
),
REGULATOR_SUPPLY
(
"vqmmc"
,
"sh_mobile_sdhi.1"
),
};
static
struct
resource
sdhi0_cn7_resources
[]
=
{
static
struct
resource
sdhi0_cn7_resources
[]
=
{
[
0
]
=
{
[
0
]
=
{
.
name
=
"SDHI0"
,
.
name
=
"SDHI0"
,
...
@@ -684,6 +695,10 @@ static int __init devices_setup(void)
...
@@ -684,6 +695,10 @@ static int __init devices_setup(void)
&
ms7724se_sdram_enter_end
,
&
ms7724se_sdram_enter_end
,
&
ms7724se_sdram_leave_start
,
&
ms7724se_sdram_leave_start
,
&
ms7724se_sdram_leave_end
);
&
ms7724se_sdram_leave_end
);
regulator_register_always_on
(
0
,
"fixed-3.3V"
,
fixed3v3_power_consumers
,
ARRAY_SIZE
(
fixed3v3_power_consumers
),
3300000
);
/* Reset Release */
/* Reset Release */
fpga_out
=
__raw_readw
(
FPGA_OUT
);
fpga_out
=
__raw_readw
(
FPGA_OUT
);
/* bit4: NTSC_PDN, bit5: NTSC_RESET */
/* bit4: NTSC_PDN, bit5: NTSC_RESET */
...
...
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