Sesh
|
IOCTL commands for setting MAC and IP addresses
|
Sesh
02/26/2016 5:01 PM
post115876
|
IOCTL commands for setting MAC and IP addresses
Hello,
I have a TAP interface and wish to override the default MAC and assign a IP address. What ioctl commands are available
in QNX to support this.
I saw a few posts around SIOCSIFADDR. Not sure if this is used for both of the above cases. Will 'ifru_addr' be used for
setting both addresses?
--------------------------------------------------------------------
struct ifreq {
char ifr_name[IFNAMSIZ]; /* if name, e.g. "en0" */
union {
struct sockaddr ifru_addr;
struct sockaddr ifru_dstaddr;
struct sockaddr ifru_broadaddr;
struct sockaddr_storage ifru_space;
#ifndef __QNXNTO__
short ifru_flags;
#else
int ifru_flags;
#endif
int ifru_metric;
int ifru_mtu;
int ifru_dlt;
unsigned int ifru_value;
void * ifru_data;
struct {
uint32_t b_buflen;
void *b_buf;
} ifru_b;
#ifdef __QNXNTO__
int ifru_fibmask;
#endif
} ifr_ifru;
--------------------------------------------------
|
|
|