From patchwork Tue Sep 4 18:08:55 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Elder X-Patchwork-Id: 1403591 Return-Path: X-Original-To: patchwork-ceph-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 7480A3FC71 for ; Tue, 4 Sep 2012 18:09:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932456Ab2IDSI7 (ORCPT ); Tue, 4 Sep 2012 14:08:59 -0400 Received: from mail-iy0-f174.google.com ([209.85.210.174]:65061 "EHLO mail-iy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932453Ab2IDSI6 (ORCPT ); Tue, 4 Sep 2012 14:08:58 -0400 Received: by iahk25 with SMTP id k25so5860739iah.19 for ; Tue, 04 Sep 2012 11:08:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject :content-type:content-transfer-encoding:x-gm-message-state; bh=vyOrOheOD66doPnRv8wKv11wPmD+EDylYuLrVlnLbd8=; b=oAjD7B7Pj9j78jO1urXIlfs0w2NBqYhOwvMod34LBdGQvyr/ifzIggUhUfNIY2J07L GHd5vGBcwRYQhoyPBUpCIOkQr1WC2YZfJf8Xi9fddXb1u+15/WFGlaIzRCl0zyYQJpHj FVxfVvnOLfRKpQFGT29Q5WqKKUWkdm7BofoOSUU/pV+pqxbz1hR8PagG2vm2JXjBX3Eg TbOD166wWu+FukbeIPd6Y9PMDmTWcKK7UE60CLVCcx9Sfy+FN0ohTT9ufGGWaWbsKdi9 JzwqCNaD2RDuJ4GvVtwC6vtwjUSB23yzjnXMJ1q/V5ys4mfXwAz9YNC1JQUebtXVHDj+ 9ueQ== Received: by 10.50.217.137 with SMTP id oy9mr15091856igc.56.1346782138087; Tue, 04 Sep 2012 11:08:58 -0700 (PDT) Received: from [172.22.22.4] (c-71-195-31-37.hsd1.mn.comcast.net. [71.195.31.37]) by mx.google.com with ESMTPS id nh1sm13081105igc.11.2012.09.04.11.08.56 (version=SSLv3 cipher=OTHER); Tue, 04 Sep 2012 11:08:57 -0700 (PDT) Message-ID: <504643B7.1060507@inktank.com> Date: Tue, 04 Sep 2012 13:08:55 -0500 From: Alex Elder User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120827 Thunderbird/15.0 MIME-Version: 1.0 To: "ceph-devel@vger.kernel.org" Subject: [PATCH] rbd: rename block_name -> object_prefix X-Gm-Message-State: ALoCoQnxIT18wNbgRNiYtFBo64AYgml2G0gjBmTLIU2f+75+RNSV7jdUOnJ8FzUrArUAYPGWI7yH Sender: ceph-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: ceph-devel@vger.kernel.org In the on-disk image header structure there is a field "block_name" which represents what we now call the "object prefix" for an rbd image. Rename this field "object_prefix" to be consistent with modern usage. This appears to be the only remaining vestige of the use of "block" in symbols that represent objects in the rbd code. This addresses http://tracker.newdream.net/issues/1761 Signed-off-by: Alex Elder Reviewed-by: Josh Durgin Reviewed-by: Dan Mick --- drivers/block/rbd.c | 4 ++-- drivers/block/rbd_types.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c index fd51f9d..2b40a4a 100644 --- a/drivers/block/rbd.c +++ b/drivers/block/rbd.c @@ -522,11 +522,11 @@ static int rbd_header_from_disk(struct rbd_image_header *header, snap_count = le32_to_cpu(ondisk->snap_count); - size = sizeof (ondisk->block_name) + 1; + size = sizeof (ondisk->object_prefix) + 1; header->object_prefix = kmalloc(size, GFP_KERNEL); if (!header->object_prefix) return -ENOMEM; - memcpy(header->object_prefix, ondisk->block_name, size - 1); + memcpy(header->object_prefix, ondisk->object_prefix, size - 1); header->object_prefix[size - 1] = '\0'; if (snap_count) { diff --git a/drivers/block/rbd_types.h b/drivers/block/rbd_types.h index 0924e9e..d9d8a77 100644 --- a/drivers/block/rbd_types.h +++ b/drivers/block/rbd_types.h @@ -47,7 +47,7 @@ struct rbd_image_snap_ondisk { struct rbd_image_header_ondisk { char text[40]; - char block_name[24]; + char object_prefix[24]; char signature[4]; char version[8]; struct {