From: Sakari Ailus <sakari.ailus@linux.intel.com>
To: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Cc: linuxarm@huawei.com, mauro.chehab@huawei.com,
Bingbu Cao <bingbu.cao@intel.com>,
Dan Scally <djrscally@gmail.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Tianshu Qiu <tian.shu.qiu@intel.com>,
Yong Zhi <yong.zhi@intel.com>,
linux-kernel@vger.kernel.org, linux-media@vger.kernel.org
Subject: Re: [PATCH] media: ipu3: don't use recursion at the Kernel
Date: Thu, 2 Dec 2021 14:50:47 +0200 [thread overview]
Message-ID: <YajBJ8W8e6UdDrcU@paasikivi.fi.intel.com> (raw)
In-Reply-To: <cf020b6a04b3a9d7f08750927b1d100f63ff4689.1638445455.git.mchehab+huawei@kernel.org>
Hi Mauro,
On Thu, Dec 02, 2021 at 12:44:26PM +0100, Mauro Carvalho Chehab wrote:
> The Kernel stack is too small. Doing recursions there is a very
> bad idea, as, if something gets wrong, it could lead to data
> corruption. So, re-implement cio2_check_fwnode_graph() to avoid
> recursion.
Any decent compiler should be able to optimise out tail recursion.
But is checking the secondary pointer even needed these days?
fwnode_graph_get_next_endpoint() does that already, it's not something
drivers should be required to do.
--
Kind regards,
Sakari Ailus
prev parent reply other threads:[~2021-12-02 12:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-02 11:44 Mauro Carvalho Chehab
2021-12-02 12:31 ` Daniel Scally
2021-12-02 12:50 ` Sakari Ailus [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=YajBJ8W8e6UdDrcU@paasikivi.fi.intel.com \
--to=sakari.ailus@linux.intel.com \
--cc=bingbu.cao@intel.com \
--cc=djrscally@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=mauro.chehab@huawei.com \
--cc=mchehab+huawei@kernel.org \
--cc=mchehab@kernel.org \
--cc=tian.shu.qiu@intel.com \
--cc=yong.zhi@intel.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
all inboxes | Powered by JetHome®