/** * ecryptfs_miscdev_quit * @euid: effective user id of miscdevess sending quit packet * @user_ns: The namespace in which @euid applies * @pid: miscdevess id of miscdevess sending quit packet * * Returns zero on success; non-zero otherwise */ static int ecryptfs_miscdev_quit(uid_t euid, struct user_namespace *user_ns, struct pid *pid) { int rc; rc = ecryptfs_process_quit(euid, user_ns, pid); if (rc) printk(KERN_WARNING "Error processing QUIT message; rc = [%d]\n", rc); return rc; }
/** * ecryptfs_process_nl_quit * @skb: The socket buffer containing the nlmsghdr in QUIT state * * Gets uid and pid of the skb and deletes the corresponding daemon * id, if it is the registered that is requesting the * deletion. Returns zero after deleting the desired daemon id; * non-zero otherwise. */ static int ecryptfs_process_nl_quit(struct sk_buff *skb) { int rc; rc = ecryptfs_process_quit(NETLINK_CREDS(skb)->uid, NETLINK_CREDS(skb)->pid); if (rc) printk(KERN_WARNING "Error processing QUIT message; rc = [%d]\n", rc); return rc; }
/** * ecryptfs_process_nl_quit * @skb: The socket buffer containing the nlmsghdr in QUIT state * * Gets uid and pid of the skb and deletes the corresponding daemon * id, if it is the registered that is requesting the * deletion. Returns zero after deleting the desired daemon id; * non-zero otherwise. */ static int ecryptfs_process_nl_quit(struct sk_buff *skb) { struct pid *pid; int rc; pid = find_get_pid(NETLINK_CREDS(skb)->pid); rc = ecryptfs_process_quit(NETLINK_CREDS(skb)->uid, NULL, pid); put_pid(pid); if (rc) printk(KERN_WARNING "Error processing QUIT message; rc = [%d]\n", rc); return rc; }