|
@@ -115,6 +115,11 @@ static inline void ceph_oid_init(struct ceph_object_id *oid)
|
|
oid->name_len = 0;
|
|
oid->name_len = 0;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+#define CEPH_OID_INIT_ONSTACK(oid) \
|
|
|
|
+ ({ ceph_oid_init(&oid); oid; })
|
|
|
|
+#define CEPH_DEFINE_OID_ONSTACK(oid) \
|
|
|
|
+ struct ceph_object_id oid = CEPH_OID_INIT_ONSTACK(oid)
|
|
|
|
+
|
|
static inline bool ceph_oid_empty(const struct ceph_object_id *oid)
|
|
static inline bool ceph_oid_empty(const struct ceph_object_id *oid)
|
|
{
|
|
{
|
|
return oid->name == oid->inline_name && !oid->name_len;
|
|
return oid->name == oid->inline_name && !oid->name_len;
|