All of lore.kernel.org
 help / color / mirror / Atom feed
From: Josh Durgin <josh.durgin@inktank.com>
To: Alex Elder <elder@inktank.com>
Cc: ceph-devel@vger.kernel.org
Subject: Re: [PATCH] rbd: update feature bits
Date: Thu, 11 Apr 2013 13:04:37 -0700	[thread overview]
Message-ID: <51671755.6040205@inktank.com> (raw)
In-Reply-To: <516715E1.5090708@inktank.com>

Reviewed-by: Josh Durgin <josh.durgin@inktank.com>

On 04/11/2013 12:58 PM, Alex Elder wrote:
> There is a new rbd feature bit defined for "fancy striping." Add
> it to the ones defined in the kernel client.
>
> Change RBD_FEATURES_ALL so it represents the set of all feature
> bits (rather than just the ones we support).  Define a new symbol
> RBD_FEATURES_SUPPORTED to indicate the supported ones.
>
> Signed-off-by: Alex Elder <elder@inktank.com>
> ---
>   drivers/block/rbd.c |    9 ++++++---
>   1 file changed, 6 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
> index 11b7987..503e64f 100644
> --- a/drivers/block/rbd.c
> +++ b/drivers/block/rbd.c
> @@ -73,11 +73,14 @@
>
>   /* Feature bits */
>
> -#define RBD_FEATURE_LAYERING      1
> +#define RBD_FEATURE_LAYERING	(1<<0)
> +#define RBD_FEATURE_STRIPINGV2	(1<<1)
> +#define RBD_FEATURES_ALL \
> +	    (RBD_FEATURE_LAYERING | RBD_FEATURE_STRIPINGV2)
>
>   /* Features supported by this (client software) implementation. */
>
> -#define RBD_FEATURES_ALL          (0)
> +#define RBD_FEATURES_SUPPORTED	(0)
>
>   /*
>    * An RBD device name will be "rbd#", where the "rbd" comes from
> @@ -2843,7 +2846,7 @@ static int _rbd_dev_v2_snap_features(struct
> rbd_device *rbd_dev, u64 snap_id,
>   		return ret;
>
>   	incompat = le64_to_cpu(features_buf.incompat);
> -	if (incompat & ~RBD_FEATURES_ALL)
> +	if (incompat & ~RBD_FEATURES_SUPPORTED)
>   		return -ENXIO;
>
>   	*snap_features = le64_to_cpu(features_buf.features);
>


      reply	other threads:[~2013-04-11 20:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-11 19:58 [PATCH] rbd: update feature bits Alex Elder
2013-04-11 20:04 ` Josh Durgin [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51671755.6040205@inktank.com \
    --to=josh.durgin@inktank.com \
    --cc=ceph-devel@vger.kernel.org \
    --cc=elder@inktank.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.