commit | d3c9d3065acaa037410e487924c41dc54457da3a | [log] [tgz] |
---|---|---|
author | Simon Glass <sjg@chromium.org> | Sun Dec 29 21:19:21 2019 -0700 |
committer | Simon Glass <sjg@chromium.org> | Tue Jan 07 16:02:38 2020 -0700 |
tree | 3c4d8ba6098fae5410decb45a559d6f339f43fc4 | |
parent | 4a26385008e46fb9ca579de2c59da625223065bf [diff] |
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: Simon Glass <sjg@chromium.org>