summaryrefslogtreecommitdiffstats
path: root/storage/formats/fs.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2009-04-09 14:06:55 -0400
committerChris Lumens <clumens@redhat.com>2009-04-09 14:06:55 -0400
commitc1ece24b11e089d9b9aeaee9803673be385ab974 (patch)
tree1704238f25e08eeb77d770a07138d07bfd251694 /storage/formats/fs.py
parent676eef46f74815161985bced95275f1a53fd6363 (diff)
downloadanaconda-c1ece24b11e089d9b9aeaee9803673be385ab974.tar.gz
anaconda-c1ece24b11e089d9b9aeaee9803673be385ab974.tar.xz
anaconda-c1ece24b11e089d9b9aeaee9803673be385ab974.zip
When a new module is loaded, update the kernel_filesystems list.
Diffstat (limited to 'storage/formats/fs.py')
-rw-r--r--storage/formats/fs.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/storage/formats/fs.py b/storage/formats/fs.py
index 657f73c4b..19f488c44 100644
--- a/storage/formats/fs.py
+++ b/storage/formats/fs.py
@@ -53,6 +53,8 @@ def get_kernel_filesystems():
for line in open("/proc/filesystems").readlines():
fs_list.append(line.split()[-1])
return fs_list
+
+global kernel_filesystems
kernel_filesystems = get_kernel_filesystems()
def fsFromConfig(attrs, *args, **kwargs):
@@ -433,6 +435,8 @@ class FS(DeviceFormat):
def loadModule(self):
"""Load whatever kernel module is required to support this filesystem."""
+ global kernel_filesystems
+
if not self._modules or self.type in kernel_filesystems:
return
@@ -451,6 +455,10 @@ class FS(DeviceFormat):
self._supported = False
return
+ # If we successfully loaded a kernel module, for this filesystem, we
+ # also need to update the list of supported filesystems.
+ kernel_filesystems = get_kernel_filesystems()
+
def mount(self, *args, **kwargs):
""" Mount this filesystem.