Commit 666c299
committed
mtd: spinand: Enhance the logic when picking a variant
Currently the best variant picked in the first one in the list provided
in the manufacturer driver. This worked well while all operations where
performed at the same speed, but with the introduction of DTR transfers
and per operation maximum frequencies, this no longer works correctly.
Let's continue iterating over all the alternatives, even if we find a
match, keeping a reference over the theoretically fastest
operation. Only at the end we can tell which variant is the best.
This logic happening only once at boot, the extra computing needed
compared to the previous version is acceptable wrt. the expected
improvements.
Signed-off-by: Miquel Raynal <[email protected]>1 parent 7ce0d16 commit 666c299
1 file changed
+10
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1213 | 1213 | | |
1214 | 1214 | | |
1215 | 1215 | | |
| 1216 | + | |
| 1217 | + | |
1216 | 1218 | | |
1217 | 1219 | | |
1218 | 1220 | | |
1219 | 1221 | | |
| 1222 | + | |
1220 | 1223 | | |
1221 | 1224 | | |
1222 | 1225 | | |
| |||
1235 | 1238 | | |
1236 | 1239 | | |
1237 | 1240 | | |
| 1241 | + | |
| 1242 | + | |
1238 | 1243 | | |
1239 | 1244 | | |
1240 | | - | |
1241 | | - | |
| 1245 | + | |
| 1246 | + | |
| 1247 | + | |
| 1248 | + | |
1242 | 1249 | | |
1243 | 1250 | | |
1244 | | - | |
| 1251 | + | |
1245 | 1252 | | |
1246 | 1253 | | |
1247 | 1254 | | |
| |||
0 commit comments