David Miller [mailto:da...@davemloft.net]
Sent: Thursday, October 09, 2014 3:45 AM
[..]
I think a much simpler fix is to take rtnl_lock() in the workqueue
function and suspend/resume ops.
Every other place you are adding the mutex already holds the RTNL
mutex.
If I use the rtnl_lock(), I
the
driver more safe.
Hayes Wang (3):
r8152: autoresume before setting feature
r8152: adjust usb_autopm_xxx
r8152: add mutex for hw settings
drivers/net/usb/r8152.c | 98 +
1 file changed, 83 insertions(+), 15 deletions(-)
--
1.9.3
Resume the device before setting the feature.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 5cfd414..c5afe8c 100644
--- a/drivers
Use the mutex to avoid the settings are interrupted by other ones.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 64 -
1 file changed, 63 insertions(+), 1 deletion(-)
diff --git a/drivers/net/usb/r8152.c b/drivers
Add usb_autopm_xxx for rtl8152_get_settings() ,and remove
usb_autopm_xxx from read_mii_word() and write_mii_word().
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 24 +++-
1 file changed, 11 insertions(+), 13 deletions(-)
diff --git a/drivers
Use mutex to avoid that the serial hw settings would be interrupted
by other settings. Although there is no problem now, it makes the
driver more safe.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 69 +++--
1 file changed, 67 insertions
Use mutex to avoid that the serial hw settings would be interrupted
by other settings. Although there is no problem now, it makes the
driver more safe.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 69 +++--
1 file
Restart autonegotiation is necessary after setting EEE.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index b9a9815..6532620 100644
--- a/drivers/net/usb/r8152.c
+++ b/drivers/net/usb
Restart autonegotiation is necessary after setting EEE.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index b9a9815..6532620 100644
--- a/drivers/net/usb/r8152.c
Resume the device before setting the MAC address.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 604ef21..5ee7582 100644
--- a/drivers/net/usb/r8152.c
Resume the device before setting the MAC address.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 16 +---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 604ef21..e823358 100644
--- a/drivers/net/usb
Restart autonegotiation is necessary after setting EEE.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index a4d4c4a..e4dcfc1 100644
--- a/drivers/net/usb/r8152.c
+++ b/drivers/net
Restart autonegotiation is necessary after setting EEE.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index a4d4c4a..e4dcfc1 100644
--- a/drivers/net/usb/r8152.c
Resume the device before setting the MAC address.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 16 +---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 604ef21..e823358 100644
Resume the device before setting the MAC address.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 604ef21..5ee7582 100644
The firmware would be clear when the power cut is enabled for
RTL8153.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 18b9e0d..604ef21 100644
--- a/drivers/net/usb
by the firmware would occur.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 28 +---
1 file changed, 1 insertion(+), 27 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index f68a4e6..18b9e0d 100644
--- a/drivers/net/usb/r8152.c
+++ b
The patches fix the issues when the firmware exists.
For the multiple OS, the firmware may be loaded by the
driver of the other OS. And the Linux driver has influences
on it.
Hayes Wang (2):
r8152: remove clearing bp
r8152: disable power cut for RTL8153
drivers/net/usb/r8152.c | 30
The flag of RTL8152_UNPLUG should only be set when the device is
unplugged, not each time the rtl8152_disconnect() is called.
Otherwise, the device wouldn't be stopped normally.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion
The flag of RTL8152_UNPLUG should only be set when the device is
unplugged, not each time the rtl8152_disconnect() is called.
Otherwise, the device wouldn't be stopped normally.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 6 +-
1 file changed, 5 insertions
The patches fix the issues when the firmware exists.
For the multiple OS, the firmware may be loaded by the
driver of the other OS. And the Linux driver has influences
on it.
Hayes Wang (2):
r8152: remove clearing bp
r8152: disable power cut for RTL8153
drivers/net/usb/r8152.c | 30
by the firmware would occur.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 28 +---
1 file changed, 1 insertion(+), 27 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index f68a4e6..18b9e0d 100644
--- a/drivers
The firmware would be clear when the power cut is enabled for
RTL8153.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 18b9e0d..604ef21 100644
Replace the EEE definitions with the ones which is declared
in "mdio.h".
Chage some definitions to make them readable.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 35 ++-
1 file changed, 14 insertions(+), 21 deletions(-)
diff --git a/drive
Add functions to enable EEE and set EEE advertisement.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 101
1 file changed, 76 insertions(+), 25 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index d225aa1
Support get_eee() and set_eee() of ethtool_ops.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 128
1 file changed, 128 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 887b6a2..a4d4c4a 100644
Modify some definitions about EEE, and add the support of setting
the EEE through ethtool.
Hayes Wang (3):
r8152: change the EEE definition
r8152: add functions to set EEE
r8152: support ethtool eee
drivers/net/usb/r8152.c | 246
1 file
Modify some definitions about EEE, and add the support of setting
the EEE through ethtool.
Hayes Wang (3):
r8152: change the EEE definition
r8152: add functions to set EEE
r8152: support ethtool eee
drivers/net/usb/r8152.c | 246
1 file
Support get_eee() and set_eee() of ethtool_ops.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 128
1 file changed, 128 insertions(+)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 887b6a2
Add functions to enable EEE and set EEE advertisement.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 101
1 file changed, 76 insertions(+), 25 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb
Replace the EEE definitions with the ones which is declared
in mdio.h.
Chage some definitions to make them readable.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 35 ++-
1 file changed, 14 insertions(+), 21 deletions(-)
diff
netif_carrier_off would be called when autoresuming, even though
the cable is plugged. This causes some applications do relative
actions when detecting the carrier off. Keep the status of the
carrier, and let it be modified when the linking change occurs.
Signed-off-by: Hayes Wang
---
drivers
netif_carrier_off would be called when autoresuming, even though
the cable is plugged. This causes some applications do relative
actions when detecting the carrier off. Keep the status of the
carrier, and let it be modified when the linking change occurs.
Signed-off-by: Hayes Wang hayesw
when linking on. The hw would enter the
ALDPS mode after several seconds when link down occurs and the ALDPS
is enabled.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 62 +++--
1 file changed, 45 insertions(+), 17 deletions(-)
diff --git
when linking on. The hw would enter the
ALDPS mode after several seconds when link down occurs and the ALDPS
is enabled.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 62 +++--
1 file changed, 45 insertions(+), 17
File: rtl_nic/rtl8168h-1.fw
Version: 0.0.1
File: rtl_nic/rtl8168h-2.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-1.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-2.fw
Version: 0.0.1
Signed-off-by: Hayes Wang
---
WHENCE| 12
rtl_nic/rtl8107e-1.fw | Bin 0 -> 2496 by
Remove the "changed" test in __rtl8169_set_features(). Instead, do
simple test in rtl8169_set_features().
Set the RxChkSum and RxVlan through __rtl8169_set_features() in
rtl_open().
Signed-off-by: Francois Romieu
Signed-off-by: Hayes Wang
---
drivers/net/ethernet/realtek/r8
From: Francois Romieu [mailto:rom...@fr.zoreil.com]
> Sent: Tuesday, September 16, 2014 8:03 AM
[...]
> However it's getting messy and the code stomps CPlusCmd in
> rtl_open right
> before it's given a chance to be read in hw_start. Something like the
> untested patch below should avoid it and
From: Francois Romieu [mailto:rom...@fr.zoreil.com]
Sent: Tuesday, September 16, 2014 8:03 AM
[...]
However it's getting messy and the code stomps CPlusCmd in
rtl_open right
before it's given a chance to be read in hw_start. Something like the
untested patch below should avoid it and keep
Remove the changed test in __rtl8169_set_features(). Instead, do
simple test in rtl8169_set_features().
Set the RxChkSum and RxVlan through __rtl8169_set_features() in
rtl_open().
Signed-off-by: Francois Romieu rom...@fr.zoreil.com
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net
File: rtl_nic/rtl8168h-1.fw
Version: 0.0.1
File: rtl_nic/rtl8168h-2.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-1.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-2.fw
Version: 0.0.1
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
WHENCE| 12
rtl_nic/rtl8107e-1.fw | Bin
Francois Romieu [mailto:rom...@fr.zoreil.com]
> Sent: Saturday, September 13, 2014 3:40 AM
[...]
> The same fix should be relevant for NETIF_F_RXCSUM. You may thus as
> well remove the "changed" test in __rtl8169_set_features and keep
> everything there.
In the probe function (rtl_init_one),
Francois Romieu [mailto:rom...@fr.zoreil.com]
Sent: Saturday, September 13, 2014 3:40 AM
[...]
The same fix should be relevant for NETIF_F_RXCSUM. You may thus as
well remove the changed test in __rtl8169_set_features and keep
everything there.
In the probe function (rtl_init_one), RxChkSum
File: rtl_nic/rtl8168h-1.fw
Version: 0.0.1
File: rtl_nic/rtl8168h-2.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-1.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-2.fw
Version: 0.0.1
Signed-off-by: Hayes Wang
---
WHENCE| 12
rtl_nic/rtl8107e-1.fw | Bin 0 -> 2496 by
File: rtl_nic/rtl8168h-1.fw
Version: 0.0.1
File: rtl_nic/rtl8168h-2.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-1.fw
Version: 0.0.1
File: rtl_nic/rtl8107e-2.fw
Version: 0.0.1
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
WHENCE| 12
rtl_nic/rtl8107e-1.fw | Bin
The setting should depend on the new features not the current one.
Signed-off-by: Hayes Wang
---
drivers/net/ethernet/realtek/r8169.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/realtek/r8169.c
b/drivers/net/ethernet/realtek/r8169.c
index f3ce284
There are two issues for hw rx vlan. The patches are
used to fix them.
Hayes Wang (2):
r8169: fix the default setting of rx vlan
r8169: fix setting rx vlan
drivers/net/ethernet/realtek/r8169.c | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
--
1.9.3
--
To unsubscribe from
If the parameter "features" of __rtl8169_set_features() is equal to
dev->features, the variable "changed" is alwayes 0, and nothing would
be changed.
Signed-off-by: Hayes Wang
---
drivers/net/ethernet/realtek/r8169.c | 7 ++-
1 file changed, 6 insertions(+), 1
Support hw VLAN for tx and rx. And enable them by default.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 79 -
1 file changed, 65 insertions(+), 14 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index
Support hw VLAN for tx and rx. And enable them by default.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 85 +
1 file changed, 71 insertions(+), 14 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index
Support hw VLAN for tx and rx. And enable them by default.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 79 -
1 file changed, 65 insertions(+), 14 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb
If the parameter features of __rtl8169_set_features() is equal to
dev-features, the variable changed is alwayes 0, and nothing would
be changed.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/ethernet/realtek/r8169.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion
There are two issues for hw rx vlan. The patches are
used to fix them.
Hayes Wang (2):
r8169: fix the default setting of rx vlan
r8169: fix setting rx vlan
drivers/net/ethernet/realtek/r8169.c | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
--
1.9.3
--
To unsubscribe from
The setting should depend on the new features not the current one.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/ethernet/realtek/r8169.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/realtek/r8169.c
b/drivers/net/ethernet/realtek
Support hw VLAN for tx and rx. And enable them by default.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 85 +
1 file changed, 71 insertions(+), 14 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb
From: Ivan Vecera [mailto:ivec...@redhat.com]
> Sent: Tuesday, September 09, 2014 8:19 PM
[...]
> Thanks Hayes,
> have you got any idea when do you update them?
If all are fine, I would release them this week.
Best Regards,
Hayes
--
To unsubscribe from this list: send the line "unsubscribe
From: Ivan Vecera [mailto:ivec...@redhat.com]
Sent: Tuesday, September 09, 2014 8:19 PM
[...]
Thanks Hayes,
have you got any idea when do you update them?
If all are fine, I would release them this week.
Best Regards,
Hayes
--
To unsubscribe from this list: send the line unsubscribe
From: Ivan Vecera [mailto:ivec...@redhat.com]
> Sent: Monday, September 08, 2014 9:01 PM
> To: Hau; net...@vger.kernel.org
> Cc: nic_swsd; linux-kernel@vger.kernel.org; rom...@fr.zoreil.com
> Subject: Re: [PATCH net-next v2] r8169:add support for
> RTL8168H and RTL8107E
[...]
> Where are these
Replace mdelay with usleep_range to avoid busy loop.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index f95e678..2130c75 100644
--- a/drivers
Replace mdelay with usleep_range to avoid busy loop.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index f95e678..2130c75
From: Ivan Vecera [mailto:ivec...@redhat.com]
Sent: Monday, September 08, 2014 9:01 PM
To: Hau; net...@vger.kernel.org
Cc: nic_swsd; linux-kernel@vger.kernel.org; rom...@fr.zoreil.com
Subject: Re: [PATCH net-next v2] r8169:add support for
RTL8168H and RTL8107E
[...]
Where are these new
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
v3:
Remove
ether_addr_copy(dev->perm_addr, dev->dev_addr);
v2:
Use "%pM" format specifier for printing a MAC address.
Hayes Wang (2):
r8152: cha
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 35 +++
1 file changed, 19 insertions(+), 16 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 34 +-
1 file changed, 17
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 34 +-
1
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 35 +++
1 file changed, 19 insertions(+), 16 deletions(-)
diff --git a/drivers/net/usb/r8152.c b
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
v3:
Remove
ether_addr_copy(dev-perm_addr, dev-dev_addr);
v2:
Use %pM format specifier for printing a MAC address.
Hayes Wang (2):
r8152: change the location
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 35 ---
1 file changed, 20 insertions(+), 15 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
v2:
Use "%pM" format specifier for printing a MAC address.
Hayes Wang (2):
r8152: change the location of rtl8152_set_mac_address
r8152: use eth_hw_addr_random
d
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 34 +-
1 file changed, 17
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 39 ---
1 file changed, 24 insertions(+), 15 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 34 +-
1 file changed, 17
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
Hayes Wang (2):
r8152: change the location of rtl8152_set_mac_address
r8152: use eth_hw_addr_random
drivers/net/usb/r8152.c | 65
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 34 +-
1
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
Hayes Wang (2):
r8152: change the location of rtl8152_set_mac_address
r8152: use eth_hw_addr_random
drivers/net/usb/r8152.c | 65
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 39 ---
1 file changed, 24 insertions(+), 15 deletions(-)
diff --git a/drivers/net/usb/r8152.c b
Exchange the location of rtl8152_set_mac_address() and
set_ethernet_addr(). Then, the set_ethernet_addr() could
set the MAC address by calling rtl8152_set_mac_address()
later.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 34 +-
1
If the interface has invalid MAC address, it couldn't
be used. In order to let it work normally, give a
random one.
v2:
Use %pM format specifier for printing a MAC address.
Hayes Wang (2):
r8152: change the location of rtl8152_set_mac_address
r8152: use eth_hw_addr_random
drivers/net/usb
If the hw doesn't have a valid MAC address, give a random one and
set it to the hw.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 35 ---
1 file changed, 20 insertions(+), 15 deletions(-)
diff --git a/drivers/net/usb/r8152.c b
> From: Zhang Rui [mailto:rui.zh...@intel.com]
> Sent: Monday, September 01, 2014 4:09 PM
[...]
> Hi, Hayes,
>
> We got a regression report complaining that wakeup from Suspend to RAM
> crashes, please refer to
> https://bugzilla.kernel.org/show_bug.cgi?id=82741
>
> and it seems that it is
The variable "rx_buf_sz" is used by both tx and rx buffers. Replace
it with "agg_buf_sz".
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/n
The variable rx_buf_sz is used by both tx and rx buffers. Replace
it with agg_buf_sz.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb
From: Zhang Rui [mailto:rui.zh...@intel.com]
Sent: Monday, September 01, 2014 4:09 PM
[...]
Hi, Hayes,
We got a regression report complaining that wakeup from Suspend to RAM
crashes, please refer to
https://bugzilla.kernel.org/show_bug.cgi?id=82741
and it seems that it is introduced by
From: David Miller [mailto:da...@davemloft.net]
[...]
> This driver has a loop that iterates MAX_TX times to initialize both
> the RX and TX buffers.
>
> So if they are not equal, it can't possibly work.
Excuse me. I don't find that the "RTL8152_MAX_TX" is used by
rx buffer. The rx buffer only
From: David Miller [mailto:da...@davemloft.net]
[...]
This driver has a loop that iterates MAX_TX times to initialize both
the RX and TX buffers.
So if they are not equal, it can't possibly work.
Excuse me. I don't find that the RTL8152_MAX_TX is used by
rx buffer. The rx buffer only use
Because the Tx has the features of stopping queue and aggregation,
We don't need many tx buffers. Change the tx number from 10 to 4
to reduce the usage of the memory. This could save 16K * 6 bytes
memory.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 2 +-
1 file changed, 1 insertion
Because the Tx has the features of stopping queue and aggregation,
We don't need many tx buffers. Change the tx number from 10 to 4
to reduce the usage of the memory. This could save 16K * 10 bytes
memory.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 2 +-
1 file changed, 1 insertion
Because the Tx has the features of stopping queue and aggregation,
We don't need many tx buffers. Change the tx number from 10 to 4
to reduce the usage of the memory. This could save 16K * 10 bytes
memory.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 2 +-
1 file
Because the Tx has the features of stopping queue and aggregation,
We don't need many tx buffers. Change the tx number from 10 to 4
to reduce the usage of the memory. This could save 16K * 6 bytes
memory.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 2 +-
1 file
Replace the strncpy with strlcpy, and use sizeof to determine the
length.
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 2470d9c..33dcc97 100644
--- a/drivers
: CHECK: Alignment should match open parenthesis
total: 0 errors, 5 warnings, 16 checks, 3567 lines checked
Signed-off-by: Hayes Wang
---
drivers/net/usb/r8152.c | 66 ++---
1 file changed, 35 insertions(+), 31 deletions(-)
diff --git a/drivers/net/usb
From: David Miller [mailto:da...@davemloft.net]
[...]
> That still doesn't convince me.
>
> The functions I see you removing are just programming a set of
> registers in some way.
That is to clear the break point of the firmware. If a firmware exists,
you should clear it before updating a new
From: David Miller [mailto:da...@davemloft.net]
[...]
That still doesn't convince me.
The functions I see you removing are just programming a set of
registers in some way.
That is to clear the break point of the firmware. If a firmware exists,
you should clear it before updating a new one.
: CHECK: Alignment should match open parenthesis
total: 0 errors, 5 warnings, 16 checks, 3567 lines checked
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 66 ++---
1 file changed, 35 insertions(+), 31 deletions(-)
diff --git
Replace the strncpy with strlcpy, and use sizeof to determine the
length.
Signed-off-by: Hayes Wang hayesw...@realtek.com
---
drivers/net/usb/r8152.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c
index 2470d9c..33dcc97
From: David Miller [mailto:da...@davemloft.net]
[...]
> You haven't told us why you need to do this.
>
> These are just programming registers in the chip, and I see no reason
> to not keep these in the driver with real code.
>
> I'm not applying this series, you haven't explained what is
Francois Romieu [mailto:rom...@fr.zoreil.com]
[...]
> > +static void rtl_request_firmware(struct r8152 *tp)
> > +{
> > + char *fw_name = NULL;
> > +
> > + if (tp->rtl_fw.fw)
> > + goto out_request;
> > +
> > + switch (tp->version) {
> > + case RTL_VER_01:
> > + fw_name
Francois Romieu [mailto:rom...@fr.zoreil.com]
[...]
+static void rtl_request_firmware(struct r8152 *tp)
+{
+ char *fw_name = NULL;
+
+ if (tp-rtl_fw.fw)
+ goto out_request;
+
+ switch (tp-version) {
+ case RTL_VER_01:
+ fw_name =
From: David Miller [mailto:da...@davemloft.net]
[...]
You haven't told us why you need to do this.
These are just programming registers in the chip, and I see no reason
to not keep these in the driver with real code.
I'm not applying this series, you haven't explained what is happening
Sergei Shtylyov [mailto:sergei.shtyl...@cogentembedded.com]
[...]
> >> Why leave 2 empty lines? One is enough.
>
> > The next patch would use another fucntion at the
> > same location. I skip removing the empty line and
> > re-adding it again. Is that better to do so? I would
> > resend
701 - 800 of 1253 matches
Mail list logo