Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-30 Thread Joe Perches
On Thu, 2018-03-29 at 23:03 -0700, Quytelda Kahja wrote: > If we just want to have the address field full of zeros during the > driver probe, is there a reason we should zero it explicitly here? > When the 'struct net_device' is first allocated using > alloc_etherdev(), the dev_addr field is

Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-30 Thread Joe Perches
On Thu, 2018-03-29 at 23:03 -0700, Quytelda Kahja wrote: > If we just want to have the address field full of zeros during the > driver probe, is there a reason we should zero it explicitly here? > When the 'struct net_device' is first allocated using > alloc_etherdev(), the dev_addr field is

Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-30 Thread Quytelda Kahja
If we just want to have the address field full of zeros during the driver probe, is there a reason we should zero it explicitly here? When the 'struct net_device' is first allocated using alloc_etherdev(), the dev_addr field is explicitly set to zeros (in the subfunction dev_addr_init() in

Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-30 Thread Quytelda Kahja
If we just want to have the address field full of zeros during the driver probe, is there a reason we should zero it explicitly here? When the 'struct net_device' is first allocated using alloc_etherdev(), the dev_addr field is explicitly set to zeros (in the subfunction dev_addr_init() in

Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-29 Thread Joe Perches
On Wed, 2018-03-28 at 22:51 -0700, Quytelda Kahja wrote: > Copying the dummy HW address into the struct net_device doesn't need > to be done byte by byte; use ether_addr_copy() instead. > Additionally, dev->dev_addr is not eight bytes long. > ether_setup() sets the dev->addr_len to ETH_ALEN

Re: [PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-29 Thread Joe Perches
On Wed, 2018-03-28 at 22:51 -0700, Quytelda Kahja wrote: > Copying the dummy HW address into the struct net_device doesn't need > to be done byte by byte; use ether_addr_copy() instead. > Additionally, dev->dev_addr is not eight bytes long. > ether_setup() sets the dev->addr_len to ETH_ALEN

[PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-28 Thread Quytelda Kahja
Copying the dummy HW address into the struct net_device doesn't need to be done byte by byte; use ether_addr_copy() instead. Additionally, dev->dev_addr is not eight bytes long. ether_setup() sets the dev->addr_len to ETH_ALEN (defined as 6) in the net core code. Signed-off-by: Quytelda Kahja

[PATCH 1/9] staging: ks7010: Replace manual array copy with ether_addr_copy().

2018-03-28 Thread Quytelda Kahja
Copying the dummy HW address into the struct net_device doesn't need to be done byte by byte; use ether_addr_copy() instead. Additionally, dev->dev_addr is not eight bytes long. ether_setup() sets the dev->addr_len to ETH_ALEN (defined as 6) in the net core code. Signed-off-by: Quytelda Kahja