Debian Codegraph @

flashchips/boya_bohong.c

raw
1 /*
2 * This file is part of the flashrom project.
3 *
4 * Copyright (C) 2000 Silicon Integrated System Corporation
5 * Copyright (C) 2004 Tyan Corp
6 * Copyright (C) 2005-2008 coresystems GmbH <[email protected]>
7 * Copyright (C) 2006-2009 Carl-Daniel Hailfinger
8 * Copyright (C) 2009 Sean Nelson <[email protected]>
9 *
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 */
20
21 {
22 .vendor = "Boya/BoHong Microelectronics",
23 .name = "B.25D16A",
24 .bustype = BUS_SPI,
25 .manufacture_id = BOYA_BOHONG_ID,
26 .model_id = BOYA_BOHONG_B_25D16A,
27 .total_size = 2048,
28 .page_size = 256,
29 .feature_bits = FEATURE_WRSR_WREN,
30 .tested = TEST_OK_PR,
31 .probe = PROBE_SPI_RDID,
32 .probe_timing = TIMING_ZERO,
33 .block_erasers =
34 {
35 {
36 .eraseblocks = { {4 * 1024, 512} },
37 .block_erase = SPI_BLOCK_ERASE_20,
38 }, {
39 .eraseblocks = { {32 * 1024, 64} },
40 .block_erase = SPI_BLOCK_ERASE_52,
41 }, {
42 .eraseblocks = { {64 * 1024, 32} },
43 .block_erase = SPI_BLOCK_ERASE_D8,
44 }, {
45 .eraseblocks = { {2 * 1024 * 1024, 1} },
46 .block_erase = SPI_BLOCK_ERASE_60,
47 }, {
48 .eraseblocks = { {2 * 1024 * 1024, 1} },
49 .block_erase = SPI_BLOCK_ERASE_C7,
50 }
51 },
52 .printlock = SPI_PRETTYPRINT_STATUS_REGISTER_BP2_SRWD,
53 .unlock = SPI_DISABLE_BLOCKPROTECT_BP2_SRWD,
54 .write = SPI_CHIP_WRITE256,
55 .read = SPI_CHIP_READ,
56 .voltage = {2700, 3600},
57 },
58
59 {
60 .vendor = "Boya/BoHong Microelectronics",
61 .name = "B.25D80A",
62 .bustype = BUS_SPI,
63 .manufacture_id = BOYA_BOHONG_ID,
64 .model_id = BOYA_BOHONG_B__25D80A,
65 .total_size = 1024,
66 .page_size = 256,
67 .feature_bits = FEATURE_WRSR_WREN,
68 .tested = TEST_OK_PR,
69 .probe = PROBE_SPI_RDID,
70 .probe_timing = TIMING_ZERO,
71 .block_erasers =
72 {
73 {
74 .eraseblocks = { {4 * 1024, 256} },
75 .block_erase = SPI_BLOCK_ERASE_20,
76 }, {
77 .eraseblocks = { {32 * 1024, 32} },
78 .block_erase = SPI_BLOCK_ERASE_52,
79 }, {
80 .eraseblocks = { {64 * 1024, 16} },
81 .block_erase = SPI_BLOCK_ERASE_D8,
82 }, {
83 .eraseblocks = { {1 * 1024 * 1024, 1} },
84 .block_erase = SPI_BLOCK_ERASE_60,
85 }, {
86 .eraseblocks = { {1 * 1024 * 1024, 1} },
87 .block_erase = SPI_BLOCK_ERASE_C7,
88 }
89 },
90 .printlock = SPI_PRETTYPRINT_STATUS_REGISTER_BP2_SRWD,
91 .unlock = SPI_DISABLE_BLOCKPROTECT_BP2_SRWD,
92 .write = SPI_CHIP_WRITE256,
93 .read = SPI_CHIP_READ,
94 .voltage = {2700, 3600},
95 },
96
97 {
98 .vendor = "Boya/BoHong Microelectronics",
99 .name = "B.25Q64AS",
100 .bustype = BUS_SPI,
101 .manufacture_id = BOYA_BOHONG_ID,
102 .model_id = BOYA_BOHONG_B_25Q64AS,
103 .total_size = 8192,
104 .page_size = 256,
105 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI,
106 .tested = TEST_OK_PREW,
107 .probe = PROBE_SPI_RDID,
108 .probe_timing = TIMING_ZERO,
109 .block_erasers =
110 {
111 {
112 .eraseblocks = { {4 * 1024, 2048} },
113 .block_erase = SPI_BLOCK_ERASE_20,
114 }, {
115 .eraseblocks = { {32 * 1024, 256} },
116 .block_erase = SPI_BLOCK_ERASE_52,
117 }, {
118 .eraseblocks = { {64 * 1024, 128} },
119 .block_erase = SPI_BLOCK_ERASE_D8,
120 }, {
121 .eraseblocks = { {16 * 512 * 1024, 1} },
122 .block_erase = SPI_BLOCK_ERASE_60,
123 }, {
124 .eraseblocks = { {16 * 512 * 1024, 1} },
125 .block_erase = SPI_BLOCK_ERASE_C7,
126 }
127 },
128 .printlock = SPI_PRETTYPRINT_STATUS_REGISTER_PLAIN,
129 .unlock = SPI_DISABLE_BLOCKPROTECT_BP4_SRWD,
130 .write = SPI_CHIP_WRITE256,
131 .read = SPI_CHIP_READ,
132 .voltage = {2700, 3600},
133 },
134
135 {
136 .vendor = "Boya/BoHong Microelectronics",
137 .name = "B.25Q128AS",
138 .bustype = BUS_SPI,
139 .manufacture_id = BOYA_BOHONG_ID,
140 .model_id = BOYA_BOHONG_B_25Q128AS,
141 .total_size = 16384,
142 .page_size = 256,
143 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI,
144 .tested = TEST_OK_PREW,
145 .probe = PROBE_SPI_RDID,
146 .probe_timing = TIMING_ZERO,
147 .block_erasers =
148 {
149 {
150 .eraseblocks = { {4 * 1024, 4096} },
151 .block_erase = SPI_BLOCK_ERASE_20,
152 }, {
153 .eraseblocks = { {32 * 1024, 512} },
154 .block_erase = SPI_BLOCK_ERASE_52,
155 }, {
156 .eraseblocks = { {64 * 1024, 256} },
157 .block_erase = SPI_BLOCK_ERASE_D8,
158 }, {
159 .eraseblocks = { {16 * 1024 * 1024, 1} },
160 .block_erase = SPI_BLOCK_ERASE_60,
161 }, {
162 .eraseblocks = { {16 * 1024 * 1024, 1} },
163 .block_erase = SPI_BLOCK_ERASE_C7,
164 }
165 },
166 .printlock = SPI_PRETTYPRINT_STATUS_REGISTER_PLAIN,
167 .unlock = SPI_DISABLE_BLOCKPROTECT_AT25FS040,
168 .write = SPI_CHIP_WRITE256,
169 .read = SPI_CHIP_READ,
170 .voltage = {2700, 3600},
171 },