net: ethernet: ti: cpsw-proxy-client: Fix size of ipv4_addr member
commit ea5090c97de3b1e8f97323d103b2a3dcc33a876d from git://git.ti.com/ti-linux-kernel/ti-linux-kernel.git The ipv4_addr member of struct cpsw_virt_port is defined for being used when sending ETHREMOTECFG_IPv4_REGISTER and ETHREMOTECFG_IPv4_DEREGISTER requests. The same ipv4_addr member is defined in their respective request structures in drivers/net/ethernet/ti/eth_remote_msg.h as an array of u8 of size ETHREMOTECFG_IPV4ADDRLEN which is 4. The ipv4_addr member should have a size of 32 bits and thus should be an array of u8 of size 4, instead of the currently defined size of 8. Fix this by defining the ipv4_addr member as an array of u8 having the size ETHREMOTECFG_IPV4ADDRLEN. Also, use the ETHREMOTECFG_IPV4ADDRLEN macro for memcpy when creating requests in the create_request() function for the ETHREMOTECFG_IPV4_REGISTER and ETHREMOTECFG_IPV4_DEREGISTER requests. Fixes: 9343810f28a1 ("net: ethernet: ti: Add CPSW Proxy Client driver") Signed-off-by:Guillaume La Roque <glaroque@baylibre.com> Signed-off-by:
Siddharth Vadapalli <s-vadapalli@ti.com> Signed-off-by:
Vignesh Raghavendra <vigneshr@ti.com> Signed-off-by:
Xulin Sun <xulin.sun@windriver.com>
Loading
Please register or sign in to comment