From: Andrew Lunn <andrew@lunn.ch>
To: Jakub Raczynski <j.raczynski@samsung.com>
Cc: netdev@vger.kernel.org, k.tegowski@samsung.com,
k.domagalski@samsung.com, andrew+netdev@lunn.ch,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, mcoquelin.stm32@gmail.com,
alexandre.torgue@foss.st.com,
linux-stm32@st-md-mailman.stormreply.com,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net 2/2] net/stmmac: Verify provided DTS AXI setup
Date: Tue, 7 Jul 2026 21:04:00 +0200 [thread overview]
Message-ID: <ee504cab-b1da-4584-8693-70ed5cd943c7@lunn.ch> (raw)
In-Reply-To: <20260707174431.1264520-3-j.raczynski@samsung.com>
On Tue, Jul 07, 2026 at 07:44:31PM +0200, Jakub Raczynski wrote:
> During parsing of AXI setup, there are few issues:
> - 'axi_blen' array is uninitialized value on stack without zero-init stack
> configured. This can result in random AXI burst length config if
> DTS config provides shorter array than AXI_BLEN.
What does the DT blinding say about the length? Is it allowed to be
short?
Are we talking about:
snps,blen:
$ref: /schemas/types.yaml#/definitions/uint32-array
description:
this is a vector of supported burst length.
minItems: 7
maxItems: 7
So it should be 7. Are there any in kernel DT blobs which don't pass
7? Can we just error out when it is not 7?
> - In case of failed memory allocation for AXI and error, there is no handling
> of that. Fix it by checking if AXI config is error and return if so,
> as this can only lack of memory. No AXI config, although is probably
> wrong in most cases, is not treated as error, as generic config is mostly
> provided in drivers.
This seems like a different fix. Maybe put it into a patch of its own.
> Fixes: afea03656add ("stmmac: rework DMA bus setting and introduce new platform AXI structure")
Again, does this bother anybody? At least axi_blen issue seems to be
that the DT blob is broken, so i doubt it actually does. Are there
reports of memory allocation error and resulting Opps.
Andrew
---
pw-bot: cr
prev parent reply other threads:[~2026-07-07 19:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20260707174437eucas1p2cedaa017eea6cd5696535b17925a3b53@eucas1p2.samsung.com>
2026-07-07 17:44 ` [PATCH net 0/2] net/stmmac: Verify more wrong DTS configuration Jakub Raczynski
2026-07-07 17:44 ` [PATCH net 1/2] net/stmmac: Protect against zero queue DTS config Jakub Raczynski
2026-07-07 18:57 ` Andrew Lunn
2026-07-07 17:44 ` [PATCH net 2/2] net/stmmac: Verify provided DTS AXI setup Jakub Raczynski
2026-07-07 19:04 ` Andrew Lunn [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ee504cab-b1da-4584-8693-70ed5cd943c7@lunn.ch \
--to=andrew@lunn.ch \
--cc=alexandre.torgue@foss.st.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=j.raczynski@samsung.com \
--cc=k.domagalski@samsung.com \
--cc=k.tegowski@samsung.com \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox