diff --git a/arch/arm/src/imxrt/imxrt_enet.c b/arch/arm/src/imxrt/imxrt_enet.c index e40a29ab180..92dd5bc5d5e 100644 --- a/arch/arm/src/imxrt/imxrt_enet.c +++ b/arch/arm/src/imxrt/imxrt_enet.c @@ -1750,7 +1750,7 @@ static int imxrt_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/lpc43xx/lpc43_ethernet.c b/arch/arm/src/lpc43xx/lpc43_ethernet.c index b6ff901d468..befb76174fd 100644 --- a/arch/arm/src/lpc43xx/lpc43_ethernet.c +++ b/arch/arm/src/lpc43xx/lpc43_ethernet.c @@ -2761,7 +2761,7 @@ static int lpc43_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/sam34/sam_emac.c b/arch/arm/src/sam34/sam_emac.c index 5eaa9c8d695..486b0fb770f 100644 --- a/arch/arm/src/sam34/sam_emac.c +++ b/arch/arm/src/sam34/sam_emac.c @@ -2326,7 +2326,7 @@ static int sam_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/sama5/sam_emaca.c b/arch/arm/src/sama5/sam_emaca.c index 7eef64f42e1..1555242e531 100644 --- a/arch/arm/src/sama5/sam_emaca.c +++ b/arch/arm/src/sama5/sam_emaca.c @@ -2362,7 +2362,7 @@ static int sam_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/sama5/sam_emacb.c b/arch/arm/src/sama5/sam_emacb.c index 174da786d3a..e2fbaa8015e 100644 --- a/arch/arm/src/sama5/sam_emacb.c +++ b/arch/arm/src/sama5/sam_emacb.c @@ -2729,7 +2729,7 @@ static int sam_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/sama5/sam_gmac.c b/arch/arm/src/sama5/sam_gmac.c index 98872e5d455..6b37ba686dd 100644 --- a/arch/arm/src/sama5/sam_gmac.c +++ b/arch/arm/src/sama5/sam_gmac.c @@ -2317,7 +2317,7 @@ static int sam_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/samv7/sam_emac.c b/arch/arm/src/samv7/sam_emac.c index b67a9d7b0f4..71872e99680 100644 --- a/arch/arm/src/samv7/sam_emac.c +++ b/arch/arm/src/samv7/sam_emac.c @@ -3213,7 +3213,7 @@ static int sam_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/stm32/stm32_eth.c b/arch/arm/src/stm32/stm32_eth.c index 3e3aa6390aa..406fdfc963c 100644 --- a/arch/arm/src/stm32/stm32_eth.c +++ b/arch/arm/src/stm32/stm32_eth.c @@ -2873,7 +2873,7 @@ static int stm32_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/stm32f7/stm32_ethernet.c b/arch/arm/src/stm32f7/stm32_ethernet.c index 403772ba40d..8bc11ffe203 100644 --- a/arch/arm/src/stm32f7/stm32_ethernet.c +++ b/arch/arm/src/stm32f7/stm32_ethernet.c @@ -2975,7 +2975,7 @@ static int stm32_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_ARCH_PHY_INTERRUPT case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/arch/arm/src/tiva/tm4c/tm4c_ethernet.c b/arch/arm/src/tiva/tm4c/tm4c_ethernet.c index 9033f9b1106..71c4a970258 100644 --- a/arch/arm/src/tiva/tm4c/tm4c_ethernet.c +++ b/arch/arm/src/tiva/tm4c/tm4c_ethernet.c @@ -2874,7 +2874,7 @@ static int tiva_ioctl(struct net_driver_s *dev, int cmd, unsigned long arg) #ifdef CONFIG_TIVA_PHY_INTERRUPTS case SIOCMIINOTIFY: /* Set up for PHY event notifications */ { - struct mii_iotcl_notify_s *req = (struct mii_iotcl_notify_s *)((uintptr_t)arg); + struct mii_ioctl_notify_s *req = (struct mii_ioctl_notify_s *)((uintptr_t)arg); ret = phy_notify_subscribe(dev->d_ifname, req->pid, &req->event); if (ret == OK) diff --git a/include/net/if.h b/include/net/if.h index 4be72038ca2..aa3749e1460 100644 --- a/include/net/if.h +++ b/include/net/if.h @@ -118,7 +118,7 @@ * of PHY state changes. */ -struct mii_iotcl_notify_s +struct mii_ioctl_notify_s { pid_t pid; /* PID of the task to receive the signal. Zero means "this task" */ struct sigevent event; /* Describe the way a task is to be notified */ @@ -156,7 +156,7 @@ struct lifreq int lifru_count; /* Number of devices */ int lifru_mtu; /* MTU size */ uint8_t lifru_flags; /* Interface flags */ - struct mii_iotcl_notify_s llfru_mii_notify; /* PHY event notification */ + struct mii_ioctl_notify_s llfru_mii_notify; /* PHY event notification */ struct mii_ioctl_data_s lifru_mii_data; /* MII request data */ } lifr_ifru; }; @@ -170,8 +170,7 @@ struct lifreq #define lifr_count lifr_ifru.lifru_count /* Number of devices */ #define lifr_flags lifr_ifru.lifru_flags /* interface flags */ #define lifr_mii_notify_pid lifr_ifru.llfru_mii_notify.pid /* PID to be notified */ -#define lifr_mii_notify_signo lifr_ifru.llfru_mii_notify.signo /* Signal to notify with */ -#define lifr_mii_notify_arg lifr_ifru.llfru_mii_notify.arg /* sigval argument */ +#define lifr_mii_notify_event lifr_ifru.llfru_mii_notify.event /* Describes notification */ #define lifr_mii_phy_id lifr_ifru.lifru_mii_data.phy_id /* PHY device address */ #define lifr_mii_reg_num lifr_ifru.lifru_mii_data.reg_num /* PHY register address */ #define lifr_mii_val_in lifr_ifru.lifru_mii_data.val_in /* PHY input data */ @@ -207,7 +206,7 @@ struct ifreq int ifru_count; /* Number of devices */ int ifru_mtu; /* MTU size */ uint8_t ifru_flags; /* Interface flags */ - struct mii_iotcl_notify_s ifru_mii_notify; /* PHY event notification */ + struct mii_ioctl_notify_s ifru_mii_notify; /* PHY event notification */ struct mii_ioctl_data_s ifru_mii_data; /* MII request data */ } ifr_ifru; }; @@ -221,7 +220,7 @@ struct ifreq #define ifr_count ifr_ifru.ifru_count /* Number of devices */ #define ifr_flags ifr_ifru.ifru_flags /* interface flags */ #define ifr_mii_notify_pid ifr_ifru.ifru_mii_notify.pid /* PID to be notified */ -#define ifr_mii_notify_signo ifr_ifru.ifru_mii_notify.signo /* Signal to notify with */ +#define ifr_mii_notify_event ifr_ifru.ifru_mii_notify.event /* Describes notification */ #define ifr_mii_notify_arg ifr_ifru.ifru_mii_notify.arg /* sigval argument */ #define ifr_mii_phy_id ifr_ifru.ifru_mii_data.phy_id /* PHY device address */ #define ifr_mii_reg_num ifr_ifru.ifru_mii_data.reg_num /* PHY register address */ diff --git a/net/netdev/netdev_ioctl.c b/net/netdev/netdev_ioctl.c index 4cd26fb79d3..639e0e1fb24 100644 --- a/net/netdev/netdev_ioctl.c +++ b/net/netdev/netdev_ioctl.c @@ -1077,7 +1077,7 @@ static int netdev_ifr_ioctl(FAR struct socket *psock, int cmd, dev = netdev_ifr_dev(req); if (dev && dev->d_ioctl) { - struct mii_iotcl_notify_s *notify = &req->ifr_ifru.ifru_mii_notify; + struct mii_ioctl_notify_s *notify = &req->ifr_ifru.ifru_mii_notify; ret = dev->d_ioctl(dev, cmd, ((unsigned long)(uintptr_t)notify)); } } @@ -1540,7 +1540,7 @@ ssize_t net_ioctl_arglen(int cmd) return sizeof(struct rtentry); case SIOCMIINOTIFY: - return sizeof(struct mii_iotcl_notify_s); + return sizeof(struct mii_ioctl_notify_s); case SIOCGMIIPHY: case SIOCGMIIREG: