22 Aug, 2012

2 commits


21 Aug, 2012

1 commit

  • The debugfs directory includes the cluster fsid and our unique global_id.
    We need to delay the initialization of the debug entry until we have
    learned both the fsid and our global_id from the monitor or else the
    second client can't create its debugfs entry and will fail (and multiple
    client instances aren't properly reflected in debugfs).

    Reported by: Yan, Zheng
    Signed-off-by: Sage Weil
    Reviewed-by: Yehuda Sadeh

    Sage Weil
     

03 Aug, 2012

1 commit

  • The initial ->atomic_open op was carried over from the old intent code,
    which was incomplete and didn't really work. Replace it with a fresh
    method. In particular:

    * always attempt to do an atomic open+lookup, both for the create case
    and for lookups of existing files.
    * fix symlink handling by returning 1 to the VFS so that we can follow
    the link to its destination. This fixes a longstanding ceph bug (#2392).

    Signed-off-by: Sage Weil

    Sage Weil
     

02 Aug, 2012

1 commit

  • Pull second vfs pile from Al Viro:
    "The stuff in there: fsfreeze deadlock fixes by Jan (essentially, the
    deadlock reproduced by xfstests 068), symlink and hardlink restriction
    patches, plus assorted cleanups and fixes.

    Note that another fsfreeze deadlock (emergency thaw one) is *not*
    dealt with - the series by Fernando conflicts a lot with Jan's, breaks
    userland ABI (FIFREEZE semantics gets changed) and trades the deadlock
    for massive vfsmount leak; this is going to be handled next cycle.
    There probably will be another pull request, but that stuff won't be
    in it."

    Fix up trivial conflicts due to unrelated changes next to each other in
    drivers/{staging/gdm72xx/usb_boot.c, usb/gadget/storage_common.c}

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (54 commits)
    delousing target_core_file a bit
    Documentation: Correct s_umount state for freeze_fs/unfreeze_fs
    fs: Remove old freezing mechanism
    ext2: Implement freezing
    btrfs: Convert to new freezing mechanism
    nilfs2: Convert to new freezing mechanism
    ntfs: Convert to new freezing mechanism
    fuse: Convert to new freezing mechanism
    gfs2: Convert to new freezing mechanism
    ocfs2: Convert to new freezing mechanism
    xfs: Convert to new freezing code
    ext4: Convert to new freezing mechanism
    fs: Protect write paths by sb_start_write - sb_end_write
    fs: Skip atime update on frozen filesystem
    fs: Add freezing handling to mnt_want_write() / mnt_drop_write()
    fs: Improve filesystem freezing handling
    switch the protection of percpu_counter list to spinlock
    nfsd: Push mnt_want_write() outside of i_mutex
    btrfs: Push mnt_want_write() outside of i_mutex
    fat: Push mnt_want_write() outside of i_mutex
    ...

    Linus Torvalds
     

01 Aug, 2012

1 commit

  • Pull Ceph changes from Sage Weil:
    "Lots of stuff this time around:

    - lots of cleanup and refactoring in the libceph messenger code, and
    many hard to hit races and bugs closed as a result.
    - lots of cleanup and refactoring in the rbd code from Alex Elder,
    mostly in preparation for the layering functionality that will be
    coming in 3.7.
    - some misc rbd cleanups from Josh Durgin that are finally going
    upstream
    - support for CRUSH tunables (used by newer clusters to improve the
    data placement)
    - some cleanup in our use of d_parent that Al brought up a while back
    - a random collection of fixes across the tree

    There is another patch coming that fixes up our ->atomic_open()
    behavior, but I'm going to hammer on it a bit more before sending it."

    Fix up conflicts due to commits that were already committed earlier in
    drivers/block/rbd.c, net/ceph/{messenger.c, osd_client.c}

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: (132 commits)
    rbd: create rbd_refresh_helper()
    rbd: return obj version in __rbd_refresh_header()
    rbd: fixes in rbd_header_from_disk()
    rbd: always pass ops array to rbd_req_sync_op()
    rbd: pass null version pointer in add_snap()
    rbd: make rbd_create_rw_ops() return a pointer
    rbd: have __rbd_add_snap_dev() return a pointer
    libceph: recheck con state after allocating incoming message
    libceph: change ceph_con_in_msg_alloc convention to be less weird
    libceph: avoid dropping con mutex before fault
    libceph: verify state after retaking con lock after dispatch
    libceph: revoke mon_client messages on session restart
    libceph: fix handling of immediate socket connect failure
    ceph: update MAINTAINERS file
    libceph: be less chatty about stray replies
    libceph: clear all flags on con_close
    libceph: clean up con flags
    libceph: replace connection state bits with states
    libceph: drop unnecessary CLOSED check in socket state change callback
    libceph: close socket directly from ceph_con_close()
    ...

    Linus Torvalds
     

31 Jul, 2012

6 commits


14 Jul, 2012

