summaryrefslogtreecommitdiff
path: root/drivers/misc/reset_sandbox.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2015-10-03 17:21:16 (GMT)
committerSimon Glass <sjg@chromium.org>2015-10-05 14:47:49 (GMT)
commit7bb91dd109e2aff5f7f51aed44ac7890f9a4d158 (patch)
tree3bb4b5d521198729104557dabbcf854743bd8889 /drivers/misc/reset_sandbox.c
parentcbfc2ff9da392d61cd456703ea6256996eb8beb1 (diff)
downloadu-boot-fsl-qoriq-7bb91dd109e2aff5f7f51aed44ac7890f9a4d158.tar.xz
sandbox: Correct operaion of 'reset' command
Currently 'reset' only works with the test device tree. When run without a device tree, or with the normal device tree, the following error is displayed: Reset not supported on this platform Fix the driver and the standard device tree to avoid this. Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Stephen Warren <swarren@nvidia.com> Tested-by: Stephen Warren <swarren@wwwdotorg.org>
Diffstat (limited to 'drivers/misc/reset_sandbox.c')
-rw-r--r--drivers/misc/reset_sandbox.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/reset_sandbox.c b/drivers/misc/reset_sandbox.c
index 917121b..2691bb0 100644
--- a/drivers/misc/reset_sandbox.c
+++ b/drivers/misc/reset_sandbox.c
@@ -40,7 +40,7 @@ static int sandbox_reset_request(struct udevice *dev, enum reset_t type)
* (see the U_BOOT_DEVICE() declaration below) should not do anything.
* If we are that device, return an error.
*/
- if (gd->fdt_blob && dev->of_offset == -1)
+ if (state->fdt_fname && dev->of_offset == -1)
return -ENODEV;
switch (type) {