From patchwork Fri Apr 18 14:48:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yan, Zheng" X-Patchwork-Id: 4016751 Return-Path: X-Original-To: patchwork-ceph-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 51E409F2BA for ; Fri, 18 Apr 2014 14:49:26 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 91496203B6 for ; Fri, 18 Apr 2014 14:49:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C34A8203B1 for ; Fri, 18 Apr 2014 14:49:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753913AbaDROtQ (ORCPT ); Fri, 18 Apr 2014 10:49:16 -0400 Received: from mga11.intel.com ([192.55.52.93]:42749 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751314AbaDROtM (ORCPT ); Fri, 18 Apr 2014 10:49:12 -0400 Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP; 18 Apr 2014 07:49:12 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.97,884,1389772800"; d="scan'208";a="522900175" Received: from unknown (HELO zyan5-mobl.ccr.corp.intel.com) ([10.255.20.58]) by fmsmga002.fm.intel.com with ESMTP; 18 Apr 2014 07:48:44 -0700 From: "Yan, Zheng" To: ceph-devel@vger.kernel.org Cc: "Yan, Zheng" Subject: [PATCH 1/6] ceph: avoid releasing caps that are being used Date: Fri, 18 Apr 2014 22:48:37 +0800 Message-Id: <1397832522-9557-1-git-send-email-zheng.z.yan@intel.com> X-Mailer: git-send-email 1.9.0 Sender: ceph-devel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: ceph-devel@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP To avoid releasing caps that are being used, encode_inode_release() should send implemented caps to MDS. Signed-off-by: Yan, Zheng --- fs/ceph/caps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ceph/caps.c b/fs/ceph/caps.c index 9946ce3..de39a03 100644 --- a/fs/ceph/caps.c +++ b/fs/ceph/caps.c @@ -3267,7 +3267,7 @@ int ceph_encode_inode_release(void **p, struct inode *inode, rel->seq = cpu_to_le32(cap->seq); rel->issue_seq = cpu_to_le32(cap->issue_seq), rel->mseq = cpu_to_le32(cap->mseq); - rel->caps = cpu_to_le32(cap->issued); + rel->caps = cpu_to_le32(cap->implemented); rel->wanted = cpu_to_le32(cap->mds_wanted); rel->dname_len = 0; rel->dname_seq = 0;