10 commits


06 Jul, 2012

1 commit


20 Jun, 2012

1 commit

  • I got lots of NULL pointer dereference Oops when compiling kernel on ceph.
    The bug is because the kernel page migration routine replaces some pages
    in the page cache with new pages, these new pages' private can be non-zero.

    Signed-off-by: Zheng Yan
    Signed-off-by: Sage Weil
    (cherry picked from commit 28c0254ede13ab575d2df5c6585ed3d4817c3e6b)

    Yan, Zheng
     

16 Jun, 2012

1 commit


06 Jun, 2012

1 commit

  • Move the initialization of a ceph connection's private pointer,
    operations vector pointer, and peer name information into
    ceph_con_init(). Rearrange the arguments so the connection pointer
    is first. Hide the byte-swapping of the peer entity number inside
    ceph_con_init()

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     

02 Jun, 2012

1 commit

  • Pull vfs changes from Al Viro.
    "A lot of misc stuff. The obvious groups:
    * Miklos' atomic_open series; kills the damn abuse of
    ->d_revalidate() by NFS, which was the major stumbling block for
    all work in that area.
    * ripping security_file_mmap() and dealing with deadlocks in the
    area; sanitizing the neighborhood of vm_mmap()/vm_munmap() in
    general.
    * ->encode_fh() switched to saner API; insane fake dentry in
    mm/cleancache.c gone.
    * assorted annotations in fs (endianness, __user)
    * parts of Artem's ->s_dirty work (jff2 and reiserfs parts)
    * ->update_time() work from Josef.
    * other bits and pieces all over the place.

    Normally it would've been in two or three pull requests, but
    signal.git stuff had eaten a lot of time during this cycle ;-/"

    Fix up trivial conflicts in Documentation/filesystems/vfs.txt (the
    'truncate_range' inode method was removed by the VM changes, the VFS
    update adds an 'update_time()' method), and in fs/btrfs/ulist.[ch] (due
    to sparse fix added twice, with other changes nearby).

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (95 commits)
    nfs: don't open in ->d_revalidate
    vfs: retry last component if opening stale dentry
    vfs: nameidata_to_filp(): don't throw away file on error
    vfs: nameidata_to_filp(): inline __dentry_open()
    vfs: do_dentry_open(): don't put filp
    vfs: split __dentry_open()
    vfs: do_last() common post lookup
    vfs: do_last(): add audit_inode before open
    vfs: do_last(): only return EISDIR for O_CREAT
    vfs: do_last(): check LOOKUP_DIRECTORY
    vfs: do_last(): make ENOENT exit RCU safe
    vfs: make follow_link check RCU safe
    vfs: do_last(): use inode variable
    vfs: do_last(): inline walk_component()
    vfs: do_last(): make exit RCU safe
    vfs: split do_lookup()
    Btrfs: move over to use ->update_time
    fs: introduce inode operation ->update_time
    reiserfs: get rid of resierfs_sync_super
    reiserfs: mark the superblock as dirty a bit later
    ...

    Linus Torvalds
     

01 Jun, 2012

