* [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly
@ 2014-03-19 9:39 Wang Weidong
2014-03-20 20:07 ` David Miller
2014-03-21 1:50 ` [PATCH net-next v2] " Wang Weidong
0 siblings, 2 replies; 6+ messages in thread
From: Wang Weidong @ 2014-03-19 9:39 UTC (permalink / raw)
To: David Miller, jcliburn, chris.snook; +Cc: netdev
As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
directly"), using a wrapper around SET_ETHTOOL_OPS macro is
not actually required, remove and use SET_ETHTOOL_OPS directly.
Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
---
drivers/net/ethernet/atheros/atlx/atl2.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/drivers/net/ethernet/atheros/atlx/atl2.c b/drivers/net/ethernet/atheros/atlx/atl2.c
index 265ce1b..9262521 100644
--- a/drivers/net/ethernet/atheros/atlx/atl2.c
+++ b/drivers/net/ethernet/atheros/atlx/atl2.c
@@ -71,8 +71,6 @@ static DEFINE_PCI_DEVICE_TABLE(atl2_pci_tbl) = {
};
MODULE_DEVICE_TABLE(pci, atl2_pci_tbl);
-static void atl2_set_ethtool_ops(struct net_device *netdev);
-
static void atl2_check_options(struct atl2_adapter *adapter);
/**
@@ -1397,7 +1395,7 @@ static int atl2_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
atl2_setup_pcicmd(pdev);
netdev->netdev_ops = &atl2_netdev_ops;
- atl2_set_ethtool_ops(netdev);
+ SET_ETHTOOL_OPS(netdev, &atl2_ethtool_ops);
netdev->watchdog_timeo = 5 * HZ;
strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
@@ -2105,11 +2103,6 @@ static const struct ethtool_ops atl2_ethtool_ops = {
.set_eeprom = atl2_set_eeprom,
};
-static void atl2_set_ethtool_ops(struct net_device *netdev)
-{
- SET_ETHTOOL_OPS(netdev, &atl2_ethtool_ops);
-}
-
#define LBYTESWAP(a) ((((a) & 0x00ff00ff) << 8) | \
(((a) & 0xff00ff00) >> 8))
#define LONGSWAP(a) ((LBYTESWAP(a) << 16) | (LBYTESWAP(a) >> 16))
--
1.7.12
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly
2014-03-19 9:39 [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly Wang Weidong
@ 2014-03-20 20:07 ` David Miller
2014-03-20 20:17 ` David Miller
2014-03-21 1:50 ` [PATCH net-next v2] " Wang Weidong
1 sibling, 1 reply; 6+ messages in thread
From: David Miller @ 2014-03-20 20:07 UTC (permalink / raw)
To: wangweidong1; +Cc: jcliburn, chris.snook, netdev
From: Wang Weidong <wangweidong1@huawei.com>
Date: Wed, 19 Mar 2014 17:39:15 +0800
> As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
> directly"), using a wrapper around SET_ETHTOOL_OPS macro is
> not actually required, remove and use SET_ETHTOOL_OPS directly.
>
> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
Applied, thank you.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly
2014-03-20 20:07 ` David Miller
@ 2014-03-20 20:17 ` David Miller
2014-03-21 1:41 ` Wang Weidong
0 siblings, 1 reply; 6+ messages in thread
From: David Miller @ 2014-03-20 20:17 UTC (permalink / raw)
To: wangweidong1; +Cc: jcliburn, chris.snook, netdev
From: David Miller <davem@davemloft.net>
Date: Thu, 20 Mar 2014 16:07:01 -0400 (EDT)
> From: Wang Weidong <wangweidong1@huawei.com>
> Date: Wed, 19 Mar 2014 17:39:15 +0800
>
>> As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
>> directly"), using a wrapper around SET_ETHTOOL_OPS macro is
>> not actually required, remove and use SET_ETHTOOL_OPS directly.
>>
>> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
>
> Applied, thank you.
I reverted, you did not ever build test this:
drivers/net/ethernet/atheros/atlx/atl2.c: In function ‘atl2_probe’:
drivers/net/ethernet/atheros/atlx/atl2.c:1398:2: error: ‘atl2_ethtool_ops’ undeclared (first use in this function)
drivers/net/ethernet/atheros/atlx/atl2.c:1398:2: note: each undeclared identifier is reported only once for each function it appears in
make[1]: *** [drivers/net/ethernet/atheros/atlx/atl2.o] Error 1
make: *** [drivers/net/ethernet/atheros/atlx/atl2.o] Error 2
If you do not even have the time to do a test build, then I do not
have the time to review and apply your patches.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly
2014-03-20 20:17 ` David Miller
@ 2014-03-21 1:41 ` Wang Weidong
0 siblings, 0 replies; 6+ messages in thread
From: Wang Weidong @ 2014-03-21 1:41 UTC (permalink / raw)
To: David Miller; +Cc: jcliburn, chris.snook, netdev
On 2014/3/21 4:17, David Miller wrote:
> From: David Miller <davem@davemloft.net>
> Date: Thu, 20 Mar 2014 16:07:01 -0400 (EDT)
>
>> From: Wang Weidong <wangweidong1@huawei.com>
>> Date: Wed, 19 Mar 2014 17:39:15 +0800
>>
>>> As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
>>> directly"), using a wrapper around SET_ETHTOOL_OPS macro is
>>> not actually required, remove and use SET_ETHTOOL_OPS directly.
>>>
>>> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
>>
>> Applied, thank you.
>
> I reverted, you did not ever build test this:
>
> drivers/net/ethernet/atheros/atlx/atl2.c: In function ‘atl2_probe’:
> drivers/net/ethernet/atheros/atlx/atl2.c:1398:2: error: ‘atl2_ethtool_ops’ undeclared (first use in this function)
> drivers/net/ethernet/atheros/atlx/atl2.c:1398:2: note: each undeclared identifier is reported only once for each function it appears in
> make[1]: *** [drivers/net/ethernet/atheros/atlx/atl2.o] Error 1
> make: *** [drivers/net/ethernet/atheros/atlx/atl2.o] Error 2
>
> If you do not even have the time to do a test build, then I do not
> have the time to review and apply your patches.
>
Hi David,
So sorry for your time. I built all the kernel at first time, and this error
log was hidden, although, I should build it in the drivers/ and ensured it OK,
It is my mistake.
I will fix it.
Regards
Wang
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH net-next v2] atheros/atlx: use SET_ETHTOOL_OPS directly
2014-03-19 9:39 [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly Wang Weidong
2014-03-20 20:07 ` David Miller
@ 2014-03-21 1:50 ` Wang Weidong
2014-03-21 19:37 ` David Miller
1 sibling, 1 reply; 6+ messages in thread
From: Wang Weidong @ 2014-03-21 1:50 UTC (permalink / raw)
To: David Miller, jcliburn, chris.snook; +Cc: netdev
As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
directly"), using a wrapper around SET_ETHTOOL_OPS macro is
not actually required, remove and use SET_ETHTOOL_OPS directly.
Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
---
Change note:
v2: fix the build error.
---
drivers/net/ethernet/atheros/atlx/atl2.c | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/drivers/net/ethernet/atheros/atlx/atl2.c b/drivers/net/ethernet/atheros/atlx/atl2.c
index 265ce1b..78befb5 100644
--- a/drivers/net/ethernet/atheros/atlx/atl2.c
+++ b/drivers/net/ethernet/atheros/atlx/atl2.c
@@ -55,6 +55,7 @@ static const char atl2_driver_name[] = "atl2";
static const char atl2_driver_string[] = "Atheros(R) L2 Ethernet Driver";
static const char atl2_copyright[] = "Copyright (c) 2007 Atheros Corporation.";
static const char atl2_driver_version[] = ATL2_DRV_VERSION;
+static const struct ethtool_ops atl2_ethtool_ops;
MODULE_AUTHOR("Atheros Corporation <xiong.huang@atheros.com>, Chris Snook <csnook@redhat.com>");
MODULE_DESCRIPTION("Atheros Fast Ethernet Network Driver");
@@ -71,8 +72,6 @@ static DEFINE_PCI_DEVICE_TABLE(atl2_pci_tbl) = {
};
MODULE_DEVICE_TABLE(pci, atl2_pci_tbl);
-static void atl2_set_ethtool_ops(struct net_device *netdev);
-
static void atl2_check_options(struct atl2_adapter *adapter);
/**
@@ -1397,7 +1396,7 @@ static int atl2_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
atl2_setup_pcicmd(pdev);
netdev->netdev_ops = &atl2_netdev_ops;
- atl2_set_ethtool_ops(netdev);
+ SET_ETHTOOL_OPS(netdev, &atl2_ethtool_ops);
netdev->watchdog_timeo = 5 * HZ;
strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
@@ -2105,11 +2104,6 @@ static const struct ethtool_ops atl2_ethtool_ops = {
.set_eeprom = atl2_set_eeprom,
};
-static void atl2_set_ethtool_ops(struct net_device *netdev)
-{
- SET_ETHTOOL_OPS(netdev, &atl2_ethtool_ops);
-}
-
#define LBYTESWAP(a) ((((a) & 0x00ff00ff) << 8) | \
(((a) & 0xff00ff00) >> 8))
#define LONGSWAP(a) ((LBYTESWAP(a) << 16) | (LBYTESWAP(a) >> 16))
--
1.7.12
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH net-next v2] atheros/atlx: use SET_ETHTOOL_OPS directly
2014-03-21 1:50 ` [PATCH net-next v2] " Wang Weidong
@ 2014-03-21 19:37 ` David Miller
0 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2014-03-21 19:37 UTC (permalink / raw)
To: wangweidong1; +Cc: jcliburn, chris.snook, netdev
From: Wang Weidong <wangweidong1@huawei.com>
Date: Fri, 21 Mar 2014 09:50:43 +0800
> As commit a6e28b34205b("staging/et131x: use SET_ETHTOOL_OPS
> directly"), using a wrapper around SET_ETHTOOL_OPS macro is
> not actually required, remove and use SET_ETHTOOL_OPS directly.
>
> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
Applied.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-03-21 19:37 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-19 9:39 [PATCH net-next] atheros/atlx: use SET_ETHTOOL_OPS directly Wang Weidong
2014-03-20 20:07 ` David Miller
2014-03-20 20:17 ` David Miller
2014-03-21 1:41 ` Wang Weidong
2014-03-21 1:50 ` [PATCH net-next v2] " Wang Weidong
2014-03-21 19:37 ` David Miller
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.