The pathname of the program to run is passed as program. The args argument is an array of 0-terminated strings. The array itself should be terminated by a NULL pointer.
The argument strings should be copied into the new process as the new process's argv array. In the new process, argv[argc] must be NULL.
By convention, argv in new processes contains the name that was used to invoke the program. This is not necessarily the same as program, and furthermore is only a convention and should not be enforced by the kernel.
The process file table and current working directory are not modified by execve.
ENODEV The device prefix of program did not exist. ENOTDIR A non-final component of program was not a directory. ENOENT program did not exist. EISDIR program is a directory. ENOEXEC program is not in a recognizable executable file format, was for the wrong platform, or contained invalid fields. ENOMEM Insufficient virtual memory is available. E2BIG The total size of the argument strings is too large. EIO A hard I/O error occurred. EFAULT One of the args is an invalid pointer.