2 * Copyright (c) 2010-2013, NVIDIA CORPORATION. All rights reserved.
4 * SPDX-License-Identifier: GPL-2.0
7 /* Tegra114 high-level function multiplexing */
10 #include <asm/arch/clock.h>
11 #include <asm/arch/funcmux.h>
12 #include <asm/arch/pinmux.h>
14 int funcmux_select(enum periph_id id, int config)
16 int bad_config = config != FUNCMUX_DEFAULT;
21 case FUNCMUX_UART4_GMI:
22 pinmux_set_func(PMUX_PINGRP_GMI_A16_PJ7,
24 pinmux_set_func(PMUX_PINGRP_GMI_A17_PB0,
26 pinmux_set_func(PMUX_PINGRP_GMI_A18_PB1,
28 pinmux_set_func(PMUX_PINGRP_GMI_A19_PK7,
31 pinmux_set_io(PMUX_PINGRP_GMI_A16_PJ7, PMUX_PIN_OUTPUT);
32 pinmux_set_io(PMUX_PINGRP_GMI_A17_PB0, PMUX_PIN_INPUT);
33 pinmux_set_io(PMUX_PINGRP_GMI_A18_PB1, PMUX_PIN_INPUT);
34 pinmux_set_io(PMUX_PINGRP_GMI_A19_PK7, PMUX_PIN_OUTPUT);
36 pinmux_tristate_disable(PMUX_PINGRP_GMI_A16_PJ7);
37 pinmux_tristate_disable(PMUX_PINGRP_GMI_A17_PB0);
38 pinmux_tristate_disable(PMUX_PINGRP_GMI_A18_PB1);
39 pinmux_tristate_disable(PMUX_PINGRP_GMI_A19_PK7);
44 /* Add other periph IDs here as needed */
47 debug("%s: invalid periph_id %d", __func__, id);
52 debug("%s: invalid config %d for periph_id %d", __func__,