/**************************************************************************** * syscall/syscall_funclookup.c * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. The * ASF licenses this file to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance with the * License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations * under the License. * ****************************************************************************/ /**************************************************************************** * Included Files ****************************************************************************/ #include #include /* The content of this file is only meaningful during the kernel phase of * a kernel build. */ #if defined(CONFIG_LIB_SYSCALL) && defined(__KERNEL__) #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include /**************************************************************************** * Pre-processor Definitions ****************************************************************************/ /**************************************************************************** * Public Data ****************************************************************************/ /* Function lookup tables. This table is indexed by the system call numbers * defined above. Given the system call number, this table provides the * address of the corresponding system function. * * This table is only available during the kernel phase of a kernel build. */ const uintptr_t g_funclookup[SYS_nsyscalls] = { # define SYSCALL_LOOKUP1(f,n) (uintptr_t)f # define SYSCALL_LOOKUP(f,n) , (uintptr_t)f # include # undef SYSCALL_LOOKUP1 # undef SYSCALL_LOOKUP }; /**************************************************************************** * Public Functions ****************************************************************************/ #endif /* CONFIG_LIB_SYSCALL && __KERNEL__ */