* [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps
@ 2020-09-28 14:44 Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 2/3] update UAPI header copies Dan Murphy
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Dan Murphy @ 2020-09-28 14:44 UTC (permalink / raw)
To: mkubecek; +Cc: netdev, Dan Murphy
Commit 63130d0b00040 ("update link mode tables") missed adding in the
400000base link_caps to the array.
Signed-off-by: Dan Murphy <dmurphy@ti.com>
---
ethtool.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/ethtool.c b/ethtool.c
index 4f93c0f96985..974b14063de2 100644
--- a/ethtool.c
+++ b/ethtool.c
@@ -659,6 +659,16 @@ static void dump_link_caps(const char *prefix, const char *an_prefix,
"200000baseDR4/Full" },
{ 0, ETHTOOL_LINK_MODE_200000baseCR4_Full_BIT,
"200000baseCR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_400000baseKR4_Full_BIT,
+ "400000baseKR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_400000baseSR4_Full_BIT,
+ "400000baseSR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_400000baseLR4_ER4_FR4_Full_BIT,
+ "400000baseLR4_ER4_FR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_400000baseDR4_Full_BIT,
+ "400000baseDR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT,
+ "400000baseCR4/Full" },
};
int indent;
int did1, new_line_pend;
--
2.28.0.585.ge1cfff676549
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH ethtool v3 2/3] update UAPI header copies
2020-09-28 14:44 [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Dan Murphy
@ 2020-09-28 14:44 ` Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 3/3] Update link mode tables for fiber Dan Murphy
2020-09-28 16:37 ` [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Michal Kubecek
2 siblings, 0 replies; 6+ messages in thread
From: Dan Murphy @ 2020-09-28 14:44 UTC (permalink / raw)
To: mkubecek; +Cc: netdev, Dan Murphy
Update to kernel commit 55f13311785c
Signed-off-by: Dan Murphy <dmurphy@ti.com>
---
uapi/linux/ethtool.h | 2 ++
uapi/linux/ethtool_netlink.h | 19 ++++++++++++++++++-
2 files changed, 20 insertions(+), 1 deletion(-)
diff --git a/uapi/linux/ethtool.h b/uapi/linux/ethtool.h
index 847ccd0b1fce..052689bcc90c 100644
--- a/uapi/linux/ethtool.h
+++ b/uapi/linux/ethtool.h
@@ -1615,6 +1615,8 @@ enum ethtool_link_mode_bit_indices {
ETHTOOL_LINK_MODE_400000baseLR4_ER4_FR4_Full_BIT = 87,
ETHTOOL_LINK_MODE_400000baseDR4_Full_BIT = 88,
ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT = 89,
+ ETHTOOL_LINK_MODE_100baseFX_Half_BIT = 90,
+ ETHTOOL_LINK_MODE_100baseFX_Full_BIT = 91,
/* must be last entry */
__ETHTOOL_LINK_MODE_MASK_NBITS
};
diff --git a/uapi/linux/ethtool_netlink.h b/uapi/linux/ethtool_netlink.h
index cebdb52e6a05..c022883cdb22 100644
--- a/uapi/linux/ethtool_netlink.h
+++ b/uapi/linux/ethtool_netlink.h
@@ -79,6 +79,7 @@ enum {
ETHTOOL_MSG_TSINFO_GET_REPLY,
ETHTOOL_MSG_CABLE_TEST_NTF,
ETHTOOL_MSG_CABLE_TEST_TDR_NTF,
+ ETHTOOL_MSG_TUNNEL_INFO_GET_REPLY,
/* add new constants above here */
__ETHTOOL_MSG_KERNEL_CNT,
@@ -91,9 +92,12 @@ enum {
#define ETHTOOL_FLAG_COMPACT_BITSETS (1 << 0)
/* provide optional reply for SET or ACT requests */
#define ETHTOOL_FLAG_OMIT_REPLY (1 << 1)
+/* request statistics, if supported by the driver */
+#define ETHTOOL_FLAG_STATS (1 << 2)
#define ETHTOOL_FLAG_ALL (ETHTOOL_FLAG_COMPACT_BITSETS | \
- ETHTOOL_FLAG_OMIT_REPLY)
+ ETHTOOL_FLAG_OMIT_REPLY | \
+ ETHTOOL_FLAG_STATS)
enum {
ETHTOOL_A_HEADER_UNSPEC,
@@ -376,12 +380,25 @@ enum {
ETHTOOL_A_PAUSE_AUTONEG, /* u8 */
ETHTOOL_A_PAUSE_RX, /* u8 */
ETHTOOL_A_PAUSE_TX, /* u8 */
+ ETHTOOL_A_PAUSE_STATS, /* nest - _PAUSE_STAT_* */
/* add new constants above here */
__ETHTOOL_A_PAUSE_CNT,
ETHTOOL_A_PAUSE_MAX = (__ETHTOOL_A_PAUSE_CNT - 1)
};
+enum {
+ ETHTOOL_A_PAUSE_STAT_UNSPEC,
+ ETHTOOL_A_PAUSE_STAT_PAD,
+
+ ETHTOOL_A_PAUSE_STAT_TX_FRAMES,
+ ETHTOOL_A_PAUSE_STAT_RX_FRAMES,
+
+ /* add new constants above here */
+ __ETHTOOL_A_PAUSE_STAT_CNT,
+ ETHTOOL_A_PAUSE_STAT_MAX = (__ETHTOOL_A_PAUSE_STAT_CNT - 1)
+};
+
/* EEE */
enum {
--
2.28.0.585.ge1cfff676549
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH ethtool v3 3/3] Update link mode tables for fiber
2020-09-28 14:44 [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 2/3] update UAPI header copies Dan Murphy
@ 2020-09-28 14:44 ` Dan Murphy
2020-09-28 16:37 ` [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Michal Kubecek
2 siblings, 0 replies; 6+ messages in thread
From: Dan Murphy @ 2020-09-28 14:44 UTC (permalink / raw)
To: mkubecek; +Cc: netdev, Dan Murphy
Update the link mode tables to include 100base Fx Full and Half duplex
modes.
Signed-off-by: Dan Murphy <dmurphy@ti.com>
---
ethtool.8.in | 2 ++
ethtool.c | 6 ++++++
netlink/settings.c | 2 ++
3 files changed, 10 insertions(+)
diff --git a/ethtool.8.in b/ethtool.8.in
index d0921949b37e..7c6e23e28ffa 100644
--- a/ethtool.8.in
+++ b/ethtool.8.in
@@ -794,6 +794,8 @@ lB l lB.
0x8000000000000000000000 400000baseLR4_ER4_FR4 Full
0x10000000000000000000000 400000baseDR4 Full
0x20000000000000000000000 400000baseCR4 Full
+0x40000000000000000000000 100baseFX Half
+0x80000000000000000000000 100baseFX Full
.TE
.TP
.BI phyad \ N
diff --git a/ethtool.c b/ethtool.c
index 974b14063de2..39a1862a72a4 100644
--- a/ethtool.c
+++ b/ethtool.c
@@ -463,6 +463,8 @@ static void init_global_link_mode_masks(void)
ETHTOOL_LINK_MODE_400000baseLR4_ER4_FR4_Full_BIT,
ETHTOOL_LINK_MODE_400000baseDR4_Full_BIT,
ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT,
+ ETHTOOL_LINK_MODE_100baseFX_Half_BIT,
+ ETHTOOL_LINK_MODE_100baseFX_Full_BIT,
};
static const enum ethtool_link_mode_bit_indices
additional_advertised_flags_bits[] = {
@@ -669,6 +671,10 @@ static void dump_link_caps(const char *prefix, const char *an_prefix,
"400000baseDR4/Full" },
{ 0, ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT,
"400000baseCR4/Full" },
+ { 0, ETHTOOL_LINK_MODE_100baseFX_Half_BIT,
+ "100baseFx/Half" },
+ { 1, ETHTOOL_LINK_MODE_100baseFX_Full_BIT,
+ "100baseFx/Full" },
};
int indent;
int did1, new_line_pend;
diff --git a/netlink/settings.c b/netlink/settings.c
index 3059d4d0d0b7..41a2e5af1945 100644
--- a/netlink/settings.c
+++ b/netlink/settings.c
@@ -162,6 +162,8 @@ static const struct link_mode_info link_modes[] = {
[ETHTOOL_LINK_MODE_400000baseLR4_ER4_FR4_Full_BIT] = __REAL(400000),
[ETHTOOL_LINK_MODE_400000baseDR4_Full_BIT] = __REAL(400000),
[ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT] = __REAL(400000),
+ [ETHTOOL_LINK_MODE_100baseFX_Half_BIT] = __HALF_DUPLEX(100),
+ [ETHTOOL_LINK_MODE_100baseFX_Full_BIT] = __REAL(100),
};
const unsigned int link_modes_count = ARRAY_SIZE(link_modes);
--
2.28.0.585.ge1cfff676549
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps
2020-09-28 14:44 [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 2/3] update UAPI header copies Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 3/3] Update link mode tables for fiber Dan Murphy
@ 2020-09-28 16:37 ` Michal Kubecek
2020-09-28 16:43 ` Dan Murphy
2 siblings, 1 reply; 6+ messages in thread
From: Michal Kubecek @ 2020-09-28 16:37 UTC (permalink / raw)
To: Dan Murphy; +Cc: netdev
[-- Attachment #1: Type: text/plain, Size: 1319 bytes --]
On Mon, Sep 28, 2020 at 09:44:01AM -0500, Dan Murphy wrote:
> Commit 63130d0b00040 ("update link mode tables") missed adding in the
> 400000base link_caps to the array.
>
> Signed-off-by: Dan Murphy <dmurphy@ti.com>
> ---
I'm sorry, I only found these patches shortly after I pushed similar
update as I needed updated UAPI headers for new format descriptions.
Michal
> ethtool.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/ethtool.c b/ethtool.c
> index 4f93c0f96985..974b14063de2 100644
> --- a/ethtool.c
> +++ b/ethtool.c
> @@ -659,6 +659,16 @@ static void dump_link_caps(const char *prefix, const char *an_prefix,
> "200000baseDR4/Full" },
> { 0, ETHTOOL_LINK_MODE_200000baseCR4_Full_BIT,
> "200000baseCR4/Full" },
> + { 0, ETHTOOL_LINK_MODE_400000baseKR4_Full_BIT,
> + "400000baseKR4/Full" },
> + { 0, ETHTOOL_LINK_MODE_400000baseSR4_Full_BIT,
> + "400000baseSR4/Full" },
> + { 0, ETHTOOL_LINK_MODE_400000baseLR4_ER4_FR4_Full_BIT,
> + "400000baseLR4_ER4_FR4/Full" },
> + { 0, ETHTOOL_LINK_MODE_400000baseDR4_Full_BIT,
> + "400000baseDR4/Full" },
> + { 0, ETHTOOL_LINK_MODE_400000baseCR4_Full_BIT,
> + "400000baseCR4/Full" },
> };
> int indent;
> int did1, new_line_pend;
> --
> 2.28.0.585.ge1cfff676549
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps
2020-09-28 16:37 ` [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Michal Kubecek
@ 2020-09-28 16:43 ` Dan Murphy
2020-09-28 16:52 ` Michal Kubecek
0 siblings, 1 reply; 6+ messages in thread
From: Dan Murphy @ 2020-09-28 16:43 UTC (permalink / raw)
To: Michal Kubecek; +Cc: netdev
Michal
On 9/28/20 11:37 AM, Michal Kubecek wrote:
> On Mon, Sep 28, 2020 at 09:44:01AM -0500, Dan Murphy wrote:
>> Commit 63130d0b00040 ("update link mode tables") missed adding in the
>> 400000base link_caps to the array.
>>
>> Signed-off-by: Dan Murphy <dmurphy@ti.com>
>> ---
> I'm sorry, I only found these patches shortly after I pushed similar
> update as I needed updated UAPI headers for new format descriptions.
Is there an action I need to take here?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps
2020-09-28 16:43 ` Dan Murphy
@ 2020-09-28 16:52 ` Michal Kubecek
0 siblings, 0 replies; 6+ messages in thread
From: Michal Kubecek @ 2020-09-28 16:52 UTC (permalink / raw)
To: Dan Murphy; +Cc: netdev
On Mon, Sep 28, 2020 at 11:43:59AM -0500, Dan Murphy wrote:
> Michal
>
> On 9/28/20 11:37 AM, Michal Kubecek wrote:
> > On Mon, Sep 28, 2020 at 09:44:01AM -0500, Dan Murphy wrote:
> > > Commit 63130d0b00040 ("update link mode tables") missed adding in the
> > > 400000base link_caps to the array.
> > >
> > > Signed-off-by: Dan Murphy <dmurphy@ti.com>
> > > ---
> > I'm sorry, I only found these patches shortly after I pushed similar
> > update as I needed updated UAPI headers for new format descriptions.
>
> Is there an action I need to take here?
I don't think so, I believe I have everything that was in your patches
(with minor diffrences) but you may want to check.
Michal
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2020-09-28 16:52 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-28 14:44 [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 2/3] update UAPI header copies Dan Murphy
2020-09-28 14:44 ` [PATCH ethtool v3 3/3] Update link mode tables for fiber Dan Murphy
2020-09-28 16:37 ` [PATCH ethtool v3 1/3] Add missing 400000base modes for dump_link_caps Michal Kubecek
2020-09-28 16:43 ` Dan Murphy
2020-09-28 16:52 ` Michal Kubecek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).