Accessing the device driver api's from application

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
I am quite new to linux. I am developing a driver for ADSL modem. I have to test the driver through some application programs which has to call the driver api's. The basic problem is the inteface between these two.
I am doing something like this -
{
int sock;
struct ifreq req;
 
sock = socket(AF_INET, SOCK_RAW, IPPROTO_RAW);
strcpy(req.ifr_name, "adsl");  /*I have installed the driver and able to see it using                                                 ifconfig */
ioctl(sock, SIOCGIFMAP, req);
 
}
 
Doing as above will my "get_stats" method in the driver be called? If not how is it to be done? How can other methods - (*hard_start_xmit) be called from the application?
 
Thanks in Advance
 
Vinay

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux