break;
        case ETH_P_IP:
                nic_type |= NIC_TYPE_F_IPV4;
-               ip = (struct iphdr *)network_data;
+               ip = network_data;
 
                /* Check DHCPv4 */
                if (ip->protocol == IPPROTO_UDP) {
-                       struct udphdr *udp = (struct udphdr *)
+                       struct udphdr *udp =
                                        (network_data + sizeof(struct iphdr));
                        if (ntohs(udp->dest) == 67 || ntohs(udp->dest) == 68)
                                nic_type |= NIC_TYPE_F_DHCP;
                break;
        case ETH_P_IPV6:
                nic_type |= NIC_TYPE_F_IPV6;
-               ipv6 = (struct ipv6hdr *)network_data;
+               ipv6 = network_data;
 
                if (ipv6->nexthdr == IPPROTO_ICMPV6) /* Check NDP request */ {
-                       struct icmp6hdr *icmp6 = (struct icmp6hdr *)
+                       struct icmp6hdr *icmp6 =
                                        (network_data + sizeof(struct ipv6hdr));
                        if (icmp6->icmp6_type == NDISC_NEIGHBOUR_SOLICITATION)
                                nic_type |= NIC_TYPE_ICMPV6;
                } else if (ipv6->nexthdr == IPPROTO_UDP) /* Check DHCPv6 */ {
-                       struct udphdr *udp = (struct udphdr *)
+                       struct udphdr *udp =
                                        (network_data + sizeof(struct ipv6hdr));
                        if (ntohs(udp->dest) == 546 || ntohs(udp->dest) == 547)
                                nic_type |= NIC_TYPE_F_DHCP;
 
 static int rx_complete(void *arg, void *data, int len, int context)
 {
-       struct phy_dev *phy_dev = (struct phy_dev *)arg;
+       struct phy_dev *phy_dev = arg;
 
-       return gdm_lte_receive_pkt(phy_dev, (char *)data, len);
+       return gdm_lte_receive_pkt(phy_dev, data, len);
 }
 
 void start_rx_proc(struct phy_dev *phy_dev)
 
 
 static int up_to_host(struct mux_rx *r)
 {
-       struct mux_dev *mux_dev = (struct mux_dev *)r->mux_dev;
+       struct mux_dev *mux_dev = r->mux_dev;
        struct mux_pkt_header *mux_header;
        unsigned int start_flag;
        unsigned int payload_size;
 static void gdm_mux_rcv_complete(struct urb *urb)
 {
        struct mux_rx *r = urb->context;
-       struct mux_dev *mux_dev = (struct mux_dev *)r->mux_dev;
+       struct mux_dev *mux_dev = r->mux_dev;
        struct rx_cxt *rx = &mux_dev->rx;
        unsigned long flags;
 
 
 
 static int set_mac_address(u8 *data, void *arg)
 {
-       struct phy_dev *phy_dev = (struct phy_dev *)arg;
+       struct phy_dev *phy_dev = arg;
        struct lte_udev *udev = phy_dev->priv_dev;
        struct tlv *tlv = (struct tlv *)data;
        u8 mac_address[ETH_ALEN] = {0, };
                list_del(&r->to_host_list);
                spin_unlock_irqrestore(&rx->to_host_lock, flags);
 
-               phy_dev = (struct phy_dev *)r->cb_data;
-               udev = (struct lte_udev *)phy_dev->priv_dev;
+               phy_dev = r->cb_data;
+               udev = phy_dev->priv_dev;
                hci = (struct hci_packet *)r->buf;
                cmd_evt = gdm_dev16_to_cpu(&udev->gdm_ed, hci->cmd_evt);