RE: [PATCH net-next 10/18] ravb: Factorise ravb_ring_format function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



HI Sergei,

Thanks for the feedback.

> Subject: Re: [PATCH net-next 10/18] ravb: Factorise ravb_ring_format
> function
> 
> On 7/22/21 5:13 PM, Biju Das wrote:
> 
> > The ravb_ring_format function uses extended descriptor in rx for R-Car
> > where as it use normal descriptor for RZ/G2L. Factorise rx ring buffer
> > buildup to extend the support for later SoC.
> >
> > Signed-off-by: Biju Das <biju.das.jz@xxxxxxxxxxxxxx>
> > Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@xxxxxxxxxxxxxx>
> > ---
> >  drivers/net/ethernet/renesas/ravb.h      |  1 +
> >  drivers/net/ethernet/renesas/ravb_main.c | 34
> > +++++++++++++++---------
> >  2 files changed, 23 insertions(+), 12 deletions(-)
> >
> > diff --git a/drivers/net/ethernet/renesas/ravb.h
> > b/drivers/net/ethernet/renesas/ravb.h
> > index 3a9cf6e8671a..a3258c5d0c3d 100644
> > --- a/drivers/net/ethernet/renesas/ravb.h
> > +++ b/drivers/net/ethernet/renesas/ravb.h
> > @@ -990,6 +990,7 @@ enum ravb_chip_id {
> >
> >  struct ravb_ops {
> >  	void (*ring_free)(struct net_device *ndev, int q);
> > +	void (*ring_format)(struct net_device *ndev, int q);
> 
>    Like I said, we don't need another indirection.... also both ops are
> for RX.

OK. Will add this as part of ravb_drv_data.

> 
> [...]
> > diff --git a/drivers/net/ethernet/renesas/ravb_main.c
> > b/drivers/net/ethernet/renesas/ravb_main.c
> > index a3b8b243fd54..c23f0d420c70 100644
> > --- a/drivers/net/ethernet/renesas/ravb_main.c
> > +++ b/drivers/net/ethernet/renesas/ravb_main.c
> > @@ -311,26 +311,15 @@ static void ravb_ring_free(struct net_device
> > *ndev, int q)  }
> >
> >  /* Format skb and descriptor buffer for Ethernet AVB */ -static void
> > ravb_ring_format(struct net_device *ndev, int q)
> > +static void ravb_ring_format_rx(struct net_device *ndev, int rxq)
> 
>    How about ravb_rx_ring_format(struct net_device *ndev, int q)?

Agreed.

Cheers,
Biju

> 
> [...]
> 
> MBR, Sergei




[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux