Help Needed
Hello Everyone
We have written here the driver as LKM(Loadable Kernel Module) for
testing purpose which we have Loaded successfully. Now we want to write
the user mode application using the ioctl. But we are unable to load
the driver using the application.
We have written the code as below:
int main()
{
char DriverName[256];
int fd;
int temp;
int i = 100;
strcpy(DriverName,"LoadAnalyzerTest");
printf("\nDriver Name %s",DriverName);
fd = open(DriverName, O_RDONLY); //fails
if(fd<0)
{
printf("fd:: %d",fd);
printf("errno:: %d",errno); //errno 2 viz ENOENT
printf("\n Unable To Open The Device");
exit(-1);
}
temp = ioctl(fd,SIOCDEVPRIVATE,(char *)&i);
close(fd);
}
Can any one help in this regard as I need it very urgently.
Thanx & Regards
Naveen Kumar Lall
The Information contained and transmitted by this E-MAIL is proprietary to
Wipro Limited and is intended for use only by the individual or entity to which
it is addressed, and may contain information that is privileged, confidential or
exempt from disclosure under applicable law. If this is a forwarded message,
the content of this E-MAIL may not have been sent with the authority of the
Company. If you are not the intended recipient, an agent of the intended
recipient or a person responsible for delivering the information to the named
recipient, you are notified that any use, distribution, transmission, printing,
copying or dissemination of this information in any way or in any manner is
strictly prohibited. If you have received this communication in error, please
delete this mail & notify us immediately at mailadmin@wipro.com
Reply to: