]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/blobdiff - repair/slab.h
xfs: perags need atomic operational state
[thirdparty/xfsprogs-dev.git] / repair / slab.h
index 4aa551212581e2902a91451c9f13d10445566d41..aab46ecf1f080487e3578ea7104a11541195c405 100644 (file)
@@ -1,21 +1,7 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * Copyright (C) 2016 Oracle.  All Rights Reserved.
- *
  * Author: Darrick J. Wong <darrick.wong@oracle.com>
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it would be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write the Free Software Foundation,
- * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301, USA.
  */
 #ifndef SLAB_H_
 #define SLAB_H_
@@ -54,7 +40,7 @@ extern void *bag_item(struct xfs_bag *, size_t);
 
 #define foreach_bag_ptr_reverse(bag, idx, ptr) \
        for ((idx) = bag_count(bag) - 1, (ptr) = bag_item((bag), (idx)); \
-            (idx) >= 0 && (ptr) != NULL; \
+            (ptr) != NULL; \
             (idx)--, (ptr) = bag_item((bag), (idx)))
 
 #endif /* SLAB_H_ */