Skip to content

Commit

Permalink
lvm: Add missing argument to libblockdev API for thinpool
Browse files Browse the repository at this point in the history
It takes a boolean:
```
 * @discard: whether discard/TRIM is required to be supported or not
```

So I don't know offhand whether anything in anaconda has support for
forcing TRIM support on or not.  `git grep -i trim` in both blivet and
anaconda has no obvious hits, so I'm going to go ahead and assume no.
In that case, let's pass `False` here to avoid blowing chunks.

NOTE: Not actually tested, but I was trying to do thinp via kickstart
with a rawhide installer and saw a traceback for this, and it looks
right to me.
  • Loading branch information
cgwalters committed May 21, 2015
1 parent 93d0e21 commit 085ff18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blivet/devices/lvm.py
Expand Up @@ -1016,7 +1016,7 @@ def __init__(self, name, parents=None, size=None, uuid=None,
raise ValueError("invalid metadatasize value")

if chunksize is not None and \
not blockdev.lvm.is_valid_thpool_chunk_size(chunksize):
not blockdev.lvm.is_valid_thpool_chunk_size(chunksize, False):
raise ValueError("invalid chunksize value")

super(LVMThinPoolDevice, self).__init__(name, parents=parents,
Expand Down

0 comments on commit 085ff18

Please sign in to comment.