in u-boot-1.1.6\common\Env_common.c, fun env_get_char_spec() and var env_ptr in u-boot are externed as followed:
<span style="font-size:18px;">extern env_t *env_ptr;
extern uchar env_get_char_spec(int);</span>
in u-boot, var env_ptr and fun
env_get_char_spec()(and others also) are defined in many files, such as, env_nand.c, env_nowhere.c and so on(env parameters can be stored in different memory media).
but in the Makefile located at dir u-boot-1.1.6/common, all these file seem to be compiled when compiling u-boot. so the question is which definitions in all these file var env_ptr and fun env_get_char_spec() will refer to?
at start of each such file, there is macro in the conditional compilation statement to control the file contents to be compiled. there is only one macro's value equaling to 1 and only the corresponding file will be compiled.
notices:
1. if there are multilple definitions in several C file in result for executing "go to definition" to a var or fun in Source Insight, you can check at the beginning of this file whether there is a extern for this var or fun. if does, except that special one, other definitions may be disable by a conditional compilation or defined with a attribute of "static".
2. if there are multilple definitions in several C file in result for executing "go to definition" to a macro, in this case, how to find which the only definition this reference uses? you can check these macro definitions in the corresponding files whether the macro value is a static fun, if this, this macro definition is not the target macro definition.