From owner-svn-src-all@FreeBSD.ORG Tue Mar 22 10:39:35 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4330A106566B; Tue, 22 Mar 2011 10:39:35 +0000 (UTC) (envelope-from pjd@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 335718FC08; Tue, 22 Mar 2011 10:39:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p2MAdZJp054971; Tue, 22 Mar 2011 10:39:35 GMT (envelope-from pjd@svn.freebsd.org) Received: (from pjd@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p2MAdZ10054963; Tue, 22 Mar 2011 10:39:35 GMT (envelope-from pjd@svn.freebsd.org) Message-Id: <201103221039.p2MAdZ10054963@svn.freebsd.org> From: Pawel Jakub Dawidek Date: Tue, 22 Mar 2011 10:39:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r219864 - head/sbin/hastd X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Mar 2011 10:39:35 -0000 Author: pjd Date: Tue Mar 22 10:39:34 2011 New Revision: 219864 URL: http://svn.freebsd.org/changeset/base/219864 Log: White space cleanups. MFC after: 1 week Modified: head/sbin/hastd/activemap.c head/sbin/hastd/hastd.8 head/sbin/hastd/hastd.c head/sbin/hastd/primary.c head/sbin/hastd/proto_tcp4.c head/sbin/hastd/secondary.c head/sbin/hastd/subr.c Modified: head/sbin/hastd/activemap.c ============================================================================== --- head/sbin/hastd/activemap.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/activemap.c Tue Mar 22 10:39:34 2011 (r219864) @@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$"); #define ACTIVEMAP_MAGIC 0xac71e4 struct activemap { int am_magic; /* Magic value. */ - off_t am_mediasize; /* Media size in bytes. */ + off_t am_mediasize; /* Media size in bytes. */ uint32_t am_extentsize; /* Extent size in bytes, must be power of 2. */ uint8_t am_extentshift;/* 2 ^ extentbits == extentsize */ Modified: head/sbin/hastd/hastd.8 ============================================================================== --- head/sbin/hastd/hastd.8 Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/hastd.8 Tue Mar 22 10:39:34 2011 (r219864) @@ -95,7 +95,7 @@ following option: .Bd -ragged -offset indent .Cd "options GEOM_GATE" .Ed -.Pp +.Pp The connection between two .Nm daemons is always initiated from the one running as primary to the one Modified: head/sbin/hastd/hastd.c ============================================================================== --- head/sbin/hastd/hastd.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/hastd.c Tue Mar 22 10:39:34 2011 (r219864) @@ -132,19 +132,19 @@ dtype2str(mode_t mode) if (S_ISBLK(mode)) return ("block device"); - else if (S_ISCHR(mode)) + else if (S_ISCHR(mode)) return ("character device"); - else if (S_ISDIR(mode)) + else if (S_ISDIR(mode)) return ("directory"); else if (S_ISFIFO(mode)) return ("pipe or FIFO"); - else if (S_ISLNK(mode)) + else if (S_ISLNK(mode)) return ("symbolic link"); - else if (S_ISREG(mode)) + else if (S_ISREG(mode)) return ("regular file"); else if (S_ISSOCK(mode)) return ("socket"); - else if (S_ISWHT(mode)) + else if (S_ISWHT(mode)) return ("whiteout"); else return ("unknown"); @@ -929,7 +929,7 @@ main_loop(void) time_t lastcheck, now; fd_set rfds; - lastcheck = time(NULL); + lastcheck = time(NULL); seltimeout.tv_sec = REPORT_INTERVAL; seltimeout.tv_usec = 0; Modified: head/sbin/hastd/primary.c ============================================================================== --- head/sbin/hastd/primary.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/primary.c Tue Mar 22 10:39:34 2011 (r219864) @@ -183,7 +183,7 @@ static pthread_mutex_t metadata_lock; while (((hio) = TAILQ_FIRST(&hio_##name##_list[(ncomp)])) == NULL && !_last) { \ cv_timedwait(&hio_##name##_list_cond[(ncomp)], \ &hio_##name##_list_lock[(ncomp)], (timeout)); \ - if ((timeout) != 0) \ + if ((timeout) != 0) \ _last = true; \ } \ if (hio != NULL) { \ @@ -1268,7 +1268,7 @@ keepalive_send(struct hast_resource *res rw_unlock(&hio_remote_lock[ncomp]); return; } - + PJDLOG_ASSERT(res->hr_remotein != NULL); PJDLOG_ASSERT(res->hr_remoteout != NULL); @@ -1314,7 +1314,7 @@ remote_send_thread(void *arg) /* Remote component is 1 for now. */ ncomp = 1; - lastcheck = time(NULL); + lastcheck = time(NULL); for (;;) { pjdlog_debug(2, "remote_send: Taking request."); Modified: head/sbin/hastd/proto_tcp4.c ============================================================================== --- head/sbin/hastd/proto_tcp4.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/proto_tcp4.c Tue Mar 22 10:39:34 2011 (r219864) @@ -337,7 +337,7 @@ tcp4_connect_wait(void *ctx, int timeout tv.tv_usec = 0; again: FD_ZERO(&fdset); - FD_SET(tctx->tc_fd, &fdset); + FD_SET(tctx->tc_fd, &fdset); ret = select(tctx->tc_fd + 1, NULL, &fdset, NULL, &tv); if (ret == 0) { error = ETIMEDOUT; Modified: head/sbin/hastd/secondary.c ============================================================================== --- head/sbin/hastd/secondary.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/secondary.c Tue Mar 22 10:39:34 2011 (r219864) @@ -65,8 +65,8 @@ __FBSDID("$FreeBSD$"); #include "synch.h" struct hio { - uint64_t hio_seq; - int hio_error; + uint64_t hio_seq; + int hio_error; struct nv *hio_nv; void *hio_data; uint8_t hio_cmd; Modified: head/sbin/hastd/subr.c ============================================================================== --- head/sbin/hastd/subr.c Tue Mar 22 10:29:36 2011 (r219863) +++ head/sbin/hastd/subr.c Tue Mar 22 10:39:34 2011 (r219864) @@ -134,12 +134,12 @@ const char * role2str(int role) { - switch (role) { - case HAST_ROLE_INIT: + switch (role) { + case HAST_ROLE_INIT: return ("init"); - case HAST_ROLE_PRIMARY: + case HAST_ROLE_PRIMARY: return ("primary"); - case HAST_ROLE_SECONDARY: + case HAST_ROLE_SECONDARY: return ("secondary"); } return ("unknown");