aboutsummaryrefslogtreecommitdiff
path: root/lib/libufs/cgroup.c
diff options
context:
space:
mode:
authorPedro F. Giffuni <pfg@FreeBSD.org>2016-05-18 19:59:05 +0000
committerPedro F. Giffuni <pfg@FreeBSD.org>2016-05-18 19:59:05 +0000
commit44444759e55ced33e066e5caa7739dfa09baa037 (patch)
tree75d92b7e4d9a9ef2f229ca78c57492b63756aeb2 /lib/libufs/cgroup.c
parentfefbf770248c1aa61eeb60b673a3aa7921a916ca (diff)
downloadsrc-44444759e55ced33e066e5caa7739dfa09baa037.tar.gz
src-44444759e55ced33e066e5caa7739dfa09baa037.zip
libufs: Simplify generation number calculation.
UFS generation numbers have been unsigned since 2013 (r256435).
Notes
Notes: svn path=/head/; revision=300163
Diffstat (limited to 'lib/libufs/cgroup.c')
-rw-r--r--lib/libufs/cgroup.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libufs/cgroup.c b/lib/libufs/cgroup.c
index 8ab33f7c7c9f..dfb10d3feb94 100644
--- a/lib/libufs/cgroup.c
+++ b/lib/libufs/cgroup.c
@@ -157,7 +157,7 @@ gotit:
bzero(block, (int)fs->fs_bsize);
dp2 = (struct ufs2_dinode *)&block;
for (i = 0; i < INOPB(fs); i++) {
- dp2->di_gen = arc4random() / 2 + 1;
+ dp2->di_gen = arc4random();
dp2++;
}
if (bwrite(disk, ino_to_fsba(fs,