Ok I changed my struct to :
Code:
struct info {
int pid;
char root_path[4096];
char pwd_path[4096];
};
And I was able to copy the path to root_path using copy_to_user and print it in the kernel log before returning from my system call.
After running my syscall test in a c program and running dmesg to see if it printed the root_path kernel side, it did print it.
But in user program root_path disappeared as when I execute the program it prints nothing. Can somebody please help me I dont know what I am doing wrong.