]> git.proxmox.com Git - ceph.git/blame - ceph/src/include/krbd.h
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / src / include / krbd.h
CommitLineData
7c673cae
FG
1/*
2 * Ceph - scalable distributed file system
3 *
4 * Copyright (C) 2014 Inktank Storage, Inc.
5 *
6 * This is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License version 2.1, as published by the Free Software
9 * Foundation. See file COPYING.
10 *
11 */
12
13#ifndef CEPH_KRBD_H
14#define CEPH_KRBD_H
15
16#include "rados/librados.h"
17
18#ifdef __cplusplus
19extern "C" {
20#endif
21
22struct krbd_ctx;
23
24int krbd_create_from_context(rados_config_t cct, struct krbd_ctx **pctx);
25void krbd_destroy(struct krbd_ctx *ctx);
26
27int krbd_map(struct krbd_ctx *ctx, const char *pool, const char *image,
28 const char *snap, const char *options, char **pdevnode);
29
30int krbd_unmap(struct krbd_ctx *ctx, const char *devnode,
31 const char *options);
32int krbd_unmap_by_spec(struct krbd_ctx *ctx, const char *pool,
33 const char *image, const char *snap,
34 const char *options);
35
36#ifdef __cplusplus
37}
38#endif
39
40#ifdef __cplusplus
41
42namespace ceph {
43 class Formatter;
44}
45
46int krbd_showmapped(struct krbd_ctx *ctx, ceph::Formatter *f);
47
48#endif /* __cplusplus */
49
50#endif /* CEPH_KRBD_H */