Re: [PATCH] media: ipu3: don't use recursion at the Kernel

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

 



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



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux