/*
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
*
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * SPDX-License-Identifier: GPL-2.0+
*/
#include <common.h>
static int write_word(flash_info_t *info, ulong dest, ulong data)
{
ulong addr = (ulong) (info->start[0]);
- ulong start, last;
+ ulong start;
int flag;
ulong i;
int data_short[2];
enable_interrupts();
start = get_timer(0);
- last = start;
while ((my_in_8((unsigned char *)(dest + i))) !=
(data_ch[i])) {
if (get_timer(start) >
enable_interrupts();
start = get_timer(0);
- last = start;
while ((my_in_be16((unsigned short *)(dest + (i * 2)))) !=
(data_short[i])) {
if (get_timer(start) > CONFIG_SYS_FLASH_WRITE_TOUT)