Re: [PATCH net-next v2 1/3] net/stmmac/dwxgmac: Modify DMA functions for future hardware
From: Jakub Raczynski
Date: Mon Jun 08 2026 - 04:37:56 EST
On Fri, Jun 05, 2026 at 07:02:10PM -0700, Jakub Kicinski wrote:
>
> +1, this feels a bit sloppy. The driver has some painful abstraction
> layers but if we cut ourselves some slack because of that that'd be
> basically encouraging shitty architectures.
> --
> pw-bot: cr
>
Alright, will think about it.
As said in commit, problem is that current code really does assume
number of DMA=MTL=TC's and uses it interchangeably. So that was quite minimal
setup to get this stuff to work.
This is not longer true though for new hardware.
XGMAC 3.20a and 3.40a are fully compatible with dwxgmac2 as far as
I can tell, so new HW is generally supported with generic xgmac driver,
only some features are extra. And since there is no free space in some
registers, it should continue being that way.
Probably better solution would be to not change these functions to return
something, but rather check this in upper layer using synopsys_id or
whatever version. Will see what is more feasible.
BR
Jakub Raczynski