From: Zaiyu Wang <zaiyuwang@trustnetic.com>
To: dev@dpdk.org
Cc: stable@dpdk.org, Zaiyu Wang <zaiyuwang@trustnetic.com>,
Jiawen Wu <jiawenwu@trustnetic.com>,
Jian Wang <jianwang@trustnetic.com>,
Ferruh Yigit <ferruh.yigit@intel.com>
Subject: [PATCH 2/2] net/txgbe: remove meaningless choice for SW-FW sync
Date: Mon, 24 Feb 2025 17:59:08 +0800 [thread overview]
Message-ID: <20250224095910.27384-3-zaiyuwang@trustnetic.com> (raw)
In-Reply-To: <20250224095910.27384-1-zaiyuwang@trustnetic.com>
Remove superfluous 'if' and 'else' for SW-FW sync.
Bugzilla ID: 1581
Fixes: 5364a1ce30df ("net/txgbe: add PHY init")
Cc: stable@dpdk.org
Signed-off-by: Zaiyu Wang <zaiyuwang@trustnetic.com>
---
drivers/net/txgbe/base/txgbe_phy.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/drivers/net/txgbe/base/txgbe_phy.c b/drivers/net/txgbe/base/txgbe_phy.c
index d87af656d5..ce6882e262 100644
--- a/drivers/net/txgbe/base/txgbe_phy.c
+++ b/drivers/net/txgbe/base/txgbe_phy.c
@@ -80,12 +80,8 @@ static s32 txgbe_read_phy_if(struct txgbe_hw *hw)
if (hw->phy.nw_mng_if_sel & TXGBE_ETHPHYIF_MDIO_ACT)
hw->phy.addr = TXGBE_ETHPHYIF_MDIO_BASE(hw->phy.nw_mng_if_sel);
- if (!hw->phy.phy_semaphore_mask) {
- if (hw->bus.lan_id)
- hw->phy.phy_semaphore_mask = TXGBE_MNGSEM_SWPHY;
- else
- hw->phy.phy_semaphore_mask = TXGBE_MNGSEM_SWPHY;
- }
+ if (!hw->phy.phy_semaphore_mask)
+ hw->phy.phy_semaphore_mask = TXGBE_MNGSEM_SWPHY;
return 0;
}
--
2.21.0.windows.1
prev parent reply other threads:[~2025-02-24 10:04 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-24 9:59 [PATCH 0/2] Wangxun bug fixes Zaiyu Wang
2025-02-24 9:59 ` [PATCH 1/2] net/ngbe: fix WOL and NCSI capability error Zaiyu Wang
2025-02-24 9:59 ` Zaiyu Wang [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250224095910.27384-3-zaiyuwang@trustnetic.com \
--to=zaiyuwang@trustnetic.com \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@intel.com \
--cc=jianwang@trustnetic.com \
--cc=jiawenwu@trustnetic.com \
--cc=stable@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).