/*
* Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
+ *
+ * Copyright (c) 2012, 2013, Intel Corporation.
*/
/*
* This file is part of Lustre, http://www.lustre.org/
*/
#define DEBUG_SUBSYSTEM S_CLASS
-#ifndef EXPORT_SYMTAB
-# define EXPORT_SYMTAB
-#endif
#ifndef __KERNEL__
#include <liblustre.h>
LTIME_S(dst->i_ctime) = src->o_ctime;
if (valid & OBD_MD_FLSIZE)
i_size_write(dst, src->o_size);
- /* optimum IO size */
- if (valid & OBD_MD_FLBLKSZ && src->o_blksize > (1 << dst->i_blkbits)) {
- dst->i_blkbits = cfs_ffs(src->o_blksize) - 1;
-#ifdef HAVE_INODE_BLKSIZE
- dst->i_blksize = src->o_blksize;
-#endif
- }
+ /* optimum IO size */
+ if (valid & OBD_MD_FLBLKSZ && src->o_blksize > (1 << dst->i_blkbits))
+ dst->i_blkbits = ffs(src->o_blksize) - 1;
- if (dst->i_blkbits < CFS_PAGE_SHIFT) {
-#ifdef HAVE_INODE_BLKSIZE
- dst->i_blksize = CFS_PAGE_SIZE;
-#endif
- dst->i_blkbits = CFS_PAGE_SHIFT;
- }
+ if (dst->i_blkbits < CFS_PAGE_SHIFT)
+ dst->i_blkbits = CFS_PAGE_SHIFT;
/* allocation of space */
if (valid & OBD_MD_FLBLOCKS && src->o_blocks > dst->i_blocks)
{
valid &= src->o_valid;
- LASSERTF(!(valid & (OBD_MD_FLTYPE | OBD_MD_FLGENER | OBD_MD_FLFID |
- OBD_MD_FLID | OBD_MD_FLGROUP)),
- "object "LPU64"/"LPU64", valid %x\n",
- src->o_id, src->o_seq, valid);
+ LASSERTF(!(valid & (OBD_MD_FLTYPE | OBD_MD_FLGENER | OBD_MD_FLFID |
+ OBD_MD_FLID | OBD_MD_FLGROUP)),
+ "object "DOSTID", valid %x\n", POSTID(&src->o_oi), valid);
if (valid & (OBD_MD_FLCTIME | OBD_MD_FLMTIME))
CDEBUG(D_INODE,
dst->i_blocks = -1;
}
- if (valid & OBD_MD_FLBLKSZ) {
- dst->i_blkbits = cfs_ffs(src->o_blksize)-1;
-#ifdef HAVE_INODE_BLKSIZE
- dst->i_blksize = src->o_blksize;
-#endif
- }
+ if (valid & OBD_MD_FLBLKSZ)
+ dst->i_blkbits = ffs(src->o_blksize)-1;
if (valid & OBD_MD_FLMODE)
dst->i_mode = (dst->i_mode & S_IFMT) | (src->o_mode & ~S_IFMT);
if (valid & OBD_MD_FLUID)