This repository was archived by the owner on Aug 27, 2025. It is now read-only.
Commit 0957092
dtoverlay: Don't mix non-fatal errors and offsets
FDT errors are small negative integers, and non-fatal errors are the
positive versions of the same errors. This scheme only works if the
non-fatal error values are never returned from a function where a
positive integer has another interpretation.
dtoverlay_get_target_offset broke this rule, leading eventually to
an invalid DT and failure to boot. Fortunately, finding the offset for
a fragment target is a non-destructive operation and therefore always
non-fatal, so move the NON_FATAL classification to the callers - of
which there are only three.
See: raspberrypi/firmware#16861 parent affef1e commit 0957092
1 file changed
+6
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
976 | 976 | | |
977 | 977 | | |
978 | 978 | | |
979 | | - | |
| 979 | + | |
980 | 980 | | |
981 | 981 | | |
982 | 982 | | |
| |||
988 | 988 | | |
989 | 989 | | |
990 | 990 | | |
991 | | - | |
| 991 | + | |
992 | 992 | | |
993 | 993 | | |
994 | 994 | | |
995 | | - | |
| 995 | + | |
996 | 996 | | |
997 | 997 | | |
998 | 998 | | |
| |||
1007 | 1007 | | |
1008 | 1008 | | |
1009 | 1009 | | |
1010 | | - | |
| 1010 | + | |
1011 | 1011 | | |
1012 | 1012 | | |
1013 | 1013 | | |
| |||
1071 | 1071 | | |
1072 | 1072 | | |
1073 | 1073 | | |
1074 | | - | |
| 1074 | + | |
1075 | 1075 | | |
1076 | 1076 | | |
1077 | 1077 | | |
| |||
1239 | 1239 | | |
1240 | 1240 | | |
1241 | 1241 | | |
1242 | | - | |
| 1242 | + | |
1243 | 1243 | | |
1244 | 1244 | | |
1245 | 1245 | | |
| |||
0 commit comments