DECLARE_GLOBAL_DATA_PTR;
-env_t *env_ptr;
+/*
+ * Because we only ever have the default environment available we must mark
+ * it as invalid.
+ */
+static int env_nowhere_init(void)
+{
+ gd->env_addr = (ulong)&default_environment[0];
+ gd->env_valid = ENV_INVALID;
+
+ return 0;
+}
U_BOOT_ENV_LOCATION(nowhere) = {
.location = ENVL_NOWHERE,
+ .init = env_nowhere_init,
+ ENV_NAME("nowhere")
};