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: <e68993e6-add4-dcd1-3ae2-0f4b3f768d3e@omp.ru>
Date:   Wed, 25 Aug 2021 21:49:15 +0300
From:   Sergey Shtylyov <s.shtylyov@....ru>
To:     Biju Das <biju.das.jz@...renesas.com>,
        "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>
CC:     Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>,
        Andrew Lunn <andrew@...n.ch>,
        Sergei Shtylyov <sergei.shtylyov@...il.com>,
        "Geert Uytterhoeven" <geert+renesas@...der.be>,
        Adam Ford <aford173@...il.com>,
        Yoshihiro Shimoda <yoshihiro.shimoda.uh@...esas.com>,
        <netdev@...r.kernel.org>, <linux-renesas-soc@...r.kernel.org>,
        Chris Paterson <Chris.Paterson2@...esas.com>,
        Biju Das <biju.das@...renesas.com>
Subject: Re: [PATCH net-next 02/13] ravb: Add multi_irq to struct ravb_hw_info

On 8/25/21 10:01 AM, Biju Das wrote:

> R-Car Gen3 supports separate interrupts for E-MAC and DMA queues,
> whereas R-Car Gen2 and RZ/G2L have a single interrupt instead.
> 
> Add a multi_irq hw feature bit to struct ravb_hw_info to enable

   So you have 'multi_irq' in the patch subject/description but 'multi_irqs'?
Not very consistent...

> this only for R-Car Gen3.
> 
> Signed-off-by: Biju Das <biju.das.jz@...renesas.com>
> Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>
> ---
>  drivers/net/ethernet/renesas/ravb.h      |  1 +
>  drivers/net/ethernet/renesas/ravb_main.c | 22 ++++++++++++++--------
>  drivers/net/ethernet/renesas/ravb_ptp.c  |  8 +++++---
>  3 files changed, 20 insertions(+), 11 deletions(-)
> 
> diff --git a/drivers/net/ethernet/renesas/ravb.h b/drivers/net/ethernet/renesas/ravb.h
> index 84700a82a41c..da486e06b322 100644
> --- a/drivers/net/ethernet/renesas/ravb.h
> +++ b/drivers/net/ethernet/renesas/ravb.h
> @@ -997,6 +997,7 @@ struct ravb_hw_info {
>  	/* hardware features */
>  	unsigned internal_delay:1;	/* AVB-DMAC has internal delays */
>  	unsigned tx_counters:1;		/* E-MAC has TX counters */
> +	unsigned multi_irqs:1;		/* AVB-DMAC and E-MAC has multiple irqs */

   It's generally written IRQs but we can live with that. :-)

[...]
> diff --git a/drivers/net/ethernet/renesas/ravb_ptp.c b/drivers/net/ethernet/renesas/ravb_ptp.c
> index 6984bd5b7da9..c099656dd75b 100644
> --- a/drivers/net/ethernet/renesas/ravb_ptp.c
> +++ b/drivers/net/ethernet/renesas/ravb_ptp.c
[...]
> @@ -252,7 +254,7 @@ static int ravb_ptp_perout(struct ptp_clock_info *ptp,
>  		error = ravb_ptp_update_compare(priv, (u32)start_ns);
>  		if (!error) {
>  			/* Unmask interrupt */
> -			if (priv->chip_id == RCAR_GEN2)
> +			if (!info->multi_irqs)
>  				ravb_modify(ndev, GIC, GIC_PTME, GIC_PTME);
>  			else
>  				ravb_write(ndev, GIE_PTMS0, GIE);
> @@ -264,7 +266,7 @@ static int ravb_ptp_perout(struct ptp_clock_info *ptp,
>  		perout->period = 0;
>  
>  		/* Mask interrupt */
> -		if (priv->chip_id == RCAR_GEN2)
> +		if (!info->multi_irqs)
>  			ravb_modify(ndev, GIC, GIC_PTME, 0);
>  		else
>  			ravb_write(ndev, GID_PTMD0, GID);

   Hm... Let's assume GIE/GID are a part of multi-IRQ feature...

Reviewed-by: Sergey Shtylyov <s.shtylyov@....ru>

[...]

MBR, Sergey

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