1*4882a593Smuzhiyun /* 2*4882a593Smuzhiyun * Copyright (c) 2010-2012, NVIDIA CORPORATION. All rights reserved. 3*4882a593Smuzhiyun * 4*4882a593Smuzhiyun * SPDX-License-Identifier: GPL-2.0 5*4882a593Smuzhiyun */ 6*4882a593Smuzhiyun 7*4882a593Smuzhiyun /* Tegra high-level function multiplexing */ 8*4882a593Smuzhiyun 9*4882a593Smuzhiyun #ifndef _TEGRA_FUNCMUX_H_ 10*4882a593Smuzhiyun #define _TEGRA_FUNCMUX_H_ 11*4882a593Smuzhiyun 12*4882a593Smuzhiyun /** 13*4882a593Smuzhiyun * Select a config for a particular peripheral. 14*4882a593Smuzhiyun * 15*4882a593Smuzhiyun * Each peripheral can operate through a number of configurations, 16*4882a593Smuzhiyun * which are sets of pins that it uses to bring out its signals. 17*4882a593Smuzhiyun * The basic config is 0, and higher numbers indicate different 18*4882a593Smuzhiyun * pinmux settings to bring the peripheral out on other pins, 19*4882a593Smuzhiyun * 20*4882a593Smuzhiyun * This function also disables tristate for the function's pins, 21*4882a593Smuzhiyun * so that they operate in normal mode. 22*4882a593Smuzhiyun * 23*4882a593Smuzhiyun * @param id Peripheral id 24*4882a593Smuzhiyun * @param config Configuration to use (FUNCMUX_...), 0 for default 25*4882a593Smuzhiyun * @return 0 if ok, -1 on error (e.g. incorrect id or config) 26*4882a593Smuzhiyun */ 27*4882a593Smuzhiyun int funcmux_select(enum periph_id id, int config); 28*4882a593Smuzhiyun 29*4882a593Smuzhiyun #endif /* _TEGRA_FUNCMUX_H_ */ 30