cregit-Linux how code gets into the kernel

Release 4.12 include/linux/ceph/buffer.h

#ifndef __FS_CEPH_BUFFER_H

#define __FS_CEPH_BUFFER_H

#include <linux/kref.h>
#include <linux/mm.h>
#include <linux/vmalloc.h>
#include <linux/types.h>
#include <linux/uio.h>

/*
 * a simple reference counted buffer.
 *
 * use kmalloc for smaller sizes, vmalloc for larger sizes.
 */

struct ceph_buffer {
	
struct kref kref;
	
struct kvec vec;
	
size_t alloc_len;
};

extern struct ceph_buffer *ceph_buffer_new(size_t len, gfp_t gfp);
extern void ceph_buffer_release(struct kref *kref);


static inline struct ceph_buffer *ceph_buffer_get(struct ceph_buffer *b) { kref_get(&b->kref); return b; }

Contributors

PersonTokensPropCommitsCommitProp
Sage Weil25100.00%2100.00%
Total25100.00%2100.00%


static inline void ceph_buffer_put(struct ceph_buffer *b) { kref_put(&b->kref, ceph_buffer_release); }

Contributors

PersonTokensPropCommitsCommitProp
Sage Weil22100.00%2100.00%
Total22100.00%2100.00%

extern int ceph_decode_buffer(struct ceph_buffer **b, void **p, void *end); #endif

Overall Contributors

PersonTokensPropCommitsCommitProp
Sage Weil12999.23%480.00%
Ilya Dryomov10.77%120.00%
Total130100.00%5100.00%
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.