Skip to content
Commit 153851dd authored by Simon Glass's avatar Simon Glass
Browse files

dm: core: Add a new flag to track platform data



We want to avoid allocating platform data twice. This could happen if
device_probe() is called after device_ofdata_to_platdata() for the same
device.

Add a flag to track whether device_ofdata_to_platdata() has been called on
a device. Check the flag to make sure it doesn't happen twice, and clear
the flag when the data is freed.

Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
parent bcd90cb6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment