sh-pfc: Add r8a73a4 pinmux support

Add initial PFC support for the r8a73a4 SoC.

At this point only GPIO interface is supported, move to newer interfaces
planned as incremental changes.

Original authors are Morimoto-san with help from Yoshii-san, thanks to
them for the heavy lifting. Adjusted by Magnus to work together with
updated code in drivers/pinctrl.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Takashi Yoshii <takashi.yoshii.zj@renesas.com>
Signed-off-by: Magnus Damm <damm@opensource.se>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
This commit is contained in:
Magnus Damm 2013-03-26 22:49:49 +09:00 committed by Simon Horman
parent ba774cc738
commit c98f6c21af
6 changed files with 3754 additions and 0 deletions

View file

@ -1,6 +1,924 @@
#ifndef __ASM_R8A73A4_H__
#define __ASM_R8A73A4_H__
/*
* Pin Function Controller:
* GPIO_FN_xx - GPIO used to select pin function
* GPIO_PORTxx - GPIO mapped to real I/O pin on CPU
*/
enum {
/* PORT */
GPIO_PORT0, GPIO_PORT1, GPIO_PORT2, GPIO_PORT3, GPIO_PORT4,
GPIO_PORT5, GPIO_PORT6, GPIO_PORT7, GPIO_PORT8, GPIO_PORT9,
GPIO_PORT10, GPIO_PORT11, GPIO_PORT12, GPIO_PORT13, GPIO_PORT14,
GPIO_PORT15, GPIO_PORT16, GPIO_PORT17, GPIO_PORT18, GPIO_PORT19,
GPIO_PORT20, GPIO_PORT21, GPIO_PORT22, GPIO_PORT23, GPIO_PORT24,
GPIO_PORT25, GPIO_PORT26, GPIO_PORT27, GPIO_PORT28, GPIO_PORT29,
GPIO_PORT30, GPIO_PORT32, GPIO_PORT33, GPIO_PORT34,
GPIO_PORT35, GPIO_PORT36, GPIO_PORT37, GPIO_PORT38, GPIO_PORT39,
GPIO_PORT40, GPIO_PORT64,
GPIO_PORT65, GPIO_PORT66, GPIO_PORT67, GPIO_PORT68, GPIO_PORT69,
GPIO_PORT70, GPIO_PORT71, GPIO_PORT72, GPIO_PORT73, GPIO_PORT74,
GPIO_PORT75, GPIO_PORT76, GPIO_PORT77, GPIO_PORT78, GPIO_PORT79,
GPIO_PORT80, GPIO_PORT81, GPIO_PORT82, GPIO_PORT83, GPIO_PORT84,
GPIO_PORT85, GPIO_PORT96, GPIO_PORT97, GPIO_PORT98, GPIO_PORT99,
GPIO_PORT100, GPIO_PORT101, GPIO_PORT102, GPIO_PORT103, GPIO_PORT104,
GPIO_PORT105, GPIO_PORT106, GPIO_PORT107, GPIO_PORT108, GPIO_PORT109,
GPIO_PORT110, GPIO_PORT111, GPIO_PORT112, GPIO_PORT113, GPIO_PORT114,
GPIO_PORT115, GPIO_PORT116, GPIO_PORT117, GPIO_PORT118, GPIO_PORT119,
GPIO_PORT120, GPIO_PORT121, GPIO_PORT122, GPIO_PORT123, GPIO_PORT124,
GPIO_PORT125, GPIO_PORT126, GPIO_PORT128, GPIO_PORT129,
GPIO_PORT130, GPIO_PORT131, GPIO_PORT132, GPIO_PORT133, GPIO_PORT134,
GPIO_PORT160, GPIO_PORT161, GPIO_PORT162, GPIO_PORT163, GPIO_PORT164,
GPIO_PORT165, GPIO_PORT166, GPIO_PORT167, GPIO_PORT168, GPIO_PORT169,
GPIO_PORT170, GPIO_PORT171, GPIO_PORT172, GPIO_PORT173, GPIO_PORT174,
GPIO_PORT175, GPIO_PORT176, GPIO_PORT177, GPIO_PORT178,
GPIO_PORT192, GPIO_PORT193, GPIO_PORT194,
GPIO_PORT195, GPIO_PORT196, GPIO_PORT197, GPIO_PORT198, GPIO_PORT199,
GPIO_PORT200, GPIO_PORT201, GPIO_PORT202, GPIO_PORT203, GPIO_PORT204,
GPIO_PORT205, GPIO_PORT206, GPIO_PORT207, GPIO_PORT208, GPIO_PORT209,
GPIO_PORT210, GPIO_PORT211, GPIO_PORT212, GPIO_PORT213, GPIO_PORT214,
GPIO_PORT215, GPIO_PORT216, GPIO_PORT217, GPIO_PORT218, GPIO_PORT219,
GPIO_PORT220, GPIO_PORT221, GPIO_PORT222, GPIO_PORT224,
GPIO_PORT225, GPIO_PORT226, GPIO_PORT227, GPIO_PORT228, GPIO_PORT229,
GPIO_PORT230, GPIO_PORT231, GPIO_PORT232, GPIO_PORT233, GPIO_PORT234,
GPIO_PORT235, GPIO_PORT236, GPIO_PORT237, GPIO_PORT238, GPIO_PORT239,
GPIO_PORT240, GPIO_PORT241, GPIO_PORT242, GPIO_PORT243, GPIO_PORT244,
GPIO_PORT245, GPIO_PORT246, GPIO_PORT247, GPIO_PORT248, GPIO_PORT249,
GPIO_PORT250, GPIO_PORT256, GPIO_PORT257, GPIO_PORT258, GPIO_PORT259,
GPIO_PORT260, GPIO_PORT261, GPIO_PORT262, GPIO_PORT263, GPIO_PORT264,
GPIO_PORT265, GPIO_PORT266, GPIO_PORT267, GPIO_PORT268, GPIO_PORT269,
GPIO_PORT270, GPIO_PORT271, GPIO_PORT272, GPIO_PORT273, GPIO_PORT274,
GPIO_PORT275, GPIO_PORT276, GPIO_PORT277, GPIO_PORT278, GPIO_PORT279,
GPIO_PORT280, GPIO_PORT281, GPIO_PORT282, GPIO_PORT283,
GPIO_PORT288, GPIO_PORT289,
GPIO_PORT290, GPIO_PORT291, GPIO_PORT292, GPIO_PORT293, GPIO_PORT294,
GPIO_PORT295, GPIO_PORT296, GPIO_PORT297, GPIO_PORT298, GPIO_PORT299,
GPIO_PORT300, GPIO_PORT301, GPIO_PORT302, GPIO_PORT303, GPIO_PORT304,
GPIO_PORT305, GPIO_PORT306, GPIO_PORT307, GPIO_PORT308,
GPIO_PORT320, GPIO_PORT321, GPIO_PORT322, GPIO_PORT323, GPIO_PORT324,
GPIO_PORT325, GPIO_PORT326, GPIO_PORT327, GPIO_PORT328, GPIO_PORT329,
/* Port0 */
GPIO_FN_LCDD0,
GPIO_FN_PDM2_CLK_0,
GPIO_FN_DU0_DR0,
GPIO_FN_IRQ0,
/* Port1 */
GPIO_FN_LCDD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_FN_KEYOUT4,
/* Port109 */
GPIO_FN_KEYOUT5,
GPIO_FN_IRQ43,
/* Port110 */
GPIO_FN_KEYOUT6,
GPIO_FN_IRQ44,
/* Port111 */
GPIO_FN_KEYOUT7,
GPIO_FN_RFANAEN,
GPIO_FN_IRQ45,
/* Port112 */
GPIO_FN_KEYIN8,
GPIO_FN_KEYOUT8,
GPIO_FN_SF_IRQ_04,
GPIO_FN_IRQ46,
/* Port113 */
GPIO_FN_KEYIN9,
GPIO_FN_KEYOUT9,
GPIO_FN_SF_IRQ_05,
GPIO_FN_IRQ47,
/* Port114 */
GPIO_FN_KEYIN10,
GPIO_FN_KEYOUT10,
GPIO_FN_SF_IRQ_06,
GPIO_FN_IRQ48,
/* Port115 */
GPIO_FN_KEYIN11,
GPIO_FN_KEYOUT11,
GPIO_FN_SF_IRQ_07,
GPIO_FN_IRQ49,
/* Port116 */
GPIO_FN_SCIFA0_TXD,
GPIO_FN_CSCIF0_TX,
/* Port117 */
GPIO_FN_SCIFA0_RXD,
GPIO_FN_CSCIF0_RX,
/* Port118 */
GPIO_FN_SCIFA1_TXD,
GPIO_FN_CSCIF1_TX,
/* Port119 */
GPIO_FN_SCIFA1_RXD,
GPIO_FN_CSCIF1_RX,
/* Port120 */
GPIO_FN_SF_PORT_1_120,
GPIO_FN_SCIFB3_RXD_120,
GPIO_FN_DU0_CDE,
/* Port121 */
GPIO_FN_SF_PORT_0_121,
GPIO_FN_SCIFB3_TXD_121,
/* Port122 */
GPIO_FN_SCIFB0_TXD,
GPIO_FN_CHSCIF0_HTX,
/* Port123 */
GPIO_FN_SCIFB0_RXD,
GPIO_FN_CHSCIF0_HRX,
/* Port124 */
GPIO_FN_ISP_STROBE_124,
/* Port125 */
GPIO_FN_STP_ISD_0,
GPIO_FN_PDM4_CLK_125,
GPIO_FN_MSIOF2_TXD,
GPIO_FN_SIM0_VOLTSEL0,
/* Port126 */
GPIO_FN_TS_SDEN,
GPIO_FN_MSIOF7_SYNC,
GPIO_FN_ST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IO_D1,
GPIO_FN_VIO_D0,
/* Port213 - Port222 FN5 */
GPIO_FN_GIO_OUT9,
GPIO_FN_GIO_OUT8,
GPIO_FN_GIO_OUT7,
GPIO_FN_GIO_OUT6,
GPIO_FN_GIO_OUT5_217,
GPIO_FN_GIO_OUT4_218,
GPIO_FN_GIO_OUT3_219,
GPIO_FN_GIO_OUT2_220,
GPIO_FN_GIO_OUT1_221,
GPIO_FN_GIO_OUT0_222,
/* Port224 */
GPIO_FN_RDWR_224,
GPIO_FN_VIO_HD,
GPIO_FN_SIM1_GPO2,
/* Port225 */
GPIO_FN_RD_N,
/* Port226 */
GPIO_FN_WAIT_N,
GPIO_FN_VIO_CLK,
GPIO_FN_SIM1_GPO1,
/* Port227 */
GPIO_FN_WE0_N,
GPIO_FN_RDWR_227,
/* Port228 */
GPIO_FN_WE1_N,
GPIO_FN_SIM0_GPO0,
/* Port229 */
GPIO_FN_PWMO,
GPIO_FN_VIO_CKO1_229,
/* Port230 */
GPIO_FN_SLIM_CLK,
GPIO_FN_VIO_CKO4_230,
/* Port231 */
GPIO_FN_SLIM_DATA,
GPIO_FN_VIO_CKO5_231,
/* Port232 */
GPIO_FN_VIO_CKO2_232,
GPIO_FN_SF_PORT_0_232,
/* Port233 */
GPIO_FN_VIO_CKO3_233,
GPIO_FN_SF_PORT_1_233,
/* Port234 */
GPIO_FN_FSIACK,
GPIO_FN_PDM3_CLK_234,
GPIO_FN_ISP_IRIS1_234,
/* Port235 */
GPIO_FN_FSIAISLD,
GPIO_FN_PDM3_DATA_235,
/* Port236 */
GPIO_FN_FSIAOMC,
GPIO_FN_PDM0_OUTCLK_236,
GPIO_FN_ISP_IRIS0_236,
/* Port237 */
GPIO_FN_FSIAOLR,
GPIO_FN_FSIAILR,
/* Port238 */
GPIO_FN_FSIAOBT,
GPIO_FN_FSIAIBT,
/* Port239 */
GPIO_FN_FSIAOSLD,
GPIO_FN_PDM0_OUTDATA_239,
/* Port240 */
GPIO_FN_FSIBISLD,
/* Port241 */
GPIO_FN_FSIBOLR,
GPIO_FN_FSIBILR,
/* Port242 */
GPIO_FN_FSIBOMC,
GPIO_FN_ISP_SHUTTER1_242,
/* Port243 */
GPIO_FN_FSIBOBT,
GPIO_FN_FSIBIBT,
/* Port244 */
GPIO_FN_FSIBOSLD,
GPIO_FN_FSIASPDIF,
/* Port245 */
GPIO_FN_FSIBCK,
GPIO_FN_ISP_SHUTTER0_245,
/* Port246 - Port250 FN1 */
GPIO_FN_ISP_IRIS1_246,
GPIO_FN_ISP_IRIS0_247,
GPIO_FN_ISP_SHUTTER1_248,
GPIO_FN_ISP_SHUTTER0_249,
GPIO_FN_ISP_STROBE_250,
/* Port256 - Port258 */
GPIO_FN_MSIOF0_SYNC,
GPIO_FN_MSIOF0_RXD,
GPIO_FN_MSIOF0_SCK,
/* Port259 */
GPIO_FN_MSIOF0_SS2,
GPIO_FN_VIO_CKO3_259,
/* Port260 */
GPIO_FN_MSIOF0_TXD,
/* Port261 */
GPIO_FN_SCIFB1_SCK_261,
GPIO_FN_CHSCIF1_HSCK,
/* Port262 */
GPIO_FN_SCIFB2_SCK_262,
/* Port263 - Port266 FN1 */
GPIO_FN_MSIOF1_SS2,
GPIO_FN_MSIOF1_TXD,
GPIO_FN_MSIOF1_RXD,
GPIO_FN_MSIOF1_SS1,
/* Port263 - Port266 FN4 */
GPIO_FN_MSIOF5_SS2,
GPIO_FN_MSIOF5_TXD,
GPIO_FN_MSIOF5_RXD,
GPIO_FN_MSIOF5_SS1,
/* Port267 */
GPIO_FN_MSIOF0_SS1,
/* Port268 */
GPIO_FN_MSIOF1_SCK,
GPIO_FN_MSIOF5_SCK,
/* Port269 */
GPIO_FN_MSIOF1_SYNC,
GPIO_FN_MSIOF5_SYNC,
/* Port270 - Port273 FN1 */
GPIO_FN_MSIOF2_SS1,
GPIO_FN_MSIOF2_SS2,
GPIO_FN_MSIOF3_SS2,
GPIO_FN_MSIOF3_SS1,
/* Port270 - Port273 FN3 */
GPIO_FN_VIO_CKO5_270,
GPIO_FN_VIO_CKO2_271,
GPIO_FN_VIO_CKO1_272,
GPIO_FN_VIO_CKO4_273,
/* Port274 */
GPIO_FN_MSIOF4_SS2,
GPIO_FN_TPU1TO0,
/* Port275 - Port280 */
GPIO_FN_IC_DP,
GPIO_FN_SIM0_RST,
GPIO_FN_IC_DM,
GPIO_FN_SIM0_BSICOMP,
GPIO_FN_SIM0_CLK,
GPIO_FN_SIM0_IO,
/* Port281 */
GPIO_FN_SIM1_IO,
GPIO_FN_PDM2_DATA_281,
/* Port282 */
GPIO_FN_SIM1_CLK,
GPIO_FN_PDM2_CLK_282,
/* Port283 */
GPIO_FN_SIM1_RST,
/* Port289 */
GPIO_FN_SDHID1_0,
GPIO_FN_STMDATA0_2,
/* Port290 */
GPIO_FN_SDHID1_1,
GPIO_FN_STMDATA1_2,
GPIO_FN_IRQ51,
/* Port291 - Port294 FN1 */
GPIO_FN_SDHID1_2,
GPIO_FN_SDHID1_3,
GPIO_FN_SDHICLK1,
GPIO_FN_SDHICMD1,
/* Port291 - Port294 FN3 */
GPIO_FN_STMDATA2_2,
GPIO_FN_STMDATA3_2,
GPIO_FN_STMCLK_2,
GPIO_FN_STMSIDI_2,
/* Port295 */
GPIO_FN_SDHID2_0,
GPIO_FN_MSIOF4_TXD,
GPIO_FN_SCIFB2_TXD_295,
GPIO_FN_MSIOF6_TXD,
/* Port296 */
GPIO_FN_SDHID2_1,
GPIO_FN_MSIOF6_SS2,
GPIO_FN_IRQ52,
/* Port297 - Port300 FN1 */
GPIO_FN_SDHID2_2,
GPIO_FN_SDHID2_3,
GPIO_FN_SDHICLK2,
GPIO_FN_SDHICMD2,
/* Port297 - Port300 FN2 */
GPIO_FN_MSIOF4_RXD,
GPIO_FN_MSIOF4_SYNC,
GPIO_FN_MSIOF4_SCK,
GPIO_FN_MSIOF4_SS1,
/* Port297 - Port300 FN3 */
GPIO_FN_SCIFB2_RXD_297,
GPIO_FN_SCIFB2_CTS_298,
GPIO_FN_SCIFB2_SCK_299,
GPIO_FN_SCIFB2_RTS_300,
/* Port297 - Port300 FN4 */
GPIO_FN_MSIOF6_RXD,
GPIO_FN_MSIOF6_SYNC,
GPIO_FN_MSIOF6_SCK,
GPIO_FN_MSIOF6_SS1,
/* Port301 */
GPIO_FN_SDHICD0,
GPIO_FN_IRQ50,
/* Port302 - Port306 FN1 */
GPIO_FN_SDHID0_0,
GPIO_FN_SDHID0_1,
GPIO_FN_SDHID0_2,
GPIO_FN_SDHID0_3,
GPIO_FN_SDHICMD0,
/* Port302 - Port306 FN3 */
GPIO_FN_STMDATA0_1,
GPIO_FN_STMDATA1_1,
GPIO_FN_STMDATA2_1,
GPIO_FN_STMDATA3_1,
GPIO_FN_STMSIDI_1,
/* Port307 */
GPIO_FN_SDHIWP0,
/* Port308 */
GPIO_FN_SDHICLK0,
GPIO_FN_STMCLK_1,
/* Port320 - Port329 */
GPIO_FN_IRQ16,
GPIO_FN_IRQ17,
GPIO_FN_IRQ28,
GPIO_FN_IRQ29,
GPIO_FN_IRQ30,
GPIO_FN_IRQ53,
GPIO_FN_IRQ54,
GPIO_FN_IRQ55,
GPIO_FN_IRQ56,
GPIO_FN_IRQ57,
};
void r8a73a4_add_standard_devices(void);
void r8a73a4_clock_init(void);
void r8a73a4_pinmux_init(void);

