Deleted Added
full compact
uipc_mqueue.c (229272) uipc_mqueue.c (234607)
1/*-
2 * Copyright (c) 2005 David Xu <davidxu@freebsd.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 29 unchanged lines hidden (view full) ---

38 * times at different mount points but shows same contents.
39 *
40 * 2) Standard POSIX message queue API. The syscalls do not use vfs layer,
41 * but directly operate on internal data structure, this allows user to
42 * use the IPC facility without having to mount mqueue file system.
43 */
44
45#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2005 David Xu <davidxu@freebsd.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 29 unchanged lines hidden (view full) ---

38 * times at different mount points but shows same contents.
39 *
40 * 2) Standard POSIX message queue API. The syscalls do not use vfs layer,
41 * but directly operate on internal data structure, this allows user to
42 * use the IPC facility without having to mount mqueue file system.
43 */
44
45#include <sys/cdefs.h>
46__FBSDID("$FreeBSD: head/sys/kern/uipc_mqueue.c 229272 2012-01-02 12:12:10Z ed $");
46__FBSDID("$FreeBSD: head/sys/kern/uipc_mqueue.c 234607 2012-04-23 14:10:34Z trasz $");
47
48#include "opt_compat.h"
49
50#include <sys/param.h>
51#include <sys/kernel.h>
52#include <sys/systm.h>
53#include <sys/limits.h>
54#include <sys/buf.h>

--- 643 unchanged lines hidden (view full) ---

698/*
699 * task routine
700 */
701static void
702do_recycle(void *context, int pending __unused)
703{
704 struct vnode *vp = (struct vnode *)context;
705
47
48#include "opt_compat.h"
49
50#include <sys/param.h>
51#include <sys/kernel.h>
52#include <sys/systm.h>
53#include <sys/limits.h>
54#include <sys/buf.h>

--- 643 unchanged lines hidden (view full) ---

698/*
699 * task routine
700 */
701static void
702do_recycle(void *context, int pending __unused)
703{
704 struct vnode *vp = (struct vnode *)context;
705
706 vrecycle(vp, curthread);
706 vrecycle(vp);
707 vdrop(vp);
708}
709
710/*
711 * Allocate a vnode
712 */
713static int
714mqfs_allocv(struct mount *mp, struct vnode **vpp, struct mqfs_node *pn)

--- 345 unchanged lines hidden (view full) ---

1060#endif
1061
1062static int
1063mqfs_inactive(struct vop_inactive_args *ap)
1064{
1065 struct mqfs_node *pn = VTON(ap->a_vp);
1066
1067 if (pn->mn_deleted)
707 vdrop(vp);
708}
709
710/*
711 * Allocate a vnode
712 */
713static int
714mqfs_allocv(struct mount *mp, struct vnode **vpp, struct mqfs_node *pn)

--- 345 unchanged lines hidden (view full) ---

1060#endif
1061
1062static int
1063mqfs_inactive(struct vop_inactive_args *ap)
1064{
1065 struct mqfs_node *pn = VTON(ap->a_vp);
1066
1067 if (pn->mn_deleted)
1068 vrecycle(ap->a_vp, ap->a_td);
1068 vrecycle(ap->a_vp);
1069 return (0);
1070}
1071
1072#if 0
1073struct vop_reclaim_args {
1074 struct vop_generic_args a_gen;
1075 struct vnode *a_vp;
1076 struct thread *a_td;

--- 1760 unchanged lines hidden ---
1069 return (0);
1070}
1071
1072#if 0
1073struct vop_reclaim_args {
1074 struct vop_generic_args a_gen;
1075 struct vnode *a_vp;
1076 struct thread *a_td;

--- 1760 unchanged lines hidden ---