[dpdk-dev] [PATCH v2 01/16] fm10k: use default mailbox message handler for pf
> -Original Message- > From: Richardson, Bruce > Sent: Tuesday, February 16, 2016 6:50 PM > To: Wang, Xiao W > Cc: Chen, Jing D ; dev at dpdk.org; He, Shaopeng > > Subject: Re: [PATCH v2 01/16] fm10k: use default mailbox message handler for > pf > > On Wed, Jan 27, 2016 at 11:50:32AM +0800, Wang Xiao W wrote: > > The new share code makes fm10k_msg_update_pvid_pf function static, so > > we can not refer to it now in fm10k_ethdev.c. The registered pf > > handler is almost the same as the default pf handler, removing it has no > impact on mailbox. > > > > Signed-off-by: Wang Xiao W > > While the patch itself looks ok, checkpatch gives a warning about the commit > message being too long. > > WARNING:COMMIT_LOG_LONG_LINE: Possible unwrapped commit > description (prefer a > maximum 75 chars per line) > #6: > The new share code makes fm10k_msg_update_pvid_pf function static, so we > can > > total: 0 errors, 1 warnings, 0 checks, 31 lines checked > > Since the next patch breaks compilation, a V3 will be needed, so please fix > this > warning in the process. I'd also ask that you run checkpatch on all patches > before submitting and fix any issue raised. Thanks for the comment, I used an old checkpatch.pl to check the patches, it gave no warning. I have updated the checkpatch.pl and got the above warning. I will rework the patch set, thanks again. > > Thanks, > /Bruce
[dpdk-dev] [PATCH v2 01/16] fm10k: use default mailbox message handler for pf
On Wed, Jan 27, 2016 at 11:50:32AM +0800, Wang Xiao W wrote: > The new share code makes fm10k_msg_update_pvid_pf function static, so we can > not refer to it now in fm10k_ethdev.c. The registered pf handler is almost the > same as the default pf handler, removing it has no impact on mailbox. > > Signed-off-by: Wang Xiao W While the patch itself looks ok, checkpatch gives a warning about the commit message being too long. WARNING:COMMIT_LOG_LONG_LINE: Possible unwrapped commit description (prefer a maximum 75 chars per line) #6: The new share code makes fm10k_msg_update_pvid_pf function static, so we can total: 0 errors, 1 warnings, 0 checks, 31 lines checked Since the next patch breaks compilation, a V3 will be needed, so please fix this warning in the process. I'd also ask that you run checkpatch on all patches before submitting and fix any issue raised. Thanks, /Bruce
[dpdk-dev] [PATCH v2 01/16] fm10k: use default mailbox message handler for pf
The new share code makes fm10k_msg_update_pvid_pf function static, so we can not refer to it now in fm10k_ethdev.c. The registered pf handler is almost the same as the default pf handler, removing it has no impact on mailbox. Signed-off-by: Wang Xiao W --- drivers/net/fm10k/fm10k_ethdev.c | 17 ++--- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_ethdev.c index e4aed94..2c38ce9 100644 --- a/drivers/net/fm10k/fm10k_ethdev.c +++ b/drivers/net/fm10k/fm10k_ethdev.c @@ -2367,29 +2367,16 @@ static const struct fm10k_msg_data fm10k_msgdata_vf[] = { FM10K_TLV_MSG_ERROR_HANDLER(fm10k_tlv_msg_error), }; -/* Mailbox message handler in PF */ -static const struct fm10k_msg_data fm10k_msgdata_pf[] = { - FM10K_PF_MSG_ERR_HANDLER(XCAST_MODES, fm10k_msg_err_pf), - FM10K_PF_MSG_ERR_HANDLER(UPDATE_MAC_FWD_RULE, fm10k_msg_err_pf), - FM10K_PF_MSG_LPORT_MAP_HANDLER(fm10k_msg_lport_map_pf), - FM10K_PF_MSG_ERR_HANDLER(LPORT_CREATE, fm10k_msg_err_pf), - FM10K_PF_MSG_ERR_HANDLER(LPORT_DELETE, fm10k_msg_err_pf), - FM10K_PF_MSG_UPDATE_PVID_HANDLER(fm10k_msg_update_pvid_pf), - FM10K_TLV_MSG_ERROR_HANDLER(fm10k_tlv_msg_error), -}; - static int fm10k_setup_mbx_service(struct fm10k_hw *hw) { - int err; + int err = 0; /* Initialize mailbox lock */ fm10k_mbx_initlock(hw); /* Replace default message handler with new ones */ - if (hw->mac.type == fm10k_mac_pf) - err = hw->mbx.ops.register_handlers(>mbx, fm10k_msgdata_pf); - else + if (hw->mac.type == fm10k_mac_vf) err = hw->mbx.ops.register_handlers(>mbx, fm10k_msgdata_vf); if (err) { -- 1.9.3