Commit 4ced9531 authored by Pavel Emelyanov's avatar Pavel Emelyanov

files: Open-code MAKE_GEN_ID macro into its single caller

Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent 1e538cf0
...@@ -188,7 +188,7 @@ static int collect_fds(pid_t pid, struct parasite_drain_fd *dfds) ...@@ -188,7 +188,7 @@ static int collect_fds(pid_t pid, struct parasite_drain_fd *dfds)
static u32 make_gen_id(const struct fd_parms *p) static u32 make_gen_id(const struct fd_parms *p)
{ {
return MAKE_FD_GENID(p->stat.st_dev, p->stat.st_ino, p->pos); return ((u32)p->stat.st_dev) ^ ((u32)p->stat.st_ino) ^ ((u32)p->pos);
} }
int do_dump_gen_file(struct fd_parms *p, int lfd, int do_dump_gen_file(struct fd_parms *p, int lfd,
......
...@@ -10,9 +10,6 @@ ...@@ -10,9 +10,6 @@
#define FD_PID_INVALID (-2U) #define FD_PID_INVALID (-2U)
#define FD_DESC_INVALID (-3U) #define FD_DESC_INVALID (-3U)
#define MAKE_FD_GENID(dev, ino, pos) \
(((u32)(dev) ^ (u32)(ino) ^ (u32)(pos)))
struct fdinfo_entry; struct fdinfo_entry;
extern int fd_id_generate(pid_t pid, FdinfoEntry *fe); extern int fd_id_generate(pid_t pid, FdinfoEntry *fe);
extern u32 fd_id_generate_special(void); extern u32 fd_id_generate_special(void);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment