Commit a8449f2
dlm: add __CHECKER__ for false positives
This patch will adds #ifndef __CHECKER__ for false positives warnings
about an imbalance lock/unlock srcu handling. Which are shown by running
sparse checks:
fs/dlm/midcomms.c:1065:20: warning: context imbalance in 'dlm_midcomms_get_mhandle' - wrong count at exit
Using __CHECKER__ will tell sparse to ignore these sections.
Those imbalances are false positive because from upper layer it is
always required to call a function in sequence, e.g. if
dlm_midcomms_get_mhandle() is successful there must be a
dlm_midcomms_commit_mhandle() call afterwards.
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>1 parent 314a554 commit a8449f2
2 files changed
Lines changed: 20 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1303 | 1303 | | |
1304 | 1304 | | |
1305 | 1305 | | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
1306 | 1310 | | |
1307 | 1311 | | |
1308 | 1312 | | |
| |||
1336 | 1340 | | |
1337 | 1341 | | |
1338 | 1342 | | |
| 1343 | + | |
1339 | 1344 | | |
1340 | 1345 | | |
1341 | 1346 | | |
| |||
1362 | 1367 | | |
1363 | 1368 | | |
1364 | 1369 | | |
| 1370 | + | |
| 1371 | + | |
| 1372 | + | |
| 1373 | + | |
1365 | 1374 | | |
1366 | 1375 | | |
1367 | 1376 | | |
1368 | 1377 | | |
1369 | 1378 | | |
| 1379 | + | |
1370 | 1380 | | |
1371 | 1381 | | |
1372 | 1382 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1062 | 1062 | | |
1063 | 1063 | | |
1064 | 1064 | | |
| 1065 | + | |
| 1066 | + | |
| 1067 | + | |
| 1068 | + | |
1065 | 1069 | | |
1066 | 1070 | | |
1067 | 1071 | | |
| |||
1127 | 1131 | | |
1128 | 1132 | | |
1129 | 1133 | | |
| 1134 | + | |
1130 | 1135 | | |
1131 | 1136 | | |
1132 | 1137 | | |
| |||
1136 | 1141 | | |
1137 | 1142 | | |
1138 | 1143 | | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
1139 | 1148 | | |
1140 | 1149 | | |
1141 | 1150 | | |
| |||
1157 | 1166 | | |
1158 | 1167 | | |
1159 | 1168 | | |
| 1169 | + | |
1160 | 1170 | | |
1161 | 1171 | | |
1162 | 1172 | | |
| |||
0 commit comments