onenand.c (0649cd0d4908d9b983a0361b8665938ef25701be) onenand.c (203e94f6c9ca03e260175ce240f5856507395585)
1/*
2 * (C) Copyright 2010 DENX Software Engineering
3 * Wolfgang Denk <wd@denx.de>
4 *
5 * (C) Copyright 2005-2009 Samsung Electronics
6 * Kyungmin Park <kyungmin.park@samsung.com>
7 *
8 * SPDX-License-Identifier: GPL-2.0+

--- 46 unchanged lines hidden (view full) ---

55 mtd_read(mtd, env_addr, ONENAND_MAX_ENV_SIZE,
56 &retlen, (u_char *)buf);
57 else
58 mtd->writesize = MAX_ONENAND_PAGESIZE;
59#endif /* !ENV_IS_EMBEDDED */
60
61 rc = env_import(buf, 1);
62 if (rc)
1/*
2 * (C) Copyright 2010 DENX Software Engineering
3 * Wolfgang Denk <wd@denx.de>
4 *
5 * (C) Copyright 2005-2009 Samsung Electronics
6 * Kyungmin Park <kyungmin.park@samsung.com>
7 *
8 * SPDX-License-Identifier: GPL-2.0+

--- 46 unchanged lines hidden (view full) ---

55 mtd_read(mtd, env_addr, ONENAND_MAX_ENV_SIZE,
56 &retlen, (u_char *)buf);
57 else
58 mtd->writesize = MAX_ONENAND_PAGESIZE;
59#endif /* !ENV_IS_EMBEDDED */
60
61 rc = env_import(buf, 1);
62 if (rc)
63 gd->env_valid = 1;
63 gd->env_valid = ENV_VALID;
64}
65
66int saveenv(void)
67{
68 env_t env_new;
69 int ret;
70 struct mtd_info *mtd = &onenand_mtd;
71#ifdef CONFIG_ENV_ADDR_FLEX

--- 33 unchanged lines hidden (view full) ---

105
106 return 0;
107}
108
109int env_init(void)
110{
111 /* use default */
112 gd->env_addr = (ulong)&default_environment[0];
64}
65
66int saveenv(void)
67{
68 env_t env_new;
69 int ret;
70 struct mtd_info *mtd = &onenand_mtd;
71#ifdef CONFIG_ENV_ADDR_FLEX

--- 33 unchanged lines hidden (view full) ---

105
106 return 0;
107}
108
109int env_init(void)
110{
111 /* use default */
112 gd->env_addr = (ulong)&default_environment[0];
113 gd->env_valid = 1;
113 gd->env_valid = ENV_VALID;
114
115 return 0;
116}
114
115 return 0;
116}