View file

@ -22,6 +22,11 @@ config GPIO_SH_PFC
This enables support for GPIOs within the SoC's pin function
controller.
config PINCTRL_PFC_R8A73A4
def_bool y
depends on ARCH_R8A73A4
select PINCTRL_SH_PFC
config PINCTRL_PFC_R8A7740
def_bool y
depends on ARCH_R8A7740

View file

@ -3,6 +3,7 @@ ifeq ($(CONFIG_GPIO_SH_PFC),y)
sh-pfc-objs += gpio.o
endif
obj-$(CONFIG_PINCTRL_SH_PFC) += sh-pfc.o
obj-$(CONFIG_PINCTRL_PFC_R8A73A4) += pfc-r8a73a4.o
obj-$(CONFIG_PINCTRL_PFC_R8A7740) += pfc-r8a7740.o
obj-$(CONFIG_PINCTRL_PFC_R8A7779) += pfc-r8a7779.o
obj-$(CONFIG_PINCTRL_PFC_SH7203) += pfc-sh7203.o

View file

@ -418,6 +418,9 @@ static int sh_pfc_remove(struct platform_device *pdev)
}
static const struct platform_device_id sh_pfc_id_table[] = {
#ifdef CONFIG_PINCTRL_PFC_R8A73A4
{ "pfc-r8a73a4", (kernel_ulong_t)&r8a73a4_pinmux_info },
#endif
#ifdef CONFIG_PINCTRL_PFC_R8A7740
{ "pfc-r8a7740", (kernel_ulong_t)&r8a7740_pinmux_info },
#endif

View file

@ -54,6 +54,7 @@ void sh_pfc_write_raw_reg(void __iomem *mapped_reg, unsigned long reg_width,
int sh_pfc_get_pin_index(struct sh_pfc *pfc, unsigned int pin);
int sh_pfc_config_mux(struct sh_pfc *pfc, unsigned mark, int pinmux_type);
extern const struct sh_pfc_soc_info r8a73a4_pinmux_info;
extern const struct sh_pfc_soc_info r8a7740_pinmux_info;
extern const struct sh_pfc_soc_info r8a7779_pinmux_info;
extern const struct sh_pfc_soc_info sh7203_pinmux_info;

File diff suppressed because it is too large Load diff