4 commits

  • A ceph client has a pointer to a ceph messenger structure in it.
    There is always exactly one ceph messenger for a ceph client, so
    there is no need to allocate it separate from the ceph client
    structure.

    Switch the ceph_client structure to embed its ceph_messenger
    structure.

    Signed-off-by: Alex Elder
    Reviewed-by: Yehuda Sadeh
    Reviewed-by: Sage Weil

    Alex Elder
     
  • I got lots of NULL pointer dereference Oops when compiling kernel on ceph.
    The bug is because the kernel page migration routine replaces some pages
    in the page cache with new pages, these new pages' private can be non-zero.

    Signed-off-by: Zheng Yan
    Signed-off-by: Sage Weil

    Yan, Zheng
     
  • Merge misc patches from Andrew Morton:

    - the "misc" tree - stuff from all over the map

    - checkpatch updates

    - fatfs

    - kmod changes

    - procfs

    - cpumask

    - UML

    - kexec

    - mqueue

    - rapidio

    - pidns

    - some checkpoint-restore feature work. Reluctantly. Most of it
    delayed a release. I'm still rather worried that we don't have a
    clear roadmap to completion for this work.

    * emailed from Andrew Morton : (78 patches)
    kconfig: update compression algorithm info
    c/r: prctl: add ability to set new mm_struct::exe_file
    c/r: prctl: extend PR_SET_MM to set up more mm_struct entries
    c/r: procfs: add arg_start/end, env_start/end and exit_code members to /proc/$pid/stat
    syscalls, x86: add __NR_kcmp syscall
    fs, proc: introduce /proc//task//children entry
    sysctl: make kernel.ns_last_pid control dependent on CHECKPOINT_RESTORE
    aio/vfs: cleanup of rw_copy_check_uvector() and compat_rw_copy_check_uvector()
    eventfd: change int to __u64 in eventfd_signal()
    fs/nls: add Apple NLS
    pidns: make killed children autoreap
    pidns: use task_active_pid_ns in do_notify_parent
    rapidio/tsi721: add DMA engine support
    rapidio: add DMA engine support for RIO data transfers
    ipc/mqueue: add rbtree node caching support
    tools/selftests: add mq_perf_tests
    ipc/mqueue: strengthen checks on mqueue creation
    ipc/mqueue: correct mq_attr_ok test
    ipc/mqueue: improve performance of send/recv
    selftests: add mq_open_tests
    ...

    Linus Torvalds
     
  • ULONG_MAX is often used to check for integer overflow when calculating
    allocation size. While ULONG_MAX happens to work on most systems, there
    is no guarantee that `size_t' must be the same size as `long'.

    This patch introduces SIZE_MAX, the maximum value of `size_t', to improve
    portability and readability for allocation size validation.

    Signed-off-by: Xi Wang
    Acked-by: Alex Elder
    Cc: David Airlie
    Cc: Pekka Enberg
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Xi Wang
     

31 May, 2012

1 commit

  • Pull ceph updates from Sage Weil:
    "There are some updates and cleanups to the CRUSH placement code, a bug
    fix with incremental maps, several cleanups and fixes from Josh Durgin
    in the RBD block device code, a series of cleanups and bug fixes from
    Alex Elder in the messenger code, and some miscellaneous bounds
    checking and gfp cleanups/fixes."

    Fix up trivial conflicts in net/ceph/{messenger.c,osdmap.c} due to the
    networking people preferring "unsigned int" over just "unsigned".

    * git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client: (45 commits)
    libceph: fix pg_temp updates
    libceph: avoid unregistering osd request when not registered
    ceph: add auth buf in prepare_write_connect()
    ceph: rename prepare_connect_authorizer()
    ceph: return pointer from prepare_connect_authorizer()
    ceph: use info returned by get_authorizer
    ceph: have get_authorizer methods return pointers
    ceph: ensure auth ops are defined before use
    ceph: messenger: reduce args to create_authorizer
    ceph: define ceph_auth_handshake type
    ceph: messenger: check return from get_authorizer
    ceph: messenger: rework prepare_connect_authorizer()
    ceph: messenger: check prepare_write_connect() result
    ceph: don't set WRITE_PENDING too early
    ceph: drop msgr argument from prepare_write_connect()
    ceph: messenger: send banner in process_connect()
    ceph: messenger: reset connection kvec caller
    libceph: don't reset kvec in prepare_write_banner()
    ceph: ignore preferred_osd field
    ceph: fully initialize new layout
    ...

    Linus Torvalds
     

30 May, 2012

2 commits

  • Use parent_inode has a flag for whether nfsd wants a connectable fh, but
    generate one opportunistically so that we can take advantage of the
    additional info in there.

    Signed-off-by: Sage Weil
    Signed-off-by: Al Viro

    Sage Weil
     
  • pass inode + parent's inode or NULL instead of dentry + bool saying
    whether we want the parent or not.

    NOTE: that needs ceph fix folded in.

    Signed-off-by: Al Viro

    Al Viro
     

17 May, 2012

6 commits

  • Rather than passing a bunch of arguments to be filled in with the
    content of the ceph_auth_handshake buffer now returned by the
    get_authorizer method, just use the returned information in the
    caller, and drop the unnecessary arguments.

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     
  • Have the get_authorizer auth_client method return a ceph_auth
    pointer rather than an integer, pointer-encoding any returned
    error value. This is to pave the way for making use of the
    returned value in an upcoming patch.

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     
  • In the create_authorizer method for both the mds and osd clients,
    the auth_client->ops pointer is blindly dereferenced. There is no
    obvious guarantee that this pointer has been assigned. And
    furthermore, even if the ops pointer is non-null there is definitely
    no guarantee that the create_authorizer or destroy_authorizer
    methods are defined.

    Add checks in both routines to make sure they are defined (non-null)
    before use. Add similar checks in a few other spots in these files
    while we're at it.

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     
  • Make use of the new ceph_auth_handshake structure in order to reduce
    the number of arguments passed to the create_authorizor method in
    ceph_auth_client_ops. Use a local variable of that type as a
    shorthand in the get_authorizer method definitions.

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     
  • The definitions for the ceph_mds_session and ceph_osd both contain
    five fields related only to "authorizers." Encapsulate those fields
    into their own struct type, allowing for better isolation in some
    upcoming patches.

    Fix the #includes in "linux/ceph/osd_client.h" to lay out their more
    complete canonical path.

    Signed-off-by: Alex Elder
    Reviewed-by: Sage Weil

    Alex Elder
     
  • Old users may not expect EINVAL, and there is no clear user-visibile
    behavior change now that we ignore it.

    Signed-off-by: Sage Weil
    Reviewed-by: Alex Elder

    Sage Weil