Commit 028ddca
bcache: Remove unnecessary NULL point check in node allocations
Due to the previous fix of __bch_btree_node_alloc, the return value will
never be a NULL pointer. So IS_ERR is enough to handle the failure
situation. Fix it by replacing IS_ERR_OR_NULL check by an IS_ERR check.
Fixes: cafe563 ("bcache: A block layer cache")
Cc: stable@vger.kernel.org
Signed-off-by: Zheng Wang <zyytlz.wz@163.com>
Signed-off-by: Coly Li <colyli@suse.de>
Link: https://lore.kernel.org/r/20230615121223.22502-5-colyli@suse.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>1 parent ccb8c3b commit 028ddca
2 files changed
+7
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1138 | 1138 | | |
1139 | 1139 | | |
1140 | 1140 | | |
1141 | | - | |
| 1141 | + | |
1142 | 1142 | | |
1143 | 1143 | | |
1144 | 1144 | | |
| |||
1340 | 1340 | | |
1341 | 1341 | | |
1342 | 1342 | | |
1343 | | - | |
| 1343 | + | |
1344 | 1344 | | |
1345 | 1345 | | |
1346 | 1346 | | |
| |||
1352 | 1352 | | |
1353 | 1353 | | |
1354 | 1354 | | |
1355 | | - | |
| 1355 | + | |
1356 | 1356 | | |
1357 | 1357 | | |
1358 | 1358 | | |
| |||
1487 | 1487 | | |
1488 | 1488 | | |
1489 | 1489 | | |
1490 | | - | |
| 1490 | + | |
1491 | 1491 | | |
1492 | 1492 | | |
1493 | 1493 | | |
| |||
1669 | 1669 | | |
1670 | 1670 | | |
1671 | 1671 | | |
1672 | | - | |
| 1672 | + | |
1673 | 1673 | | |
1674 | 1674 | | |
1675 | 1675 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1723 | 1723 | | |
1724 | 1724 | | |
1725 | 1725 | | |
1726 | | - | |
| 1726 | + | |
1727 | 1727 | | |
1728 | 1728 | | |
1729 | 1729 | | |
| |||
2087 | 2087 | | |
2088 | 2088 | | |
2089 | 2089 | | |
2090 | | - | |
| 2090 | + | |
2091 | 2091 | | |
2092 | 2092 | | |
2093 | 2093 | | |
| |||
0 commit comments