]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-client.git/commitdiff
rbd: don't use ENOTSUPP
authorAlex Elder <elder@dreamhost.com>
Thu, 1 Nov 2012 13:39:26 +0000 (08:39 -0500)
committerAlex Elder <elder@inktank.com>
Mon, 19 Nov 2012 23:37:47 +0000 (17:37 -0600)
ENOTSUPP is not a standard errno (it shows up as "Unknown error 524"
in an error message).  This is what was getting produced when the
the local rbd code does not implement features required by a
discovered rbd image.

Change the error code returned in this case to ENXIO.

Signed-off-by: Alex Elder <elder@inktank.com>
drivers/block/rbd.c

index 6512a8ee0b09a46cba89d0f7d1f6348053efbb0c..3378963a3afbe3d12735006e23eaee9e8f8681bc 100644 (file)
@@ -2465,7 +2465,7 @@ static int _rbd_dev_v2_snap_features(struct rbd_device *rbd_dev, u64 snap_id,
 
        incompat = le64_to_cpu(features_buf.incompat);
        if (incompat & ~RBD_FEATURES_ALL)
-               return -ENOTSUPP;
+               return -ENXIO;
 
        *snap_features = le64_to_cpu(features_buf.features);