]> git.sur5r.net Git - openocd/commitdiff
FLASH/NOR: Remove useless file str7x.h
authorAntonio Borneo <borneo.antonio@gmail.com>
Wed, 17 Nov 2010 13:20:02 +0000 (21:20 +0800)
committerØyvind Harboe <oyvind.harboe@zylin.com>
Wed, 17 Nov 2010 16:02:36 +0000 (17:02 +0100)
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
src/flash/nor/Makefile.am
src/flash/nor/str7x.c
src/flash/nor/str7x.h [deleted file]

index 4170bd0a74d962d3af1b412eb6fe6a26c316bf85..272b536f9741216e13c935bd4dafbe4ebd8bf291 100644 (file)
@@ -39,7 +39,6 @@ noinst_HEADERS = \
        imp.h \
        non_cfi.h \
        ocl.h \
-       str7x.h \
        str9x.h \
        str9xpec.h \
        tms470.h
index 3a74d3538b7c422d56aa5ec386abe606c6e86d0b..6136f310d38572b3181247980715f0b9bf70a4a0 100644 (file)
 #endif
 
 #include "imp.h"
-#include "str7x.h"
 #include <target/arm.h>
 #include <helper/binarybuffer.h>
 #include <target/algorithm.h>
 
 
+/*  Flash registers */
+
+#define FLASH_CR0              0x00000000
+#define FLASH_CR1              0x00000004
+#define FLASH_DR0              0x00000008
+#define FLASH_DR1              0x0000000C
+#define FLASH_AR               0x00000010
+#define FLASH_ER               0x00000014
+#define FLASH_NVWPAR   0x0000DFB0
+#define FLASH_NVAPR0   0x0000DFB8
+#define FLASH_NVAPR1   0x0000DFBC
+
+/* FLASH_CR0 register bits */
+
+#define FLASH_WMS              0x80000000
+#define FLASH_SUSP             0x40000000
+#define FLASH_WPG              0x20000000
+#define FLASH_DWPG             0x10000000
+#define FLASH_SER              0x08000000
+#define FLASH_SPR              0x01000000
+#define FLASH_BER              0x04000000
+#define FLASH_MER              0x02000000
+#define FLASH_LOCK             0x00000010
+#define FLASH_BSYA1            0x00000004
+#define FLASH_BSYA0            0x00000002
+
+/* FLASH_CR1 register bits */
+
+#define FLASH_B1S              0x02000000
+#define FLASH_B0S              0x01000000
+#define FLASH_B1F1             0x00020000
+#define FLASH_B1F0             0x00010000
+#define FLASH_B0F7             0x00000080
+#define FLASH_B0F6             0x00000040
+#define FLASH_B0F5             0x00000020
+#define FLASH_B0F4             0x00000010
+#define FLASH_B0F3             0x00000008
+#define FLASH_B0F2             0x00000004
+#define FLASH_B0F1             0x00000002
+#define FLASH_B0F0             0x00000001
+
+/* FLASH_ER register bits */
+
+#define FLASH_WPF              0x00000100
+#define FLASH_RESER            0x00000080
+#define FLASH_SEQER            0x00000040
+#define FLASH_10ER             0x00000008
+#define FLASH_PGER             0x00000004
+#define FLASH_ERER             0x00000002
+#define FLASH_ERR              0x00000001
+
+
+struct str7x_flash_bank
+{
+       uint32_t *sector_bits;
+       uint32_t disable_bit;
+       uint32_t busy_bits;
+       uint32_t register_base;
+       struct working_area *write_algorithm;
+};
+
+struct str7x_mem_layout {
+       uint32_t sector_start;
+       uint32_t sector_size;
+       uint32_t sector_bit;
+};
+
+enum str7x_status_codes
+{
+       STR7X_CMD_SUCCESS = 0,
+       STR7X_INVALID_COMMAND = 1,
+       STR7X_SRC_ADDR_ERROR = 2,
+       STR7X_DST_ADDR_ERROR = 3,
+       STR7X_SRC_ADDR_NOT_MAPPED = 4,
+       STR7X_DST_ADDR_NOT_MAPPED = 5,
+       STR7X_COUNT_ERROR = 6,
+       STR7X_INVALID_SECTOR = 7,
+       STR7X_SECTOR_NOT_BLANK = 8,
+       STR7X_SECTOR_NOT_PREPARED = 9,
+       STR7X_COMPARE_ERROR = 10,
+       STR7X_BUSY = 11
+};
+
 static struct str7x_mem_layout mem_layout_str7bank0[] = {
        {0x00000000, 0x02000, 0x01},
        {0x00002000, 0x02000, 0x02},
diff --git a/src/flash/nor/str7x.h b/src/flash/nor/str7x.h
deleted file mode 100644 (file)
index 77dfee6..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/***************************************************************************
- *   Copyright (C) 2005 by Dominic Rath                                    *
- *   Dominic.Rath@gmx.de                                                   *
- *                                                                         *
- *   Copyright (C) 2008 by Spencer Oliver                                  *
- *   spen@spen-soft.co.uk                                                  *
- *                                                                         *
- *   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.             *
- ***************************************************************************/
-#ifndef STR7X_H
-#define STR7X_H
-
-struct str7x_flash_bank
-{
-       uint32_t *sector_bits;
-       uint32_t disable_bit;
-       uint32_t busy_bits;
-       uint32_t register_base;
-       struct working_area *write_algorithm;
-};
-
-enum str7x_status_codes
-{
-       STR7X_CMD_SUCCESS = 0,
-       STR7X_INVALID_COMMAND = 1,
-       STR7X_SRC_ADDR_ERROR = 2,
-       STR7X_DST_ADDR_ERROR = 3,
-       STR7X_SRC_ADDR_NOT_MAPPED = 4,
-       STR7X_DST_ADDR_NOT_MAPPED = 5,
-       STR7X_COUNT_ERROR = 6,
-       STR7X_INVALID_SECTOR = 7,
-       STR7X_SECTOR_NOT_BLANK = 8,
-       STR7X_SECTOR_NOT_PREPARED = 9,
-       STR7X_COMPARE_ERROR = 10,
-       STR7X_BUSY = 11
-};
-
-/*  Flash registers */
-
-#define FLASH_CR0              0x00000000
-#define FLASH_CR1              0x00000004
-#define FLASH_DR0              0x00000008
-#define FLASH_DR1              0x0000000C
-#define FLASH_AR               0x00000010
-#define FLASH_ER               0x00000014
-#define FLASH_NVWPAR   0x0000DFB0
-#define FLASH_NVAPR0   0x0000DFB8
-#define FLASH_NVAPR1   0x0000DFBC
-
-/* FLASH_CR0 register bits */
-
-#define FLASH_WMS              0x80000000
-#define FLASH_SUSP             0x40000000
-#define FLASH_WPG              0x20000000
-#define FLASH_DWPG             0x10000000
-#define FLASH_SER              0x08000000
-#define FLASH_SPR              0x01000000
-#define FLASH_BER              0x04000000
-#define FLASH_MER              0x02000000
-#define FLASH_LOCK             0x00000010
-#define FLASH_BSYA1            0x00000004
-#define FLASH_BSYA0            0x00000002
-
-/* FLASH_CR1 register bits */
-
-#define FLASH_B1S              0x02000000
-#define FLASH_B0S              0x01000000
-#define FLASH_B1F1             0x00020000
-#define FLASH_B1F0             0x00010000
-#define FLASH_B0F7             0x00000080
-#define FLASH_B0F6             0x00000040
-#define FLASH_B0F5             0x00000020
-#define FLASH_B0F4             0x00000010
-#define FLASH_B0F3             0x00000008
-#define FLASH_B0F2             0x00000004
-#define FLASH_B0F1             0x00000002
-#define FLASH_B0F0             0x00000001
-
-/* FLASH_ER register bits */
-
-#define FLASH_WPF              0x00000100
-#define FLASH_RESER            0x00000080
-#define FLASH_SEQER            0x00000040
-#define FLASH_10ER             0x00000008
-#define FLASH_PGER             0x00000004
-#define FLASH_ERER             0x00000002
-#define FLASH_ERR              0x00000001
-
-struct str7x_mem_layout {
-       uint32_t sector_start;
-       uint32_t sector_size;
-       uint32_t sector_bit;
-};
-
-#endif /* STR7X_H */