1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-12 14:29:28 +00:00

A NOP change: style / whitespace cleanup of the noise that slipped

into r191816.

Spotted by:	bz
Approved by:	julian (mentor) (an earlier version of the diff)
This commit is contained in:
Marko Zec 2009-05-08 14:34:25 +00:00
parent ddd50c3439
commit 2114e063f0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=191917
6 changed files with 21 additions and 21 deletions

View File

@ -999,7 +999,7 @@ kern_kldload(struct thread *td, const char *file, int *fileid)
#endif
/*
* It's possible that kldloaded module will attach a new ifnet,
* It is possible that kldloaded module will attach a new ifnet,
* so vnet context must be set when this ocurs.
*/
CURVNET_SET(TD_TO_VNET(td));

View File

@ -286,7 +286,7 @@ soalloc(struct vnet *vnet)
so->so_gencnt = ++so_gencnt;
++numopensockets;
#ifdef VIMAGE
++vnet->sockcnt; /* locked with so_global_mtx */
++vnet->sockcnt; /* Locked with so_global_mtx. */
so->so_vnet = vnet;
#endif
mtx_unlock(&so_global_mtx);
@ -1306,7 +1306,7 @@ sosend(struct socket *so, struct sockaddr *addr, struct uio *uio,
CURVNET_SET(so->so_vnet);
error = so->so_proto->pr_usrreqs->pru_sosend(so, addr, uio, top,
control, flags, td);
control, flags, td);
CURVNET_RESTORE();
return (error);
}

View File

@ -63,8 +63,8 @@ __FBSDID("$FreeBSD$");
#include <sys/syscallsubr.h>
#include <sys/sysctl.h>
#include <sys/uio.h>
#include <sys/vnode.h>
#include <sys/vimage.h>
#include <sys/vnode.h>
#ifdef KTRACE
#include <sys/ktrace.h>
#endif

View File

@ -637,7 +637,7 @@ tcp_hc_purge(void *arg)
CURVNET_SET((struct vnet *) arg);
INIT_VNET_INET(curvnet);
struct hc_metrics *hc_entry, *hc_next;
int all = 0; /* XXX was: (intptr_t)arg - makes no sense? */
int all = 0;
int i;
if (V_tcp_hostcache.purgeall) {

View File

@ -275,8 +275,8 @@ struct thread {
struct lpohead td_lprof[2]; /* (a) lock profiling objects. */
struct kdtrace_thread *td_dtrace; /* (*) DTrace-specific data. */
int td_errno; /* Error returned by last syscall. */
struct vnet *td_vnet; /* (*) Effective vnet */
const char *td_vnet_lpush; /* (*) Debugging vnet push / pop */
struct vnet *td_vnet; /* (*) Effective vnet. */
const char *td_vnet_lpush; /* (*) Debugging vnet push / pop. */
};
struct mtx *thread_lock_block(struct thread *);

View File

@ -200,51 +200,51 @@ extern struct vprocg vprocg_0;
#endif
#endif
#define curvnet curthread->td_vnet
#define curvnet curthread->td_vnet
#define VNET_MAGIC_N 0x3e0d8f29
#define VNET_MAGIC_N 0x3e0d8f29
#ifdef VIMAGE
#ifdef VNET_DEBUG
#define VNET_ASSERT(condition) \
#define VNET_ASSERT(condition) \
if (!(condition)) { \
printf("VNET_ASSERT @ %s:%d %s():\n", \
__FILE__, __LINE__, __FUNCTION__); \
panic(#condition); \
}
#define CURVNET_SET_QUIET(arg) \
#define CURVNET_SET_QUIET(arg) \
VNET_ASSERT((arg)->vnet_magic_n == VNET_MAGIC_N); \
struct vnet *saved_vnet = curvnet; \
const char *saved_vnet_lpush = curthread->td_vnet_lpush; \
curvnet = arg; \
curthread->td_vnet_lpush = __FUNCTION__;
#define CURVNET_SET_VERBOSE(arg) \
#define CURVNET_SET_VERBOSE(arg) \
CURVNET_SET_QUIET(arg) \
if (saved_vnet) \
printf("curvnet_set(%p) in %s() on cpu %d, prev %p in %s()\n", curvnet, \
curthread->td_vnet_lpush, curcpu, \
printf("CURVNET_SET(%p) in %s() on cpu %d, prev %p in %s()\n", \
curvnet, curthread->td_vnet_lpush, curcpu, \
saved_vnet, saved_vnet_lpush);
#define CURVNET_SET(arg) CURVNET_SET_VERBOSE(arg)
#define CURVNET_SET(arg) CURVNET_SET_VERBOSE(arg)
#define CURVNET_RESTORE() \
#define CURVNET_RESTORE() \
VNET_ASSERT(saved_vnet == NULL || \
saved_vnet->vnet_magic_n == VNET_MAGIC_N); \
curvnet = saved_vnet; \
curthread->td_vnet_lpush = saved_vnet_lpush;
#else /* !VNET_DEBUG */
#define VNET_ASSERT(condition)
#define VNET_ASSERT(condition)
#define CURVNET_SET(arg) \
#define CURVNET_SET(arg) \
struct vnet *saved_vnet = curvnet; \
curvnet = arg;
#define CURVNET_SET_VERBOSE(arg) CURVNET_SET(arg)
#define CURVNET_SET_QUIET(arg) CURVNET_SET(arg)
#define CURVNET_SET_VERBOSE(arg) CURVNET_SET(arg)
#define CURVNET_SET_QUIET(arg) CURVNET_SET(arg)
#define CURVNET_RESTORE() \
#define CURVNET_RESTORE() \
curvnet = saved_vnet;
#endif /* !VNET_DEBUG */
#else /* !VIMAGE */