diff options
| author | Chengguang Xu <cgxu519@gmx.com> | 2018-04-12 00:04:55 -0400 |
|---|---|---|
| committer | Ilya Dryomov <idryomov@gmail.com> | 2018-06-04 14:45:54 -0400 |
| commit | fe943d50425b6646606f8ef1ef8b8d4975fdbee2 (patch) | |
| tree | 4e2ecd6eb4ba41fa02a7761d99348e13c9ad5212 /include/linux/ceph | |
| parent | 29dcea88779c856c7dc92040a0c01233263101d4 (diff) | |
libceph, rbd: add error handling for osd_req_op_cls_init()
Add proper error handling for osd_req_op_cls_init() to replace
BUG_ON statement when failing from memory allocation.
Signed-off-by: Chengguang Xu <cgxu519@gmx.com>
Reviewed-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'include/linux/ceph')
| -rw-r--r-- | include/linux/ceph/osd_client.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/ceph/osd_client.h b/include/linux/ceph/osd_client.h index 96bb32285989..b73dd7ebe585 100644 --- a/include/linux/ceph/osd_client.h +++ b/include/linux/ceph/osd_client.h | |||
| @@ -440,7 +440,7 @@ extern void osd_req_op_cls_response_data_pages(struct ceph_osd_request *, | |||
| 440 | struct page **pages, u64 length, | 440 | struct page **pages, u64 length, |
| 441 | u32 alignment, bool pages_from_pool, | 441 | u32 alignment, bool pages_from_pool, |
| 442 | bool own_pages); | 442 | bool own_pages); |
| 443 | extern void osd_req_op_cls_init(struct ceph_osd_request *osd_req, | 443 | extern int osd_req_op_cls_init(struct ceph_osd_request *osd_req, |
| 444 | unsigned int which, u16 opcode, | 444 | unsigned int which, u16 opcode, |
| 445 | const char *class, const char *method); | 445 | const char *class, const char *method); |
| 446 | extern int osd_req_op_xattr_init(struct ceph_osd_request *osd_req, unsigned int which, | 446 | extern int osd_req_op_xattr_init(struct ceph_osd_request *osd_req, unsigned int which, |
