Re: [PATCH 7/8] mtd: rawnand: qcom: Early structure initialization

Tudor Ambarus
2023-07-27T15:03:53Z

On 7/16/23 15:46, Miquel Raynal wrote:
> Instead of allocating a structure on the stack with random data and then
> expect the callee to perform the initialization (which is, in general,
> error prone), prefer zeroing the structure explicitly at allocation and
> provide the already zeroed area, so no explicit memset operation is
> needed. It is probably safer to do so, so we limit the timeframe when
> dirty data could actually be accessed by mistake.

Why is zeroed data considered safe or sane?