]> git.proxmox.com Git - pve-storage.git/commitdiff
BTRFSPlugin: reuse DirPlugin update/get_volume_attribute
authorDominik Csapak <d.csapak@proxmox.com>
Thu, 2 Jun 2022 08:52:14 +0000 (10:52 +0200)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Tue, 5 Jul 2022 09:24:58 +0000 (11:24 +0200)
this allows setting notes+protected for backups on btrfs

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Acked-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
PVE/Storage/BTRFSPlugin.pm

index be613f4045b52c03953c8d4b7e8ff468186516b0..1db4e4f8712fd23ebb8e2eba6292ac836cfd6432 100644 (file)
@@ -138,9 +138,22 @@ sub status {
     return PVE::Storage::DirPlugin::status($class, $storeid, $scfg, $cache);
 }
 
-# TODO: sub get_volume_attribute {}
+sub get_volume_attribute {
+    my ($class, $scfg, $storeid, $volname, $attribute) = @_;
+    return PVE::Storage::DirPlugin::get_volume_attribute($class, $scfg, $storeid, $volname, $attribute);
+}
 
-# TODO: sub update_volume_attribute {}
+sub update_volume_attribute {
+    my ($class, $scfg, $storeid, $volname, $attribute, $value) = @_;
+    return PVE::Storage::DirPlugin::update_volume_attribute(
+       $class,
+       $scfg,
+       $storeid,
+       $volname,
+       $attribute,
+       $value,
+    );
+}
 
 # croak would not include the caller from within this module
 sub __error {