lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240607155420.GA3743392@maili.marvell.com>
Date: Fri, 7 Jun 2024 21:24:20 +0530
From: Ratheesh Kannoth <rkannoth@...vell.com>
To: Justin Lai <justinlai0215@...ltek.com>
CC: <kuba@...nel.org>, <davem@...emloft.net>, <edumazet@...gle.com>,
        <pabeni@...hat.com>, <linux-kernel@...r.kernel.org>,
        <netdev@...r.kernel.org>, <andrew@...n.ch>, <jiri@...nulli.us>,
        <horms@...nel.org>, <pkshih@...ltek.com>, <larry.chiu@...ltek.com>
Subject: Re: [PATCH net-next v20 06/13] rtase: Implement .ndo_start_xmit
 function

On 2024-06-07 at 14:13:14, Justin Lai (justinlai0215@...ltek.com) wrote:
> Implement .ndo_start_xmit function to fill the information of the packet
> to be transmitted into the tx descriptor, and then the hardware will
> transmit the packet using the information in the tx descriptor.
> In addition, we also implemented the tx_handler function to enable the
> tx descriptor to be reused.
>
> Signed-off-by: Justin Lai <justinlai0215@...ltek.com>
> ---
>  .../net/ethernet/realtek/rtase/rtase_main.c   | 285 ++++++++++++++++++
>  1 file changed, 285 insertions(+)
>
> diff --git a/drivers/net/ethernet/realtek/rtase/rtase_main.c b/drivers/net/ethernet/realtek/rtase/rtase_main.c
> index 23406c195cff..6bdb4edbfbc1 100644
> --- a/drivers/net/ethernet/realtek/rtase/rtase_main.c
> +++ b/drivers/net/ethernet/realtek/rtase/rtase_main.c
> @@ -256,6 +256,68 @@ static void rtase_mark_to_asic(union rtase_rx_desc *desc, u32 rx_buf_sz)
>  		   cpu_to_le32(RTASE_DESC_OWN | eor | rx_buf_sz));
>  }
>
> +static u32 rtase_tx_avail(struct rtase_ring *ring)
> +{
> +	return READ_ONCE(ring->dirty_idx) + RTASE_NUM_DESC -
> +	       READ_ONCE(ring->cur_idx);
> +}
dirty_idx and cur_idx wont wrap ? its 32bit in size.

>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