* [PATCH] net-next: ethtool: Added port speed macros.
@ 2015-05-18 11:01 Parav Pandit
2015-05-18 15:46 ` David Miller
0 siblings, 1 reply; 8+ messages in thread
From: Parav Pandit @ 2015-05-18 11:01 UTC (permalink / raw)
To: netdev; +Cc: bwh, davem, parav.pandit
Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
---
include/uapi/linux/ethtool.h | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h
index 2e49fc8..ae832b4 100644
--- a/include/uapi/linux/ethtool.h
+++ b/include/uapi/linux/ethtool.h
@@ -1264,15 +1264,19 @@ enum ethtool_sfeatures_retval_bits {
* it was forced up into this mode or autonegotiated.
*/
-/* The forced speed, 10Mb, 100Mb, gigabit, [2.5|10|20|40|56]GbE. */
+/* The forced speed, 10Mb, 100Mb, gigabit, [2.5|5|10|20|25|40|50|56|100]GbE. */
#define SPEED_10 10
#define SPEED_100 100
#define SPEED_1000 1000
#define SPEED_2500 2500
+#define SPEED_5000 5000
#define SPEED_10000 10000
#define SPEED_20000 20000
+#define SPEED_25000 25000
#define SPEED_40000 40000
+#define SPEED_50000 50000
#define SPEED_56000 56000
+#define SPEED_100000 100000
#define SPEED_UNKNOWN -1
--
1.7.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-18 11:01 [PATCH] net-next: ethtool: Added port speed macros Parav Pandit
@ 2015-05-18 15:46 ` David Miller
2015-05-19 4:45 ` Parav Pandit
2015-05-19 17:00 ` Ben Hutchings
0 siblings, 2 replies; 8+ messages in thread
From: David Miller @ 2015-05-18 15:46 UTC (permalink / raw)
To: parav.pandit; +Cc: netdev, bwh
From: Parav Pandit <parav.pandit@avagotech.com>
Date: Mon, 18 May 2015 16:31:47 +0530
> Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
I thought we had decided that we weren't going to keep adding
convenience macros for new speeds, and were simply going to use
the appropriate constants in the future.
Ben?
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-18 15:46 ` David Miller
@ 2015-05-19 4:45 ` Parav Pandit
2015-05-19 16:32 ` David Miller
2015-05-19 17:00 ` Ben Hutchings
1 sibling, 1 reply; 8+ messages in thread
From: Parav Pandit @ 2015-05-19 4:45 UTC (permalink / raw)
To: David Miller; +Cc: netdev, bwh
On Mon, May 18, 2015 at 9:16 PM, David Miller <davem@davemloft.net> wrote:
> From: Parav Pandit <parav.pandit@avagotech.com>
> Date: Mon, 18 May 2015 16:31:47 +0530
>
>> Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
>
> I thought we had decided that we weren't going to keep adding
> convenience macros for new speeds, and were simply going to use
> the appropriate constants in the future.
>
I added them to accommodate any speed/PHY interface specific
configuration to make use of it.
If convenience macros are not needed, I will provide the code cleanup
patch to remove existing convenience macros. With that we will have
unified code for old and new constants.
I will anyway let Ben comment on it.
> Ben?
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-19 4:45 ` Parav Pandit
@ 2015-05-19 16:32 ` David Miller
2015-05-19 16:41 ` Parav Pandit
0 siblings, 1 reply; 8+ messages in thread
From: David Miller @ 2015-05-19 16:32 UTC (permalink / raw)
To: parav.pandit; +Cc: netdev, bwh
From: Parav Pandit <parav.pandit@avagotech.com>
Date: Tue, 19 May 2015 10:15:49 +0530
> On Mon, May 18, 2015 at 9:16 PM, David Miller <davem@davemloft.net> wrote:
>> From: Parav Pandit <parav.pandit@avagotech.com>
>> Date: Mon, 18 May 2015 16:31:47 +0530
>>
>>> Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
>>
>> I thought we had decided that we weren't going to keep adding
>> convenience macros for new speeds, and were simply going to use
>> the appropriate constants in the future.
>>
>
> I added them to accommodate any speed/PHY interface specific
> configuration to make use of it.
> If convenience macros are not needed, I will provide the code cleanup
> patch to remove existing convenience macros. With that we will have
> unified code for old and new constants.
> I will anyway let Ben comment on it.
You cannot remove the existing macros, because they are exported to
userspace and you'll break application compilation if you do that.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-19 16:32 ` David Miller
@ 2015-05-19 16:41 ` Parav Pandit
0 siblings, 0 replies; 8+ messages in thread
From: Parav Pandit @ 2015-05-19 16:41 UTC (permalink / raw)
To: David Miller; +Cc: netdev, bwh
On Tue, May 19, 2015 at 10:02 PM, David Miller <davem@davemloft.net> wrote:
> From: Parav Pandit <parav.pandit@avagotech.com>
> Date: Tue, 19 May 2015 10:15:49 +0530
>
>> On Mon, May 18, 2015 at 9:16 PM, David Miller <davem@davemloft.net> wrote:
>>> From: Parav Pandit <parav.pandit@avagotech.com>
>>> Date: Mon, 18 May 2015 16:31:47 +0530
>>>
>>>> Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
>>>
>>> I thought we had decided that we weren't going to keep adding
>>> convenience macros for new speeds, and were simply going to use
>>> the appropriate constants in the future.
>>>
>>
>> I added them to accommodate any speed/PHY interface specific
>> configuration to make use of it.
>> If convenience macros are not needed, I will provide the code cleanup
>> patch to remove existing convenience macros. With that we will have
>> unified code for old and new constants.
>> I will anyway let Ben comment on it.
>
> You cannot remove the existing macros, because they are exported to
> userspace and you'll break application compilation if you do that.
Yes, didn't think about it before.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-18 15:46 ` David Miller
2015-05-19 4:45 ` Parav Pandit
@ 2015-05-19 17:00 ` Ben Hutchings
2015-05-19 18:52 ` David Miller
1 sibling, 1 reply; 8+ messages in thread
From: Ben Hutchings @ 2015-05-19 17:00 UTC (permalink / raw)
To: David Miller; +Cc: parav.pandit, netdev, bwh
[-- Attachment #1: Type: text/plain, Size: 671 bytes --]
On Mon, 2015-05-18 at 11:46 -0400, David Miller wrote:
> From: Parav Pandit <parav.pandit@avagotech.com>
> Date: Mon, 18 May 2015 16:31:47 +0530
>
> > Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
>
> I thought we had decided that we weren't going to keep adding
> convenience macros for new speeds, and were simply going to use
> the appropriate constants in the future.
>
> Ben?
That's what I thought, but you accepted commit dcf972a334dd "ethtool,
net/mlx4_en: Add 100M, 20G, 56G speeds ethtool reporting support" not so
long ago.
Ben.
--
Ben Hutchings
I'm not a reverse psychological virus. Please don't copy me into your sig.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 811 bytes --]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-19 17:00 ` Ben Hutchings
@ 2015-05-19 18:52 ` David Miller
2015-05-19 20:32 ` David Miller
0 siblings, 1 reply; 8+ messages in thread
From: David Miller @ 2015-05-19 18:52 UTC (permalink / raw)
To: ben; +Cc: parav.pandit, netdev, bwh
From: Ben Hutchings <ben@decadent.org.uk>
Date: Tue, 19 May 2015 18:00:35 +0100
> On Mon, 2015-05-18 at 11:46 -0400, David Miller wrote:
>> From: Parav Pandit <parav.pandit@avagotech.com>
>> Date: Mon, 18 May 2015 16:31:47 +0530
>>
>> > Signed-off-by: Parav Pandit <parav.pandit@avagotech.com>
>>
>> I thought we had decided that we weren't going to keep adding
>> convenience macros for new speeds, and were simply going to use
>> the appropriate constants in the future.
>>
>> Ben?
>
> That's what I thought, but you accepted commit dcf972a334dd "ethtool,
> net/mlx4_en: Add 100M, 20G, 56G speeds ethtool reporting support" not so
> long ago.
Grumble... my bad.
Given that I should probably accept this patch set as well, hopefully
we won't get very many more of these any time soon.
Sorry for creating this mess.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] net-next: ethtool: Added port speed macros.
2015-05-19 18:52 ` David Miller
@ 2015-05-19 20:32 ` David Miller
0 siblings, 0 replies; 8+ messages in thread
From: David Miller @ 2015-05-19 20:32 UTC (permalink / raw)
To: ben; +Cc: parav.pandit, netdev, bwh
From: David Miller <davem@davemloft.net>
Date: Tue, 19 May 2015 14:52:02 -0400 (EDT)
> Given that I should probably accept this patch set as well, hopefully
> we won't get very many more of these any time soon.
And that's what I've just done.
Applied to net-next, thanks.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2015-05-19 20:32 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-18 11:01 [PATCH] net-next: ethtool: Added port speed macros Parav Pandit
2015-05-18 15:46 ` David Miller
2015-05-19 4:45 ` Parav Pandit
2015-05-19 16:32 ` David Miller
2015-05-19 16:41 ` Parav Pandit
2015-05-19 17:00 ` Ben Hutchings
2015-05-19 18:52 ` David Miller
2015-05-19 20:32 ` 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.