All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable
@ 2022-11-01  6:03 Cai Huoqing
  2022-11-01  6:03 ` [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK Cai Huoqing
  2022-11-03  3:36 ` [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Jakub Kicinski
  0 siblings, 2 replies; 9+ messages in thread
From: Cai Huoqing @ 2022-11-01  6:03 UTC (permalink / raw)
  To: kuba
  Cc: Cai Huoqing, David S. Miller, Eric Dumazet, Paolo Abeni,
	Zhengchao Shao, Alexei Starovoitov, SeongJae Park, Peter Chen,
	Bin Chen, netdev, linux-kernel

The print cmd code is in hex, so using hex cmd code intead of
decimal is easy to check the value with print info.

Signed-off-by: Cai Huoqing <cai.huoqing@linux.dev>
---
v1->v2:
	1.Add net-next prefix.
	The comments link: https://lore.kernel.org/lkml/20221027110241.0340abdf@kernel.org/

 .../net/ethernet/huawei/hinic/hinic_hw_dev.h  | 108 +++++++++---------
 1 file changed, 52 insertions(+), 56 deletions(-)

diff --git a/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h b/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
index d2d89b0a5ef0..abffd967a791 100644
--- a/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
+++ b/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
@@ -46,104 +46,100 @@ enum hinic_port_cmd {
 	HINIC_PORT_CMD_VF_REGISTER = 0x0,
 	HINIC_PORT_CMD_VF_UNREGISTER = 0x1,
 
-	HINIC_PORT_CMD_CHANGE_MTU       = 2,
+	HINIC_PORT_CMD_CHANGE_MTU = 0x2,
 
-	HINIC_PORT_CMD_ADD_VLAN         = 3,
-	HINIC_PORT_CMD_DEL_VLAN         = 4,
+	HINIC_PORT_CMD_ADD_VLAN = 0x3,
+	HINIC_PORT_CMD_DEL_VLAN = 0x4,
 
-	HINIC_PORT_CMD_SET_PFC		= 5,
+	HINIC_PORT_CMD_SET_PFC = 0x5,
 
-	HINIC_PORT_CMD_SET_MAC          = 9,
-	HINIC_PORT_CMD_GET_MAC          = 10,
-	HINIC_PORT_CMD_DEL_MAC          = 11,
+	HINIC_PORT_CMD_SET_MAC = 0x9,
+	HINIC_PORT_CMD_GET_MAC = 0xA,
+	HINIC_PORT_CMD_DEL_MAC = 0xB,
 
-	HINIC_PORT_CMD_SET_RX_MODE      = 12,
+	HINIC_PORT_CMD_SET_RX_MODE = 0xC,
 
-	HINIC_PORT_CMD_GET_PAUSE_INFO	= 20,
-	HINIC_PORT_CMD_SET_PAUSE_INFO	= 21,
+	HINIC_PORT_CMD_GET_PAUSE_INFO = 0x14,
+	HINIC_PORT_CMD_SET_PAUSE_INFO = 0x15,
 
-	HINIC_PORT_CMD_GET_LINK_STATE   = 24,
+	HINIC_PORT_CMD_GET_LINK_STATE = 0x18,
 
-	HINIC_PORT_CMD_SET_LRO		= 25,
+	HINIC_PORT_CMD_SET_LRO = 0x19,
 
-	HINIC_PORT_CMD_SET_RX_CSUM	= 26,
+	HINIC_PORT_CMD_SET_RX_CSUM = 0x1A,
 
-	HINIC_PORT_CMD_SET_RX_VLAN_OFFLOAD = 27,
+	HINIC_PORT_CMD_SET_RX_VLAN_OFFLOAD = 0x1B,
 
-	HINIC_PORT_CMD_GET_PORT_STATISTICS = 28,
+	HINIC_PORT_CMD_GET_PORT_STATISTICS = 0x1C,
 
-	HINIC_PORT_CMD_CLEAR_PORT_STATISTICS = 29,
+	HINIC_PORT_CMD_CLEAR_PORT_STATISTICS = 0x1D,
 
-	HINIC_PORT_CMD_GET_VPORT_STAT	= 30,
+	HINIC_PORT_CMD_GET_VPORT_STAT = 0x1E,
 
-	HINIC_PORT_CMD_CLEAN_VPORT_STAT	= 31,
+	HINIC_PORT_CMD_CLEAN_VPORT_STAT	= 0x1F,
 
-	HINIC_PORT_CMD_GET_RSS_TEMPLATE_INDIR_TBL = 37,
+	HINIC_PORT_CMD_GET_RSS_TEMPLATE_INDIR_TBL = 0x25,
 
-	HINIC_PORT_CMD_SET_PORT_STATE   = 41,
+	HINIC_PORT_CMD_SET_PORT_STATE = 0x29,
 
-	HINIC_PORT_CMD_SET_RSS_TEMPLATE_TBL = 43,
+	HINIC_PORT_CMD_SET_RSS_TEMPLATE_TBL = 0x2B,
+	HINIC_PORT_CMD_GET_RSS_TEMPLATE_TBL = 0x2C,
 
-	HINIC_PORT_CMD_GET_RSS_TEMPLATE_TBL = 44,
+	HINIC_PORT_CMD_SET_RSS_HASH_ENGINE = 0x2D,
+	HINIC_PORT_CMD_GET_RSS_HASH_ENGINE = 0x2E,
 
-	HINIC_PORT_CMD_SET_RSS_HASH_ENGINE = 45,
+	HINIC_PORT_CMD_GET_RSS_CTX_TBL = 0x2F,
+	HINIC_PORT_CMD_SET_RSS_CTX_TBL = 0x30,
 
-	HINIC_PORT_CMD_GET_RSS_HASH_ENGINE = 46,
+	HINIC_PORT_CMD_RSS_TEMP_MGR	= 0x31,
 
-	HINIC_PORT_CMD_GET_RSS_CTX_TBL  = 47,
+	HINIC_PORT_CMD_RD_LINE_TBL = 0x39,
 
-	HINIC_PORT_CMD_SET_RSS_CTX_TBL  = 48,
+	HINIC_PORT_CMD_RSS_CFG = 0x42,
 
-	HINIC_PORT_CMD_RSS_TEMP_MGR	= 49,
+	HINIC_PORT_CMD_FWCTXT_INIT = 0x45,
 
-	HINIC_PORT_CMD_RD_LINE_TBL	= 57,
+	HINIC_PORT_CMD_GET_LOOPBACK_MODE = 0x48,
+	HINIC_PORT_CMD_SET_LOOPBACK_MODE = 0x49,
 
-	HINIC_PORT_CMD_RSS_CFG		= 66,
+	HINIC_PORT_CMD_ENABLE_SPOOFCHK = 0x4E,
 
-	HINIC_PORT_CMD_FWCTXT_INIT      = 69,
+	HINIC_PORT_CMD_GET_MGMT_VERSION = 0x58,
 
-	HINIC_PORT_CMD_GET_LOOPBACK_MODE = 72,
-	HINIC_PORT_CMD_SET_LOOPBACK_MODE,
+	HINIC_PORT_CMD_SET_FUNC_STATE = 0x5D,
 
-	HINIC_PORT_CMD_ENABLE_SPOOFCHK = 78,
+	HINIC_PORT_CMD_GET_GLOBAL_QPN = 0x66,
 
-	HINIC_PORT_CMD_GET_MGMT_VERSION = 88,
+	HINIC_PORT_CMD_SET_VF_RATE = 0x69,
 
-	HINIC_PORT_CMD_SET_FUNC_STATE   = 93,
+	HINIC_PORT_CMD_SET_VF_VLAN = 0x6A,
+	HINIC_PORT_CMD_CLR_VF_VLAN = 0x6B,
 
-	HINIC_PORT_CMD_GET_GLOBAL_QPN   = 102,
+	HINIC_PORT_CMD_SET_TSO = 0x70,
 
-	HINIC_PORT_CMD_SET_VF_RATE = 105,
+	HINIC_PORT_CMD_UPDATE_FW = 0x72,
 
-	HINIC_PORT_CMD_SET_VF_VLAN	= 106,
+	HINIC_PORT_CMD_SET_RQ_IQ_MAP = 0x73,
 
-	HINIC_PORT_CMD_CLR_VF_VLAN,
+	HINIC_PORT_CMD_LINK_STATUS_REPORT = 0xA0,
 
-	HINIC_PORT_CMD_SET_TSO          = 112,
+	HINIC_PORT_CMD_UPDATE_MAC = 0xA4,
 
-	HINIC_PORT_CMD_UPDATE_FW	= 114,
+	HINIC_PORT_CMD_GET_CAP = 0xAA,
 
-	HINIC_PORT_CMD_SET_RQ_IQ_MAP	= 115,
+	HINIC_PORT_CMD_GET_LINK_MODE = 0xD9,
 
-	HINIC_PORT_CMD_LINK_STATUS_REPORT = 160,
+	HINIC_PORT_CMD_SET_SPEED = 0xDA,
 
-	HINIC_PORT_CMD_UPDATE_MAC = 164,
+	HINIC_PORT_CMD_SET_AUTONEG = 0xDB,
 
-	HINIC_PORT_CMD_GET_CAP          = 170,
+	HINIC_PORT_CMD_GET_STD_SFP_INFO = 0xF0,
 
-	HINIC_PORT_CMD_GET_LINK_MODE	= 217,
+	HINIC_PORT_CMD_SET_LRO_TIMER = 0xF4,
 
-	HINIC_PORT_CMD_SET_SPEED	= 218,
+	HINIC_PORT_CMD_SET_VF_MAX_MIN_RATE = 0xF9,
 
-	HINIC_PORT_CMD_SET_AUTONEG	= 219,
-
-	HINIC_PORT_CMD_GET_STD_SFP_INFO = 240,
-
-	HINIC_PORT_CMD_SET_LRO_TIMER	= 244,
-
-	HINIC_PORT_CMD_SET_VF_MAX_MIN_RATE = 249,
-
-	HINIC_PORT_CMD_GET_SFP_ABS	= 251,
+	HINIC_PORT_CMD_GET_SFP_ABS = 0xFB,
 };
 
 /* cmd of mgmt CPU message for HILINK module */
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01  6:03 [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Cai Huoqing
@ 2022-11-01  6:03 ` Cai Huoqing
  2022-11-01 10:46   ` Jani Nikula
  2022-11-03  3:36 ` [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Jakub Kicinski
  1 sibling, 1 reply; 9+ messages in thread
From: Cai Huoqing @ 2022-11-01  6:03 UTC (permalink / raw)
  To: kuba
  Cc: Cai Huoqing, David S. Miller, Eric Dumazet, Paolo Abeni,
	Zhengchao Shao, Jani Nikula, SeongJae Park, Bin Chen, netdev,
	linux-kernel

HINIC has a mailbox for PF-VF communication and the VF driver
could send port control command to PF driver via mailbox.

The control command only can be set to register in PF,
so add support in PF driver for VF PMD driver control
command when VF PMD driver work with linux PF driver.

Then there is no need to add handlers to nic_vf_cmd_msg_handler[],
because the host driver just forwards it to the firmware.
Actually the firmware works on a coprocessor MGMT_CPU(inside the NIC)
which will recv and deal with these commands.

Signed-off-by: Cai Huoqing <cai.huoqing@linux.dev>
---
v1->v2:
	1.Update the commit messsage.
	2.Add net-next prefix.
	The comments link: https://lore.kernel.org/lkml/20221031195805.74e22089@kernel.org/

 .../net/ethernet/huawei/hinic/hinic_hw_dev.h  | 64 +++++++++++++++++++
 .../net/ethernet/huawei/hinic/hinic_sriov.c   | 18 ++++++
 2 files changed, 82 insertions(+)

diff --git a/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h b/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
index abffd967a791..4f561e4e849a 100644
--- a/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
+++ b/drivers/net/ethernet/huawei/hinic/hinic_hw_dev.h
@@ -53,11 +53,15 @@ enum hinic_port_cmd {
 
 	HINIC_PORT_CMD_SET_PFC = 0x5,
 
+	HINIC_PORT_CMD_SET_ETS = 0x7,
+	HINIC_PORT_CMD_GET_ETS = 0x8,
+
 	HINIC_PORT_CMD_SET_MAC = 0x9,
 	HINIC_PORT_CMD_GET_MAC = 0xA,
 	HINIC_PORT_CMD_DEL_MAC = 0xB,
 
 	HINIC_PORT_CMD_SET_RX_MODE = 0xC,
+	HINIC_PORT_CMD_SET_ANTI_ATTACK_RATE = 0xD,
 
 	HINIC_PORT_CMD_GET_PAUSE_INFO = 0x14,
 	HINIC_PORT_CMD_SET_PAUSE_INFO = 0x15,
@@ -81,6 +85,7 @@ enum hinic_port_cmd {
 	HINIC_PORT_CMD_GET_RSS_TEMPLATE_INDIR_TBL = 0x25,
 
 	HINIC_PORT_CMD_SET_PORT_STATE = 0x29,
+	HINIC_PORT_CMD_GET_PORT_STATE = 0x30,
 
 	HINIC_PORT_CMD_SET_RSS_TEMPLATE_TBL = 0x2B,
 	HINIC_PORT_CMD_GET_RSS_TEMPLATE_TBL = 0x2C,
@@ -97,17 +102,29 @@ enum hinic_port_cmd {
 
 	HINIC_PORT_CMD_RSS_CFG = 0x42,
 
+	HINIC_PORT_CMD_GET_PHY_TYPE = 0x44,
+
 	HINIC_PORT_CMD_FWCTXT_INIT = 0x45,
 
 	HINIC_PORT_CMD_GET_LOOPBACK_MODE = 0x48,
 	HINIC_PORT_CMD_SET_LOOPBACK_MODE = 0x49,
 
+	HINIC_PORT_CMD_GET_JUMBO_FRAME_SIZE = 0x4A,
+	HINIC_PORT_CMD_SET_JUMBO_FRAME_SIZE = 0x4B,
+
 	HINIC_PORT_CMD_ENABLE_SPOOFCHK = 0x4E,
 
 	HINIC_PORT_CMD_GET_MGMT_VERSION = 0x58,
 
+	HINIC_PORT_CMD_GET_PORT_TYPE = 0x5B,
+
 	HINIC_PORT_CMD_SET_FUNC_STATE = 0x5D,
 
+	HINIC_PORT_CMD_GET_PORT_ID_BY_FUNC_ID = 0x5E,
+
+	HINIC_PORT_CMD_GET_DMA_CS = 0x64,
+	HINIC_PORT_CMD_SET_DMA_CS = 0x65,
+
 	HINIC_PORT_CMD_GET_GLOBAL_QPN = 0x66,
 
 	HINIC_PORT_CMD_SET_VF_RATE = 0x69,
@@ -121,25 +138,72 @@ enum hinic_port_cmd {
 
 	HINIC_PORT_CMD_SET_RQ_IQ_MAP = 0x73,
 
+	HINIC_PORT_CMD_SET_PFC_THD = 0x75,
+
 	HINIC_PORT_CMD_LINK_STATUS_REPORT = 0xA0,
 
+	HINIC_PORT_CMD_SET_LOSSLESS_ETH	= 0xA3,
+
 	HINIC_PORT_CMD_UPDATE_MAC = 0xA4,
 
 	HINIC_PORT_CMD_GET_CAP = 0xAA,
 
+	HINIC_PORT_CMD_UP_TC_ADD_FLOW = 0xAF,
+	HINIC_PORT_CMD_UP_TC_DEL_FLOW = 0xB0,
+	HINIC_PORT_CMD_UP_TC_GET_FLOW = 0xB1,
+
+	HINIC_PORT_CMD_UP_TC_FLUSH_TCAM = 0xB2,
+
+	HINIC_PORT_CMD_UP_TC_CTRL_TCAM_BLOCK = 0xB3,
+
+	HINIC_PORT_CMD_UP_TC_ENABLE = 0xB4,
+
+	HINIC_PORT_CMD_UP_TC_GET_TCAM_BLOCK = 0xB5,
+
+	HINIC_PORT_CMD_SET_IPSU_MAC = 0xCB,
+	HINIC_PORT_CMD_GET_IPSU_MAC = 0xCC,
+
+	HINIC_PORT_CMD_SET_XSFP_STATUS = 0xD4,
 	HINIC_PORT_CMD_GET_LINK_MODE = 0xD9,
 
 	HINIC_PORT_CMD_SET_SPEED = 0xDA,
 
 	HINIC_PORT_CMD_SET_AUTONEG = 0xDB,
 
+	HINIC_PORT_CMD_CLEAR_QP_RES = 0xDD,
+
+	HINIC_PORT_CMD_SET_SUPER_CQE = 0xDE,
+
+	HINIC_PORT_CMD_SET_VF_COS = 0xDF,
+	HINIC_PORT_CMD_GET_VF_COS = 0xE1,
+
+	HINIC_PORT_CMD_CABLE_PLUG_EVENT	= 0xE5,
+
+	HINIC_PORT_CMD_LINK_ERR_EVENT = 0xE6,
+
+	HINIC_PORT_CMD_SET_COS_UP_MAP = 0xE8,
+
+	HINIC_PORT_CMD_RESET_LINK_CFG = 0xEB,
+
 	HINIC_PORT_CMD_GET_STD_SFP_INFO = 0xF0,
 
+	HINIC_PORT_CMD_FORCE_PKT_DROP = 0xF3,
+
 	HINIC_PORT_CMD_SET_LRO_TIMER = 0xF4,
 
+	HINIC_PORT_CMD_SET_VHD_CFG = 0xF7,
+
+	HINIC_PORT_CMD_SET_LINK_FOLLOW = 0xF8,
+
 	HINIC_PORT_CMD_SET_VF_MAX_MIN_RATE = 0xF9,
 
 	HINIC_PORT_CMD_GET_SFP_ABS = 0xFB,
+
+	HINIC_PORT_CMD_Q_FILTER	= 0xFC,
+
+	HINIC_PORT_CMD_TCAM_FILTER = 0xFE,
+
+	HINIC_PORT_CMD_SET_VLAN_FILTER = 0xFF
 };
 
 /* cmd of mgmt CPU message for HILINK module */
diff --git a/drivers/net/ethernet/huawei/hinic/hinic_sriov.c b/drivers/net/ethernet/huawei/hinic/hinic_sriov.c
index a5f08b969e3f..bba41994dee6 100644
--- a/drivers/net/ethernet/huawei/hinic/hinic_sriov.c
+++ b/drivers/net/ethernet/huawei/hinic/hinic_sriov.c
@@ -489,6 +489,24 @@ static struct vf_cmd_check_handle nic_cmd_support_vf[] = {
 	{HINIC_PORT_CMD_UPDATE_MAC, hinic_mbox_check_func_id_8B},
 	{HINIC_PORT_CMD_GET_CAP, hinic_mbox_check_func_id_8B},
 	{HINIC_PORT_CMD_GET_LINK_MODE, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_GET_VF_COS, NULL},
+	{HINIC_PORT_CMD_SET_VHD_CFG, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_SET_VLAN_FILTER, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_Q_FILTER, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_TCAM_FILTER, NULL},
+	{HINIC_PORT_CMD_UP_TC_ADD_FLOW, NULL},
+	{HINIC_PORT_CMD_UP_TC_DEL_FLOW, NULL},
+	{HINIC_PORT_CMD_UP_TC_FLUSH_TCAM, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_UP_TC_CTRL_TCAM_BLOCK, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_UP_TC_ENABLE, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_CABLE_PLUG_EVENT, NULL},
+	{HINIC_PORT_CMD_LINK_ERR_EVENT, NULL},
+	{HINIC_PORT_CMD_SET_PORT_STATE, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_SET_ETS, NULL},
+	{HINIC_PORT_CMD_SET_ANTI_ATTACK_RATE, NULL},
+	{HINIC_PORT_CMD_RESET_LINK_CFG, hinic_mbox_check_func_id_8B},
+	{HINIC_PORT_CMD_SET_LINK_FOLLOW, NULL},
+	{HINIC_PORT_CMD_CLEAR_QP_RES, NULL},
 };
 
 #define CHECK_IPSU_15BIT	0X8000
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01  6:03 ` [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK Cai Huoqing
@ 2022-11-01 10:46   ` Jani Nikula
  2022-11-01 12:17     ` Cai Huoqing
  0 siblings, 1 reply; 9+ messages in thread
From: Jani Nikula @ 2022-11-01 10:46 UTC (permalink / raw)
  To: Cai Huoqing, kuba
  Cc: Cai Huoqing, David S. Miller, Eric Dumazet, Paolo Abeni,
	Zhengchao Shao, SeongJae Park, Bin Chen, netdev, linux-kernel

On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
> HINIC has a mailbox for PF-VF communication and the VF driver
> could send port control command to PF driver via mailbox.
>
> The control command only can be set to register in PF,
> so add support in PF driver for VF PMD driver control
> command when VF PMD driver work with linux PF driver.
>
> Then there is no need to add handlers to nic_vf_cmd_msg_handler[],
> because the host driver just forwards it to the firmware.
> Actually the firmware works on a coprocessor MGMT_CPU(inside the NIC)
> which will recv and deal with these commands.
>
> Signed-off-by: Cai Huoqing <cai.huoqing@linux.dev>

Out of curiosity, what exactly compelled you to Cc me on this particular
patch? I mean there aren't a whole lot of places in the kernel that
would be more off-topic for me. :)

BR,
Jani.


-- 
Jani Nikula, Intel Open Source Graphics Center

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01 10:46   ` Jani Nikula
@ 2022-11-01 12:17     ` Cai Huoqing
  2022-11-01 12:37       ` Jani Nikula
  0 siblings, 1 reply; 9+ messages in thread
From: Cai Huoqing @ 2022-11-01 12:17 UTC (permalink / raw)
  To: Jani Nikula
  Cc: kuba, David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	SeongJae Park, Bin Chen, netdev, linux-kernel

On 01 11月 22 12:46:32, Jani Nikula wrote:
> On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
> > HINIC has a mailbox for PF-VF communication and the VF driver
> > could send port control command to PF driver via mailbox.
> >
> > The control command only can be set to register in PF,
> > so add support in PF driver for VF PMD driver control
> > command when VF PMD driver work with linux PF driver.
> >
> > Then there is no need to add handlers to nic_vf_cmd_msg_handler[],
> > because the host driver just forwards it to the firmware.
> > Actually the firmware works on a coprocessor MGMT_CPU(inside the NIC)
> > which will recv and deal with these commands.
> >
> > Signed-off-by: Cai Huoqing <cai.huoqing@linux.dev>
> 
> Out of curiosity, what exactly compelled you to Cc me on this particular
> patch? I mean there aren't a whole lot of places in the kernel that
> would be more off-topic for me. :)
run ./scripts/get_maintainer.pl this patch in net-next
then get your email
Jani Nikula <jani.nikula@intel.com> (commit_signer:1/8=12%)
Maybe you have some commits in net subsystem ?
> 
> BR,
> Jani.
> 
> 
> -- 
> Jani Nikula, Intel Open Source Graphics Center

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01 12:17     ` Cai Huoqing
@ 2022-11-01 12:37       ` Jani Nikula
  2022-11-01 15:37         ` Jakub Kicinski
  0 siblings, 1 reply; 9+ messages in thread
From: Jani Nikula @ 2022-11-01 12:37 UTC (permalink / raw)
  To: Cai Huoqing
  Cc: kuba, David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	SeongJae Park, Bin Chen, netdev, linux-kernel

On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
> On 01 11月 22 12:46:32, Jani Nikula wrote:
>> On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
>> > HINIC has a mailbox for PF-VF communication and the VF driver
>> > could send port control command to PF driver via mailbox.
>> >
>> > The control command only can be set to register in PF,
>> > so add support in PF driver for VF PMD driver control
>> > command when VF PMD driver work with linux PF driver.
>> >
>> > Then there is no need to add handlers to nic_vf_cmd_msg_handler[],
>> > because the host driver just forwards it to the firmware.
>> > Actually the firmware works on a coprocessor MGMT_CPU(inside the NIC)
>> > which will recv and deal with these commands.
>> >
>> > Signed-off-by: Cai Huoqing <cai.huoqing@linux.dev>
>> 
>> Out of curiosity, what exactly compelled you to Cc me on this particular
>> patch? I mean there aren't a whole lot of places in the kernel that
>> would be more off-topic for me. :)
> run ./scripts/get_maintainer.pl this patch in net-next
> then get your email
> Jani Nikula <jani.nikula@intel.com> (commit_signer:1/8=12%)
> Maybe you have some commits in net subsystem ?

A grand total of 3 commits in drivers/net/wireless/ath/ two years ago,
adding 3 const keywords, nowhere near of what you're changing.

get_maintainer.pl is utterly broken to suggest I should be Cc'd.


BR,
Jani.


>> 
>> BR,
>> Jani.
>> 
>> 
>> -- 
>> Jani Nikula, Intel Open Source Graphics Center

-- 
Jani Nikula, Intel Open Source Graphics Center

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01 12:37       ` Jani Nikula
@ 2022-11-01 15:37         ` Jakub Kicinski
  2022-11-01 16:06           ` Jani Nikula
  0 siblings, 1 reply; 9+ messages in thread
From: Jakub Kicinski @ 2022-11-01 15:37 UTC (permalink / raw)
  To: Jani Nikula, Cai Huoqing
  Cc: David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	SeongJae Park, Bin Chen, netdev, linux-kernel

On Tue, 01 Nov 2022 14:37:39 +0200 Jani Nikula wrote:
> On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
> > On 01 11月 22 12:46:32, Jani Nikula wrote:  
> >> Out of curiosity, what exactly compelled you to Cc me on this particular
> >> patch? I mean there aren't a whole lot of places in the kernel that
> >> would be more off-topic for me. :)  
> > run ./scripts/get_maintainer.pl this patch in net-next
> > then get your email
> > Jani Nikula <jani.nikula@intel.com> (commit_signer:1/8=12%)
> > Maybe you have some commits in net subsystem ?  
> 
> A grand total of 3 commits in drivers/net/wireless/ath/ two years ago,
> adding 3 const keywords, nowhere near of what you're changing.
> 
> get_maintainer.pl is utterly broken to suggest I should be Cc'd.

Apparently is because you acked commit 8581fd402a0c ("treewide: Add
missing includes masked by cgroup -> bpf dependency").
This random driver is obviously was not the part you were acking but
heuristics :/

Cai Huoqing FWIW we recommend adding --git-min-percent 25 when running
get_maintainers, otherwise there's all sorts of noise that gets in.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK
  2022-11-01 15:37         ` Jakub Kicinski
@ 2022-11-01 16:06           ` Jani Nikula
  0 siblings, 0 replies; 9+ messages in thread
From: Jani Nikula @ 2022-11-01 16:06 UTC (permalink / raw)
  To: Jakub Kicinski, Cai Huoqing
  Cc: David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	SeongJae Park, Bin Chen, netdev, linux-kernel

On Tue, 01 Nov 2022, Jakub Kicinski <kuba@kernel.org> wrote:
> On Tue, 01 Nov 2022 14:37:39 +0200 Jani Nikula wrote:
>> On Tue, 01 Nov 2022, Cai Huoqing <cai.huoqing@linux.dev> wrote:
>> > On 01 11月 22 12:46:32, Jani Nikula wrote:  
>> >> Out of curiosity, what exactly compelled you to Cc me on this particular
>> >> patch? I mean there aren't a whole lot of places in the kernel that
>> >> would be more off-topic for me. :)  
>> > run ./scripts/get_maintainer.pl this patch in net-next
>> > then get your email
>> > Jani Nikula <jani.nikula@intel.com> (commit_signer:1/8=12%)
>> > Maybe you have some commits in net subsystem ?  
>> 
>> A grand total of 3 commits in drivers/net/wireless/ath/ two years ago,
>> adding 3 const keywords, nowhere near of what you're changing.
>> 
>> get_maintainer.pl is utterly broken to suggest I should be Cc'd.
>
> Apparently is because you acked commit 8581fd402a0c ("treewide: Add
> missing includes masked by cgroup -> bpf dependency").
> This random driver is obviously was not the part you were acking but
> heuristics :/

*rolls eyes* :D


>
> Cai Huoqing FWIW we recommend adding --git-min-percent 25 when running
> get_maintainers, otherwise there's all sorts of noise that gets in.

-- 
Jani Nikula, Intel Open Source Graphics Center

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable
  2022-11-01  6:03 [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Cai Huoqing
  2022-11-01  6:03 ` [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK Cai Huoqing
@ 2022-11-03  3:36 ` Jakub Kicinski
  2022-11-04  3:53   ` Cai Huoqing
  1 sibling, 1 reply; 9+ messages in thread
From: Jakub Kicinski @ 2022-11-03  3:36 UTC (permalink / raw)
  To: Cai Huoqing
  Cc: David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	Alexei Starovoitov, SeongJae Park, Peter Chen, Bin Chen, netdev,
	linux-kernel

On Tue,  1 Nov 2022 14:03:38 +0800 Cai Huoqing wrote:
> The print cmd code is in hex, so using hex cmd code intead of
> decimal is easy to check the value with print info.

You're still removing empty lines making this patch much harder 
to review. Once again - it should be a pure conversion to dec -> hex.
Don't make any other changes.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable
  2022-11-03  3:36 ` [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Jakub Kicinski
@ 2022-11-04  3:53   ` Cai Huoqing
  0 siblings, 0 replies; 9+ messages in thread
From: Cai Huoqing @ 2022-11-04  3:53 UTC (permalink / raw)
  To: Jakub Kicinski
  Cc: David S. Miller, Eric Dumazet, Paolo Abeni, Zhengchao Shao,
	Alexei Starovoitov, SeongJae Park, Peter Chen, Bin Chen, netdev,
	linux-kernel

On 02 11月 22 20:36:40, Jakub Kicinski wrote:
> On Tue,  1 Nov 2022 14:03:38 +0800 Cai Huoqing wrote:
> > The print cmd code is in hex, so using hex cmd code intead of
> > decimal is easy to check the value with print info.
> 
> You're still removing empty lines making this patch much harder 
> to review. Once again - it should be a pure conversion to dec -> hex.
> Don't make any other changes.
Hi, Jakub 

I fix it, and resend v4
https://lore.kernel.org/lkml/20221103080525.26885-1-cai.huoqing@linux.dev/

Thanks,
Cai

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-11-04  3:54 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-01  6:03 [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Cai Huoqing
2022-11-01  6:03 ` [PATCH net-next v2 2/2] net: hinic: Add control command support for VF PMD driver in DPDK Cai Huoqing
2022-11-01 10:46   ` Jani Nikula
2022-11-01 12:17     ` Cai Huoqing
2022-11-01 12:37       ` Jani Nikula
2022-11-01 15:37         ` Jakub Kicinski
2022-11-01 16:06           ` Jani Nikula
2022-11-03  3:36 ` [PATCH net-next v2 1/2] net: hinic: Convert the cmd code from decimal to hex to be more readable Jakub Kicinski
2022-11-04  3:53   ` Cai Huoqing

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.