Subject: Re: [PATCH v2 net-next 04/15] net: ethernet: mtk_eth_soc: add txd_size to mtk_soc_data

From: Jakub Kicinski <[email-masked]>
Date: Tue, 17 May 2022 18:33:11 -0700

On Mon, 16 May 2022 18:06:31 +0200 Lorenzo Bianconi wrote:
>  	eth->scratch_ring = dma_alloc_coherent(eth->dma_dev,
> -					       cnt * sizeof(struct mtk_tx_dma),
> +					       cnt * soc->txrx.txd_size,
>  					       &eth->phy_scratch_ring,
>  					       GFP_ATOMIC);
>  	if (unlikely(!eth->scratch_ring))
>  		return -ENOMEM;
>  
> -	eth->scratch_head = kcalloc(cnt, MTK_QDMA_PAGE_SIZE,
> -				    GFP_KERNEL);
> +	eth->scratch_head = kcalloc(cnt, MTK_QDMA_PAGE_SIZE, GFP_KERNEL);

Unrelated, but GFP_ATOMIC right next to GFP_KERNEL caught my attention.