From owner-svn-src-all@freebsd.org  Sun Dec 25 00:35:01 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5BCC9C8071D;
 Sun, 25 Dec 2016 00:35:01 +0000 (UTC)
 (envelope-from markj@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 2AC6A1336;
 Sun, 25 Dec 2016 00:35:01 +0000 (UTC)
 (envelope-from markj@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBP0Z0Mm011638;
 Sun, 25 Dec 2016 00:35:00 GMT (envelope-from markj@FreeBSD.org)
Received: (from markj@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBP0Z0Yc011637;
 Sun, 25 Dec 2016 00:35:00 GMT (envelope-from markj@FreeBSD.org)
Message-Id: <201612250035.uBP0Z0Yc011637@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: markj set sender to
 markj@FreeBSD.org using -f
From: Mark Johnston <markj@FreeBSD.org>
Date: Sun, 25 Dec 2016 00:35:00 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310531 - stable/11/sys/kern
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 00:35:01 -0000

Author: markj
Date: Sun Dec 25 00:35:00 2016
New Revision: 310531
URL: https://svnweb.freebsd.org/changeset/base/310531

Log:
  MFC r310423, r310454:
  Revert part of r300109.

Modified:
  stable/11/sys/kern/subr_sleepqueue.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/kern/subr_sleepqueue.c
==============================================================================
--- stable/11/sys/kern/subr_sleepqueue.c	Sat Dec 24 23:51:27 2016	(r310530)
+++ stable/11/sys/kern/subr_sleepqueue.c	Sun Dec 25 00:35:00 2016	(r310531)
@@ -880,7 +880,7 @@ int
 sleepq_broadcast(void *wchan, int flags, int pri, int queue)
 {
 	struct sleepqueue *sq;
-	struct thread *td;
+	struct thread *td, *tdn;
 	int wakeup_swapper;
 
 	CTR2(KTR_PROC, "sleepq_broadcast(%p, %d)", wchan, flags);
@@ -892,9 +892,14 @@ sleepq_broadcast(void *wchan, int flags,
 	KASSERT(sq->sq_type == (flags & SLEEPQ_TYPE),
 	    ("%s: mismatch between sleep/wakeup and cv_*", __func__));
 
-	/* Resume all blocked threads on the sleep queue. */
+	/*
+	 * Resume all blocked threads on the sleep queue.  The last thread will
+	 * be given ownership of sq and may re-enqueue itself before
+	 * sleepq_resume_thread() returns, so we must cache the "next" queue
+	 * item at the beginning of the final iteration.
+	 */
 	wakeup_swapper = 0;
-	while ((td = TAILQ_FIRST(&sq->sq_blocked[queue])) != NULL) {
+	TAILQ_FOREACH_SAFE(td, &sq->sq_blocked[queue], td_slpq, tdn) {
 		thread_lock(td);
 		wakeup_swapper |= sleepq_resume_thread(sq, td, pri);
 		thread_unlock(td);

From owner-svn-src-all@freebsd.org  Sun Dec 25 09:40:46 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 34361C8F8FE;
 Sun, 25 Dec 2016 09:40:46 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 012FF1FF5;
 Sun, 25 Dec 2016 09:40:45 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBP9ejkt031074;
 Sun, 25 Dec 2016 09:40:45 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBP9ej60031054;
 Sun, 25 Dec 2016 09:40:45 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612250940.uBP9ej60031054@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Sun, 25 Dec 2016 09:40:45 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310534 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 09:40:46 -0000

Author: mav
Date: Sun Dec 25 09:40:44 2016
New Revision: 310534
URL: https://svnweb.freebsd.org/changeset/base/310534

Log:
  Improve third-party copy error reporting.
  
  For EXTENDED COPY:
   - improve parameters checking to report some errors before copy start;
   - forward sense data from copy target as descriptor in case of error;
   - report which CSCD reported error in sense key specific information.
  For WRITE USING TOKEN:
   - pass through real sense data from copy target instead of reporting
  our copy error, since for initiator its a "simple" write, not a copy.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl_tpc.c

Modified: head/sys/cam/ctl/ctl_tpc.c
==============================================================================
--- head/sys/cam/ctl/ctl_tpc.c	Sun Dec 25 08:02:37 2016	(r310533)
+++ head/sys/cam/ctl/ctl_tpc.c	Sun Dec 25 09:40:44 2016	(r310534)
@@ -82,6 +82,8 @@ struct tpc_list;
 TAILQ_HEAD(runl, tpc_io);
 struct tpc_io {
 	union ctl_io		*io;
+	uint8_t			 target;
+	uint32_t		 cscd;
 	uint64_t		 lun;
 	struct tpc_list		*list;
 	struct runl		 run;
@@ -134,6 +136,11 @@ struct tpc_list {
 	int			 completed;
 	time_t			 last_active;
 	TAILQ_HEAD(, tpc_io)	 allio;
+	struct scsi_sense_data	 fwd_sense_data;
+	uint8_t			 fwd_sense_len;
+	uint8_t			 fwd_scsi_status;
+	uint8_t			 fwd_target;
+	uint16_t		 fwd_cscd;
 	struct scsi_sense_data	 sense_data;
 	uint8_t			 sense_len;
 	uint8_t			 scsi_status;
@@ -809,6 +816,44 @@ tpc_resolve(struct tpc_list *list, uint1
 	    list->init_port, &list->cscd[idx], ss, pb, pbo));
 }
 
+static void
+tpc_set_io_error_sense(struct tpc_list *list)
+{
+	int flen;
+	uint8_t csi[4];
+	uint8_t sks[3];
+	uint8_t fbuf[4 + 64];
+
+	scsi_ulto4b(list->curseg, csi);
+	if (list->fwd_cscd <= 0x07ff) {
+		sks[0] = SSD_SKS_SEGMENT_VALID;
+		scsi_ulto2b((uint8_t *)&list->cscd[list->fwd_cscd] -
+		    list->params, &sks[1]);
+	} else
+		sks[0] = 0;
+	if (list->fwd_scsi_status) {
+		fbuf[0] = 0x0c;
+		fbuf[2] = list->fwd_target;
+		flen = list->fwd_sense_len;
+		if (flen > 64) {
+			flen = 64;
+			fbuf[2] |= SSD_FORWARDED_FSDT;
+		}
+		fbuf[1] = 2 + flen;
+		fbuf[3] = list->fwd_scsi_status;
+		bcopy(&list->fwd_sense_data, &fbuf[4], flen);
+		flen += 4;
+	} else
+		flen = 0;
+	ctl_set_sense(list->ctsio, /*current_error*/ 1,
+	    /*sense_key*/ SSD_KEY_COPY_ABORTED,
+	    /*asc*/ 0x0d, /*ascq*/ 0x01,
+	    SSD_ELEM_COMMAND, sizeof(csi), csi,
+	    sks[0] ? SSD_ELEM_SKS : SSD_ELEM_SKIP, sizeof(sks), sks,
+	    flen ? SSD_ELEM_DESC : SSD_ELEM_SKIP, flen, fbuf,
+	    SSD_ELEM_NONE);
+}
+
 static int
 tpc_process_b2b(struct tpc_list *list)
 {
@@ -820,6 +865,7 @@ tpc_process_b2b(struct tpc_list *list)
 	off_t srclba, dstlba, numbytes, donebytes, roundbytes;
 	int numlba;
 	uint32_t srcblock, dstblock, pb, pbo, adj;
+	uint16_t scscd, dcscd;
 	uint8_t csi[4];
 
 	scsi_ulto4b(list->curseg, csi);
@@ -834,11 +880,7 @@ tpc_process_b2b(struct tpc_list *list)
 			ctl_set_task_aborted(list->ctsio);
 			return (CTL_RETVAL_ERROR);
 		} else if (list->error) {
-			ctl_set_sense(list->ctsio, /*current_error*/ 1,
-			    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-			    /*asc*/ 0x0d, /*ascq*/ 0x01,
-			    SSD_ELEM_COMMAND, sizeof(csi), csi,
-			    SSD_ELEM_NONE);
+			tpc_set_io_error_sense(list);
 			return (CTL_RETVAL_ERROR);
 		}
 		list->cursectors += list->segsectors;
@@ -848,8 +890,10 @@ tpc_process_b2b(struct tpc_list *list)
 
 	TAILQ_INIT(&list->allio);
 	seg = (struct scsi_ec_segment_b2b *)list->seg[list->curseg];
-	sl = tpc_resolve(list, scsi_2btoul(seg->src_cscd), &srcblock, NULL, NULL);
-	dl = tpc_resolve(list, scsi_2btoul(seg->dst_cscd), &dstblock, &pb, &pbo);
+	scscd = scsi_2btoul(seg->src_cscd);
+	dcscd = scsi_2btoul(seg->dst_cscd);
+	sl = tpc_resolve(list, scscd, &srcblock, NULL, NULL);
+	dl = tpc_resolve(list, dcscd, &dstblock, &pb, &pbo);
 	if (sl >= CTL_MAX_LUNS || dl >= CTL_MAX_LUNS) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
@@ -860,10 +904,10 @@ tpc_process_b2b(struct tpc_list *list)
 	}
 	if (pbo > 0)
 		pbo = pb - pbo;
-	sdstp = &list->cscd[scsi_2btoul(seg->src_cscd)].dtsp;
+	sdstp = &list->cscd[scscd].dtsp;
 	if (scsi_3btoul(sdstp->block_length) != 0)
 		srcblock = scsi_3btoul(sdstp->block_length);
-	ddstp = &list->cscd[scsi_2btoul(seg->dst_cscd)].dtsp;
+	ddstp = &list->cscd[dcscd].dtsp;
 	if (scsi_3btoul(ddstp->block_length) != 0)
 		dstblock = scsi_3btoul(ddstp->block_length);
 	numlba = scsi_2btoul(seg->number_of_blocks);
@@ -924,6 +968,8 @@ tpc_process_b2b(struct tpc_list *list)
 				    /*tag_type*/ CTL_TAG_SIMPLE,
 				    /*control*/ 0);
 		tior->io->io_hdr.retries = 3;
+		tior->target = SSD_FORWARDED_SDS_EXSRC;
+		tior->cscd = scscd;
 		tior->lun = sl;
 		tior->io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr = tior;
 
@@ -943,6 +989,8 @@ tpc_process_b2b(struct tpc_list *list)
 				    /*tag_type*/ CTL_TAG_SIMPLE,
 				    /*control*/ 0);
 		tiow->io->io_hdr.retries = 3;
+		tiow->target = SSD_FORWARDED_SDS_EXDST;
+		tiow->cscd = dcscd;
 		tiow->lun = dl;
 		tiow->io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr = tiow;
 
@@ -970,6 +1018,7 @@ tpc_process_verify(struct tpc_list *list
 	struct scsi_ec_segment_verify *seg;
 	struct tpc_io *tio;
 	uint64_t sl;
+	uint16_t cscd;
 	uint8_t csi[4];
 
 	scsi_ulto4b(list->curseg, csi);
@@ -983,11 +1032,7 @@ tpc_process_verify(struct tpc_list *list
 			ctl_set_task_aborted(list->ctsio);
 			return (CTL_RETVAL_ERROR);
 		} else if (list->error) {
-			ctl_set_sense(list->ctsio, /*current_error*/ 1,
-			    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-			    /*asc*/ 0x0d, /*ascq*/ 0x01,
-			    SSD_ELEM_COMMAND, sizeof(csi), csi,
-			    SSD_ELEM_NONE);
+			tpc_set_io_error_sense(list);
 			return (CTL_RETVAL_ERROR);
 		} else
 			return (CTL_RETVAL_COMPLETE);
@@ -995,7 +1040,8 @@ tpc_process_verify(struct tpc_list *list
 
 	TAILQ_INIT(&list->allio);
 	seg = (struct scsi_ec_segment_verify *)list->seg[list->curseg];
-	sl = tpc_resolve(list, scsi_2btoul(seg->src_cscd), NULL, NULL, NULL);
+	cscd = scsi_2btoul(seg->src_cscd);
+	sl = tpc_resolve(list, cscd, NULL, NULL, NULL);
 	if (sl >= CTL_MAX_LUNS) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
@@ -1018,6 +1064,8 @@ tpc_process_verify(struct tpc_list *list
 	tio->io = tpcl_alloc_io();
 	ctl_scsi_tur(tio->io, /*tag_type*/ CTL_TAG_SIMPLE, /*control*/ 0);
 	tio->io->io_hdr.retries = 3;
+	tio->target = SSD_FORWARDED_SDS_EXSRC;
+	tio->cscd = cscd;
 	tio->lun = sl;
 	tio->io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr = tio;
 	list->stage++;
@@ -1033,6 +1081,7 @@ tpc_process_register_key(struct tpc_list
 	struct tpc_io *tio;
 	uint64_t dl;
 	int datalen;
+	uint16_t cscd;
 	uint8_t csi[4];
 
 	scsi_ulto4b(list->curseg, csi);
@@ -1047,11 +1096,7 @@ tpc_process_register_key(struct tpc_list
 			ctl_set_task_aborted(list->ctsio);
 			return (CTL_RETVAL_ERROR);
 		} else if (list->error) {
-			ctl_set_sense(list->ctsio, /*current_error*/ 1,
-			    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-			    /*asc*/ 0x0d, /*ascq*/ 0x01,
-			    SSD_ELEM_COMMAND, sizeof(csi), csi,
-			    SSD_ELEM_NONE);
+			tpc_set_io_error_sense(list);
 			return (CTL_RETVAL_ERROR);
 		} else
 			return (CTL_RETVAL_COMPLETE);
@@ -1059,7 +1104,8 @@ tpc_process_register_key(struct tpc_list
 
 	TAILQ_INIT(&list->allio);
 	seg = (struct scsi_ec_segment_register_key *)list->seg[list->curseg];
-	dl = tpc_resolve(list, scsi_2btoul(seg->dst_cscd), NULL, NULL, NULL);
+	cscd = scsi_2btoul(seg->dst_cscd);
+	dl = tpc_resolve(list, cscd, NULL, NULL, NULL);
 	if (dl >= CTL_MAX_LUNS) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
@@ -1084,6 +1130,8 @@ tpc_process_register_key(struct tpc_list
 	    scsi_8btou64(seg->res_key), scsi_8btou64(seg->sa_res_key),
 	    /*tag_type*/ CTL_TAG_SIMPLE, /*control*/ 0);
 	tio->io->io_hdr.retries = 3;
+	tio->target = SSD_FORWARDED_SDS_EXDST;
+	tio->cscd = cscd;
 	tio->lun = dl;
 	tio->io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr = tio;
 	list->stage++;
@@ -1185,9 +1233,17 @@ tpc_process_wut(struct tpc_list *list)
 			ctl_set_task_aborted(list->ctsio);
 			return (CTL_RETVAL_ERROR);
 		} else if (list->error) {
-			ctl_set_sense(list->ctsio, /*current_error*/ 1,
-			    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-			    /*asc*/ 0x0d, /*ascq*/ 0x01, SSD_ELEM_NONE);
+			if (list->fwd_scsi_status) {
+				list->ctsio->io_hdr.status =
+				    CTL_SCSI_ERROR | CTL_AUTOSENSE;
+				list->ctsio->scsi_status = list->fwd_scsi_status;
+				list->ctsio->sense_data = list->fwd_sense_data;
+				list->ctsio->sense_len = list->fwd_sense_len;
+			} else {
+				ctl_set_invalid_field(list->ctsio,
+				    /*sks_valid*/ 0, /*command*/ 0,
+				    /*field*/ 0, /*bit_valid*/ 0, /*bit*/ 0);
+			}
 			return (CTL_RETVAL_ERROR);
 		}
 		list->cursectors += list->segsectors;
@@ -1210,9 +1266,8 @@ tpc_process_wut(struct tpc_list *list)
 	if (tpc_skip_ranges(list->token->range, list->token->nrange,
 	    list->offset_into_rod + list->cursectors * dstblock / srcblock,
 	    &srange, &soffset) != 0) {
-		ctl_set_sense(list->ctsio, /*current_error*/ 1,
-		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-		    /*asc*/ 0x0d, /*ascq*/ 0x04, SSD_ELEM_NONE);
+		ctl_set_invalid_field(list->ctsio, /*sks_valid*/ 0,
+		    /*command*/ 0, /*field*/ 0, /*bit_valid*/ 0, /*bit*/ 0);
 		return (CTL_RETVAL_ERROR);
 	}
 
@@ -1233,9 +1288,8 @@ tpc_process_wut(struct tpc_list *list)
 	}
 
 	if (numbytes % srcblock != 0 || numbytes % dstblock != 0) {
-		ctl_set_sense(list->ctsio, /*current_error*/ 1,
-		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-		    /*asc*/ 0x26, /*ascq*/ 0x0A, SSD_ELEM_NONE);
+		ctl_set_invalid_field(list->ctsio, /*sks_valid*/ 0,
+		    /*command*/ 0, /*field*/ 0, /*bit_valid*/ 0, /*bit*/ 0);
 		return (CTL_RETVAL_ERROR);
 	}
 
@@ -1337,9 +1391,17 @@ complete:
 			ctl_set_task_aborted(list->ctsio);
 			return (CTL_RETVAL_ERROR);
 		} else if (list->error) {
-			ctl_set_sense(list->ctsio, /*current_error*/ 1,
-			    /*sense_key*/ SSD_KEY_COPY_ABORTED,
-			    /*asc*/ 0x0d, /*ascq*/ 0x01, SSD_ELEM_NONE);
+			if (list->fwd_scsi_status) {
+				list->ctsio->io_hdr.status =
+				    CTL_SCSI_ERROR | CTL_AUTOSENSE;
+				list->ctsio->scsi_status = list->fwd_scsi_status;
+				list->ctsio->sense_data = list->fwd_sense_data;
+				list->ctsio->sense_len = list->fwd_sense_len;
+			} else {
+				ctl_set_invalid_field(list->ctsio,
+				    /*sks_valid*/ 0, /*command*/ 0,
+				    /*field*/ 0, /*bit_valid*/ 0, /*bit*/ 0);
+			}
 			return (CTL_RETVAL_ERROR);
 		}
 		list->cursectors += list->segsectors;
@@ -1616,9 +1678,17 @@ tpc_done(union ctl_io *io)
 		}
 	}
 
-	if ((io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS)
+	if ((io->io_hdr.status & CTL_STATUS_MASK) != CTL_SUCCESS) {
 		tio->list->error = 1;
-	else
+		if (io->io_hdr.io_type == CTL_IO_SCSI &&
+		    (io->io_hdr.status & CTL_STATUS_MASK) == CTL_SCSI_ERROR) {
+			tio->list->fwd_scsi_status = io->scsiio.scsi_status;
+			tio->list->fwd_sense_data = io->scsiio.sense_data;
+			tio->list->fwd_sense_len = io->scsiio.sense_len;
+			tio->list->fwd_target = tio->target;
+			tio->list->fwd_cscd = tio->cscd;
+		}
+	} else
 		atomic_add_int(&tio->list->curops, 1);
 	if (!tio->list->error && !tio->list->abort) {
 		while ((tior = TAILQ_FIRST(&tio->run)) != NULL) {
@@ -1637,6 +1707,8 @@ ctl_extended_copy_lid1(struct ctl_scsiio
 {
 	struct scsi_extended_copy *cdb;
 	struct scsi_extended_copy_lid1_data *data;
+	struct scsi_ec_cscd *cscd;
+	struct scsi_ec_segment *seg;
 	struct ctl_lun *lun;
 	struct tpc_list *list, *tlist;
 	uint8_t *ptr;
@@ -1715,6 +1787,17 @@ ctl_extended_copy_lid1(struct ctl_scsiio
 	list->flags = data->flags;
 	list->params = ctsio->kern_data_ptr;
 	list->cscd = (struct scsi_ec_cscd *)&data->data[0];
+	ptr = &data->data[0];
+	for (off = 0; off < lencscd; off += sizeof(struct scsi_ec_cscd)) {
+		cscd = (struct scsi_ec_cscd *)(ptr + off);
+		if (cscd->type_code != EC_CSCD_ID) {
+			free(list, M_CTL);
+			ctl_set_sense(ctsio, /*current_error*/ 1,
+			    /*sense_key*/ SSD_KEY_ILLEGAL_REQUEST,
+			    /*asc*/ 0x26, /*ascq*/ 0x07, SSD_ELEM_NONE);
+			goto done;
+		}
+	}
 	ptr = &data->data[lencscd];
 	for (nseg = 0, off = 0; off < lenseg; nseg++) {
 		if (nseg >= TPC_MAX_SEGS) {
@@ -1724,9 +1807,19 @@ ctl_extended_copy_lid1(struct ctl_scsiio
 			    /*asc*/ 0x26, /*ascq*/ 0x08, SSD_ELEM_NONE);
 			goto done;
 		}
-		list->seg[nseg] = (struct scsi_ec_segment *)(ptr + off);
+		seg = (struct scsi_ec_segment *)(ptr + off);
+		if (seg->type_code != EC_SEG_B2B &&
+		    seg->type_code != EC_SEG_VERIFY &&
+		    seg->type_code != EC_SEG_REGISTER_KEY) {
+			free(list, M_CTL);
+			ctl_set_sense(ctsio, /*current_error*/ 1,
+			    /*sense_key*/ SSD_KEY_ILLEGAL_REQUEST,
+			    /*asc*/ 0x26, /*ascq*/ 0x09, SSD_ELEM_NONE);
+			goto done;
+		}
+		list->seg[nseg] = seg;
 		off += sizeof(struct scsi_ec_segment) +
-		    scsi_2btoul(list->seg[nseg]->descr_length);
+		    scsi_2btoul(seg->descr_length);
 	}
 	list->inl = &data->data[lencscd + lenseg];
 	list->ncscd = lencscd / sizeof(struct scsi_ec_cscd);
@@ -1770,6 +1863,8 @@ ctl_extended_copy_lid4(struct ctl_scsiio
 {
 	struct scsi_extended_copy *cdb;
 	struct scsi_extended_copy_lid4_data *data;
+	struct scsi_ec_cscd *cscd;
+	struct scsi_ec_segment *seg;
 	struct ctl_lun *lun;
 	struct tpc_list *list, *tlist;
 	uint8_t *ptr;
@@ -1848,6 +1943,17 @@ ctl_extended_copy_lid4(struct ctl_scsiio
 	list->flags = data->flags;
 	list->params = ctsio->kern_data_ptr;
 	list->cscd = (struct scsi_ec_cscd *)&data->data[0];
+	ptr = &data->data[0];
+	for (off = 0; off < lencscd; off += sizeof(struct scsi_ec_cscd)) {
+		cscd = (struct scsi_ec_cscd *)(ptr + off);
+		if (cscd->type_code != EC_CSCD_ID) {
+			free(list, M_CTL);
+			ctl_set_sense(ctsio, /*current_error*/ 1,
+			    /*sense_key*/ SSD_KEY_ILLEGAL_REQUEST,
+			    /*asc*/ 0x26, /*ascq*/ 0x07, SSD_ELEM_NONE);
+			goto done;
+		}
+	}
 	ptr = &data->data[lencscd];
 	for (nseg = 0, off = 0; off < lenseg; nseg++) {
 		if (nseg >= TPC_MAX_SEGS) {
@@ -1857,9 +1963,19 @@ ctl_extended_copy_lid4(struct ctl_scsiio
 			    /*asc*/ 0x26, /*ascq*/ 0x08, SSD_ELEM_NONE);
 			goto done;
 		}
-		list->seg[nseg] = (struct scsi_ec_segment *)(ptr + off);
+		seg = (struct scsi_ec_segment *)(ptr + off);
+		if (seg->type_code != EC_SEG_B2B &&
+		    seg->type_code != EC_SEG_VERIFY &&
+		    seg->type_code != EC_SEG_REGISTER_KEY) {
+			free(list, M_CTL);
+			ctl_set_sense(ctsio, /*current_error*/ 1,
+			    /*sense_key*/ SSD_KEY_ILLEGAL_REQUEST,
+			    /*asc*/ 0x26, /*ascq*/ 0x09, SSD_ELEM_NONE);
+			goto done;
+		}
+		list->seg[nseg] = seg;
 		off += sizeof(struct scsi_ec_segment) +
-		    scsi_2btoul(list->seg[nseg]->descr_length);
+		    scsi_2btoul(seg->descr_length);
 	}
 	list->inl = &data->data[lencscd + lenseg];
 	list->ncscd = lencscd / sizeof(struct scsi_ec_cscd);

From owner-svn-src-all@freebsd.org  Sun Dec 25 13:34:04 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3E9BFC8DC52;
 Sun, 25 Dec 2016 13:34:04 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id F3A6017D9;
 Sun, 25 Dec 2016 13:34:03 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPDY3N4028482;
 Sun, 25 Dec 2016 13:34:03 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPDY2Nn028478;
 Sun, 25 Dec 2016 13:34:02 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612251334.uBPDY2Nn028478@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Sun, 25 Dec 2016 13:34:02 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310539 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 13:34:04 -0000

Author: mav
Date: Sun Dec 25 13:34:02 2016
New Revision: 310539
URL: https://svnweb.freebsd.org/changeset/base/310539

Log:
  Remove CTL_MAX_LUNS from places where it is not required.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c
  head/sys/cam/ctl/ctl_frontend.c
  head/sys/cam/ctl/ctl_tpc.c
  head/sys/cam/ctl/ctl_tpc_local.c

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Sun Dec 25 12:00:56 2016	(r310538)
+++ head/sys/cam/ctl/ctl.c	Sun Dec 25 13:34:02 2016	(r310539)
@@ -1218,7 +1218,7 @@ ctl_isc_port_sync(struct ctl_softc *soft
 	}
 	mtx_lock(&softc->ctl_lock);
 	STAILQ_FOREACH(lun, &softc->lun_list, links) {
-		if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		mtx_lock(&lun->lun_lock);
 		ctl_est_ua_all(lun, -1, CTL_UA_INQ_CHANGE);
@@ -2906,18 +2906,18 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 		break;
 	}
 	case CTL_DUMP_STRUCTS: {
-		int i, j, k;
+		int j, k;
 		struct ctl_port *port;
 		struct ctl_frontend *fe;
 
 		mtx_lock(&softc->ctl_lock);
 		printf("CTL Persistent Reservation information start:\n");
-		for (i = 0; i < CTL_MAX_LUNS; i++) {
-			lun = softc->ctl_luns[i];
-
-			if ((lun == NULL)
-			 || ((lun->flags & CTL_LUN_DISABLED) != 0))
+		STAILQ_FOREACH(lun, &softc->lun_list, links) {
+			mtx_lock(&lun->lun_lock);
+			if ((lun->flags & CTL_LUN_DISABLED) != 0) {
+				mtx_unlock(&lun->lun_lock);
 				continue;
+			}
 
 			for (j = 0; j < CTL_MAX_PORTS; j++) {
 				if (lun->pr_keys[j] == NULL)
@@ -2925,11 +2925,12 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 				for (k = 0; k < CTL_MAX_INIT_PER_PORT; k++){
 					if (lun->pr_keys[j][k] == 0)
 						continue;
-					printf("  LUN %d port %d iid %d key "
-					       "%#jx\n", i, j, k,
+					printf("  LUN %ju port %d iid %d key "
+					       "%#jx\n", lun->lun, j, k,
 					       (uintmax_t)lun->pr_keys[j][k]);
 				}
 			}
+			mtx_unlock(&lun->lun_lock);
 		}
 		printf("CTL Persistent Reservation information end\n");
 		printf("CTL Ports:\n");
@@ -3312,7 +3313,7 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 				sbuf_printf(sb, "\t<lun_map>on</lun_map>\n");
 				for (j = 0; j < CTL_MAX_LUNS; j++) {
 					plun = ctl_lun_map_from_port(port, j);
-					if (plun >= CTL_MAX_LUNS)
+					if (plun == UINT32_MAX)
 						continue;
 					sbuf_printf(sb,
 					    "\t<lun id=\"%u\">%u</lun>\n",
@@ -3380,8 +3381,8 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 		}
 		if (port->status & CTL_PORT_STATUS_ONLINE) {
 			STAILQ_FOREACH(lun, &softc->lun_list, links) {
-				if (ctl_lun_map_to_port(port, lun->lun) >=
-				    CTL_MAX_LUNS)
+				if (ctl_lun_map_to_port(port, lun->lun) ==
+				    UINT32_MAX)
 					continue;
 				mtx_lock(&lun->lun_lock);
 				ctl_est_ua_port(lun, lm->port, -1,
@@ -3509,7 +3510,7 @@ ctl_lun_map_set(struct ctl_port *port, u
 	}
 	old = port->lun_map[plun];
 	port->lun_map[plun] = glun;
-	if ((port->status & CTL_PORT_STATUS_ONLINE) && old >= CTL_MAX_LUNS) {
+	if ((port->status & CTL_PORT_STATUS_ONLINE) && old == UINT32_MAX) {
 		if (port->lun_enable != NULL)
 			port->lun_enable(port->targ_lun_arg, plun);
 		ctl_isc_announce_port(port);
@@ -3526,7 +3527,7 @@ ctl_lun_map_unset(struct ctl_port *port,
 		return (0);
 	old = port->lun_map[plun];
 	port->lun_map[plun] = UINT32_MAX;
-	if ((port->status & CTL_PORT_STATUS_ONLINE) && old < CTL_MAX_LUNS) {
+	if ((port->status & CTL_PORT_STATUS_ONLINE) && old != UINT32_MAX) {
 		if (port->lun_disable != NULL)
 			port->lun_disable(port->targ_lun_arg, plun);
 		ctl_isc_announce_port(port);
@@ -3540,7 +3541,7 @@ ctl_lun_map_from_port(struct ctl_port *p
 
 	if (port == NULL)
 		return (UINT32_MAX);
-	if (port->lun_map == NULL || lun_id >= CTL_MAX_LUNS)
+	if (port->lun_map == NULL || lun_id == UINT32_MAX)
 		return (lun_id);
 	return (port->lun_map[lun_id]);
 }
@@ -7142,7 +7143,7 @@ ctl_report_tagret_port_groups(struct ctl
 	STAILQ_FOREACH(port, &softc->port_list, links) {
 		if ((port->status & CTL_PORT_STATUS_ONLINE) == 0)
 			continue;
-		if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		num_target_ports++;
 		if (port->status & CTL_PORT_STATUS_HA_SHARED)
@@ -7234,7 +7235,7 @@ ctl_report_tagret_port_groups(struct ctl
 			if (!softc->is_single &&
 			    (port->status & CTL_PORT_STATUS_HA_SHARED) == 0)
 				continue;
-			if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+			if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 				continue;
 			scsi_ulto2b(port->targ_port, tpg_desc->descriptors[pc].
 			    relative_target_port_identifier);
@@ -7259,7 +7260,7 @@ ctl_report_tagret_port_groups(struct ctl
 				continue;
 			if (port->status & CTL_PORT_STATUS_HA_SHARED)
 				continue;
-			if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+			if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 				continue;
 			scsi_ulto2b(port->targ_port, tpg_desc->descriptors[pc].
 			    relative_target_port_identifier);
@@ -9078,7 +9079,7 @@ ctl_report_luns(struct ctl_scsiio *ctsio
 	mtx_lock(&softc->ctl_lock);
 	num_luns = 0;
 	for (targ_lun_id = 0; targ_lun_id < CTL_MAX_LUNS; targ_lun_id++) {
-		if (ctl_lun_map_from_port(port, targ_lun_id) < CTL_MAX_LUNS)
+		if (ctl_lun_map_from_port(port, targ_lun_id) != UINT32_MAX)
 			num_luns++;
 	}
 	mtx_unlock(&softc->ctl_lock);
@@ -9138,7 +9139,7 @@ ctl_report_luns(struct ctl_scsiio *ctsio
 	mtx_lock(&softc->ctl_lock);
 	for (targ_lun_id = 0, num_filled = 0; targ_lun_id < CTL_MAX_LUNS && num_filled < num_luns; targ_lun_id++) {
 		lun_id = ctl_lun_map_from_port(port, targ_lun_id);
-		if (lun_id >= CTL_MAX_LUNS)
+		if (lun_id == UINT32_MAX)
 			continue;
 		lun = softc->ctl_luns[lun_id];
 		if (lun == NULL)
@@ -9774,7 +9775,7 @@ ctl_inquiry_evpd_scsi_ports(struct ctl_s
 		if ((port->status & CTL_PORT_STATUS_ONLINE) == 0)
 			continue;
 		if (lun != NULL &&
-		    ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		    ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		num_target_ports++;
 		if (port->init_devid)
@@ -9825,7 +9826,7 @@ ctl_inquiry_evpd_scsi_ports(struct ctl_s
 		if ((port->status & CTL_PORT_STATUS_ONLINE) == 0)
 			continue;
 		if (lun != NULL &&
-		    ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		    ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		scsi_ulto2b(port->targ_port, pd->relative_port_id);
 		if (port->init_devid) {
@@ -11882,7 +11883,7 @@ ctl_target_reset(struct ctl_softc *softc
 	port = ctl_io_port(&io->io_hdr);
 	STAILQ_FOREACH(lun, &softc->lun_list, links) {
 		if (port != NULL &&
-		    ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		    ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		retval += ctl_do_lun_reset(lun, io, ua_type);
 	}

Modified: head/sys/cam/ctl/ctl_frontend.c
==============================================================================
--- head/sys/cam/ctl/ctl_frontend.c	Sun Dec 25 12:00:56 2016	(r310538)
+++ head/sys/cam/ctl/ctl_frontend.c	Sun Dec 25 13:34:02 2016	(r310539)
@@ -316,8 +316,8 @@ ctl_port_online(struct ctl_port *port)
 	if (port->lun_enable != NULL) {
 		if (port->lun_map) {
 			for (l = 0; l < CTL_MAX_LUNS; l++) {
-				if (ctl_lun_map_from_port(port, l) >=
-				    CTL_MAX_LUNS)
+				if (ctl_lun_map_from_port(port, l) ==
+				    UINT32_MAX)
 					continue;
 				port->lun_enable(port->targ_lun_arg, l);
 			}
@@ -338,7 +338,7 @@ ctl_port_online(struct ctl_port *port)
 	}
 	port->status |= CTL_PORT_STATUS_ONLINE;
 	STAILQ_FOREACH(lun, &softc->lun_list, links) {
-		if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		mtx_lock(&lun->lun_lock);
 		ctl_est_ua_all(lun, -1, CTL_UA_INQ_CHANGE);
@@ -360,8 +360,8 @@ ctl_port_offline(struct ctl_port *port)
 	if (port->lun_disable != NULL) {
 		if (port->lun_map) {
 			for (l = 0; l < CTL_MAX_LUNS; l++) {
-				if (ctl_lun_map_from_port(port, l) >=
-				    CTL_MAX_LUNS)
+				if (ctl_lun_map_from_port(port, l) ==
+				    UINT32_MAX)
 					continue;
 				port->lun_disable(port->targ_lun_arg, l);
 			}
@@ -373,7 +373,7 @@ ctl_port_offline(struct ctl_port *port)
 	mtx_lock(&softc->ctl_lock);
 	port->status &= ~CTL_PORT_STATUS_ONLINE;
 	STAILQ_FOREACH(lun, &softc->lun_list, links) {
-		if (ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		if (ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		mtx_lock(&lun->lun_lock);
 		ctl_est_ua_all(lun, -1, CTL_UA_INQ_CHANGE);

Modified: head/sys/cam/ctl/ctl_tpc.c
==============================================================================
--- head/sys/cam/ctl/ctl_tpc.c	Sun Dec 25 12:00:56 2016	(r310538)
+++ head/sys/cam/ctl/ctl_tpc.c	Sun Dec 25 13:34:02 2016	(r310539)
@@ -894,7 +894,7 @@ tpc_process_b2b(struct tpc_list *list)
 	dcscd = scsi_2btoul(seg->dst_cscd);
 	sl = tpc_resolve(list, scscd, &srcblock, NULL, NULL);
 	dl = tpc_resolve(list, dcscd, &dstblock, &pb, &pbo);
-	if (sl >= CTL_MAX_LUNS || dl >= CTL_MAX_LUNS) {
+	if (sl == UINT64_MAX || dl == UINT64_MAX) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
 		    /*asc*/ 0x08, /*ascq*/ 0x04,
@@ -1042,7 +1042,7 @@ tpc_process_verify(struct tpc_list *list
 	seg = (struct scsi_ec_segment_verify *)list->seg[list->curseg];
 	cscd = scsi_2btoul(seg->src_cscd);
 	sl = tpc_resolve(list, cscd, NULL, NULL, NULL);
-	if (sl >= CTL_MAX_LUNS) {
+	if (sl == UINT64_MAX) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
 		    /*asc*/ 0x08, /*ascq*/ 0x04,
@@ -1106,7 +1106,7 @@ tpc_process_register_key(struct tpc_list
 	seg = (struct scsi_ec_segment_register_key *)list->seg[list->curseg];
 	cscd = scsi_2btoul(seg->dst_cscd);
 	dl = tpc_resolve(list, cscd, NULL, NULL, NULL);
-	if (dl >= CTL_MAX_LUNS) {
+	if (dl == UINT64_MAX) {
 		ctl_set_sense(list->ctsio, /*current_error*/ 1,
 		    /*sense_key*/ SSD_KEY_COPY_ABORTED,
 		    /*asc*/ 0x08, /*ascq*/ 0x04,

Modified: head/sys/cam/ctl/ctl_tpc_local.c
==============================================================================
--- head/sys/cam/ctl/ctl_tpc_local.c	Sun Dec 25 12:00:56 2016	(r310538)
+++ head/sys/cam/ctl/ctl_tpc_local.c	Sun Dec 25 13:34:02 2016	(r310539)
@@ -290,7 +290,7 @@ tpcl_resolve(struct ctl_softc *softc, in
 		port = NULL;
 	STAILQ_FOREACH(lun, &softc->lun_list, links) {
 		if (port != NULL &&
-		    ctl_lun_map_to_port(port, lun->lun) >= CTL_MAX_LUNS)
+		    ctl_lun_map_to_port(port, lun->lun) == UINT32_MAX)
 			continue;
 		if (lun->lun_devid == NULL)
 			continue;

From owner-svn-src-all@freebsd.org  Sun Dec 25 14:54:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 15818C90F98;
 Sun, 25 Dec 2016 14:54:53 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id D8C0112A3;
 Sun, 25 Dec 2016 14:54:52 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPEsqOm062012;
 Sun, 25 Dec 2016 14:54:52 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPEsqBJ062011;
 Sun, 25 Dec 2016 14:54:52 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251454.uBPEsqBJ062011@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 14:54:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310540 - stable/11/share/mk
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 14:54:53 -0000

Author: dim
Date: Sun Dec 25 14:54:51 2016
New Revision: 310540
URL: https://svnweb.freebsd.org/changeset/base/310540

Log:
  MFC r304696:
  
  In addition to creating subdirectories under .OBJDIR for SRCS with
  relative paths, also create them for DPSRCS.  This is needed for builds
  that generate files during the depend stage, which cannot be compiled by
  themselves, since those have to be put in DPSRCS.

Modified:
  stable/11/share/mk/bsd.obj.mk
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/share/mk/bsd.obj.mk
==============================================================================
--- stable/11/share/mk/bsd.obj.mk	Sun Dec 25 13:34:02 2016	(r310539)
+++ stable/11/share/mk/bsd.obj.mk	Sun Dec 25 14:54:51 2016	(r310540)
@@ -102,7 +102,7 @@ obj: .PHONY
 		fi; \
 		${ECHO} "${CANONICALOBJDIR} created for ${.CURDIR}"; \
 	fi
-.for dir in ${SRCS:H:O:u}
+.for dir in ${SRCS:H:O:u} ${DPSRCS:H:O:u}
 	@if ! test -d ${CANONICALOBJDIR}/${dir}/; then \
 		mkdir -p ${CANONICALOBJDIR}/${dir}; \
 		if ! test -d ${CANONICALOBJDIR}/${dir}/; then \

From owner-svn-src-all@freebsd.org  Sun Dec 25 14:58:51 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D23A1C8F1ED;
 Sun, 25 Dec 2016 14:58:51 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id ACABD15D9;
 Sun, 25 Dec 2016 14:58:51 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPEwoC8062334;
 Sun, 25 Dec 2016 14:58:50 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPEwoM3062332;
 Sun, 25 Dec 2016 14:58:50 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251458.uBPEwoM3062332@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 14:58:50 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310541 - stable/11/lib/libcompiler_rt
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 14:58:51 -0000

Author: dim
Date: Sun Dec 25 14:58:50 2016
New Revision: 310541
URL: https://svnweb.freebsd.org/changeset/base/310541

Log:
  MFC r306266 (by emaste):
  
  libcompiler_rt: use ${SRCTOP} for the top of the FreeBSD tree
  
  MFC r306377 (by emaste):
  
  libcompiler_rt: move file list to Makefile.inc for reuse elsewhere
  
  Also switch to the style used in the clang390-import branch to reduce
  future conflicts.
  
  Reviewed by:	dim
  Sponsored by:	The FreeBSD Foundation
  Differential Revision:	https://reviews.freebsd.org/D8039

Added:
  stable/11/lib/libcompiler_rt/Makefile.inc
     - copied unchanged from r306377, head/lib/libcompiler_rt/Makefile.inc
Modified:
  stable/11/lib/libcompiler_rt/Makefile
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/lib/libcompiler_rt/Makefile
==============================================================================
--- stable/11/lib/libcompiler_rt/Makefile	Sun Dec 25 14:54:51 2016	(r310540)
+++ stable/11/lib/libcompiler_rt/Makefile	Sun Dec 25 14:58:50 2016	(r310541)
@@ -8,225 +8,9 @@ NO_PIC=
 WARNS?=	2
 
 CFLAGS+=${PICFLAG} -fvisibility=hidden -DVISIBILITY_HIDDEN
-CFLAGS+=-I${.CURDIR}/../../contrib/libcxxrt
+CFLAGS+=-I${SRCTOP}/contrib/libcxxrt
 
-.if ${MACHINE_CPUARCH} == "amd64"
-CRTARCH=x86_64
-.else
-CRTARCH=${MACHINE_CPUARCH}
-.endif
-
-CRTSRC=${.CURDIR}/../../contrib/compiler-rt/lib/builtins
-
-.PATH: ${CRTSRC}/${CRTARCH} ${CRTSRC}
-
-SRCF=	absvdi2 \
-	absvsi2 \
-	absvti2 \
-	addvdi3 \
-	addvsi3 \
-	addvti3 \
-	apple_versioning \
-	ashldi3 \
-	ashlti3 \
-	ashrdi3 \
-	ashrti3 \
-	clear_cache \
-	clzdi2 \
-	clzsi2 \
-	clzti2 \
-	cmpdi2 \
-	cmpti2 \
-	ctzdi2 \
-	ctzsi2 \
-	ctzti2 \
-	divdc3 \
-	divdi3 \
-	divmoddi4 \
-	divmodsi4 \
-	divsc3 \
-	divtc3 \
-	divti3 \
-	divxc3 \
-	enable_execute_stack \
-	eprintf \
-	extendhfsf2 \
-	ffsdi2 \
-	ffsti2 \
-	fixdfdi \
-	fixdfti \
-	fixsfdi \
-	fixsfti \
-	fixunsdfdi \
-	fixunsdfsi \
-	fixunsdfti \
-	fixunssfdi \
-	fixunssfsi \
-	fixunssfti \
-	fixunsxfdi \
-	fixunsxfsi \
-	fixunsxfti \
-	fixxfdi \
-	fixxfti \
-	floatdidf \
-	floatdisf \
-	floatditf \
-	floatdixf \
-	floatsitf \
-	floattidf \
-	floattisf \
-	floattixf \
-	floatundidf \
-	floatundisf \
-	floatunditf \
-	floatundixf \
-	floatunsidf \
-	floatunsisf \
-	floatuntidf \
-	floatuntisf \
-	floatuntixf \
-	gcc_personality_v0 \
-	int_util \
-	lshrdi3 \
-	lshrti3 \
-	moddi3 \
-	modti3 \
-	muldc3 \
-	muldi3 \
-	mulodi4 \
-	mulosi4 \
-	muloti4 \
-	mulsc3 \
-	multi3 \
-	mulvdi3 \
-	mulvsi3 \
-	mulvti3 \
-	multc3 \
-	mulxc3 \
-	negdf2 \
-	negdi2 \
-	negsf2 \
-	negti2 \
-	negvdi2 \
-	negvsi2 \
-	negvti2 \
-	paritydi2 \
-	paritysi2 \
-	parityti2 \
-	popcountdi2 \
-	popcountsi2 \
-	popcountti2 \
-	powidf2 \
-	powisf2 \
-	powitf2 \
-	powixf2 \
-	subvdi3 \
-	subvsi3 \
-	subvti3 \
-	trampoline_setup \
-	truncdfhf2 \
-	truncsfhf2 \
-	ucmpdi2 \
-	ucmpti2 \
-	udivdi3 \
-	udivmoddi4 \
-	udivmodsi4 \
-	udivmodti4 \
-	udivti3 \
-	umoddi3 \
-	umodti3
-
-# 128-bit quad precision long double support, only used on arm64
-.if ${MACHINE_CPUARCH} == "aarch64"
-SRCF+=	addtf3 \
-	comparetf2 \
-	divtf3 \
-	extenddftf2 \
-	extendsftf2 \
-	fixtfdi \
-	fixtfsi \
-	fixtfti \
-	fixunstfdi \
-	fixunstfsi \
-	fixunstfti \
-	floatunsitf \
-	multf3 \
-	subtf3 \
-	trunctfdf2 \
-	trunctfsf2
-.endif
-
-# These are already shipped by libc.a on arm and mips
-.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips"
-SRCF+=	adddf3 \
-	addsf3 \
-	divdf3 \
-	divsf3 \
-	extendsfdf2 \
-	fixdfsi \
-	fixsfsi \
-	floatsidf \
-	floatsisf \
-	muldf3 \
-	mulsf3 \
-	subdf3 \
-	subsf3 \
-	truncdfsf2
-.endif
-
-.if ${MACHINE_CPUARCH} != "arm"
-SRCF+=	comparedf2 \
-	comparesf2
-.endif
-
-.if ${MACHINE_CPUARCH} != "mips"
-SRCF+=	divsi3 \
-	modsi3 \
-	udivsi3 \
-	umodsi3
-.endif
-
-# FreeBSD-specific atomic intrinsics.
-.if ${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "armv6"
-.PATH: ${.CURDIR}/../../sys/arm/arm
-
-SRCF+=	stdatomic
-CFLAGS+=	-DEMIT_SYNC_ATOMICS
-.elif ${MACHINE_CPUARCH} == "mips"
-.PATH: ${.CURDIR}/../../sys/mips/mips
-
-SRCF+=	stdatomic
-.endif
-
-.for file in ${SRCF}
-.if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") && \
-    exists(${CRTSRC}/${CRTARCH}/${file}vfp.S)
-SRCS+= ${file}vfp.S
-. elif exists(${CRTSRC}/${CRTARCH}/${file}.S)
-SRCS+=	${file}.S
-. else
-SRCS+=	${file}.c
-. endif
-.endfor
-
-.if ${MACHINE_CPUARCH} == "arm"
-SRCS+=	aeabi_div0.c \
-	aeabi_idivmod.S \
-	aeabi_ldivmod.S \
-	aeabi_memcmp.S \
-	aeabi_memcpy.S \
-	aeabi_memmove.S \
-	aeabi_memset.S \
-	aeabi_uidivmod.S \
-	aeabi_uldivmod.S \
-	bswapdi2.S \
-	bswapsi2.S \
-	switch16.S \
-	switch32.S \
-	switch8.S \
-	switchu8.S \
-	sync_synchronize.S
-.endif
+.include "Makefile.inc"
 
 .if ${MK_INSTALLLIB} != "no"
 SYMLINKS+=libcompiler_rt.a ${LIBDIR}/libgcc.a

Copied: stable/11/lib/libcompiler_rt/Makefile.inc (from r306377, head/lib/libcompiler_rt/Makefile.inc)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/11/lib/libcompiler_rt/Makefile.inc	Sun Dec 25 14:58:50 2016	(r310541, copy of r306377, head/lib/libcompiler_rt/Makefile.inc)
@@ -0,0 +1,216 @@
+# $FreeBSD$
+
+CRTARCH=	${MACHINE_CPUARCH:C/amd64/x86_64/}
+
+CRTSRC=		${SRCTOP}/contrib/compiler-rt/lib/builtins
+
+.PATH:		${CRTSRC}/${CRTARCH}
+.PATH:		${CRTSRC}
+
+SRCF+=		absvdi2
+SRCF+=		absvsi2
+SRCF+=		absvti2
+SRCF+=		addvdi3
+SRCF+=		addvsi3
+SRCF+=		addvti3
+SRCF+=		apple_versioning
+SRCF+=		ashldi3
+SRCF+=		ashlti3
+SRCF+=		ashrdi3
+SRCF+=		ashrti3
+SRCF+=		clear_cache
+SRCF+=		clzdi2
+SRCF+=		clzsi2
+SRCF+=		clzti2
+SRCF+=		cmpdi2
+SRCF+=		cmpti2
+SRCF+=		ctzdi2
+SRCF+=		ctzsi2
+SRCF+=		ctzti2
+SRCF+=		divdc3
+SRCF+=		divdi3
+SRCF+=		divmoddi4
+SRCF+=		divmodsi4
+SRCF+=		divsc3
+SRCF+=		divtc3
+SRCF+=		divti3
+SRCF+=		divxc3
+SRCF+=		enable_execute_stack
+SRCF+=		eprintf
+SRCF+=		extendhfsf2
+SRCF+=		ffsdi2
+SRCF+=		ffsti2
+SRCF+=		fixdfdi
+SRCF+=		fixdfti
+SRCF+=		fixsfdi
+SRCF+=		fixsfti
+SRCF+=		fixunsdfdi
+SRCF+=		fixunsdfsi
+SRCF+=		fixunsdfti
+SRCF+=		fixunssfdi
+SRCF+=		fixunssfsi
+SRCF+=		fixunssfti
+SRCF+=		fixunsxfdi
+SRCF+=		fixunsxfsi
+SRCF+=		fixunsxfti
+SRCF+=		fixxfdi
+SRCF+=		fixxfti
+SRCF+=		floatdidf
+SRCF+=		floatdisf
+SRCF+=		floatditf
+SRCF+=		floatdixf
+SRCF+=		floatsitf
+SRCF+=		floattidf
+SRCF+=		floattisf
+SRCF+=		floattixf
+SRCF+=		floatundidf
+SRCF+=		floatundisf
+SRCF+=		floatunditf
+SRCF+=		floatundixf
+SRCF+=		floatunsidf
+SRCF+=		floatunsisf
+SRCF+=		floatuntidf
+SRCF+=		floatuntisf
+SRCF+=		floatuntixf
+SRCF+=		gcc_personality_v0
+SRCF+=		int_util
+SRCF+=		lshrdi3
+SRCF+=		lshrti3
+SRCF+=		moddi3
+SRCF+=		modti3
+SRCF+=		muldc3
+SRCF+=		muldi3
+SRCF+=		mulodi4
+SRCF+=		mulosi4
+SRCF+=		muloti4
+SRCF+=		mulsc3
+SRCF+=		multi3
+SRCF+=		mulvdi3
+SRCF+=		mulvsi3
+SRCF+=		mulvti3
+SRCF+=		multc3
+SRCF+=		mulxc3
+SRCF+=		negdf2
+SRCF+=		negdi2
+SRCF+=		negsf2
+SRCF+=		negti2
+SRCF+=		negvdi2
+SRCF+=		negvsi2
+SRCF+=		negvti2
+SRCF+=		paritydi2
+SRCF+=		paritysi2
+SRCF+=		parityti2
+SRCF+=		popcountdi2
+SRCF+=		popcountsi2
+SRCF+=		popcountti2
+SRCF+=		powidf2
+SRCF+=		powisf2
+SRCF+=		powitf2
+SRCF+=		powixf2
+SRCF+=		subvdi3
+SRCF+=		subvsi3
+SRCF+=		subvti3
+SRCF+=		trampoline_setup
+SRCF+=		truncdfhf2
+SRCF+=		truncsfhf2
+SRCF+=		ucmpdi2
+SRCF+=		ucmpti2
+SRCF+=		udivdi3
+SRCF+=		udivmoddi4
+SRCF+=		udivmodsi4
+SRCF+=		udivmodti4
+SRCF+=		udivti3
+SRCF+=		umoddi3
+SRCF+=		umodti3
+
+# 128-bit quad precision long double support, only used on arm64
+.if ${MACHINE_CPUARCH} == "aarch64"
+SRCF+=		addtf3
+SRCF+=		comparetf2
+SRCF+=		divtf3
+SRCF+=		extenddftf2
+SRCF+=		extendsftf2
+SRCF+=		fixtfdi
+SRCF+=		fixtfsi
+SRCF+=		fixtfti
+SRCF+=		fixunstfdi
+SRCF+=		fixunstfsi
+SRCF+=		fixunstfti
+SRCF+=		floatunsitf
+SRCF+=		multf3
+SRCF+=		subtf3
+SRCF+=		trunctfdf2
+SRCF+=		trunctfsf2
+.endif
+
+# These are already shipped by libc.a on arm and mips
+.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips"
+SRCF+=		adddf3
+SRCF+=		addsf3
+SRCF+=		divdf3
+SRCF+=		divsf3
+SRCF+=		extendsfdf2
+SRCF+=		fixdfsi
+SRCF+=		fixsfsi
+SRCF+=		floatsidf
+SRCF+=		floatsisf
+SRCF+=		muldf3
+SRCF+=		mulsf3
+SRCF+=		subdf3
+SRCF+=		subsf3
+SRCF+=		truncdfsf2
+.endif
+
+.if ${MACHINE_CPUARCH} != "arm"
+SRCF+=		comparedf2
+SRCF+=		comparesf2
+.endif
+
+.if ${MACHINE_CPUARCH} != "mips"
+SRCF+=		divsi3
+SRCF+=		modsi3
+SRCF+=		udivsi3
+SRCF+=		umodsi3
+.endif
+
+# FreeBSD-specific atomic intrinsics.
+.if ${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "armv6"
+.PATH:		${SRCTOP}/sys/arm/arm
+
+SRCF+=		stdatomic
+CFLAGS+=	-DEMIT_SYNC_ATOMICS
+.elif ${MACHINE_CPUARCH} == "mips"
+.PATH:		${SRCTOP}/sys/mips/mips
+
+SRCF+=		stdatomic
+.endif
+
+.for file in ${SRCF}
+.if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \
+    && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S)
+SRCS+=		${file}vfp.S
+. elif exists(${CRTSRC}/${CRTARCH}/${file}.S)
+SRCS+=		${file}.S
+. else
+SRCS+=		${file}.c
+. endif
+.endfor
+
+.if ${MACHINE_CPUARCH} == "arm"
+SRCS+=		aeabi_div0.c
+SRCS+=		aeabi_idivmod.S
+SRCS+=		aeabi_ldivmod.S
+SRCS+=		aeabi_memcmp.S
+SRCS+=		aeabi_memcpy.S
+SRCS+=		aeabi_memmove.S
+SRCS+=		aeabi_memset.S
+SRCS+=		aeabi_uidivmod.S
+SRCS+=		aeabi_uldivmod.S
+SRCS+=		bswapdi2.S
+SRCS+=		bswapsi2.S
+SRCS+=		switch16.S
+SRCS+=		switch32.S
+SRCS+=		switch8.S
+SRCS+=		switchu8.S
+SRCS+=		sync_synchronize.S
+.endif

From owner-svn-src-all@freebsd.org  Sun Dec 25 15:06:01 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 182C6C8F537;
 Sun, 25 Dec 2016 15:06:01 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id DB3A71C1C;
 Sun, 25 Dec 2016 15:06:00 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPF60sE066373;
 Sun, 25 Dec 2016 15:06:00 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPF60NF066370;
 Sun, 25 Dec 2016 15:06:00 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251506.uBPF60NF066370@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 15:06:00 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310542 -
 stable/11/contrib/jemalloc/include/jemalloc/internal
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 15:06:01 -0000

Author: dim
Date: Sun Dec 25 15:05:59 2016
New Revision: 310542
URL: https://svnweb.freebsd.org/changeset/base/310542

Log:
  Merge r304542 from projects/clang390-import (this fix was obsoleted in
  head by an update to jemalloc 4.3.1 in r308473):
  
  Temporarily fix "macro expansion producing 'defined' has undefined
  behavior" in jemalloc, by defining JEMALLOC_CLOCK_GETTIME in a portable
  manner.

Modified:
  stable/11/contrib/jemalloc/include/jemalloc/internal/nstime.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/jemalloc/include/jemalloc/internal/nstime.h
==============================================================================
--- stable/11/contrib/jemalloc/include/jemalloc/internal/nstime.h	Sun Dec 25 14:58:50 2016	(r310541)
+++ stable/11/contrib/jemalloc/include/jemalloc/internal/nstime.h	Sun Dec 25 15:05:59 2016	(r310542)
@@ -1,8 +1,11 @@
 /******************************************************************************/
 #ifdef JEMALLOC_H_TYPES
 
-#define	JEMALLOC_CLOCK_GETTIME defined(_POSIX_MONOTONIC_CLOCK) \
-    && _POSIX_MONOTONIC_CLOCK >= 0
+#if defined(_POSIX_MONOTONIC_CLOCK) && _POSIX_MONOTONIC_CLOCK >= 0
+#define JEMALLOC_CLOCK_GETTIME 1
+#else
+#define JEMALLOC_CLOCK_GETTIME 0
+#endif
 
 typedef struct nstime_s nstime_t;
 

From owner-svn-src-all@freebsd.org  Sun Dec 25 15:39:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A3F47C8E321;
 Sun, 25 Dec 2016 15:39:53 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 73B0CFCD;
 Sun, 25 Dec 2016 15:39:53 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPFdq00079001;
 Sun, 25 Dec 2016 15:39:52 GMT (envelope-from bapt@FreeBSD.org)
Received: (from bapt@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPFdqFR079000;
 Sun, 25 Dec 2016 15:39:52 GMT (envelope-from bapt@FreeBSD.org)
Message-Id: <201612251539.uBPFdqFR079000@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: bapt set sender to
 bapt@FreeBSD.org using -f
From: Baptiste Daroussin <bapt@FreeBSD.org>
Date: Sun, 25 Dec 2016 15:39:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310543 - head
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 15:39:53 -0000

Author: bapt
Date: Sun Dec 25 15:39:52 2016
New Revision: 310543
URL: https://svnweb.freebsd.org/changeset/base/310543

Log:
  Fix build of lib32 libraries for amd64 and powerpc64 with cross toolchain

Modified:
  head/Makefile.libcompat

Modified: head/Makefile.libcompat
==============================================================================
--- head/Makefile.libcompat	Sun Dec 25 15:05:59 2016	(r310542)
+++ head/Makefile.libcompat	Sun Dec 25 15:39:52 2016	(r310543)
@@ -85,7 +85,7 @@ LIBCOMPATCFLAGS+=	-isystem ${LIBCOMPATTM
 .if ${X_COMPILER_VERSION} >= 40800 && \
     (${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no")
 LIBCOMPATCXXFLAGS+=	-isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \
-			-nostdinc++ -L${LIBCOMPAT_OBJTREE}${.CURDIR}/lib/libc++
+			-nostdinc++
 .endif
 .endif
 

From owner-svn-src-all@freebsd.org  Sun Dec 25 16:21:50 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 66304C90305;
 Sun, 25 Dec 2016 16:21:50 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 2E65875E;
 Sun, 25 Dec 2016 16:21:50 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPGLnIe097213;
 Sun, 25 Dec 2016 16:21:49 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPGLnsn097212;
 Sun, 25 Dec 2016 16:21:49 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251621.uBPGLnsn097212@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 16:21:49 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310544 - stable/11/sys/dev/iscsi_initiator
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 16:21:50 -0000

Author: dim
Date: Sun Dec 25 16:21:49 2016
New Revision: 310544
URL: https://svnweb.freebsd.org/changeset/base/310544

Log:
  MFC r305078 (by emaste):
  
  iscsi_initiator: make logout_req::reason unsigned char
  
  Previously this reported an error from Clang 3.9.0: implict conversion
  from 'int' to 'char' changes value from 128 to -128.
  
  Discussed with:	dim, trasz
  Sponsored by:	The FreeBSD Foundation
  Differential Revision:	https://reviews.freebsd.org/D7699

Modified:
  stable/11/sys/dev/iscsi_initiator/iscsi.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/iscsi_initiator/iscsi.h
==============================================================================
--- stable/11/sys/dev/iscsi_initiator/iscsi.h	Sun Dec 25 15:39:52 2016	(r310543)
+++ stable/11/sys/dev/iscsi_initiator/iscsi.h	Sun Dec 25 16:21:49 2016	(r310544)
@@ -356,7 +356,7 @@ typedef struct text_req {
 
 typedef struct logout_req {
      char	cmd;	// 0x06
-     char	reason;	// 0 - close session
+     u_char	reason;	// 0 - close session
      			// 1 - close connection
      			// 2 - remove the connection for recovery
      char	_2[2];

From owner-svn-src-all@freebsd.org  Sun Dec 25 16:37:37 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 536C8C90607;
 Sun, 25 Dec 2016 16:37:37 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 08E4BC8E;
 Sun, 25 Dec 2016 16:37:36 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPGbaWn003367;
 Sun, 25 Dec 2016 16:37:36 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPGba3s003365;
 Sun, 25 Dec 2016 16:37:36 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251637.uBPGba3s003365@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 16:37:36 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310545 - in stable/11/sys: conf modules/bwn
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 16:37:37 -0000

Author: dim
Date: Sun Dec 25 16:37:35 2016
New Revision: 310545
URL: https://svnweb.freebsd.org/changeset/base/310545

Log:
  MFC r305393:
  
  Make some additional -Wconstant-conversion warnings from clang 3.9.0 in
  bwn(4) non-fatal for now.

Modified:
  stable/11/sys/conf/files
  stable/11/sys/modules/bwn/Makefile
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/conf/files
==============================================================================
--- stable/11/sys/conf/files	Sun Dec 25 16:21:49 2016	(r310544)
+++ stable/11/sys/conf/files	Sun Dec 25 16:37:35 2016	(r310545)
@@ -1201,13 +1201,13 @@ dev/bwi/bwiphy.c		optional bwi
 dev/bwi/bwirf.c			optional bwi
 dev/bwi/if_bwi.c		optional bwi
 dev/bwi/if_bwi_pci.c		optional bwi pci
-# XXX Work around clang warning, until maintainer approves fix.
+# XXX Work around clang warnings, until maintainer approves fix.
 dev/bwn/if_bwn.c		optional bwn siba_bwn \
 	compile-with "${NORMAL_C} ${NO_WSOMETIMES_UNINITIALIZED}"
 dev/bwn/if_bwn_pci.c		optional bwn pci bhnd
 dev/bwn/if_bwn_phy_common.c	optional bwn siba_bwn
 dev/bwn/if_bwn_phy_g.c		optional bwn siba_bwn \
-	compile-with "${NORMAL_C} ${NO_WSOMETIMES_UNINITIALIZED}"
+	compile-with "${NORMAL_C} ${NO_WSOMETIMES_UNINITIALIZED} ${NO_WCONSTANT_CONVERSION}"
 dev/bwn/if_bwn_phy_lp.c		optional bwn siba_bwn \
 	compile-with "${NORMAL_C} ${NO_WSOMETIMES_UNINITIALIZED}"
 dev/bwn/if_bwn_phy_n.c		optional bwn siba_bwn

Modified: stable/11/sys/modules/bwn/Makefile
==============================================================================
--- stable/11/sys/modules/bwn/Makefile	Sun Dec 25 16:21:49 2016	(r310544)
+++ stable/11/sys/modules/bwn/Makefile	Sun Dec 25 16:37:35 2016	(r310545)
@@ -28,7 +28,7 @@ SRCS+=	device_if.h bus_if.h pci_if.h opt
 
 .include <bsd.kmod.mk>
 
-# XXX Work around clang warning, until maintainer approves fix.
+# XXX Work around clang warnings, until maintainer approves fix.
 CWARNFLAGS.if_bwn.c=	${NO_WSOMETIMES_UNINITIALIZED}
-CWARNFLAGS.if_bwn_phy_g.c=	${NO_WSOMETIMES_UNINITIALIZED}
+CWARNFLAGS.if_bwn_phy_g.c=	${NO_WSOMETIMES_UNINITIALIZED} ${NO_WCONSTANT_CONVERSION}
 CWARNFLAGS.if_bwn_phy_lp.c=	${NO_WSOMETIMES_UNINITIALIZED}

From owner-svn-src-all@freebsd.org  Sun Dec 25 17:01:59 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id BFD7DC90E41;
 Sun, 25 Dec 2016 17:01:59 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 8EF651893;
 Sun, 25 Dec 2016 17:01:59 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPH1wxt011962;
 Sun, 25 Dec 2016 17:01:58 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPH1wMa011960;
 Sun, 25 Dec 2016 17:01:58 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612251701.uBPH1wMa011960@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Sun, 25 Dec 2016 17:01:58 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310546 - in stable/11/sys: conf modules/si
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 17:01:59 -0000

Author: dim
Date: Sun Dec 25 17:01:58 2016
New Revision: 310546
URL: https://svnweb.freebsd.org/changeset/base/310546

Log:
  Similar to r310545, make some additional -Wconstant-conversion warnings
  from clang 3.9.0 in si(4) non-fatal for now.
  
  Direct commit to stable/11, since si(4) has been deleted from head.

Modified:
  stable/11/sys/conf/files
  stable/11/sys/modules/si/Makefile

Modified: stable/11/sys/conf/files
==============================================================================
--- stable/11/sys/conf/files	Sun Dec 25 16:37:35 2016	(r310545)
+++ stable/11/sys/conf/files	Sun Dec 25 17:01:58 2016	(r310546)
@@ -2558,7 +2558,8 @@ dev/sdhci/sdhci_if.m		optional sdhci
 dev/sdhci/sdhci_pci.c		optional sdhci pci
 dev/sf/if_sf.c			optional sf pci
 dev/sge/if_sge.c		optional sge pci
-dev/si/si.c			optional si
+dev/si/si.c			optional si \
+	compile-with "${NORMAL_C} ${NO_WCONSTANT_CONVERSION}"
 dev/si/si2_z280.c		optional si
 dev/si/si3_t225.c		optional si
 dev/si/si_eisa.c		optional si eisa

Modified: stable/11/sys/modules/si/Makefile
==============================================================================
--- stable/11/sys/modules/si/Makefile	Sun Dec 25 16:37:35 2016	(r310545)
+++ stable/11/sys/modules/si/Makefile	Sun Dec 25 17:01:58 2016	(r310546)
@@ -9,3 +9,5 @@ SRCS+=	opt_compat.h opt_debug_si.h opt_e
 SRCS.DEV_EISA=si_eisa.c eisa_if.h
 
 .include <bsd.kmod.mk>
+
+CWARNFLAGS.si.c=	${NO_WCONSTANT_CONVERSION}

From owner-svn-src-all@freebsd.org  Sun Dec 25 17:37:19 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D4668C90A9B;
 Sun, 25 Dec 2016 17:37:19 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A3BFB1142;
 Sun, 25 Dec 2016 17:37:19 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPHbIZq027942;
 Sun, 25 Dec 2016 17:37:18 GMT (envelope-from tuexen@FreeBSD.org)
Received: (from tuexen@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPHbIhd027939;
 Sun, 25 Dec 2016 17:37:18 GMT (envelope-from tuexen@FreeBSD.org)
Message-Id: <201612251737.uBPHbIhd027939@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: tuexen set sender to
 tuexen@FreeBSD.org using -f
From: Michael Tuexen <tuexen@FreeBSD.org>
Date: Sun, 25 Dec 2016 17:37:18 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310547 - head/sys/netinet
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 17:37:19 -0000

Author: tuexen
Date: Sun Dec 25 17:37:18 2016
New Revision: 310547
URL: https://svnweb.freebsd.org/changeset/base/310547

Log:
  Remove a KASSERT which is not always true.
  
  In case of the empty queue tp->snd_holes and tcp_sackhole_insert()
  failing due to memory shortage, tp->snd_holes will be empty.
  This problem was hit when stress tests where performed by pho.
  
  PR:		215513
  Reported by:	pho
  Tested by:	pho
  Sponsored by:	Netflix, Inc.

Modified:
  head/sys/netinet/tcp_sack.c

Modified: head/sys/netinet/tcp_sack.c
==============================================================================
--- head/sys/netinet/tcp_sack.c	Sun Dec 25 17:01:58 2016	(r310546)
+++ head/sys/netinet/tcp_sack.c	Sun Dec 25 17:37:18 2016	(r310547)
@@ -470,9 +470,6 @@ tcp_sack_doack(struct tcpcb *tp, struct 
 		tp->snd_fack = sblkp->end;
 		sack_changed = 1;
 	}
-	/* We must have at least one SACK hole in scoreboard. */
-	KASSERT(!TAILQ_EMPTY(&tp->snd_holes),
-	    ("SACK scoreboard must not be empty"));
 	cur = TAILQ_LAST(&tp->snd_holes, sackhole_head); /* Last SACK hole. */
 	/*
 	 * Since the incoming sack blocks are sorted, we can process them

From owner-svn-src-all@freebsd.org  Sun Dec 25 17:53:13 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 871CAC9003C;
 Sun, 25 Dec 2016 17:53:13 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 23EF11D9E;
 Sun, 25 Dec 2016 17:53:13 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPHrCw0036011;
 Sun, 25 Dec 2016 17:53:12 GMT (envelope-from bapt@FreeBSD.org)
Received: (from bapt@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPHrBld035996;
 Sun, 25 Dec 2016 17:53:11 GMT (envelope-from bapt@FreeBSD.org)
Message-Id: <201612251753.uBPHrBld035996@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: bapt set sender to
 bapt@FreeBSD.org using -f
From: Baptiste Daroussin <bapt@FreeBSD.org>
Date: Sun, 25 Dec 2016 17:53:11 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-vendor@freebsd.org
Subject: svn commit: r310550 - in vendor/heirloom-doctools/dist: checknr eqn
 eqn/eqn.d grap mpm pic ptx refer soelim troff troff/libhnj troff/nroff.d
 troff/troff.d troff/troff.d/dhtml troff/troff.d/dpost.d ...
X-SVN-Group: vendor
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 17:53:13 -0000

Author: bapt
Date: Sun Dec 25 17:53:10 2016
New Revision: 310550
URL: https://svnweb.freebsd.org/changeset/base/310550

Log:
  Import heirloom doctools 2016-11-06

Added:
  vendor/heirloom-doctools/dist/eqn/eqn.d/eqnchar.7.in   (contents, props changed)
  vendor/heirloom-doctools/dist/grap/grap.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/ptx/ptx.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/refer/lookbib.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/refer/refer.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/refer/roffbib.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/soelim/soelim.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/nroff.d/nroff.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/B.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/BI.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/C.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CB.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CI.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CR.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CW.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/H.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HB.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HI.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/I.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/R.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/S.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/tmac.d/mcolor.7.in   (contents, props changed)
  vendor/heirloom-doctools/dist/troff/troff.d/troff.1.in   (contents, props changed)
  vendor/heirloom-doctools/dist/vgrind/vgrind.1.in   (contents, props changed)
Deleted:
  vendor/heirloom-doctools/dist/eqn/eqn.d/eqnchar.7
  vendor/heirloom-doctools/dist/grap/grap.1
  vendor/heirloom-doctools/dist/ptx/ptx.1
  vendor/heirloom-doctools/dist/refer/lookbib.1
  vendor/heirloom-doctools/dist/refer/refer.1
  vendor/heirloom-doctools/dist/refer/roffbib.1
  vendor/heirloom-doctools/dist/soelim/soelim.1
  vendor/heirloom-doctools/dist/troff/nroff.d/nroff.1
  vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.1
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/B
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/BI
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/C
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CB
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CI
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CR
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CW
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/H
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HB
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HI
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/I
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/R
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/S
  vendor/heirloom-doctools/dist/troff/troff.d/tmac.d/mcolor.7
  vendor/heirloom-doctools/dist/troff/troff.d/troff.1
  vendor/heirloom-doctools/dist/vgrind/vgrind.1
Modified:
  vendor/heirloom-doctools/dist/checknr/checknr.c
  vendor/heirloom-doctools/dist/eqn/eqn.d/Makefile.mk
  vendor/heirloom-doctools/dist/eqn/io.c
  vendor/heirloom-doctools/dist/grap/Makefile.mk
  vendor/heirloom-doctools/dist/grap/grapl.l
  vendor/heirloom-doctools/dist/grap/main.c
  vendor/heirloom-doctools/dist/mpm/page.cc
  vendor/heirloom-doctools/dist/pic/input.c
  vendor/heirloom-doctools/dist/pic/main.c
  vendor/heirloom-doctools/dist/pic/picl.l
  vendor/heirloom-doctools/dist/ptx/Makefile.mk
  vendor/heirloom-doctools/dist/ptx/ptx.c
  vendor/heirloom-doctools/dist/refer/Makefile.mk
  vendor/heirloom-doctools/dist/refer/hunt2.c
  vendor/heirloom-doctools/dist/soelim/Makefile.mk
  vendor/heirloom-doctools/dist/soelim/soelim.c
  vendor/heirloom-doctools/dist/troff/ext.h
  vendor/heirloom-doctools/dist/troff/libhnj/Makefile.mk
  vendor/heirloom-doctools/dist/troff/libhnj/test.c
  vendor/heirloom-doctools/dist/troff/n1.c
  vendor/heirloom-doctools/dist/troff/n2.c
  vendor/heirloom-doctools/dist/troff/n3.c
  vendor/heirloom-doctools/dist/troff/n5.c
  vendor/heirloom-doctools/dist/troff/n7.c
  vendor/heirloom-doctools/dist/troff/n8.c
  vendor/heirloom-doctools/dist/troff/n9.c
  vendor/heirloom-doctools/dist/troff/ni.c
  vendor/heirloom-doctools/dist/troff/nii.c
  vendor/heirloom-doctools/dist/troff/nroff.d/Makefile.mk
  vendor/heirloom-doctools/dist/troff/nroff.d/n6.c
  vendor/heirloom-doctools/dist/troff/nroff.d/pt.h
  vendor/heirloom-doctools/dist/troff/tdef.h
  vendor/heirloom-doctools/dist/troff/troff.d/Makefile.mk
  vendor/heirloom-doctools/dist/troff/troff.d/afm.c
  vendor/heirloom-doctools/dist/troff/troff.d/afm.h
  vendor/heirloom-doctools/dist/troff/troff.d/dhtml/dhtml.l
  vendor/heirloom-doctools/dist/troff/troff.d/dhtml/lib.c
  vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/Makefile.mk
  vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.c
  vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/misc.c
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/Makefile.mk
  vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/makefont.c
  vendor/heirloom-doctools/dist/troff/troff.d/otf.c
  vendor/heirloom-doctools/dist/troff/troff.d/otfdump.c
  vendor/heirloom-doctools/dist/troff/troff.d/pt.h
  vendor/heirloom-doctools/dist/troff/troff.d/t10.c
  vendor/heirloom-doctools/dist/troff/troff.d/t6.c
  vendor/heirloom-doctools/dist/troff/troff.d/ta.c
  vendor/heirloom-doctools/dist/troff/troff.d/tmac.d/Makefile.mk
  vendor/heirloom-doctools/dist/troff/troff.d/troff.h
  vendor/heirloom-doctools/dist/vgrind/Makefile.mk
  vendor/heirloom-doctools/dist/vgrind/regexp.c
  vendor/heirloom-doctools/dist/vgrind/vgrindefs.c

Modified: vendor/heirloom-doctools/dist/checknr/checknr.c
==============================================================================
--- vendor/heirloom-doctools/dist/checknr/checknr.c	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/checknr/checknr.c	Sun Dec 25 17:53:10 2016	(r310550)
@@ -427,7 +427,7 @@ prop(int i)
 
 /* ARGSUSED */
 static void
-chkcmd(char *line, char *mac)
+chkcmd(char *line __unused, char *mac)
 {
 	int i;
 

Modified: vendor/heirloom-doctools/dist/eqn/eqn.d/Makefile.mk
==============================================================================
--- vendor/heirloom-doctools/dist/eqn/eqn.d/Makefile.mk	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/eqn/eqn.d/Makefile.mk	Sun Dec 25 17:53:10 2016	(r310550)
@@ -8,7 +8,7 @@ FLAGS = -I. -I.. -I../../include $(DEFIN
 .c.o:
 	$(CC) $(_CFLAGS) $(FLAGS) -c $<
 
-all: eqn
+all: eqn eqnchar.7
 
 eqn: $(OBJ)
 	$(CC) $(_CFLAGS) $(_LDFLAGS) $(OBJ) $(LIBS) -o eqn
@@ -29,10 +29,13 @@ install:
 	$(INSTALL) -c -m 644 eqnchar.7 $(ROOT)$(MANDIR)/man7/eqnchar.7
 
 clean:
-	rm -f $(OBJ) eqn e.c y.tab.* core log *~
+	rm -f $(OBJ) eqn e.c y.tab.* core log *~ eqnchar.7
 
 mrproper: clean
 
+eqnchar.7: eqnchar.7.in
+	sed 's"/usr/pub/"$(ROOT)$(PUBDIR)/"' eqnchar.7.in > $@
+
 diacrit.o: ../diacrit.c ../e.h y.tab.h
 eqnbox.o: ../eqnbox.c ../e.h
 font.o: ../font.c ../e.h

Added: vendor/heirloom-doctools/dist/eqn/eqn.d/eqnchar.7.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/dist/eqn/eqn.d/eqnchar.7.in	Sun Dec 25 17:53:10 2016	(r310550)
@@ -0,0 +1,212 @@
+'\" e
+.\" Sccsid @(#)eqnchar.7b	1.2 (gritter) 12/9/05
+.\" Derived from eqnchar(7), Unix 7th edition:
+.\" Copyright(C) Caldera International Inc. 2001-2002. All rights reserved.
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\"   Redistributions of source code and documentation must retain the
+.\"    above copyright notice, this list of conditions and the following
+.\"    disclaimer.
+.\"   Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in the
+.\"    documentation and/or other materials provided with the distribution.
+.\"   All advertising materials mentioning features or use of this software
+.\"    must display the following acknowledgement:
+.\"      This product includes software developed or owned by Caldera
+.\"      International, Inc.
+.\"   Neither the name of Caldera International, Inc. nor the names of
+.\"    other contributors may be used to endorse or promote products
+.\"    derived from this software without specific prior written permission.
+.\"
+.\" USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA
+.\" INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR
+.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE
+.\" LIABLE FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR
+.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+.\" BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+.\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+.\" OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+.\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+.TH EQNCHAR 7 "12/9/05" "Heirloom Documentation Tools" "BSD System Compatibility"
+.EQ
+tdefine ciplus % "\o'\(pl\(ci'" %
+ndefine ciplus % O+ %
+tdefine citimes % "\o'\(mu\(ci'" %
+ndefine citimes % Ox %
+tdefine =wig % "\(eq\h'-\w'\(eq'u-\w'\s-2\(ap'u/2u'\v'-.4m'\s-2\z\(ap\(ap\s+2\v'.4m'\h'\w'\(eq'u-\w'\s-2\(ap'u/2u'" %
+ndefine =wig % ="~" %
+tdefine bigstar % "\o'\(pl\(mu'" %
+ndefine bigstar % X|- %
+tdefine =dot % "\z\(eq\v'-.6m'\h'.2m'\s+2.\s-2\v'.6m'\h'.1m'" %
+ndefine =dot % = dot %
+tdefine orsign % "\s-2\v'-.15m'\z\e\e\h'-.05m'\z\(sl\(sl\v'.15m'\s+2" %
+ndefine orsign % \e/ %
+tdefine andsign % "\s-2\v'-.15m'\z\(sl\(sl\h'-.05m'\z\e\e\v'.15m'\s+2" %
+ndefine andsign % /\e %
+tdefine =del % "\v'.3m'\z=\v'-.6m'\h'.3m'\s-1\(*D\s+1\v'.3m'" %
+ndefine =del % = to DELTA %
+tdefine oppA % "\s-2\v'-.15m'\z\e\e\h'-.05m'\z\(sl\(sl\v'-.15m'\h'-.75m'\z-\z-\h'.2m'\z-\z-\v'.3m'\h'.4m'\s+2" %
+ndefine oppA % V- %
+tdefine oppE %"\s-3\v'.2m'\z\(em\v'-.5m'\z\(em\v'-.5m'\z\(em\v'.55m'\h'.9m'\z\(br\z\(br\v'.25m'\s+3" %
+ndefine oppE % E/ %
+tdefine incl % "\s-1\z\(or\h'-.1m'\v'-.45m'\z\(em\v'.7m'\z\(em\v'.2m'\(em\v'-.45m'\s+1" %
+ndefine incl % C_ %
+tdefine nomem % "\o'\(mo\(sl'" %
+ndefine nomem % C-/ %
+tdefine angstrom % "\fR\zA\v'-.3m'\h'.2m'\(de\v'.3m'\fP\h'.2m'" %
+ndefine angstrom % A to o %
+tdefine star %{ roman "\v'.5m'\s+3*\s-3\v'-.5m'"}%
+ndefine star % * %
+tdefine || % \(or\(or %
+tdefine <wig % "\z<\v'.4m'\(ap\v'-.4m'" %
+ndefine <wig %{ < from "~" }%
+tdefine >wig % "\z>\v'.4m'\(ap\v'-.4m'" %
+ndefine >wig %{ > from "~" }%
+tdefine langle % "\s-3\b'\(sl\e'\s0" %
+ndefine langle %<%
+tdefine rangle % "\s-3\b'\e\(sl'\s0" %
+ndefine rangle %>%
+tdefine hbar % "\zh\v'-.6m'\h'.05m'\(ru\v'.6m'" %
+ndefine hbar % h\u-\d %
+ndefine ppd % _| %
+tdefine ppd % "\o'\(ru\s-2\(or\s+2'" %
+tdefine <-> % "\o'\(<-\(->'" %
+ndefine <-> % "<-->" %
+tdefine <=> % "\s-2\z<\v'.05m'\h'.2m'\z=\h'.55m'=\h'-.6m'\v'-.05m'>\s+2" %
+ndefine <=> % "<=>" %
+tdefine |< % "\o'<\(or'" %
+ndefine |< % <| %
+tdefine |> % "\o'>\(or'" %
+ndefine |> % |> %
+tdefine ang % "\v'-.15m'\z\s-2\(sl\s+2\v'.15m'\(ru" %
+ndefine ang % /_ %
+tdefine rang % "\z\(or\h'.15m'\(ru" %
+ndefine rang % L %
+tdefine 3dot % "\v'-.8m'\z.\v'.5m'\z.\v'.5m'.\v'-.2m'" %
+ndefine 3dot % .\u.\u.\d\d %
+tdefine thf % ".\v'-.5m'.\v'.5m'." %
+ndefine thf % ..\u.\d %
+tdefine quarter % roman \(14 %
+ndefine quarter % 1/4 %
+tdefine 3quarter % roman \(34 %
+ndefine 3quarter % 3/4 %
+tdefine degree % \(de %
+ndefine degree % nothing sup o %
+tdefine square % \(sq %
+ndefine square % [] %
+tdefine circle % \(ci %
+ndefine circle % O %
+tdefine blot % "\fB\(sq\fP" %
+ndefine blot % HIX %
+tdefine bullet % \(bu %
+ndefine bullet % oxe %
+tdefine -wig % "\(~=" %
+ndefine -wig % - to "~" %
+tdefine wig % \(ap %
+ndefine wig % "~" %
+tdefine prop % \(pt %
+ndefine prop % oc %
+tdefine empty % \(es %
+ndefine empty % O/ %
+tdefine member % \(mo %
+ndefine member % C- %
+tdefine cup % \(cu %
+ndefine cup % U %
+define cap % \(ca %
+define subset % \(sb %
+define supset % \(sp %
+define !subset % \(ib %
+define !supset % \(ip %
+.EN
+.SH NAME
+eqnchar \- special character definitions for eqn
+.SH SYNOPSIS
+.HP
+.ad l
+.nh
+.B eqn /usr/pub/eqnchar
+.RB [ files ]
+.B | troff
+.RB [ options ]
+.HP
+.B neqn /usr/pub/eqnchar
+.RB [ files ]
+.B | nroff
+.RB [ options ]
+.br
+.hy 1
+.ad b
+.SH DESCRIPTION
+.I Eqnchar
+contains
+.I troff
+and
+.I nroff
+character definitions for constructing characters that are not
+available on the Graphic Systems typesetter.
+These definitions are primarily intended for use with
+.I eqn
+and
+.IR neqn .
+It contains
+definitions for the following characters
+.PP
+.nf
+.ta \w'angstrom  'u \n(.lu/3u +\w'angstrom  'u \n(.lu*2u/3u +\w'angstrom  'u
+.EQ
+"ciplus"	ciplus	"|\||"	||	"square"	square
+.EN
+.EQ
+"citimes"	citimes	"langle"	langle	"circle"	circle
+.EN
+.EQ
+"wig"	wig	"rangle"	rangle	"blot"	blot
+.EN
+.EQ
+"-wig"	-wig	"hbar"	hbar	"bullet"	bullet
+.EN
+.EQ
+">wig"	>wig	"ppd"	ppd	"prop"	prop
+.EN
+.EQ
+"<wig"	<wig	"<->"	<->	"empty"	empty
+.EN
+.EQ
+"=wig"	=wig	"<=>"	<=>	"member"	member
+.EN
+.EQ
+"star"	star	"|\|"	|<	"nomem"	nomem
+.EN
+.EQ
+"bigstar"	bigstar	"|\|>"	|>	"cup"	cup
+.EN
+.EQ
+"=dot"	=dot	"ang"	ang	"cap"	cap
+.EN
+.EQ
+"orsign"	orsign	"rang"	rang	"incl"	incl
+.EN
+.EQ
+"andsign"	andsign	"3dot"	3dot	"subset"	subset
+.EN
+.EQ
+"=del"	=del	"thf"	thf	"supset"	supset
+.EN
+.EQ
+"oppA"	oppA	"quarter"	quarter	"!subset"	!subset
+.EN
+.EQ
+"oppE"	oppE	"3quarter"	3quarter	"!supset"	!supset
+.EN
+.EQ
+"angstrom"	angstrom	"degree"	degree
+.EN
+.SH FILES
+/usr/pub/eqnchar
+.SH SEE ALSO
+troff(1), eqn(1)

Modified: vendor/heirloom-doctools/dist/eqn/io.c
==============================================================================
--- vendor/heirloom-doctools/dist/eqn/io.c	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/eqn/io.c	Sun Dec 25 17:53:10 2016	(r310550)
@@ -25,6 +25,7 @@
 #include <stdarg.h>
 #include <stdlib.h>
 #include <libgen.h>
+#include "global.h"
 
 static char	*in;	/* input buffer */
 static size_t	insize;	/* input buffer size */
@@ -283,7 +284,7 @@ setfile(int argc, char **argv) {
 }
 
 void
-yyerror(char *unused) {;}
+yyerror(char *unused __unused) {;}
 
 void
 init(void) {

Modified: vendor/heirloom-doctools/dist/grap/Makefile.mk
==============================================================================
--- vendor/heirloom-doctools/dist/grap/Makefile.mk	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/grap/Makefile.mk	Sun Dec 25 17:53:10 2016	(r310550)
@@ -8,7 +8,7 @@ YFLAGS = -d
 .c.o:
 	$(CC) $(_CFLAGS) $(FLAGS) -c $<
 
-all: grap.c grapl.c grap
+all: grap.c grapl.c grap grap.1
 
 grap: $(OBJ)
 	$(CC) $(_CFLAGS) $(_LDFLAGS) $(OBJ) $(LIBS) -lm -o grap
@@ -23,10 +23,13 @@ install:
 	$(INSTALL) -c -m 644 grap.1 $(ROOT)$(MANDIR)/man1/grap.1
 
 clean:
-	rm -f $(OBJ) grapl.c grap.c y.tab.h grap core log *~
+	rm -f $(OBJ) grapl.c grap.c y.tab.h grap core log *~ grap.1
 
 mrproper: clean
 
+grap.1: grap.1.in
+	sed 's"/usr/ucblib/"$(ROOT)$(LIBDIR)/"' grap.1.in > $@
+
 coord.o: coord.c grap.h y.tab.h
 for.o: for.c grap.h y.tab.h
 frame.o: frame.c grap.h y.tab.h

Added: vendor/heirloom-doctools/dist/grap/grap.1.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/dist/grap/grap.1.in	Sun Dec 25 17:53:10 2016	(r310550)
@@ -0,0 +1,430 @@
+.\"
+.\" Changes by Gunnar Ritter, Freiburg i. Br., Germany, October 2005.
+.\"
+.\" Derived from Plan 9 v4 /opt/unix/plan9v4/sys/man/1/grap
+.\"
+.\" Copyright (C) 2003, Lucent Technologies Inc. and others.
+.\" All Rights Reserved.
+.\"
+.\" Distributed under the terms of the Lucent Public License Version 1.02.
+.\"
+.\" Sccsid @(#)grap.1	1.5 (gritter) 2/2/07
+.TH GRAP 1 "2/2/07" "Heirloom Documentation Tools" "User Commands"
+.SH NAME
+grap \- pic preprocessor for drawing graphs
+.SH SYNOPSIS
+\fBgrap\fR [\fB\-SU\fR] [\fIfile\fR]
+.SH DESCRIPTION
+.I Grap
+is a
+.IR pic (1)
+preprocessor for drawing graphs on a typesetter.
+Graphs are surrounded by the
+.I troff
+`commands'
+.B \&.G1
+and
+.BR  \&.G2 .
+Data are scaled and plotted,
+with tick marks supplied automatically.
+Commands exist to modify the frame,
+add labels, override the default ticks,
+change the plotting style,
+define coordinate ranges and transformations,
+and include data from files.
+In addition,
+.I grap
+provides the same loops, conditionals, and macro processing that
+.I pic
+does.
+.PP
+.BI frame
+.B ht
+.I e
+.B wid
+.I e
+.B top
+.B dotted
+.IR ... :
+Set the frame around the graph to specified
+.B ht
+and
+.BR wid ;
+default is 2 by 3 (inches).
+The line
+.I styles
+.RB ( dotted ,
+.BR dashed ,
+.BR invis ,
+.BR solid
+(default))
+of the 
+.I sides
+.RB ( top ,
+.BR bot ,
+.BR left ,
+.BR right )
+of the frame can be set
+independently.
+.PP
+.B label
+.I side
+.B \&"a label"
+.B \&"as a set of strings"
+.IR adjust :
+Place label on specified side; default side is bottom.
+.I adjust
+is
+.B up
+(or
+.B down
+.B left
+.BR right )
+.I expr
+to shift default position;
+.B width
+.I expr
+sets the width explicitly.
+.PP
+.BI ticks
+.I side
+.B in
+.B at
+.IR "optname expr, expr, ..." :
+Put ticks on
+.I side
+at
+.I "expr, ...,
+and label with
+.I \&"expr"\f1.
+If any
+.I expr
+is followed by "...", label tick with "...",
+and turn off all automatic labels.
+If "..." contains
+.BR %f 's,
+they will be interpreted as
+.B printf
+formatting instructions for the tick value.
+Ticks point
+.B in
+or
+.B out
+(default out).
+Tick iterator: instead of
+.B at
+.IR \&... ,
+use
+.BI from
+.I expr
+.B to
+.I expr
+.B by
+.I "op expr
+where
+.I op
+is optionally
+.B +\-*/
+for additive or multiplicative steps.
+.B by
+can be omitted, to give steps of size 1.
+If no ticks are requested, they are supplied automatically;
+suppress this with
+.B ticks
+.BR off .
+Automatic ticks normally
+leave a margin of 7% on each side; set this to anything by
+.B margin
+.B =
+.IR expr .
+.PP
+.B grid
+.I "side linedesc"
+.B at
+.IR "optname expr, expr, ..." :
+Draw grids perpendicular to
+.I side
+in style
+.I linedesc
+at
+.I "expr, ....\&
+Iterators and labels work as with ticks.
+.PP
+.B coord
+.I optname
+.B x
+.I "min, max"
+.B y
+.I "min, max"
+.B "log x
+.BR " log y" :
+Set range of coords and optional log scaling on either or both.
+This overrides computation of data range.
+Default value of
+.I optname
+is current coordinate system
+(each
+.B coord
+defines a new coordinate system).
+.PP
+.B plot
+.I \&"str"
+.B at
+.IR point ;
+.B
+.I \&"str"
+.B at
+.IR point :
+Put
+.I str
+at
+.IR point .
+Text position can be qualified with
+.BR rjust ,
+.BR ljust ,
+.BR above ,
+.BR below
+after "...".
+.PP
+.B line
+.B from
+.I point
+.B to
+.IR "point linedesc" :
+Draw line from here to there.
+.B arrow
+works in place of
+.BR line .
+.PP
+.B next
+.I optname
+.B at
+.IR "point linedesc" :
+Continue plot of data in
+.I optname to
+.IR point ;
+default is current.
+.PP
+.BI draw
+.IR "optname linedesc ..." :
+Set mode for
+.BR next :
+use this style from now on,
+and plot "..." at each point (if given).
+.PP
+.BI new
+.IR "optname linedesc ..." :
+Set mode for
+.BR next ,
+but disconnect from previous.
+.PP
+A list of numbers
+.I "x y1 y2 y3 ...
+is treated as 
+.B plot
+.B bullet
+.B at
+.IR x,y1 ;
+.B plot
+.B bullet
+.B at
+.IR x,y2 ;
+etc., or as
+.B next
+.B at
+.I x,y1
+etc., if
+.B draw
+is specified.
+Abscissae of 1,2,3,... are provided if there is only one input number per line.
+.PP
+A
+point
+.I "optname expr, expr
+maps the point to the named coordinate system.
+A
+.I linedesc
+is one of
+.B dot
+.B dash
+.B invis
+.B solid
+optionally followed by an expression.
+.PP
+.BI define
+.I name
+.BI { whatever } \f1:
+Define a macro.
+There are macros already defined for standard plotting
+symbols like
+.BR bullet ,
+.BR circle ,
+.BR star ,
+.BR plus ,
+etc., in
+.BR /sys/lib/grap.defines ,
+which is included if it exists.
+.PP
+.I var
+.B =
+.IR expr :
+Evaluate an expression.
+Operators are
+.B=
+.B +
+.B \-
+.B *
+and
+.BR / .
+Functions are
+.B log
+and
+.B exp
+(both base 10),
+.BR sin ,
+.BR cos ,
+.BR sqrt ;
+.B rand
+returns random number on [0,1);
+.BI max( e , e )\f1,
+.BI min( e , e )\f1,
+.BI int( e )\f1.
+.PP
+.B print
+.IR expr ;
+.B print
+\fR"\f2...\fR"\f1:
+As a debugging aid, print
+.I expr
+or
+.I string
+on the standard error.
+.PP
+.B copy
+\fR"\fIfile name\fR"\fR:
+Include this file right here.
+.PP
+.B copy
+.B thru
+.IR macro :
+Pass rest of input (until
+.BR \&.G2 )
+through
+.IR macro ,
+treating each field (non-blank, or "...") as an argument.
+.I macro
+can be the name of a macro previously defined,
+or the body of one in place, like
+.BR "/plot $1 at $2,$3/" .
+.PP
+.B copy
+.B thru
+.I macro
+.B until
+\fR"\fIstring\fR"\fR:
+Stop copy when input is
+.I string
+(left-justified).
+.PP
+.BI pic
+.IR "remainder of line" :
+Copy to output with leading blanks removed.
+.PP
+.BI graph
+.IR "Name pic-position" :
+Start a new frame, place it at specified position,
+e.g.,
+.B graph
+.B Thing2
+.BR "with .sw at Thing1.se + (0.1,0)" .
+.I Name
+must be capitalized to keep
+.I pic
+happy.
+.PP
+.BI \&. "anything at beginning of
+.IR line :
+Copied verbatim.
+.PP
+.B sh
+.BI % anything
+.BR % :
+Pass everything between the
+.BR % 's
+to the shell;
+as with macros,
+.B %
+may be any character and
+.I anything
+may include newlines.
+The
+.B \-S
+option disables execution of the shell command;
+the
+.B \-U
+option reverts the effect of a previous
+.IR \-S .
+.PP
+.B #
+.IR anything :
+A comment, which is discarded.
+.PP
+Order is mostly irrelevant; no category is mandatory.
+Any arguments on the
+.B \&.G1
+line are placed on the generated
+.B \&.PS
+line for
+.IR pic .
+.\".SH EXAMPLES
+.\".EX
+.\".ps -1
+.\".vs -1
+.\"\&.G1
+.\"frame ht 1 top invis right invis
+.\"coord x 0, 10 y 1, 3 log y
+.\"ticks left in at 1 "bottommost tick", 2,3 "top tick"
+.\"ticks bot in from 0 to 10 by 2
+.\"label bot "silly graph"
+.\"label left "left side label" "here"
+.\"grid left dashed at 2.5
+.\"copy thru / circle at $1,$2 /
+.\"1 1
+.\"2 1.5
+.\"3 2
+.\"4 1.5
+.\"10 3
+.\"\&.G2
+.\".G1
+.\"frame ht 1 top invis right invis
+.\"coord x 0, 10 y 1, 3 log y
+.\"ticks left in at 1 "bottommost tick", 2,3 "top tick"
+.\"ticks bot in from 0 to 10 by 2
+.\"label bot "silly graph"
+.\"label left "left side label" "here"
+.\"grid left dashed at 2.5
+.\"copy thru / circle at $1,$2 /
+.\"1 1
+.\"2 1.5
+.\"3 2
+.\"4 1.5
+.\"10 3
+.\".G2
+.\".ps
+.\".vs
+.\".EE
+.SH FILES
+.TP
+.B /usr/ucblib/grap.defines
+definitions of standard plotting characters, e.g., bullet
+.\".SH SOURCE
+.\".B /sys/src/cmd/grap
+.SH "SEE ALSO"
+.IR pic (1), 
+.IR troff (1)
+.br
+J. L. Bentley and B. W. Kernighan,
+``GRAP\(emA Language for Typesetting Graphs'',
+.I
+Unix Research System Programmer's Manual,
+Tenth Edition, Volume 2.

Modified: vendor/heirloom-doctools/dist/grap/grapl.l
==============================================================================
--- vendor/heirloom-doctools/dist/grap/grapl.l	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/grap/grapl.l	Sun Dec 25 17:53:10 2016	(r310550)
@@ -12,6 +12,7 @@
 
 /*	Sccsid @(#)grapl.l	1.4 (gritter) 11/22/05	*/
 %}
+%option nounput
 %Start A str def thru sh
 
 %{
@@ -237,10 +238,3 @@ WS	[ \t]
 <str>.		{ CADD; }
 
 %%
-
-#ifdef	FLEX_SCANNER
-void xxcruft(void)
-{
-	unput(0);
-}
-#endif	/* FLEX_SCANNER */

Modified: vendor/heirloom-doctools/dist/grap/main.c
==============================================================================
--- vendor/heirloom-doctools/dist/grap/main.c	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/grap/main.c	Sun Dec 25 17:53:10 2016	(r310550)
@@ -17,8 +17,12 @@
 #include <string.h>
 #include <unistd.h>
 #include "grap.h"
+#include "global.h"
 #include "y.tab.h"
 
+static void onintr(int n);
+static void fpecatch(int n);
+
 int	dbg	= 0;
 
 #define GRAPDEFINES LIBDIR "/grap.defines"
@@ -48,8 +52,6 @@ extern void getdata(void);
 int
 main(int argc, char *argv[])
 {
-	extern void onintr(int), fpecatch(int);
-
 	if (signal(SIGINT, SIG_IGN) != SIG_IGN)
 		signal(SIGINT, onintr);
 	signal(SIGFPE, fpecatch);
@@ -102,14 +104,14 @@ main(int argc, char *argv[])
 }
 
 /*ARGSUSED*/
-void onintr(int n)
+static void onintr(int n __unused)
 {
 	if (!dbg)
 		unlink(tempfile);
 	exit(1);
 }
 
-void fpecatch(int n)
+static void fpecatch(int n)
 {
 	WARNING("floating point exception");
 	onintr(n);

Modified: vendor/heirloom-doctools/dist/mpm/page.cc
==============================================================================
--- vendor/heirloom-doctools/dist/mpm/page.cc	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/mpm/page.cc	Sun Dec 25 17:53:10 2016	(r310550)
@@ -147,25 +147,9 @@ static void justify(stream *scratch, int
 		}
 }
 
-// If r were added to s, would the height of the composed result be at most maxht?
-int wouldfit(range *r, stream *s, int maxht)
-{
-	if (r->rawht() + s->rawht() <= maxht)
-		return 1;		// the conservative test succeeded
-	stream scratch;			// local playground for costly test
-	for (stream cd = *s; cd.more(); cd.advance())
-		scratch.append(cd.current());
-	scratch.append(r);
-	movefloats(&scratch, ((double) scratch.rawht())/maxht);
-	trimspace(&scratch);
-	int retval = scratch.height() <= maxht;
-	scratch.freeall();
-	return retval;
-}
-
 // If s1 were added to s, would the height of the composed result be at most maxht?
 // The computational structure is similar to that above.
-int wouldfit(stream *s1, stream *s, int maxht)
+static int wouldfit(stream *s1, stream *s, int maxht)
 {
 	if (s1->rawht() + s->rawht() <= maxht)
 		return 1;
@@ -316,7 +300,7 @@ void multicol::dump()
 }
 
 // From the head of queue qp, peel off a piece whose raw height is at most space.
-int peeloff(stream *qp, int space)
+static int peeloff(stream *qp, int space)
 {
 	stream *s1 = qp->current()->children();
 	if (!(s1 && s1->more() && s1->current()->height() <= space))

Modified: vendor/heirloom-doctools/dist/pic/input.c
==============================================================================
--- vendor/heirloom-doctools/dist/pic/input.c	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/pic/input.c	Sun Dec 25 17:53:10 2016	(r310550)
@@ -492,8 +492,6 @@ void eprint(void)	/* try to print contex
 	ep = ebuf;
 }
 
-void yywrap(void) {}
-
 static char	*newfile = 0;		/* filename for file copy */
 char	*untilstr = 0;		/* string that terminates a thru */
 int	thru	= 0;		/* 1 if copying thru macro */

Modified: vendor/heirloom-doctools/dist/pic/main.c
==============================================================================
--- vendor/heirloom-doctools/dist/pic/main.c	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/pic/main.c	Sun Dec 25 17:53:10 2016	(r310550)
@@ -17,6 +17,7 @@
 #include	"pic.h"
 #include	"y.tab.h"
 
+static void reset(void);
 extern const char	version[];
 
 obj	**objlist = 0;		/* store the elements here */
@@ -208,7 +209,7 @@ void getdata(void)
 	char *p, *buf = NULL, *buf1 = NULL;
 	size_t size = 0;
 	int ln;
-	void reset(void), openpl(char *), closepl(char *);
+	void openpl(char *), closepl(char *);
 	int yyparse(void);
 
 	curfile->lineno = 0;
@@ -281,7 +282,7 @@ void getdata(void)
 	free(buf1);
 }
 
-void reset(void)
+static void reset(void)
 {
 	obj *op;
 	int i;

Modified: vendor/heirloom-doctools/dist/pic/picl.l
==============================================================================
--- vendor/heirloom-doctools/dist/pic/picl.l	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/pic/picl.l	Sun Dec 25 17:53:10 2016	(r310550)
@@ -12,6 +12,8 @@
 
 /*	Sccsid @(#)picl.l	1.9 (gritter) 8/6/06	*/
 %}
+%option noyywrap
+%option nounput
 %Start A str def xsc br thru sh
 %e 1700
 %k 150
@@ -47,7 +49,6 @@ extern	struct	symtab	symtab[];
 
 int	yyback(int *, int);
 int	yylook(void);
-int	yywrap(void);
 
 #define	CADD	cbuf[clen++]=yytext[0]; \
 		if (clen>=CBUFLEN-1) { WARNING("string too long", cbuf); BEGIN A; }

Modified: vendor/heirloom-doctools/dist/ptx/Makefile.mk
==============================================================================
--- vendor/heirloom-doctools/dist/ptx/Makefile.mk	Sun Dec 25 17:40:18 2016	(r310549)
+++ vendor/heirloom-doctools/dist/ptx/Makefile.mk	Sun Dec 25 17:53:10 2016	(r310550)
@@ -5,7 +5,7 @@ FLAGS = -DLIBDIR='"$(LIBDIR)"' $(EUC) -I
 .c.o:
 	$(CC) $(_CFLAGS) $(FLAGS) -c $<
 
-all: ptx
+all: ptx ptx.1
 
 ptx: $(OBJ)
 	$(CC) $(_CFLAGS) $(_LDFLAGS) $(OBJ) $(LIBS) -o ptx
@@ -18,6 +18,12 @@ install:
 	$(INSTALL) -c -m 644 eign $(ROOT)$(LIBDIR)/eign
 
 clean:
-	rm -f $(OBJ) ptx core log *~
+	rm -f $(OBJ) ptx core log *~ ptx.1
 
 mrproper: clean
+
+ptx.1: ptx.1.in
+	sed -e "s'/usr/5bin/sort'`which sort`'" \
+	    -e 's"/usr/ucblib/doctools/tmac/"$(ROOT)$(BINDIR)/"' \
+	    -e 's"/usr/ucblib/"$(ROOT)$(LIBDIR)/"' \
+	    ptx.1.in > $@

Added: vendor/heirloom-doctools/dist/ptx/ptx.1.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/dist/ptx/ptx.1.in	Sun Dec 25 17:53:10 2016	(r310550)
@@ -0,0 +1,158 @@
+.\"
+.\" Sccsid @(#)ptx.1	1.6 (gritter) 2/2/07
+.\" Parts taken from ptx(1), Unix 7th edition:
+.\" Copyright(C) Caldera International Inc. 2001-2002. All rights reserved.
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\"   Redistributions of source code and documentation must retain the
+.\"    above copyright notice, this list of conditions and the following
+.\"    disclaimer.
+.\"   Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in the
+.\"    documentation and/or other materials provided with the distribution.
+.\"   All advertising materials mentioning features or use of this software
+.\"    must display the following acknowledgement:
+.\"      This product includes software developed or owned by Caldera
+.\"      International, Inc.
+.\"   Neither the name of Caldera International, Inc. nor the names of
+.\"    other contributors may be used to endorse or promote products
+.\"    derived from this software without specific prior written permission.
+.\"
+.\" USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA
+.\" INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR
+.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE
+.\" LIABLE FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR
+.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+.\" BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+.\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+.\" OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+.\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+.Dd February 2, 2007
+.Dt PTX 1
+.Os
+.Sh NAME
+.Nm ptx
+.Nd permuted index
+.Sh SYNOPSIS
+.Nm
+.Op Fl ftr
+.Op Fl w Ar n
+.Op Fl g Ar n
+.Op Fl o Ar only
+.Op Fl i Ar ignore
+.Op Fl b Ar break
+.Op Ar input Op Ar output
+.Sh DESCRIPTION
+.Nm
+generates a permuted index to file
+.Ar input
+on file
+.Ar output
+(standard input and output default).
+It has three phases: the first does the permutation, generating
+one line for each keyword in an input line.
+The keyword is rotated to the front.
+The permuted file is then
+sorted.
+Finally, the sorted lines are rotated so the keyword
+comes at the middle of the page.
+.Nm
+produces output in the form:
+.Bd -literal -offset XXXXX
+\&.xx "tail" "before keyword" "keyword and after" "head"
+.Ed
+.Pp
+where .xx may be an
+.Cm nroff
+or
+.Xr troff  1
+macro
+for user-defined formatting.
+Once choice for this macro is supplied in the
+.Sq Fl mptx
+macro package.
+The
+.Em before keyword
+and
+.Em keyword and after
+fields incorporate as much of the line as will fit
+around the keyword when it is printed at the middle of the page.

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Sun Dec 25 17:54:25 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F5ADC900C0;
 Sun, 25 Dec 2016 17:54:25 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 037FA1F07;
 Sun, 25 Dec 2016 17:54:24 +0000 (UTC)
 (envelope-from bapt@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPHsO4l036102;
 Sun, 25 Dec 2016 17:54:24 GMT (envelope-from bapt@FreeBSD.org)
Received: (from bapt@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPHsN3v036095;
 Sun, 25 Dec 2016 17:54:23 GMT (envelope-from bapt@FreeBSD.org)
Message-Id: <201612251754.uBPHsN3v036095@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: bapt set sender to
 bapt@FreeBSD.org using -f
From: Baptiste Daroussin <bapt@FreeBSD.org>
Date: Sun, 25 Dec 2016 17:54:23 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-vendor@freebsd.org
Subject: svn commit: r310551 - in vendor/heirloom-doctools/20161106: . checknr
 col eqn eqn/checkeq.d eqn/eqn.d eqn/eqnchar.d eqn/neqn.d grap include mpm pic
 picpack ptx refer soelim tbl troff troff/libhnj t...
X-SVN-Group: vendor
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 17:54:25 -0000

Author: bapt
Date: Sun Dec 25 17:54:23 2016
New Revision: 310551
URL: https://svnweb.freebsd.org/changeset/base/310551

Log:
  Tag import of heirloom doctools 2016-11-06

Added:
  vendor/heirloom-doctools/20161106/
     - copied from r306788, vendor/heirloom-doctools/dist/
  vendor/heirloom-doctools/20161106/compat.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/compat.c
  vendor/heirloom-doctools/20161106/eqn/eqn.d/eqnchar.7.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/eqn/eqn.d/eqnchar.7.in
  vendor/heirloom-doctools/20161106/grap/grap.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/grap/grap.1.in
  vendor/heirloom-doctools/20161106/ptx/ptx.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/ptx/ptx.1.in
  vendor/heirloom-doctools/20161106/refer/lookbib.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/refer/lookbib.1.in
  vendor/heirloom-doctools/20161106/refer/refer.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/refer/refer.1.in
  vendor/heirloom-doctools/20161106/refer/roffbib.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/refer/roffbib.1.in
  vendor/heirloom-doctools/20161106/soelim/soelim.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/soelim/soelim.1.in
  vendor/heirloom-doctools/20161106/troff/nroff.d/nroff.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/nroff.d/nroff.1.in
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/dpost.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.1.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/B.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/B.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/BI.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/BI.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/C.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/C.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CB.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CB.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CI.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CI.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CR.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CR.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CW.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/CW.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/H.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/H.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/HB.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HB.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/HI.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/HI.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/I.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/I.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/R.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/R.in
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/S.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/S.in
  vendor/heirloom-doctools/20161106/troff/troff.d/tmac.d/mcolor.7.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/tmac.d/mcolor.7.in
  vendor/heirloom-doctools/20161106/troff/troff.d/troff.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/troff.1.in
  vendor/heirloom-doctools/20161106/vgrind/vgrind.1.in
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/vgrind/vgrind.1.in
Replaced:
  vendor/heirloom-doctools/20161106/checknr/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/checknr/Makefile.mk
  vendor/heirloom-doctools/20161106/checknr/checknr.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/checknr/checknr.c
  vendor/heirloom-doctools/20161106/col/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/col/Makefile.mk
  vendor/heirloom-doctools/20161106/configure
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/configure
  vendor/heirloom-doctools/20161106/eqn/checkeq.d/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/eqn/checkeq.d/Makefile.mk
  vendor/heirloom-doctools/20161106/eqn/checkeq.d/checkeq.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/checkeq.d/checkeq.c
  vendor/heirloom-doctools/20161106/eqn/diacrit.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/diacrit.c
  vendor/heirloom-doctools/20161106/eqn/e.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/e.h
  vendor/heirloom-doctools/20161106/eqn/eqn.d/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/eqn/eqn.d/Makefile.mk
  vendor/heirloom-doctools/20161106/eqn/eqnbox.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/eqnbox.c
  vendor/heirloom-doctools/20161106/eqn/eqnchar.d/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/eqn/eqnchar.d/Makefile.mk
  vendor/heirloom-doctools/20161106/eqn/eqnchar.d/genutf8.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/eqnchar.d/genutf8.c
  vendor/heirloom-doctools/20161106/eqn/funny.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/funny.c
  vendor/heirloom-doctools/20161106/eqn/integral.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/integral.c
  vendor/heirloom-doctools/20161106/eqn/io.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/eqn/io.c
  vendor/heirloom-doctools/20161106/eqn/lex.c
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/eqn/lex.c
  vendor/heirloom-doctools/20161106/eqn/lookup.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/lookup.c
  vendor/heirloom-doctools/20161106/eqn/matrix.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/matrix.c
  vendor/heirloom-doctools/20161106/eqn/neqn.d/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/eqn/neqn.d/Makefile.mk
  vendor/heirloom-doctools/20161106/eqn/paren.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/paren.c
  vendor/heirloom-doctools/20161106/eqn/shift.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/shift.c
  vendor/heirloom-doctools/20161106/eqn/text.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/eqn/text.c
  vendor/heirloom-doctools/20161106/grap/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/grap/Makefile.mk
  vendor/heirloom-doctools/20161106/grap/coord.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/grap/coord.c
  vendor/heirloom-doctools/20161106/grap/grap.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/grap/grap.h
  vendor/heirloom-doctools/20161106/grap/grapl.l
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/grap/grapl.l
  vendor/heirloom-doctools/20161106/grap/input.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/grap/input.c
  vendor/heirloom-doctools/20161106/grap/main.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/grap/main.c
  vendor/heirloom-doctools/20161106/grap/misc.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/grap/misc.c
  vendor/heirloom-doctools/20161106/include/global.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/include/global.h
  vendor/heirloom-doctools/20161106/mk.config
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/mk.config
  vendor/heirloom-doctools/20161106/mpm/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/mpm/Makefile.mk
  vendor/heirloom-doctools/20161106/mpm/misc.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/mpm/misc.h
  vendor/heirloom-doctools/20161106/mpm/page.cc
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/mpm/page.cc
  vendor/heirloom-doctools/20161106/pic/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/pic/Makefile.mk
  vendor/heirloom-doctools/20161106/pic/arcgen.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/arcgen.c
  vendor/heirloom-doctools/20161106/pic/blockgen.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/blockgen.c
  vendor/heirloom-doctools/20161106/pic/for.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/for.c
  vendor/heirloom-doctools/20161106/pic/input.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/pic/input.c
  vendor/heirloom-doctools/20161106/pic/main.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/pic/main.c
  vendor/heirloom-doctools/20161106/pic/misc.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/misc.c
  vendor/heirloom-doctools/20161106/pic/pic.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/pic.h
  vendor/heirloom-doctools/20161106/pic/picl.l
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/pic/picl.l
  vendor/heirloom-doctools/20161106/pic/pltroff.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/pltroff.c
  vendor/heirloom-doctools/20161106/pic/symtab.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/pic/symtab.c
  vendor/heirloom-doctools/20161106/picpack/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/picpack/Makefile.mk
  vendor/heirloom-doctools/20161106/picpack/picpack.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/picpack/picpack.c
  vendor/heirloom-doctools/20161106/ptx/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/ptx/Makefile.mk
  vendor/heirloom-doctools/20161106/ptx/ptx.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/ptx/ptx.c
  vendor/heirloom-doctools/20161106/refer/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/refer/Makefile.mk
  vendor/heirloom-doctools/20161106/refer/deliv2.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/deliv2.c
  vendor/heirloom-doctools/20161106/refer/glue1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/glue1.c
  vendor/heirloom-doctools/20161106/refer/glue3.c
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/refer/glue3.c
  vendor/heirloom-doctools/20161106/refer/glue4.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/glue4.c
  vendor/heirloom-doctools/20161106/refer/glue5.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/glue5.c
  vendor/heirloom-doctools/20161106/refer/hunt1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt1.c
  vendor/heirloom-doctools/20161106/refer/hunt2.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/refer/hunt2.c
  vendor/heirloom-doctools/20161106/refer/hunt5.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt5.c
  vendor/heirloom-doctools/20161106/refer/hunt6.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt6.c
  vendor/heirloom-doctools/20161106/refer/hunt7.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt7.c
  vendor/heirloom-doctools/20161106/refer/hunt8.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt8.c
  vendor/heirloom-doctools/20161106/refer/hunt9.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/hunt9.c
  vendor/heirloom-doctools/20161106/refer/inv1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/inv1.c
  vendor/heirloom-doctools/20161106/refer/inv2.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/inv2.c
  vendor/heirloom-doctools/20161106/refer/inv3.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/inv3.c
  vendor/heirloom-doctools/20161106/refer/inv5.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/inv5.c
  vendor/heirloom-doctools/20161106/refer/inv6.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/inv6.c
  vendor/heirloom-doctools/20161106/refer/mkey1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/mkey1.c
  vendor/heirloom-doctools/20161106/refer/mkey2.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/mkey2.c
  vendor/heirloom-doctools/20161106/refer/refer..c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer..c
  vendor/heirloom-doctools/20161106/refer/refer0.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer0.c
  vendor/heirloom-doctools/20161106/refer/refer1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer1.c
  vendor/heirloom-doctools/20161106/refer/refer2.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer2.c
  vendor/heirloom-doctools/20161106/refer/refer3.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer3.c
  vendor/heirloom-doctools/20161106/refer/refer5.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer5.c
  vendor/heirloom-doctools/20161106/refer/refer6.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer6.c
  vendor/heirloom-doctools/20161106/refer/refer7.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer7.c
  vendor/heirloom-doctools/20161106/refer/refer8.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/refer8.c
  vendor/heirloom-doctools/20161106/refer/shell.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/shell.c
  vendor/heirloom-doctools/20161106/refer/sortbib.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/sortbib.c
  vendor/heirloom-doctools/20161106/refer/tick.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/refer/tick.c
  vendor/heirloom-doctools/20161106/soelim/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/soelim/Makefile.mk
  vendor/heirloom-doctools/20161106/soelim/soelim.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/soelim/soelim.c
  vendor/heirloom-doctools/20161106/tbl/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/tbl/Makefile.mk
  vendor/heirloom-doctools/20161106/tbl/t..c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t..c
  vendor/heirloom-doctools/20161106/tbl/t0.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t0.c
  vendor/heirloom-doctools/20161106/tbl/t1.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t1.c
  vendor/heirloom-doctools/20161106/tbl/t3.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t3.c
  vendor/heirloom-doctools/20161106/tbl/t4.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t4.c
  vendor/heirloom-doctools/20161106/tbl/t5.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t5.c
  vendor/heirloom-doctools/20161106/tbl/t8.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/t8.c
  vendor/heirloom-doctools/20161106/tbl/tb.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tb.c
  vendor/heirloom-doctools/20161106/tbl/tc.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tc.c
  vendor/heirloom-doctools/20161106/tbl/te.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/te.c
  vendor/heirloom-doctools/20161106/tbl/tg.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tg.c
  vendor/heirloom-doctools/20161106/tbl/tm.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tm.c
  vendor/heirloom-doctools/20161106/tbl/ts.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/ts.c
  vendor/heirloom-doctools/20161106/tbl/tt.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tt.c
  vendor/heirloom-doctools/20161106/tbl/tu.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tu.c
  vendor/heirloom-doctools/20161106/tbl/tv.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/tbl/tv.c
  vendor/heirloom-doctools/20161106/troff/ext.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/ext.h
  vendor/heirloom-doctools/20161106/troff/libhnj/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/libhnj/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/libhnj/hnjalloc.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/libhnj/hnjalloc.c
  vendor/heirloom-doctools/20161106/troff/libhnj/test.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/libhnj/test.c
  vendor/heirloom-doctools/20161106/troff/n1.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n1.c
  vendor/heirloom-doctools/20161106/troff/n2.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n2.c
  vendor/heirloom-doctools/20161106/troff/n3.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n3.c
  vendor/heirloom-doctools/20161106/troff/n4.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/n4.c
  vendor/heirloom-doctools/20161106/troff/n5.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n5.c
  vendor/heirloom-doctools/20161106/troff/n7.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n7.c
  vendor/heirloom-doctools/20161106/troff/n8.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n8.c
  vendor/heirloom-doctools/20161106/troff/n9.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/n9.c
  vendor/heirloom-doctools/20161106/troff/ni.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/ni.c
  vendor/heirloom-doctools/20161106/troff/nii.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/nii.c
  vendor/heirloom-doctools/20161106/troff/nroff.d/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/nroff.d/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/nroff.d/draw.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/nroff.d/draw.c
  vendor/heirloom-doctools/20161106/troff/nroff.d/n10.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/nroff.d/n10.c
  vendor/heirloom-doctools/20161106/troff/nroff.d/n6.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/nroff.d/n6.c
  vendor/heirloom-doctools/20161106/troff/nroff.d/pt.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/nroff.d/pt.h
  vendor/heirloom-doctools/20161106/troff/tdef.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/tdef.h
  vendor/heirloom-doctools/20161106/troff/troff.d/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/afm.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/afm.c
  vendor/heirloom-doctools/20161106/troff/troff.d/afm.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/afm.h
  vendor/heirloom-doctools/20161106/troff/troff.d/devaps/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/troff/troff.d/devaps/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/dhtml/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/troff/troff.d/dhtml/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/dhtml/dhtml.l
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dhtml/dhtml.l
  vendor/heirloom-doctools/20161106/troff/troff.d/dhtml/lib.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dhtml/lib.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/color.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/color.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/dpost.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/dpost.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/dpost.h
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/draw.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/draw.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/gen.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/gen.h
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/misc.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/misc.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/ps_include.c
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/ps_include.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/request.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/request.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/request.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/dpost.d/request.h
  vendor/heirloom-doctools/20161106/troff/troff.d/draw.c
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/troff/troff.d/draw.c
  vendor/heirloom-doctools/20161106/troff/troff.d/font/Makefile.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/troff/troff.d/font/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/makefont.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/font/devhtml/makefont.c
  vendor/heirloom-doctools/20161106/troff/troff.d/fontmap.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/fontmap.c
  vendor/heirloom-doctools/20161106/troff/troff.d/fontmap.h
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/troff/troff.d/fontmap.h
  vendor/heirloom-doctools/20161106/troff/troff.d/otf.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/otf.c
  vendor/heirloom-doctools/20161106/troff/troff.d/otfdump.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/otfdump.c
  vendor/heirloom-doctools/20161106/troff/troff.d/pt.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/pt.h
  vendor/heirloom-doctools/20161106/troff/troff.d/t10.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/t10.c
  vendor/heirloom-doctools/20161106/troff/troff.d/t6.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/t6.c
  vendor/heirloom-doctools/20161106/troff/troff.d/ta.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/ta.c
  vendor/heirloom-doctools/20161106/troff/troff.d/tmac.d/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/tmac.d/Makefile.mk
  vendor/heirloom-doctools/20161106/troff/troff.d/troff.h
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/troff/troff.d/troff.h
  vendor/heirloom-doctools/20161106/version.mk
     - copied unchanged from r307921, vendor/heirloom-doctools/dist/version.mk
  vendor/heirloom-doctools/20161106/vgrind/Makefile.mk
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/vgrind/Makefile.mk
  vendor/heirloom-doctools/20161106/vgrind/regexp.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/vgrind/regexp.c
  vendor/heirloom-doctools/20161106/vgrind/vfontedpr.c
     - copied unchanged from r307809, vendor/heirloom-doctools/dist/vgrind/vfontedpr.c
  vendor/heirloom-doctools/20161106/vgrind/vgrindefs.c
     - copied unchanged from r310550, vendor/heirloom-doctools/dist/vgrind/vgrindefs.c
Deleted:
  vendor/heirloom-doctools/20161106/eqn/eqn.d/eqnchar.7
  vendor/heirloom-doctools/20161106/grap/grap.1
  vendor/heirloom-doctools/20161106/picpack/getopt.c
  vendor/heirloom-doctools/20161106/ptx/ptx.1
  vendor/heirloom-doctools/20161106/refer/lookbib.1
  vendor/heirloom-doctools/20161106/refer/refer.1
  vendor/heirloom-doctools/20161106/refer/roffbib.1
  vendor/heirloom-doctools/20161106/soelim/soelim.1
  vendor/heirloom-doctools/20161106/troff/nroff.d/nroff.1
  vendor/heirloom-doctools/20161106/troff/troff.d/devaps/getopt.c
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/dpost.1
  vendor/heirloom-doctools/20161106/troff/troff.d/dpost.d/getopt.c
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/B
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/BI
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/C
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CB
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CI
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CR
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/CW
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/H
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/HB
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/HI
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/I
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/R
  vendor/heirloom-doctools/20161106/troff/troff.d/font/devhtml/S
  vendor/heirloom-doctools/20161106/troff/troff.d/tmac.d/mcolor.7
  vendor/heirloom-doctools/20161106/troff/troff.d/troff.1
  vendor/heirloom-doctools/20161106/vgrind/vgrind.1

Copied: vendor/heirloom-doctools/20161106/checknr/Makefile.mk (from r307921, vendor/heirloom-doctools/dist/checknr/Makefile.mk)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/checknr/Makefile.mk	Sun Dec 25 17:54:23 2016	(r310551, copy of r307921, vendor/heirloom-doctools/dist/checknr/Makefile.mk)
@@ -0,0 +1,21 @@
+OBJ = checknr.o
+
+FLAGS = $(DEFINES) -I../include
+
+.c.o:
+	$(CC) $(_CFLAGS) $(FLAGS) -c $<
+
+all: checknr
+
+checknr: $(OBJ)
+	$(CC) $(_CFLAGS) $(_LDFLAGS) $(OBJ) $(LIBS) -o checknr
+
+install:
+	$(INSTALL) -c checknr $(ROOT)$(BINDIR)/checknr
+	$(STRIP) $(ROOT)$(BINDIR)/checknr
+	$(INSTALL) -c -m 644 checknr.1 $(ROOT)$(MANDIR)/man1/checknr.1
+
+clean:
+	rm -f $(OBJ) checknr core log *~
+
+mrproper: clean

Copied: vendor/heirloom-doctools/20161106/checknr/checknr.c (from r310550, vendor/heirloom-doctools/dist/checknr/checknr.c)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/checknr/checknr.c	Sun Dec 25 17:54:23 2016	(r310551, copy of r310550, vendor/heirloom-doctools/dist/checknr/checknr.c)
@@ -0,0 +1,637 @@
+/*	Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T	*/
+/*	  All Rights Reserved  	*/
+
+
+/*
+ * Copyright (c) 1980 Regents of the University of California.
+ * All rights reserved. The Berkeley software License Agreement
+ * specifies the terms and conditions for redistribution.
+ */
+
+/*
+ * Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
+ * Use is subject to license terms.
+ */
+
+/*	from OpenSolaris "checknr.c	1.8	05/06/02 SMI"	*/
+
+/*
+ * Portions Copyright (c) 2005 Gunnar Ritter, Freiburg i. Br., Germany
+ */
+#if __GNUC__ >= 3 && __GNUC_MINOR__ >= 4 || __GNUC__ >= 4
+#define	USED	__attribute__ ((used))
+#elif defined __GNUC__
+#define	USED	__attribute__ ((unused))
+#else
+#define	USED
+#endif
+static const char sccsid[] USED = "@(#)/usr/ucb/checknr.sl	1.3 (gritter) 11/6/05";
+
+/*
+ * checknr: check an nroff/troff input file for matching macro calls.
+ * we also attempt to match size and font changes, but only the embedded
+ * kind.  These must end in \s0 and \fP resp.  Maybe more sophistication
+ * later but for now think of these restrictions as contributions to
+ * structured typesetting.
+ */
+#include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <string.h>
+#include <ctype.h>
+#include "global.h"
+
+static	int	maxstk;	/* Stack size */
+#define	MAXBR	100	/* Max number of bracket pairs known */
+#define	MAXCMDS	500	/* Max number of commands known */
+
+/*
+ * The stack on which we remember what we've seen so far.
+ */
+static struct stkstr {
+	int opno;	/* number of opening bracket */
+	int pl;		/* '+', '-', ' ' for \s, 1 for \f, 0 for .ft */
+	int parm;	/* parm to size, font, etc */
+	int lno;	/* line number the thing came in in */
+} *stk;
+static int stktop;
+
+/*
+ * The kinds of opening and closing brackets.
+ */
+static struct brstr {
+	char *opbr;
+	char *clbr;
+} br[MAXBR] = {
+	/* A few bare bones troff commands */
+#define	SZ	0
+	{ "sz",	"sz" },	/* also \s */
+#define	FT	1
+	{ "ft",	"ft" },	/* also \f */
+	/* the -mm package */
+	{ "AL",	"LE" },
+	{ "AS",	"AE" },
+	{ "BL",	"LE" },
+	{ "BS",	"BE" },
+	{ "DF",	"DE" },
+	{ "DL",	"LE" },
+	{ "DS",	"DE" },
+	{ "FS",	"FE" },
+	{ "ML",	"LE" },
+	{ "NS",	"NE" },
+	{ "RL",	"LE" },
+	{ "VL",	"LE" },
+	/* the -ms package */
+	{ "AB",	"AE" },
+	{ "BD",	"DE" },
+	{ "CD",	"DE" },
+	{ "DS",	"DE" },
+	{ "FS",	"FE" },
+	{ "ID",	"DE" },
+	{ "KF",	"KE" },
+	{ "KS",	"KE" },
+	{ "LD",	"DE" },
+	{ "LG",	"NL" },
+	{ "QS",	"QE" },
+	{ "RS",	"RE" },
+	{ "SM",	"NL" },
+	{ "XA",	"XE" },
+	{ "XS",	"XE" },
+	/* The -me package */
+	{ "(b",	")b" },
+	{ "(c",	")c" },
+	{ "(d",	")d" },
+	{ "(f",	")f" },
+	{ "(l",	")l" },
+	{ "(q",	")q" },
+	{ "(x",	")x" },
+	{ "(z",	")z" },
+	/* Things needed by preprocessors */
+	{ "EQ",	"EN" },
+	{ "TS",	"TE" },
+	/* Refer */
+	{ "[",	"]" },
+	{ NULL,	NULL }
+};
+
+/*
+ * All commands known to nroff, plus macro packages.
+ * Used so we can complain about unrecognized commands.
+ */
+static char *knowncmds[MAXCMDS] = {
+"$c", "$f", "$h", "$p", "$s", "(b", "(c", "(d", "(f", "(l", "(q", "(t",
+"(x", "(z", ")b", ")c", ")d", ")f", ")l", ")q", ")t", ")x", ")z", "++",
+"+c", "1C", "1c", "2C", "2c", "@(", "@)", "@C", "@D", "@F", "@I", "@M",
+"@c", "@e", "@f", "@h", "@m", "@n", "@o", "@p", "@r", "@t", "@z", "AB",
+"AE", "AF", "AI", "AL", "AM", "AS", "AT", "AU", "AX", "B",  "B1", "B2",
+"BD", "BE", "BG", "BL", "BS", "BT", "BX", "C1", "C2", "CD", "CM", "CT",
+"D",  "DA", "DE", "DF", "DL", "DS", "DT", "EC", "EF", "EG", "EH", "EM",
+"EN", "EQ", "EX", "FA", "FD", "FE", "FG", "FJ", "FK", "FL", "FN", "FO",
+"FQ", "FS", "FV", "FX", "H",  "HC", "HD", "HM", "HO", "HU", "I",  "ID",
+"IE", "IH", "IM", "IP", "IX", "IZ", "KD", "KE", "KF", "KQ", "KS", "LB",
+"LC", "LD", "LE", "LG", "LI", "LP", "MC", "ME", "MF", "MH", "ML", "MR",
+"MT", "ND", "NE", "NH", "NL", "NP", "NS", "OF", "OH", "OK", "OP", "P",
+"P1", "PF", "PH", "PP", "PT", "PX", "PY", "QE", "QP", "QS", "R",  "RA",
+"RC", "RE", "RL", "RP", "RQ", "RS", "RT", "S",  "S0", "S2", "S3", "SA",
+"SG", "SH", "SK", "SM", "SP", "SY", "T&", "TA", "TB", "TC", "TD", "TE",
+"TH", "TL", "TM", "TP", "TQ", "TR", "TS", "TX", "UL", "US", "UX", "VL",
+"WC", "WH", "XA", "XD", "XE", "XF", "XK", "XP", "XS", "[",  "[-", "[0",
+"[1", "[2", "[3", "[4", "[5", "[<", "[>", "[]", "]",  "]-", "]<", "]>",
+"][", "ab", "ac", "ad", "af", "am", "ar", "as", "b",  "ba", "bc", "bd",
+"bi", "bl", "bp", "br", "bx", "c.", "c2", "cc", "ce", "cf", "ch",
+"chop", "cs", "ct", "cu", "da", "de", "di", "dl", "dn", "do", "ds",
+"dt", "dw", "dy", "ec", "ef", "eh", "el", "em", "eo", "ep", "ev",
+"evc", "ex", "fallback", "fc", "feature", "fi", "fl", "flig", "fo",
+"fp", "ft", "ftr", "fz", "fzoom", "hc", "he", "hidechar", "hl", "hp",
+"ht", "hw", "hx", "hy", "hylang", "i", "ie", "if", "ig", "in", "ip",
+"it", "ix", "kern", "kernafter", "kernbefore", "kernpair", "lc", "lg",
+"lhang", "lc_ctype", "li", "ll", "ln", "lo", "lp", "ls", "lt", "m1",
+"m2", "m3", "m4", "mc", "mk", "mo", "n1", "n2", "na", "ne", "nf", "nh",
+"nl", "nm", "nn", "np", "nr", "ns", "nx", "of", "oh", "os", "pa",
+"papersize", "pc", "pi", "pl", "pm", "pn", "po", "pp", "ps", "q",
+"r",  "rb", "rd", "re", "recursionlimit", "return", "rhang", "rm",
+"rn", "ro", "rr", "rs", "rt", "sb", "sc", "sh", "shift", "sk", "so",
+"sp", "ss", "st", "sv", "sz", "ta", "tc", "th", "ti", "tl", "tm", "tp",
+"tr", "track", "u",  "uf", "uh", "ul", "vs", "wh", "xflag", "xp", "yr",
+0
+};
+
+static	int	lineno;		/* current line number in input file */
+static	char	*line;		/* the current line */
+static	size_t	linesize;	/* allocated size of current line */
+static	char	*cfilename;	/* name of current file */
+static	int	nfiles;		/* number of files to process */
+static	int	fflag;		/* -f: ignore \f */
+static	int	sflag;		/* -s: ignore \s */
+static	int	ncmds;		/* size of knowncmds */
+static	int	slot;		/* slot in knowncmds found by binsrch */
+
+static void growstk(void);
+static void usage(void);
+static void process(FILE *f);
+static void complain(int i);
+static void prop(int i);
+static void chkcmd(char *line, char *mac);
+static void nomatch(char *mac);
+static int eq(char *s1, char *s2);
+static void pe(int lineno);
+static void checkknown(char *mac);
+static void addcmd(char *line);
+static void addmac(char *mac);
+static int binsrch(char *mac);
+
+static void
+growstk(void)
+{
+	stktop++;
+	if (stktop >= maxstk) {
+		maxstk *= 2;
+		stk = realloc(stk, sizeof *stk * maxstk);
+	}
+}
+
+int
+main(int argc, char **argv)
+{
+	FILE *f;
+	int i;
+	char *cp, *cq, c;
+
+	stk = calloc(sizeof *stk, maxstk = 100);
+	/* Figure out how many known commands there are */
+	while (knowncmds[ncmds])
+		ncmds++;
+	while (argc > 1 && argv[1][0] == '-') {
+		switch (argv[1][1]) {
+
+		/* -a: add pairs of macros */
+		case 'a':
+			/* look for empty macro slots */
+			for (i = 0; br[i].opbr; i++)
+				;
+			cp = &argv[1][3];
+			while (*cp) {
+				size_t s;
+				if (i >= MAXBR - 3) {
+					printf("Only %d known pairs allowed\n",
+							MAXBR/2);
+					exit(1);
+				}
+				for (cq = cp; *cq && *cq != '.'; cq++);
+				if (*cq != '.')
+					usage();
+				*cq = 0;
+				s = cq - cp + 1;
+				br[i].opbr = malloc(s);
+				n_strcpy(br[i].opbr, cp, s);
+				*cq = '.';
+				cp = &cq[1];
+				for (cq = cp; *cq && *cq != '.'; cq++);
+				c = *cq;
+				*cq = 0;
+				s = cq - cp + 1;
+				br[i].clbr = malloc(s);
+				n_strcpy(br[i].clbr, cp, s);
+				*cq = c;
+				cp = c ? &cq[1] : cq;
+				/* knows pairs are also known cmds */
+				addmac(br[i].opbr);
+				addmac(br[i].clbr);
+				i++;
+			}
+			break;
+
+		/* -c: add known commands */
+		case 'c':
+			cp = &argv[1][3];
+			while (*cp) {
+				for (cq = cp; *cq && *cq != '.'; cq++);
+				c = *cq;
+				*cq = 0;
+				addmac(cp);
+				*cq = c;
+				cp = c ? &cq[1] : cq;
+			}
+			break;
+
+		/* -f: ignore font changes */
+		case 'f':
+			fflag = 1;
+			break;
+
+		/* -s: ignore size changes */
+		case 's':
+			sflag = 1;
+			break;
+		default:
+			usage();
+		}
+		argc--; argv++;
+	}
+
+	nfiles = argc - 1;
+
+	if (nfiles > 0) {
+		for (i = 1; i < argc; i++) {
+			cfilename = argv[i];
+			f = fopen(cfilename, "r");
+			if (f == NULL) {
+				perror(cfilename);
+				exit(1);
+				}
+			else {
+				process(f);
+				fclose(f);
+			}
+		}
+	} else {
+		cfilename = "stdin";
+		process(stdin);
+	}
+	return (0);
+}
+
+static void
+usage(void)
+{
+	printf("Usage: checknr -s -f -a.xx.yy.xx.yy... -c.xx.xx.xx...\n");
+	exit(1);
+}
+
+static void
+process(FILE *f)
+{
+	int i, n;
+	char mac[512];	/* The current macro or nroff command */
+	int pl;
+
+	stktop = -1;
+	for (lineno = 1; getline(&line, &linesize, f) > 0; lineno++) {
+		if (line[0] == '.') {
+			/*
+			 * find and isolate the macro/command name.
+			 */
+			strncpy(mac, line+1, sizeof mac-1)[sizeof mac-1] = 0;
+			if (isspace(mac[0]&0377)) {
+				pe(lineno);
+				printf("Empty command\n");
+			} else {
+				for (i = 1; mac[i]; i++)
+					if (isspace(mac[i]&0377)) {
+						mac[i] = 0;
+						break;
+					}
+			}
+
+			/*
+			 * Is it a known command?
+			 */
+			checkknown(mac);
+
+			/*
+			 * Should we add it?
+			 */
+			if (eq(mac, "de"))
+				addcmd(line);
+
+			chkcmd(line, mac);
+		}
+
+		/*
+		 * At this point we process the line looking
+		 * for \s and \f.
+		 */
+		for (i = 0; line[i]; i++)
+			if (line[i] == '\\' && (i == 0 || line[i-1] != '\\')) {
+				if (!sflag && line[++i] == 's') {
+					pl = line[++i]&0377;
+					if (isdigit(pl)) {
+						n = pl - '0';
+						pl = ' ';
+					} else
+						n = 0;
+					while (isdigit(line[++i]&0377))
+						n = 10 * n + line[i] - '0';
+					i--;
+					if (n == 0) {
+						if (stk[stktop].opno == SZ) {
+							stktop--;
+						} else {
+							pe(lineno);
+							printf(
+						"unmatched \\s0\n");
+						}
+					} else {
+						growstk();
+						stk[stktop].opno = SZ;
+						stk[stktop].pl = pl;
+						stk[stktop].parm = n;
+						stk[stktop].lno = lineno;
+					}
+				} else if (!fflag && line[i] == 'f') {
+					n = line[++i];
+					if (n == 'P') {
+						if (stk[stktop].opno == FT) {
+							stktop--;
+						} else {
+							pe(lineno);
+							printf(
+						"unmatched \\fP\n");
+						}
+					} else {
+						growstk();
+						stk[stktop].opno = FT;
+						stk[stktop].pl = 1;
+						stk[stktop].parm = n;
+						stk[stktop].lno = lineno;
+					}
+				}
+			}
+	}
+	/*
+	 * We've hit the end and look at all this stuff that hasn't been
+	 * matched yet!  Complain, complain.
+	 */
+	for (i = stktop; i >= 0; i--) {
+		complain(i);
+	}
+}
+
+static void
+complain(int i)
+{
+	pe(stk[i].lno);
+	printf("Unmatched ");
+	prop(i);
+	printf("\n");
+}
+
+static void
+prop(int i)
+{
+	if (stk[i].pl == 0)
+		printf(".%s", br[stk[i].opno].opbr);
+	else switch (stk[i].opno) {
+	case SZ:
+		printf("\\s%c%d", stk[i].pl, stk[i].parm);
+		break;
+	case FT:
+		printf("\\f%c", stk[i].parm);
+		break;
+	default:
+		printf("Bug: stk[%d].opno = %d = .%s, .%s",
+			i, stk[i].opno, br[stk[i].opno].opbr,
+			br[stk[i].opno].clbr);
+	}
+}
+
+/* ARGSUSED */
+static void
+chkcmd(char *line __unused, char *mac)
+{
+	int i;
+
+	/*
+	 * Check to see if it matches top of stack.
+	 */
+	if (stktop >= 0 && eq(mac, br[stk[stktop].opno].clbr))
+		stktop--;	/* OK. Pop & forget */
+	else {
+		/* No. Maybe it's an opener */
+		for (i = 0; br[i].opbr; i++) {
+			if (eq(mac, br[i].opbr)) {
+				/* Found. Push it. */
+				growstk();
+				stk[stktop].opno = i;
+				stk[stktop].pl = 0;
+				stk[stktop].parm = 0;
+				stk[stktop].lno = lineno;
+				break;
+			}
+			/*
+			 * Maybe it's an unmatched closer.
+			 * NOTE: this depends on the fact
+			 * that none of the closers can be
+			 * openers too.
+			 */
+			if (eq(mac, br[i].clbr)) {
+				nomatch(mac);
+				break;
+			}
+		}
+	}
+}
+
+static void
+nomatch(char *mac)
+{
+	int i, j;
+
+	/*
+	 * Look for a match further down on stack
+	 * If we find one, it suggests that the stuff in
+	 * between is supposed to match itself.
+	 */
+	for (j = stktop; j >= 0; j--)
+		if (eq(mac, br[stk[j].opno].clbr)) {
+			/* Found.  Make a good diagnostic. */
+			if (j == stktop-2) {
+				/*
+				 * Check for special case \fx..\fR and don't
+				 * complain.
+				 */
+				if (stk[j+1].opno == FT &&
+				    stk[j+1].parm != 'R' &&
+				    stk[j+2].opno == FT &&
+				    stk[j+2].parm == 'R') {
+					stktop = j -1;
+					return;
+				}
+				/*
+				 * We have two unmatched frobs.  Chances are
+				 * they were intended to match, so we mention
+				 * them together.
+				 */
+				pe(stk[j+1].lno);
+				prop(j+1);
+				printf(" does not match %d: ", stk[j+2].lno);
+				prop(j+2);
+				printf("\n");
+			} else for (i = j+1; i <= stktop; i++) {
+				complain(i);
+			}
+			stktop = j-1;
+			return;
+		}
+	/* Didn't find one.  Throw this away. */
+	pe(lineno);
+	printf("Unmatched .%s\n", mac);
+}
+
+/* eq: are two strings equal? */
+static int
+eq(char *s1, char *s2)
+{
+	return (strcmp(s1, s2) == 0);
+}
+
+/* print the first part of an error message, given the line number */
+static void
+pe(int lineno)
+{
+	if (nfiles > 1)
+		printf("%s: ", cfilename);
+	printf("%d: ", lineno);
+}
+
+static void
+checkknown(char *mac)
+{
+
+	if (eq(mac, "."))
+		return;
+	if (binsrch(mac) >= 0)
+		return;
+	if (mac[0] == '\\' && mac[1] == '"')	/* comments */
+		return;
+
+	pe(lineno);
+	printf("Unknown command: .%s\n", mac);
+}
+
+/*
+ * We have a .de xx line in "line".  Add xx to the list of known commands.
+ */
+static void
+addcmd(char *line)
+{
+	char *mac;
+
+	/* grab the macro being defined */
+	mac = line+4;
+	while (isspace(*mac&0377))
+		mac++;
+	if (*mac == 0) {
+		pe(lineno);
+		printf("illegal define: %s\n", line);
+		return;
+	}
+	mac[2] = 0;
+	if (isspace(mac[1]&0377) || mac[1] == '\\')
+		mac[1] = 0;
+	addmac(mac);
+}
+
+/*
+ * Add mac to the list.  We should really have some kind of tree
+ * structure here but this is a quick-and-dirty job and I just don't
+ * have time to mess with it.  (I wonder if this will come back to haunt
+ * me someday?)  Anyway, I claim that .de is fairly rare in user
+ * nroff programs, and the loop below is pretty fast.
+ */
+static void
+addmac(char *mac)
+{
+	char **src, **dest, **loc;
+	size_t s;
+
+	if (binsrch(mac) >= 0) {	/* it's OK to redefine something */
+#ifdef DEBUG
+		printf("binsrch(%s) -> already in table\n", mac);
+#endif
+		return;
+	}
+	/* binsrch sets slot as a side effect */
+#ifdef DEBUG
+printf("binsrch(%s) -> %d\n", mac, slot);
+#endif
+	if (ncmds >= MAXCMDS) {
+		printf("Only %d known commands allowed\n", MAXCMDS);
+		exit(1);
+	}
+	loc = &knowncmds[slot];
+	src = &knowncmds[ncmds-1];
+	dest = src+1;
+	while (dest > loc)
+		*dest-- = *src--;
+	s = strlen(mac) + 1;
+	*loc = malloc(s);
+	n_strcpy(*loc, mac, s);
+	ncmds++;
+#ifdef DEBUG
+	printf("after: %s %s %s %s %s, %d cmds\n",
+	    knowncmds[slot-2], knowncmds[slot-1], knowncmds[slot],
+	    knowncmds[slot+1], knowncmds[slot+2], ncmds);
+#endif
+}
+
+/*
+ * Do a binary search in knowncmds for mac.
+ * If found, return the index.  If not, return -1.
+ */
+static int
+binsrch(char *mac)
+{
+	char *p;	/* pointer to current cmd in list */
+	int d;		/* difference if any */
+	int mid;	/* mid point in binary search */
+	int top, bot;	/* boundaries of bin search, inclusive */
+
+	top = ncmds-1;
+	bot = 0;
+	while (top >= bot) {
+		mid = (top+bot)/2;
+		p = knowncmds[mid];
+		d = p[0] - mac[0];
+		if (d == 0)
+			d = strcmp(&p[1], &mac[1]);
+		if (d == 0)
+			return (mid);
+		if (d < 0)
+			bot = mid + 1;
+		else
+			top = mid - 1;
+	}
+	slot = bot;	/* place it would have gone */
+	return (-1);
+}

Copied: vendor/heirloom-doctools/20161106/col/Makefile.mk (from r307921, vendor/heirloom-doctools/dist/col/Makefile.mk)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/col/Makefile.mk	Sun Dec 25 17:54:23 2016	(r310551, copy of r307921, vendor/heirloom-doctools/dist/col/Makefile.mk)
@@ -0,0 +1,22 @@
+BIN = col
+
+OBJ = col.o
+
+FLAGS = $(DEFINES) -I../include
+
+all: $(BIN)
+
+$(BIN): $(OBJ)
+	$(CC) ${_CFLAGS} $(_LDFLAGS) $(OBJ) -o $(BIN)
+
+install:
+	$(INSTALL) -c $(BIN) $(ROOT)$(BINDIR)/$(BIN)
+	$(STRIP) $(ROOT)$(BINDIR)/$(BIN)
+
+clean:
+	rm -f $(OBJ) $(BIN) core log *~
+
+mrproper: clean
+
+.c.o:
+	${CC} ${_CFLAGS} $(FLAGS) -c $<

Copied: vendor/heirloom-doctools/20161106/compat.c (from r307809, vendor/heirloom-doctools/dist/compat.c)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/compat.c	Sun Dec 25 17:54:23 2016	(r310551, copy of r307809, vendor/heirloom-doctools/dist/compat.c)
@@ -0,0 +1,47 @@
+/* Carsten Kunze, 2016 */
+
+#include <string.h>
+
+#ifndef HAVE_STRLCPY
+size_t
+strlcpy(char *dst, const char *src, size_t dstsize) {
+	size_t srcsize;
+	/* Not conform to strlcpy, but avoids to access illegal memory in case
+	 * of unterminated strings */
+	for (srcsize = 0; srcsize < dstsize; srcsize++)
+		if (!src[srcsize])
+			break;
+	if (dstsize > srcsize)
+		dstsize = srcsize;
+	else if (dstsize)
+		dstsize--;
+	if (dstsize)
+		/* assumes non-overlapping buffers */
+		memcpy(dst, src, dstsize);
+	dst[dstsize] = 0;
+	return srcsize;
+}
+#endif
+
+#ifndef HAVE_STRLCAT
+size_t
+strlcat(char *dst, const char *src, size_t dstsize) {
+	size_t ld, ls;
+	for (ld = 0; ld < dstsize - 1; ld++)
+		if (!dst[ld])
+			break;
+	dst += ld;
+	dstsize -= ld;
+	for (ls = 0; ls < dstsize; ls++)
+		if (!src[ls])
+			break;
+	if (dstsize > ls)
+		dstsize = ls;
+	else if (dstsize)
+		dstsize--;
+	if (dstsize)
+		memcpy(dst, src, dstsize);
+	dst[dstsize] = 0;
+	return ld + ls;
+}
+#endif

Copied: vendor/heirloom-doctools/20161106/configure (from r307921, vendor/heirloom-doctools/dist/configure)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/configure	Sun Dec 25 17:54:23 2016	(r310551, copy of r307921, vendor/heirloom-doctools/dist/configure)
@@ -0,0 +1,236 @@
+#!/bin/sh
+
+# Copyright (c) 2016, Carsten Kunze <carsten.kunze@arcor.de>
+#
+# Permission to use, copy, modify, and/or distribute this software for any
+# purpose with or without fee is hereby granted, provided that the above
+# copyright notice and this permission notice appear in all copies.
+#
+# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
+# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+# AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
+# INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+# LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
+# OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+# PERFORMANCE OF THIS SOFTWARE.
+
+usage () {
+	echo "Usage: $0 [-s]"
+	echo "	-s	Silence output"
+	exit $1
+}
+
+SFLAG=
+MAKE=
+DEFS=
+LIB_LEX=
+LIB_CURSES=
+cat /dev/null > compat.h
+
+while [ $# -gt 0 ]; do
+	case $1 in
+	-s) SFLAG=1;;
+	*)
+		echo "$0: $1: Unknown option" >&2
+		usage 1;;
+	esac
+	shift
+done
+
+check_for () {
+	[ -e $LOG ] && echo >>$LOG
+	A="Checking for $1 ... "
+	echo "$A" >>$LOG
+	[ -z "$SFLAG" ] && printf "$A"
+}
+
+compile () {
+	rm -f ${TMPNAM}.o $TMPNAM $OUT $ERR
+	$MAKE -f $OUTMK $TMPNAM > $OUT 2> $ERR
+	RESULT=$?
+	cat $OUT $ERR >> $LOG
+	if [ $RESULT -eq 0 ]; then true; else false; fi
+}
+
+test_result () {
+	RESULT=$?
+	RESULT_TEXT=${1:-0} # 1: omit "no", 2: say nothing
+	if [ $RESULT -eq 0 ]; then
+		echo success >>$LOG
+		[ -z "$SFLAG" -a $RESULT_TEXT -lt 2 ] && \
+		    echo "yes$PASS_TEXT"
+		PASS_TEXT=
+		[ -e $TMPC ] && rm -f $TMPC
+		true
+	else
+		[ -z "$SFLAG" -a $RESULT_TEXT -lt 1 ] && echo no
+		if [ -e $TMPC ]; then
+			echo "Failed program:" >>$LOG
+			pr -n -t $TMPC >>$LOG
+			rm -f $TMPC
+		fi
+		false
+	fi
+}
+
+gen_mk () {
+	[ $# -eq 0 ] && rm -f $OUTMK
+	[ -n "$LEX" ] && echo "LEX=$LEX" >> $OUTMK
+	[ -n "$FLOAT_STORE" ] && echo "FLOAT_STORE=$FLOAT_STORE" >> $OUTMK
+	[ -n "$DEFS" ] && echo "DEFINES=$DEFS" >> $OUTMK
+	[ -n "$INCDIR_CURSES" ] && echo "INCDIR_CURSES=$INCDIR_CURSES" >> $OUTMK
+	[ -n "$RPATH_CURSES" ] && echo "RPATH_CURSES=$RPATH_CURSES" >> $OUTMK
+	[ -n "$LIBDIR_CURSES" ] && echo "LIBDIR_CURSES=$LIBDIR_CURSES" \
+	    >> $OUTMK
+	[ -n "$LIB_CURSES" ] && echo "LIB_CURSES=$LIB_CURSES" >> $OUTMK
+	[ -n "$LIB_AVLBST" ] && echo "LIB_AVLBST=$LIB_AVLBST" >> $OUTMK
+	[ -n "$LIB_LEX" ] && echo "LIB_LEX=$LIB_LEX" >> $OUTMK
+	[ -n "$__CDBG" ] && echo "__CDBG=$__CDBG" >> $OUTMK
+	[ -n "$__CLDBG" ] && echo "__CLDBG=$__CLDBG" >> $OUTMK
+	cat $INMK >> $OUTMK || exit 1
+}
+check_make () {
+	check_for "make(1)"
+
+	cat <<EOT >$TMPMK
+all:
+	true
+EOT
+	make -f $TMPMK >> $LOG 2>&1
+	test_result && {
+		MAKE=make
+		return
+	}
+
+	echo "Failed makefile:" >>$LOG
+	pr -n -t $TMPMK >>$LOG
+
+	check_for "bmake(1)"
+
+	cat <<EOT >$TMPMK
+all:
+	true
+EOT
+	bmake -f $TMPMK >> $LOG 2>&1
+	test_result && MAKE=bmake
+}
+check_lex () {
+	check_for '$(LEX)'
+
+	cat <<EOT >$TMPL
+%%
+%%
+int main() { return 0; }
+int yywrap(void) { return 0; }
+EOT
+	compile
+	test_result && return
+
+	check_for 'flex(1)'
+
+	LEX=flex
+	gen_mk
+	compile
+	test_result && return
+
+	check_for 'lex(1)'
+
+	LEX=lex
+	gen_mk
+	compile
+	test_result && return
+}
+check_strlcpy () {
+	check_for "strlcpy(3)"
+
+	cat <<EOT >$TMPC
+#include <string.h>
+int
+main(int argc, char **argv) {
+	char a[10];
+	(void)argc;
+	strlcpy(a, *argv, sizeof a);
+	return 0;
+}
+EOT
+	compile
+	if test_result; then
+		DEFS="$DEFS -DHAVE_STRLCPY"
+	else
+		H=compat.h
+		grep -q '<sys/types\.h>' $H 2>/dev/null || cat <<EOT >>$H
+#include <sys/types.h>
+EOT
+		cat <<EOT >>$H
+size_t strlcpy(char *, const char *, size_t);
+EOT
+	fi
+}
+check_strlcat () {
+	check_for "strlcat(3)"
+
+	cat <<EOT >$TMPC
+#include <string.h>
+int
+main(int argc, char **argv) {
+	char a[10];
+	(void)argc;
+	*a = 0;
+	strlcat(a, *argv, sizeof a);
+	return 0;
+}
+EOT
+	compile
+	if test_result; then
+		DEFS="$DEFS -DHAVE_STRLCAT"
+	else
+		H=compat.h
+		grep -q '<sys/types\.h>' $H 2>/dev/null || cat <<EOT >>$H
+#include <sys/types.h>
+EOT
+		cat <<EOT >>$H
+size_t strlcat(char *, const char *, size_t);
+EOT
+	fi
+}
+check_wcslcpy () {
+	check_for "wcslcpy(3)"
+
+	cat <<EOT >$TMPC
+#include <stdio.h>
+#include <wchar.h>
+int
+main() {
+	wchar_t a, b;
+	a = getwchar();
+	wcslcpy(&b, &a, 1);
+	return 0;
+}
+EOT
+	compile
+	test_result && DEFS="$DEFS -DHAVE_WCSLCPY"
+}
+	[ ! -s compat.h ] && rm compat.h
+OUTMK=cfg.mk
+INMK=mk.config
+CFG=config
+TMPNAM=.$CFG
+TMPMK=${TMPNAM}.mk
+TMPC=${TMPNAM}.c
+TMPL=${TMPNAM}.l
+OUT=${TMPNAM}.out
+ERR=${TMPNAM}.err
+LOG=${CFG}.log
+rm -f $LOG
+gen_mk
+
+check_make
+#check_Sanitizer
+check_lex
+check_strlcpy
+check_strlcat
+check_wcslcpy
+
+gen_mk
+cat version.mk >> $OUTMK || exit 1
+rm -f $TMPNAM*

Copied: vendor/heirloom-doctools/20161106/eqn/checkeq.d/Makefile.mk (from r307921, vendor/heirloom-doctools/dist/eqn/checkeq.d/Makefile.mk)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/heirloom-doctools/20161106/eqn/checkeq.d/Makefile.mk	Sun Dec 25 17:54:23 2016	(r310551, copy of r307921, vendor/heirloom-doctools/dist/eqn/checkeq.d/Makefile.mk)
@@ -0,0 +1,23 @@
+VPATH=..
+OBJ = checkeq.o
+
+FLAGS =
+
+.c.o:
+	$(CC) $(_CFLAGS) $(FLAGS) -c $<
+
+all: checkeq
+
+checkeq: $(OBJ)
+	$(CC) $(_CFLAGS) $(_LDFLAGS) $(OBJ) $(LIBS) -o checkeq
+
+install:
+	$(INSTALL) -c checkeq $(ROOT)$(BINDIR)/checkeq
+	$(STRIP) $(ROOT)$(BINDIR)/checkeq
+	rm -f $(ROOT)$(MANDIR)/man1/checkeq.1
+	ln -s eqn.1 $(ROOT)$(MANDIR)/man1/checkeq.1
+

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Sun Dec 25 19:38:08 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7443CC90198;
 Sun, 25 Dec 2016 19:38:08 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 38EF114E8;
 Sun, 25 Dec 2016 19:38:08 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPJc714077452;
 Sun, 25 Dec 2016 19:38:07 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPJc7rb077451;
 Sun, 25 Dec 2016 19:38:07 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612251938.uBPJc7rb077451@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Sun, 25 Dec 2016 19:38:07 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310552 - head/sys/kern
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 19:38:08 -0000

Author: kib
Date: Sun Dec 25 19:38:07 2016
New Revision: 310552
URL: https://svnweb.freebsd.org/changeset/base/310552

Log:
  Some style.
  
  Reviewed by:	markj
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week
  X-Differential revision:	https://reviews.freebsd.org/D8901

Modified:
  head/sys/kern/kern_event.c

Modified: head/sys/kern/kern_event.c
==============================================================================
--- head/sys/kern/kern_event.c	Sun Dec 25 17:54:23 2016	(r310551)
+++ head/sys/kern/kern_event.c	Sun Dec 25 19:38:07 2016	(r310552)
@@ -591,7 +591,7 @@ timer2sbintime(intptr_t data, int flags)
 	case NOTE_SECONDS:
 #ifdef __LP64__
 		if (data > (SBT_MAX / SBT_1S))
-			return SBT_MAX;
+			return (SBT_MAX);
 #endif
 		return ((sbintime_t)data << 32);
 	case NOTE_MSECONDS: /* FALLTHROUGH */
@@ -600,7 +600,7 @@ timer2sbintime(intptr_t data, int flags)
 			int64_t secs = data / 1000;
 #ifdef __LP64__
 			if (secs > (SBT_MAX / SBT_1S))
-				return SBT_MAX;
+				return (SBT_MAX);
 #endif
 			return (secs << 32 | MS_TO_SBT(data % 1000));
 		}
@@ -610,7 +610,7 @@ timer2sbintime(intptr_t data, int flags)
 			int64_t secs = data / 1000000;
 #ifdef __LP64__
 			if (secs > (SBT_MAX / SBT_1S))
-				return SBT_MAX;
+				return (SBT_MAX);
 #endif
 			return (secs << 32 | US_TO_SBT(data % 1000000));
 		}
@@ -620,11 +620,11 @@ timer2sbintime(intptr_t data, int flags)
 			int64_t secs = data / 1000000000;
 #ifdef __LP64__
 			if (secs > (SBT_MAX / SBT_1S))
-				return SBT_MAX;
+				return (SBT_MAX);
 #endif
 			return (secs << 32 | US_TO_SBT(data % 1000000000));
 		}
-		return NS_TO_SBT(data);
+		return (NS_TO_SBT(data));
 	default:
 		break;
 	}

From owner-svn-src-all@freebsd.org  Sun Dec 25 19:49:10 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 59539C904B8;
 Sun, 25 Dec 2016 19:49:10 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 286A119D5;
 Sun, 25 Dec 2016 19:49:10 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPJn9oK081354;
 Sun, 25 Dec 2016 19:49:09 GMT (envelope-from hselasky@FreeBSD.org)
Received: (from hselasky@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPJn9TS081353;
 Sun, 25 Dec 2016 19:49:09 GMT (envelope-from hselasky@FreeBSD.org)
Message-Id: <201612251949.uBPJn9TS081353@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: hselasky set sender to
 hselasky@FreeBSD.org using -f
From: Hans Petter Selasky <hselasky@FreeBSD.org>
Date: Sun, 25 Dec 2016 19:49:09 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310553 - head/sys/compat/linuxkpi/common/include/linux
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 19:49:10 -0000

Author: hselasky
Date: Sun Dec 25 19:49:09 2016
New Revision: 310553
URL: https://svnweb.freebsd.org/changeset/base/310553

Log:
  Improve LinuxKPI device support. Only delete own BSD devices and not
  the ones obtained through devclass_get_device(). Some minor code
  cleanups while at it.
  
  Obtained from:	kmacy @
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/device.h

Modified: head/sys/compat/linuxkpi/common/include/linux/device.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/device.h	Sun Dec 25 19:38:07 2016	(r310552)
+++ head/sys/compat/linuxkpi/common/include/linux/device.h	Sun Dec 25 19:49:09 2016	(r310553)
@@ -63,6 +63,14 @@ struct device {
 	struct device	*parent;
 	struct list_head irqents;
 	device_t	bsddev;
+	/*
+	 * The following flag is used to determine if the LinuxKPI is
+	 * responsible for detaching the BSD device or not. If the
+	 * LinuxKPI got the BSD device using devclass_get_device(), it
+	 * must not try to detach or delete it, because it's already
+	 * done somewhere else.
+	 */
+	bool		bsddev_attached_here;
 	dev_t		devt;
 	struct class	*class;
 	void		(*release)(struct device *dev);
@@ -208,23 +216,36 @@ static inline struct device *kobj_to_dev
 static inline void
 device_initialize(struct device *dev)
 {
-	device_t bsddev;
+	device_t bsddev = NULL;
+	int unit = -1;
 
-	bsddev = NULL;
 	if (dev->devt) {
-		int unit = MINOR(dev->devt);
+		unit = MINOR(dev->devt);
 		bsddev = devclass_get_device(dev->class->bsdclass, unit);
+		dev->bsddev_attached_here = false;
+	} else if (dev->parent == NULL) {
+		bsddev = devclass_get_device(dev->class->bsdclass, 0);
+		dev->bsddev_attached_here = false;
+	} else {
+		dev->bsddev_attached_here = true;
+	}
+
+	if (bsddev == NULL && dev->parent != NULL) {
+		bsddev = device_add_child(dev->parent->bsddev,
+		    dev->class->kobj.name, unit);
 	}
+
 	if (bsddev != NULL)
 		device_set_softc(bsddev, dev);
 
 	dev->bsddev = bsddev;
+	MPASS(dev->bsddev != NULL);
 	kobject_init(&dev->kobj, &linux_dev_ktype);
 }
 
 static inline int
 device_add(struct device *dev)
-{	
+{
 	if (dev->bsddev != NULL) {
 		if (dev->devt == 0)
 			dev->devt = makedev(0, device_get_unit(dev->bsddev));
@@ -256,13 +277,13 @@ device_create_groups_vargs(struct class 
 		goto error;
 	}
 
-	device_initialize(dev);
 	dev->devt = devt;
 	dev->class = class;
 	dev->parent = parent;
 	dev->groups = groups;
 	dev->release = device_create_release;
-	dev->bsddev = devclass_get_device(dev->class->bsdclass, MINOR(devt));
+	/* device_initialize() needs the class and parent to be set */
+	device_initialize(dev);
 	dev_set_drvdata(dev, drvdata);
 
 	retval = kobject_set_name_vargs(&dev->kobj, fmt, args);
@@ -298,17 +319,21 @@ device_create_with_groups(struct class *
 static inline int
 device_register(struct device *dev)
 {
-	device_t bsddev;
-	int unit;
+	device_t bsddev = NULL;
+	int unit = -1;
 
-	bsddev = NULL;
-	unit = -1;
+	if (dev->bsddev != NULL)
+		goto done;
 
 	if (dev->devt) {
 		unit = MINOR(dev->devt);
 		bsddev = devclass_get_device(dev->class->bsdclass, unit);
+		dev->bsddev_attached_here = false;
 	} else if (dev->parent == NULL) {
 		bsddev = devclass_get_device(dev->class->bsdclass, 0);
+		dev->bsddev_attached_here = false;
+	} else {
+		dev->bsddev_attached_here = true;
 	}
 	if (bsddev == NULL && dev->parent != NULL) {
 		bsddev = device_add_child(dev->parent->bsddev,
@@ -320,6 +345,7 @@ device_register(struct device *dev)
 		device_set_softc(bsddev, dev);
 	}
 	dev->bsddev = bsddev;
+done:
 	kobject_init(&dev->kobj, &linux_dev_ktype);
 	kobject_add(&dev->kobj, &dev->class->kobj, dev_name(dev));
 
@@ -334,7 +360,7 @@ device_unregister(struct device *dev)
 	bsddev = dev->bsddev;
 	dev->bsddev = NULL;
 
-	if (bsddev != NULL) {
+	if (bsddev != NULL && dev->bsddev_attached_here) {
 		mtx_lock(&Giant);
 		device_delete_child(device_get_parent(bsddev), bsddev);
 		mtx_unlock(&Giant);
@@ -350,7 +376,7 @@ device_del(struct device *dev)
 	bsddev = dev->bsddev;
 	dev->bsddev = NULL;
 
-	if (bsddev != NULL) {
+	if (bsddev != NULL && dev->bsddev_attached_here) {
 		mtx_lock(&Giant);
 		device_delete_child(device_get_parent(bsddev), bsddev);
 		mtx_unlock(&Giant);

From owner-svn-src-all@freebsd.org  Sun Dec 25 19:49:36 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 72059C9053B;
 Sun, 25 Dec 2016 19:49:36 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 4C8AA1B7A;
 Sun, 25 Dec 2016 19:49:36 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPJnZeO081413;
 Sun, 25 Dec 2016 19:49:35 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPJnZnv081411;
 Sun, 25 Dec 2016 19:49:35 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612251949.uBPJnZnv081411@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Sun, 25 Dec 2016 19:49:35 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310554 - in head/sys: kern sys
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 19:49:36 -0000

Author: kib
Date: Sun Dec 25 19:49:35 2016
New Revision: 310554
URL: https://svnweb.freebsd.org/changeset/base/310554

Log:
  Some optimizations for kqueue timers.
  
  There is no need to do two allocations per kqueue timer. Gather all
  data needed by the timer callout into the structure and allocate it at
  once.
  
  Use the structure to preserve the result of timer2sbintime(), to not
  perform repeated 64bit calculations in callout.
  
  Remove tautological casts.
  Remove now unused p_nexttime [1].
  
  Noted by:	markj [1]
  Reviewed by:	markj (previous version)
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week
  X-MFC note:	do not remove p_nexttime
  Differential revision:	https://reviews.freebsd.org/D8901

Modified:
  head/sys/kern/kern_event.c
  head/sys/sys/event.h

Modified: head/sys/kern/kern_event.c
==============================================================================
--- head/sys/kern/kern_event.c	Sun Dec 25 19:49:09 2016	(r310553)
+++ head/sys/kern/kern_event.c	Sun Dec 25 19:49:35 2016	(r310554)
@@ -631,23 +631,29 @@ timer2sbintime(intptr_t data, int flags)
 	return (-1);
 }
 
+struct kq_timer_cb_data {
+	struct callout c;
+	sbintime_t next;	/* next timer event fires at */
+	sbintime_t to;		/* precalculated timer period */
+};
+
 static void
 filt_timerexpire(void *knx)
 {
-	struct callout *calloutp;
 	struct knote *kn;
+	struct kq_timer_cb_data *kc;
 
 	kn = knx;
 	kn->kn_data++;
 	KNOTE_ACTIVATE(kn, 0);	/* XXX - handle locking */
 
-	if ((kn->kn_flags & EV_ONESHOT) != EV_ONESHOT) {
-		calloutp = (struct callout *)kn->kn_hook;
-		*kn->kn_ptr.p_nexttime += timer2sbintime(kn->kn_sdata, 
-		    kn->kn_sfflags);
-		callout_reset_sbt_on(calloutp, *kn->kn_ptr.p_nexttime, 0,
-		    filt_timerexpire, kn, PCPU_GET(cpuid), C_ABSOLUTE);
-	}
+	if ((kn->kn_flags & EV_ONESHOT) != 0)
+		return;
+
+	kc = kn->kn_ptr.p_v;
+	kc->next += kc->to;
+	callout_reset_sbt_on(&kc->c, kc->next, 0, filt_timerexpire, kn,
+	    PCPU_GET(cpuid), C_ABSOLUTE);
 }
 
 /*
@@ -656,16 +662,16 @@ filt_timerexpire(void *knx)
 static int
 filt_timerattach(struct knote *kn)
 {
-	struct callout *calloutp;
+	struct kq_timer_cb_data *kc;
 	sbintime_t to;
 	unsigned int ncallouts;
 
-	if ((intptr_t)kn->kn_sdata < 0)
+	if (kn->kn_sdata < 0)
 		return (EINVAL);
-	if ((intptr_t)kn->kn_sdata == 0 && (kn->kn_flags & EV_ONESHOT) == 0)
+	if (kn->kn_sdata == 0 && (kn->kn_flags & EV_ONESHOT) == 0)
 		kn->kn_sdata = 1;
 	/* Only precision unit are supported in flags so far */
-	if (kn->kn_sfflags & ~NOTE_TIMER_PRECMASK)
+	if ((kn->kn_sfflags & ~NOTE_TIMER_PRECMASK) != 0)
 		return (EINVAL);
 
 	to = timer2sbintime(kn->kn_sdata, kn->kn_sfflags);
@@ -680,13 +686,12 @@ filt_timerattach(struct knote *kn)
 
 	kn->kn_flags |= EV_CLEAR;		/* automatically set */
 	kn->kn_status &= ~KN_DETACHED;		/* knlist_add clears it */
-	kn->kn_ptr.p_nexttime = malloc(sizeof(sbintime_t), M_KQUEUE, M_WAITOK);
-	calloutp = malloc(sizeof(*calloutp), M_KQUEUE, M_WAITOK);
-	callout_init(calloutp, 1);
-	kn->kn_hook = calloutp;
-	*kn->kn_ptr.p_nexttime = to + sbinuptime();
-	callout_reset_sbt_on(calloutp, *kn->kn_ptr.p_nexttime, 0,
-	    filt_timerexpire, kn, PCPU_GET(cpuid), C_ABSOLUTE);
+	kn->kn_ptr.p_v = kc = malloc(sizeof(*kc), M_KQUEUE, M_WAITOK);
+	callout_init(&kc->c, 1);
+	kc->next = to + sbinuptime();
+	kc->to = to;
+	callout_reset_sbt_on(&kc->c, kc->next, 0, filt_timerexpire, kn,
+	    PCPU_GET(cpuid), C_ABSOLUTE);
 
 	return (0);
 }
@@ -694,13 +699,12 @@ filt_timerattach(struct knote *kn)
 static void
 filt_timerdetach(struct knote *kn)
 {
-	struct callout *calloutp;
+	struct kq_timer_cb_data *kc;
 	unsigned int old;
 
-	calloutp = (struct callout *)kn->kn_hook;
-	callout_drain(calloutp);
-	free(calloutp, M_KQUEUE);
-	free(kn->kn_ptr.p_nexttime, M_KQUEUE);
+	kc = kn->kn_ptr.p_v;
+	callout_drain(&kc->c);
+	free(kc, M_KQUEUE);
 	old = atomic_fetchadd_int(&kq_ncallouts, -1);
 	KASSERT(old > 0, ("Number of callouts cannot become negative"));
 	kn->kn_status |= KN_DETACHED;	/* knlist_remove sets it */

Modified: head/sys/sys/event.h
==============================================================================
--- head/sys/sys/event.h	Sun Dec 25 19:49:09 2016	(r310553)
+++ head/sys/sys/event.h	Sun Dec 25 19:49:35 2016	(r310554)
@@ -231,7 +231,6 @@ struct knote {
 		struct		proc *p_proc;	/* proc pointer */
 		struct		kaiocb *p_aio;	/* AIO job pointer */
 		struct		aioliojob *p_lio;	/* LIO job pointer */
-		sbintime_t	*p_nexttime;	/* next timer event fires at */
 		void		*p_v;		/* generic other pointer */
 	} kn_ptr;
 	struct			filterops *kn_fop;

From owner-svn-src-all@freebsd.org  Sun Dec 25 20:17:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E9BEC90CAE;
 Sun, 25 Dec 2016 20:17:16 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6DE3BB33;
 Sun, 25 Dec 2016 20:17:16 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPKHFHq093567;
 Sun, 25 Dec 2016 20:17:15 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPKHFeC093566;
 Sun, 25 Dec 2016 20:17:15 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612252017.uBPKHFeC093566@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Sun, 25 Dec 2016 20:17:15 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310555 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 20:17:16 -0000

Author: mav
Date: Sun Dec 25 20:17:15 2016
New Revision: 310555
URL: https://svnweb.freebsd.org/changeset/base/310555

Log:
  Some random code cleaning.
  
   - Reduce indentation.
   - Remove extra braces.
   - Add few missing savety checks.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Sun Dec 25 19:49:35 2016	(r310554)
+++ head/sys/cam/ctl/ctl.c	Sun Dec 25 20:17:15 2016	(r310555)
@@ -424,7 +424,7 @@ static int ctl_init(void);
 void ctl_shutdown(void);
 static int ctl_open(struct cdev *dev, int flags, int fmt, struct thread *td);
 static int ctl_close(struct cdev *dev, int flags, int fmt, struct thread *td);
-static int ctl_serialize_other_sc_cmd(struct ctl_scsiio *ctsio);
+static void ctl_serialize_other_sc_cmd(struct ctl_scsiio *ctsio);
 static void ctl_ioctl_fill_ooa(struct ctl_lun *lun, uint32_t *cur_fill_num,
 			      struct ctl_ooa *ooa_hdr,
 			      struct ctl_ooa_entry *kern_entries);
@@ -1024,27 +1024,27 @@ ctl_isc_ua(struct ctl_softc *softc, unio
 	uint32_t iid = ctl_get_initindex(&msg->hdr.nexus);
 
 	mtx_lock(&softc->ctl_lock);
-	if (msg->hdr.nexus.targ_lun < CTL_MAX_LUNS &&
-	    (lun = softc->ctl_luns[msg->hdr.nexus.targ_mapped_lun]) != NULL) {
-		mtx_lock(&lun->lun_lock);
-		mtx_unlock(&softc->ctl_lock);
-		if (msg->ua.ua_type == CTL_UA_THIN_PROV_THRES &&
-		    msg->ua.ua_set)
-			memcpy(lun->ua_tpt_info, msg->ua.ua_info, 8);
-		if (msg->ua.ua_all) {
-			if (msg->ua.ua_set)
-				ctl_est_ua_all(lun, iid, msg->ua.ua_type);
-			else
-				ctl_clr_ua_all(lun, iid, msg->ua.ua_type);
-		} else {
-			if (msg->ua.ua_set)
-				ctl_est_ua(lun, iid, msg->ua.ua_type);
-			else
-				ctl_clr_ua(lun, iid, msg->ua.ua_type);
-		}
-		mtx_unlock(&lun->lun_lock);
-	} else
+	if (msg->hdr.nexus.targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[msg->hdr.nexus.targ_mapped_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
+		return;
+	}
+	mtx_lock(&lun->lun_lock);
+	mtx_unlock(&softc->ctl_lock);
+	if (msg->ua.ua_type == CTL_UA_THIN_PROV_THRES && msg->ua.ua_set)
+		memcpy(lun->ua_tpt_info, msg->ua.ua_info, 8);
+	if (msg->ua.ua_all) {
+		if (msg->ua.ua_set)
+			ctl_est_ua_all(lun, iid, msg->ua.ua_type);
+		else
+			ctl_clr_ua_all(lun, iid, msg->ua.ua_type);
+	} else {
+		if (msg->ua.ua_set)
+			ctl_est_ua(lun, iid, msg->ua.ua_type);
+		else
+			ctl_clr_ua(lun, iid, msg->ua.ua_type);
+	}
+	mtx_unlock(&lun->lun_lock);
 }
 
 static void
@@ -1058,8 +1058,8 @@ ctl_isc_lun_sync(struct ctl_softc *softc
 
 	targ_lun = msg->hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
-	    ((lun = softc->ctl_luns[targ_lun]) == NULL)) {
+	if (targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		return;
 	}
@@ -1289,8 +1289,8 @@ ctl_isc_mode_sync(struct ctl_softc *soft
 
 	targ_lun = msg->hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
-	    ((lun = softc->ctl_luns[targ_lun]) == NULL)) {
+	if (targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		return;
 	}
@@ -2193,7 +2193,7 @@ ctl_create_iid(struct ctl_port *port, in
  * command on this side (XFER mode) or tell the other side to execute it
  * (SER_ONLY mode).
  */
-static int
+static void
 ctl_serialize_other_sc_cmd(struct ctl_scsiio *ctsio)
 {
 	struct ctl_softc *softc = control_softc;
@@ -2201,7 +2201,6 @@ ctl_serialize_other_sc_cmd(struct ctl_sc
 	struct ctl_port *port;
 	struct ctl_lun *lun;
 	const struct ctl_cmd_entry *entry;
-	int retval = 0;
 	uint32_t targ_lun;
 
 	targ_lun = ctsio->io_hdr.nexus.targ_mapped_lun;
@@ -2216,24 +2215,10 @@ ctl_serialize_other_sc_cmd(struct ctl_sc
 	}
 
 	/* Make sure that we know about this LUN. */
-	if ((targ_lun < CTL_MAX_LUNS) &&
-	    ((lun = softc->ctl_luns[targ_lun]) != NULL)) {
-		mtx_lock(&lun->lun_lock);
-		mtx_unlock(&softc->ctl_lock);
-		/*
-		 * If the LUN is invalid, pretend that it doesn't exist.
-		 * It will go away as soon as all pending I/O has been
-		 * completed.
-		 */
-		if (lun->flags & CTL_LUN_DISABLED) {
-			mtx_unlock(&lun->lun_lock);
-			lun = NULL;
-		}
-	} else {
+	if (targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
-		lun = NULL;
-	}
-	if (lun == NULL) {
+
 		/*
 		 * The other node would not send this request to us unless
 		 * received announce that we are primary node for this LUN.
@@ -2243,6 +2228,18 @@ ctl_serialize_other_sc_cmd(struct ctl_sc
 		ctl_set_busy(ctsio);
 		goto badjuju;
 	}
+	mtx_lock(&lun->lun_lock);
+	mtx_unlock(&softc->ctl_lock);
+
+	/*
+	 * If the LUN is invalid, pretend that it doesn't exist.
+	 * It will go away as soon as all pending I/Os completed.
+	 */
+	if (lun->flags & CTL_LUN_DISABLED) {
+		mtx_unlock(&lun->lun_lock);
+		ctl_set_busy(ctsio);
+		goto badjuju;
+	}
 
 	entry = ctl_get_cmd_entry(ctsio, NULL);
 	if (ctl_scsiio_lun_check(lun, entry, ctsio) != 0) {
@@ -2314,10 +2311,9 @@ badjuju:
 		msg_info.hdr.msg_type = CTL_MSG_BAD_JUJU;
 		ctl_ha_msg_send(CTL_HA_CHAN_CTL, &msg_info,
 		    sizeof(msg_info.scsi), M_WAITOK);
-		retval = 1;
+		ctl_free_io((union ctl_io *)ctsio);
 		break;
 	}
-	return (retval);
 }
 
 /*
@@ -2685,9 +2681,9 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 		}
 
 		mtx_lock(&softc->ctl_lock);
-		if (((ooa_hdr->flags & CTL_OOA_FLAG_ALL_LUNS) == 0)
-		 && ((ooa_hdr->lun_num >= CTL_MAX_LUNS)
-		  || (softc->ctl_luns[ooa_hdr->lun_num] == NULL))) {
+		if ((ooa_hdr->flags & CTL_OOA_FLAG_ALL_LUNS) == 0 &&
+		    (ooa_hdr->lun_num >= CTL_MAX_LUNS ||
+		     softc->ctl_luns[ooa_hdr->lun_num] == NULL)) {
 			mtx_unlock(&softc->ctl_lock);
 			free(entries, M_CTL);
 			printf("%s: CTL_GET_OOA: invalid LUN %ju\n",
@@ -2739,49 +2735,37 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 
 #ifdef CTL_IO_DELAY
 		mtx_lock(&softc->ctl_lock);
-
-		if ((delay_info->lun_id >= CTL_MAX_LUNS)
-		 || (softc->ctl_luns[delay_info->lun_id] == NULL)) {
+		if (delay_info->lun_id >= CTL_MAX_LUNS ||
+		    (lun = softc->ctl_luns[delay_info->lun_id]) == NULL) {
+			mtx_unlock(&softc->ctl_lock);
 			delay_info->status = CTL_DELAY_STATUS_INVALID_LUN;
-		} else {
-			lun = softc->ctl_luns[delay_info->lun_id];
-			mtx_lock(&lun->lun_lock);
-
-			delay_info->status = CTL_DELAY_STATUS_OK;
-
-			switch (delay_info->delay_type) {
-			case CTL_DELAY_TYPE_CONT:
-				break;
-			case CTL_DELAY_TYPE_ONESHOT:
-				break;
-			default:
-				delay_info->status =
-					CTL_DELAY_STATUS_INVALID_TYPE;
-				break;
-			}
-
-			switch (delay_info->delay_loc) {
-			case CTL_DELAY_LOC_DATAMOVE:
-				lun->delay_info.datamove_type =
-					delay_info->delay_type;
-				lun->delay_info.datamove_delay =
-					delay_info->delay_secs;
-				break;
-			case CTL_DELAY_LOC_DONE:
-				lun->delay_info.done_type =
-					delay_info->delay_type;
-				lun->delay_info.done_delay =
-					delay_info->delay_secs;
-				break;
-			default:
-				delay_info->status =
-					CTL_DELAY_STATUS_INVALID_LOC;
-				break;
-			}
-			mtx_unlock(&lun->lun_lock);
+			break;
 		}
-
+		mtx_lock(&lun->lun_lock);
 		mtx_unlock(&softc->ctl_lock);
+		delay_info->status = CTL_DELAY_STATUS_OK;
+		switch (delay_info->delay_type) {
+		case CTL_DELAY_TYPE_CONT:
+		case CTL_DELAY_TYPE_ONESHOT:
+			break;
+		default:
+			delay_info->status = CTL_DELAY_STATUS_INVALID_TYPE;
+			break;
+		}
+		switch (delay_info->delay_loc) {
+		case CTL_DELAY_LOC_DATAMOVE:
+			lun->delay_info.datamove_type = delay_info->delay_type;
+			lun->delay_info.datamove_delay = delay_info->delay_secs;
+			break;
+		case CTL_DELAY_LOC_DONE:
+			lun->delay_info.done_type = delay_info->delay_type;
+			lun->delay_info.done_delay = delay_info->delay_secs;
+			break;
+		default:
+			delay_info->status = CTL_DELAY_STATUS_INVALID_LOC;
+			break;
+		}
+		mtx_unlock(&lun->lun_lock);
 #else
 		delay_info->status = CTL_DELAY_STATUS_NOT_IMPLEMENTED;
 #endif /* CTL_IO_DELAY */
@@ -2832,8 +2816,8 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 		bcopy(err_desc, new_err_desc, sizeof(*new_err_desc));
 
 		mtx_lock(&softc->ctl_lock);
-		lun = softc->ctl_luns[err_desc->lun_id];
-		if (lun == NULL) {
+		if (err_desc->lun_id >= CTL_MAX_LUNS ||
+		    (lun = softc->ctl_luns[err_desc->lun_id]) == NULL) {
 			mtx_unlock(&softc->ctl_lock);
 			free(new_err_desc, M_CTL);
 			printf("%s: CTL_ERROR_INJECT: invalid LUN %ju\n",
@@ -2876,8 +2860,8 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 		delete_done = 0;
 
 		mtx_lock(&softc->ctl_lock);
-		lun = softc->ctl_luns[delete_desc->lun_id];
-		if (lun == NULL) {
+		if (delete_desc->lun_id >= CTL_MAX_LUNS ||
+		    (lun = softc->ctl_luns[delete_desc->lun_id]) == NULL) {
 			mtx_unlock(&softc->ctl_lock);
 			printf("%s: CTL_ERROR_INJECT_DELETE: invalid LUN %ju\n",
 			       __func__, (uintmax_t)delete_desc->lun_id);
@@ -8540,8 +8524,8 @@ ctl_hndl_per_res_out_on_other_sc(union c
 
 	targ_lun = msg->hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
-	    ((lun = softc->ctl_luns[targ_lun]) == NULL)) {
+	if (targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		return;
 	}
@@ -11436,18 +11420,17 @@ ctl_failover_lun(union ctl_io *rio)
 
 	/* Find and lock the LUN. */
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun < CTL_MAX_LUNS) &&
-	    ((lun = softc->ctl_luns[targ_lun]) != NULL)) {
-		mtx_lock(&lun->lun_lock);
-		mtx_unlock(&softc->ctl_lock);
-		if (lun->flags & CTL_LUN_DISABLED) {
-			mtx_unlock(&lun->lun_lock);
-			return;
-		}
-	} else {
+	if (targ_lun > CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		return;
 	}
+	mtx_lock(&lun->lun_lock);
+	mtx_unlock(&softc->ctl_lock);
+	if (lun->flags & CTL_LUN_DISABLED) {
+		mtx_unlock(&lun->lun_lock);
+		return;
+	}
 
 	if (softc->ha_mode == CTL_HA_MODE_XFER) {
 		TAILQ_FOREACH_SAFE(io, &lun->ooa_queue, ooa_links, next_io) {
@@ -11515,15 +11498,13 @@ ctl_scsiio_precheck(struct ctl_softc *so
 	struct ctl_lun *lun;
 	const struct ctl_cmd_entry *entry;
 	uint32_t initidx, targ_lun;
-	int retval;
-
-	retval = 0;
+	int retval = 0;
 
 	lun = NULL;
-
 	targ_lun = ctsio->io_hdr.nexus.targ_mapped_lun;
-	if ((targ_lun < CTL_MAX_LUNS)
-	 && ((lun = softc->ctl_luns[targ_lun]) != NULL)) {
+	if (targ_lun < CTL_MAX_LUNS)
+		lun = softc->ctl_luns[targ_lun];
+	if (lun) {
 		/*
 		 * If the LUN is invalid, pretend that it doesn't exist.
 		 * It will go away as soon as all pending I/O has been
@@ -11533,29 +11514,22 @@ ctl_scsiio_precheck(struct ctl_softc *so
 		if (lun->flags & CTL_LUN_DISABLED) {
 			mtx_unlock(&lun->lun_lock);
 			lun = NULL;
-			ctsio->io_hdr.ctl_private[CTL_PRIV_LUN].ptr = NULL;
-			ctsio->io_hdr.ctl_private[CTL_PRIV_BACKEND_LUN].ptr = NULL;
-		} else {
-			ctsio->io_hdr.ctl_private[CTL_PRIV_LUN].ptr = lun;
-			ctsio->io_hdr.ctl_private[CTL_PRIV_BACKEND_LUN].ptr =
-				lun->be_lun;
+		}
+	}
+	ctsio->io_hdr.ctl_private[CTL_PRIV_LUN].ptr = lun;
+	if (lun) {
+		ctsio->io_hdr.ctl_private[CTL_PRIV_BACKEND_LUN].ptr =
+		    lun->be_lun;
 
-			/*
-			 * Every I/O goes into the OOA queue for a
-			 * particular LUN, and stays there until completion.
-			 */
+		/*
+		 * Every I/O goes into the OOA queue for a particular LUN,
+		 * and stays there until completion.
+		 */
 #ifdef CTL_TIME_IO
-			if (TAILQ_EMPTY(&lun->ooa_queue)) {
-				lun->idle_time += getsbinuptime() -
-				    lun->last_busy;
-			}
+		if (TAILQ_EMPTY(&lun->ooa_queue))
+			lun->idle_time += getsbinuptime() - lun->last_busy;
 #endif
-			TAILQ_INSERT_TAIL(&lun->ooa_queue, &ctsio->io_hdr,
-			    ooa_links);
-		}
-	} else {
-		ctsio->io_hdr.ctl_private[CTL_PRIV_LUN].ptr = NULL;
-		ctsio->io_hdr.ctl_private[CTL_PRIV_BACKEND_LUN].ptr = NULL;
+		TAILQ_INSERT_TAIL(&lun->ooa_queue, &ctsio->io_hdr, ooa_links);
 	}
 
 	/* Get command entry and return error if it is unsuppotyed. */
@@ -11972,7 +11946,7 @@ ctl_lun_reset(struct ctl_softc *softc, u
 
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
+	if (targ_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		io->taskio.task_status = CTL_TASK_LUN_DOES_NOT_EXIST;
@@ -12051,7 +12025,7 @@ ctl_abort_task_set(union ctl_io *io)
 	 */
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
+	if (targ_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		io->taskio.task_status = CTL_TASK_LUN_DOES_NOT_EXIST;
@@ -12136,7 +12110,7 @@ ctl_abort_task(union ctl_io *io)
 	 */
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
+	if (targ_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		io->taskio.task_status = CTL_TASK_LUN_DOES_NOT_EXIST;
@@ -12261,7 +12235,7 @@ ctl_query_task(union ctl_io *io, int tas
 	softc = control_softc;
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
+	if (targ_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		io->taskio.task_status = CTL_TASK_LUN_DOES_NOT_EXIST;
@@ -12301,7 +12275,7 @@ ctl_query_async_event(union ctl_io *io)
 	softc = control_softc;
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
 	mtx_lock(&softc->ctl_lock);
-	if ((targ_lun >= CTL_MAX_LUNS) ||
+	if (targ_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		io->taskio.task_status = CTL_TASK_LUN_DOES_NOT_EXIST;
@@ -12384,29 +12358,25 @@ ctl_run_task(union ctl_io *io)
 static void
 ctl_handle_isc(union ctl_io *io)
 {
-	int free_io;
-	struct ctl_lun *lun;
 	struct ctl_softc *softc = control_softc;
+	struct ctl_lun *lun;
+	const struct ctl_cmd_entry *entry;
 	uint32_t targ_lun;
 
 	targ_lun = io->io_hdr.nexus.targ_mapped_lun;
-	lun = softc->ctl_luns[targ_lun];
-
 	switch (io->io_hdr.msg_type) {
 	case CTL_MSG_SERIALIZE:
-		free_io = ctl_serialize_other_sc_cmd(&io->scsiio);
+		ctl_serialize_other_sc_cmd(&io->scsiio);
 		break;
-	case CTL_MSG_R2R: {
-		const struct ctl_cmd_entry *entry;
-
-		/*
-		 * This is only used in SER_ONLY mode.
-		 */
-		free_io = 0;
+	case CTL_MSG_R2R:		/* Only used in SER_ONLY mode. */
 		entry = ctl_get_cmd_entry(&io->scsiio, NULL);
+		if (targ_lun >= CTL_MAX_LUNS ||
+		    (lun = softc->ctl_luns[targ_lun]) == NULL) {
+			ctl_done(io);
+			break;
+		}
 		mtx_lock(&lun->lun_lock);
-		if (ctl_scsiio_lun_check(lun,
-		    entry, (struct ctl_scsiio *)io) != 0) {
+		if (ctl_scsiio_lun_check(lun, entry, &io->scsiio) != 0) {
 			mtx_unlock(&lun->lun_lock);
 			ctl_done(io);
 			break;
@@ -12415,51 +12385,46 @@ ctl_handle_isc(union ctl_io *io)
 		mtx_unlock(&lun->lun_lock);
 		ctl_enqueue_rtr(io);
 		break;
-	}
 	case CTL_MSG_FINISH_IO:
 		if (softc->ha_mode == CTL_HA_MODE_XFER) {
-			free_io = 0;
 			ctl_done(io);
-		} else {
-			free_io = 1;
-			mtx_lock(&lun->lun_lock);
-			TAILQ_REMOVE(&lun->ooa_queue, &io->io_hdr,
-				     ooa_links);
-			ctl_check_blocked(lun);
-			mtx_unlock(&lun->lun_lock);
+			break;
 		}
+		if (targ_lun >= CTL_MAX_LUNS ||
+		    (lun = softc->ctl_luns[targ_lun]) == NULL) {
+			ctl_free_io(io);
+			break;
+		}
+		mtx_lock(&lun->lun_lock);
+		TAILQ_REMOVE(&lun->ooa_queue, &io->io_hdr, ooa_links);
+		ctl_check_blocked(lun);
+		mtx_unlock(&lun->lun_lock);
+		ctl_free_io(io);
 		break;
 	case CTL_MSG_PERS_ACTION:
 		ctl_hndl_per_res_out_on_other_sc(
 			(union ctl_ha_msg *)&io->presio.pr_msg);
-		free_io = 1;
+		ctl_free_io(io);
 		break;
 	case CTL_MSG_BAD_JUJU:
-		free_io = 0;
 		ctl_done(io);
 		break;
-	case CTL_MSG_DATAMOVE:
-		/* Only used in XFER mode */
-		free_io = 0;
+	case CTL_MSG_DATAMOVE:		/* Only used in XFER mode */
 		ctl_datamove_remote(io);
 		break;
-	case CTL_MSG_DATAMOVE_DONE:
-		/* Only used in XFER mode */
-		free_io = 0;
+	case CTL_MSG_DATAMOVE_DONE:	/* Only used in XFER mode */
 		io->scsiio.be_move_done(io);
 		break;
 	case CTL_MSG_FAILOVER:
 		ctl_failover_lun(io);
-		free_io = 1;
+		ctl_free_io(io);
 		break;
 	default:
-		free_io = 1;
 		printf("%s: Invalid message type %d\n",
 		       __func__, io->io_hdr.msg_type);
+		ctl_free_io(io);
 		break;
 	}
-	if (free_io)
-		ctl_free_io(io);
 
 }
 
@@ -13360,37 +13325,33 @@ ctl_queue_sense(union ctl_io *io)
 	struct ctl_softc *softc;
 	uint32_t initidx, targ_lun;
 
-	softc = control_softc;
-
 	CTL_DEBUG_PRINT(("ctl_queue_sense\n"));
 
+	softc = control_softc;
+	port = ctl_io_port(&ctsio->io_hdr);
+	targ_lun = ctl_lun_map_from_port(port, io->io_hdr.nexus.targ_lun);
+
 	/*
 	 * LUN lookup will likely move to the ctl_work_thread() once we
 	 * have our new queueing infrastructure (that doesn't put things on
 	 * a per-LUN queue initially).  That is so that we can handle
 	 * things like an INQUIRY to a LUN that we don't have enabled.  We
 	 * can't deal with that right now.
+	 * If we don't have a LUN for this, just toss the sense information.
 	 */
 	mtx_lock(&softc->ctl_lock);
-
-	/*
-	 * If we don't have a LUN for this, just toss the sense
-	 * information.
-	 */
-	port = ctl_io_port(&ctsio->io_hdr);
-	targ_lun = ctl_lun_map_from_port(port, io->io_hdr.nexus.targ_lun);
-	if ((targ_lun < CTL_MAX_LUNS)
-	 && (softc->ctl_luns[targ_lun] != NULL))
-		lun = softc->ctl_luns[targ_lun];
-	else
+	if (targ_lun >= CTL_MAX_LUNS ||
+	    (lun = softc->ctl_luns[targ_lun]) == NULL) {
+		mtx_unlock(&softc->ctl_lock);
 		goto bailout;
-
-	initidx = ctl_get_initindex(&io->io_hdr.nexus);
-
+	}
 	mtx_lock(&lun->lun_lock);
+	mtx_unlock(&softc->ctl_lock);
+
 	/*
 	 * Already have CA set for this LUN...toss the sense information.
 	 */
+	initidx = ctl_get_initindex(&io->io_hdr.nexus);
 	if (ctl_is_set(lun->have_ca, initidx)) {
 		mtx_unlock(&lun->lun_lock);
 		goto bailout;
@@ -13403,10 +13364,7 @@ ctl_queue_sense(union ctl_io *io)
 	mtx_unlock(&lun->lun_lock);
 
 bailout:
-	mtx_unlock(&softc->ctl_lock);
-
 	ctl_free_io(io);
-
 	return (CTL_RETVAL_COMPLETE);
 }
 #endif

From owner-svn-src-all@freebsd.org  Sun Dec 25 20:19:33 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB449C90DD0;
 Sun, 25 Dec 2016 20:19:33 +0000 (UTC)
 (envelope-from jhibbits@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id AAA0ED23;
 Sun, 25 Dec 2016 20:19:33 +0000 (UTC)
 (envelope-from jhibbits@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPKJWJJ093699;
 Sun, 25 Dec 2016 20:19:32 GMT (envelope-from jhibbits@FreeBSD.org)
Received: (from jhibbits@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPKJWQ1093698;
 Sun, 25 Dec 2016 20:19:32 GMT (envelope-from jhibbits@FreeBSD.org)
Message-Id: <201612252019.uBPKJWQ1093698@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhibbits set sender to
 jhibbits@FreeBSD.org using -f
From: Justin Hibbits <jhibbits@FreeBSD.org>
Date: Sun, 25 Dec 2016 20:19:32 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310556 - head/sys/powerpc/powerpc
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 20:19:34 -0000

Author: jhibbits
Date: Sun Dec 25 20:19:32 2016
New Revision: 310556
URL: https://svnweb.freebsd.org/changeset/base/310556

Log:
  Use the correct format specifier for physmem chunk sizes.
  
  Arguments are unsigned, so should be printed as unsigned.

Modified:
  head/sys/powerpc/powerpc/machdep.c

Modified: head/sys/powerpc/powerpc/machdep.c
==============================================================================
--- head/sys/powerpc/powerpc/machdep.c	Sun Dec 25 20:17:15 2016	(r310555)
+++ head/sys/powerpc/powerpc/machdep.c	Sun Dec 25 20:19:32 2016	(r310556)
@@ -199,7 +199,7 @@ cpu_startup(void *dummy)
 			    phys_avail[indx + 1] - phys_avail[indx];
 
 			#ifdef __powerpc64__
-			printf("0x%016jx - 0x%016jx, %jd bytes (%jd pages)\n",
+			printf("0x%016jx - 0x%016jx, %ju bytes (%ju pages)\n",
 			#else
 			printf("0x%09jx - 0x%09jx, %ju bytes (%ju pages)\n",
 			#endif

From owner-svn-src-all@freebsd.org  Sun Dec 25 21:41:41 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 43ABBC90E13;
 Sun, 25 Dec 2016 21:41:41 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 11D171BB2;
 Sun, 25 Dec 2016 21:41:40 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPLfe28028870;
 Sun, 25 Dec 2016 21:41:40 GMT (envelope-from hselasky@FreeBSD.org)
Received: (from hselasky@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPLfesO028869;
 Sun, 25 Dec 2016 21:41:40 GMT (envelope-from hselasky@FreeBSD.org)
Message-Id: <201612252141.uBPLfesO028869@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: hselasky set sender to
 hselasky@FreeBSD.org using -f
From: Hans Petter Selasky <hselasky@FreeBSD.org>
Date: Sun, 25 Dec 2016 21:41:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310557 - head/sys/compat/linuxkpi/common/include/linux
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 21:41:41 -0000

Author: hselasky
Date: Sun Dec 25 21:41:40 2016
New Revision: 310557
URL: https://svnweb.freebsd.org/changeset/base/310557

Log:
  Use correct integer type when computing the maximum physical address
  for kmem_alloc_contig().
  
  Obtained from:	kmacy @
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/gfp.h

Modified: head/sys/compat/linuxkpi/common/include/linux/gfp.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/gfp.h	Sun Dec 25 20:19:32 2016	(r310556)
+++ head/sys/compat/linuxkpi/common/include/linux/gfp.h	Sun Dec 25 21:41:40 2016	(r310557)
@@ -136,8 +136,8 @@ alloc_pages(gfp_t gfp_mask, unsigned int
 	size_t size;
 
 	size = PAGE_SIZE << order;
-	page = kmem_alloc_contig(kmem_arena, size, gfp_mask, 0, -1,
-	    size, 0, VM_MEMATTR_DEFAULT);
+	page = kmem_alloc_contig(kmem_arena, size, gfp_mask,
+	    0, ~(vm_paddr_t)0, size, 0, VM_MEMATTR_DEFAULT);
 	if (page == 0)
 		return (NULL);
         return (virt_to_page(page));

From owner-svn-src-all@freebsd.org  Sun Dec 25 22:32:17 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 55931C91992;
 Sun, 25 Dec 2016 22:32:17 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 240C612D5;
 Sun, 25 Dec 2016 22:32:17 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBPMWGH4049821;
 Sun, 25 Dec 2016 22:32:16 GMT (envelope-from jilles@FreeBSD.org)
Received: (from jilles@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBPMWG0H049600;
 Sun, 25 Dec 2016 22:32:16 GMT (envelope-from jilles@FreeBSD.org)
Message-Id: <201612252232.uBPMWG0H049600@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jilles set sender to
 jilles@FreeBSD.org using -f
From: Jilles Tjoelker <jilles@FreeBSD.org>
Date: Sun, 25 Dec 2016 22:32:16 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310558 - stable/10/tests/sys/kern
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Dec 2016 22:32:17 -0000

Author: jilles
Date: Sun Dec 25 22:32:16 2016
New Revision: 310558
URL: https://svnweb.freebsd.org/changeset/base/310558

Log:
  MFC r309836: Add some tests for reaper functionality (in procctl()).

Added:
  stable/10/tests/sys/kern/reaper.c
     - copied unchanged from r309836, head/tests/sys/kern/reaper.c
Modified:
  stable/10/tests/sys/kern/Makefile
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/tests/sys/kern/Makefile
==============================================================================
--- stable/10/tests/sys/kern/Makefile	Sun Dec 25 21:41:40 2016	(r310557)
+++ stable/10/tests/sys/kern/Makefile	Sun Dec 25 22:32:16 2016	(r310558)
@@ -8,6 +8,7 @@ TESTSDIR=	${TESTSBASE}/sys/kern
 
 ATF_TESTS_C+=	kern_descrip_test
 ATF_TESTS_C+=	ptrace_test
+ATF_TESTS_C+=	reaper
 ATF_TESTS_C+=	unix_seqpacket_test
 ATF_TESTS_C+=	unix_passfd_test
 TEST_METADATA.unix_seqpacket_test+=	timeout="15"

Copied: stable/10/tests/sys/kern/reaper.c (from r309836, head/tests/sys/kern/reaper.c)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/tests/sys/kern/reaper.c	Sun Dec 25 22:32:16 2016	(r310558, copy of r309836, head/tests/sys/kern/reaper.c)
@@ -0,0 +1,494 @@
+/*-
+ * Copyright (c) 2016 Jilles Tjoelker
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
+
+#include <sys/procctl.h>
+#include <sys/wait.h>
+
+#include <atf-c.h>
+#include <errno.h>
+#include <signal.h>
+#include <unistd.h>
+
+ATF_TC_WITHOUT_HEAD(reaper_wait_child_first);
+ATF_TC_BODY(reaper_wait_child_first, tc)
+{
+	pid_t parent, child, grandchild, pid;
+	int status, r;
+	int pip[2];
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = pipe(pip);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pip[1]) != 0)
+			_exit(100);
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0) {
+			if (read(pip[0], &(uint8_t){ 0 }, 1) != 0)
+				_exit(102);
+			if (getppid() != parent)
+				_exit(103);
+			_exit(2);
+		} else
+			_exit(3);
+	}
+
+	pid = waitpid(child, &status, 0);
+	ATF_REQUIRE_EQ(child, pid);
+	r = WIFEXITED(status) ? WEXITSTATUS(status) : -1;
+	ATF_CHECK_EQ(3, r);
+
+	r = close(pip[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	pid = waitpid(-1, &status, 0);
+	ATF_REQUIRE(pid > 0 && pid != child);
+	r = WIFEXITED(status) ? WEXITSTATUS(status) : -1;
+	ATF_CHECK_EQ(2, r);
+
+	r = close(pip[0]);
+	ATF_REQUIRE_EQ(0, r);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_wait_grandchild_first);
+ATF_TC_BODY(reaper_wait_grandchild_first, tc)
+{
+	pid_t parent, child, grandchild, pid;
+	int status, r;
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0)
+			_exit(2);
+		else {
+			if (waitid(P_PID, grandchild, NULL,
+			    WNOWAIT | WEXITED) != 0)
+				_exit(102);
+			_exit(3);
+		}
+	}
+
+	pid = waitpid(child, &status, 0);
+	ATF_REQUIRE_EQ(child, pid);
+	r = WIFEXITED(status) ? WEXITSTATUS(status) : -1;
+	ATF_CHECK_EQ(3, r);
+
+	pid = waitpid(-1, &status, 0);
+	ATF_REQUIRE(pid > 0 && pid != child);
+	r = WIFEXITED(status) ? WEXITSTATUS(status) : -1;
+	ATF_CHECK_EQ(2, r);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_status);
+ATF_TC_BODY(reaper_status, tc)
+{
+	struct procctl_reaper_status st;
+	ssize_t sr;
+	pid_t parent, child, pid;
+	int r, status;
+	int pip[2];
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_STATUS, &st);
+	ATF_REQUIRE_EQ(0, r);
+	ATF_CHECK_EQ(0, st.rs_flags & REAPER_STATUS_OWNED);
+	ATF_CHECK(st.rs_children > 0);
+	ATF_CHECK(st.rs_descendants > 0);
+	ATF_CHECK(st.rs_descendants >= st.rs_children);
+	ATF_CHECK(st.rs_reaper != parent);
+	ATF_CHECK(st.rs_reaper > 0);
+
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = procctl(P_PID, parent, PROC_REAP_STATUS, &st);
+	ATF_REQUIRE_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_STATUS_OWNED,
+	    st.rs_flags & (REAPER_STATUS_OWNED | REAPER_STATUS_REALINIT));
+	ATF_CHECK_EQ(0, st.rs_children);
+	ATF_CHECK_EQ(0, st.rs_descendants);
+	ATF_CHECK(st.rs_reaper == parent);
+	ATF_CHECK_EQ(-1, st.rs_pid);
+
+	r = pipe(pip);
+	ATF_REQUIRE_EQ(0, r);
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pip[0]) != 0)
+			_exit(100);
+		if (procctl(P_PID, parent, PROC_REAP_STATUS, &st) != 0)
+			_exit(101);
+		if (write(pip[1], &st, sizeof(st)) != (ssize_t)sizeof(st))
+			_exit(102);
+		if (procctl(P_PID, getpid(), PROC_REAP_STATUS, &st) != 0)
+			_exit(103);
+		if (write(pip[1], &st, sizeof(st)) != (ssize_t)sizeof(st))
+			_exit(104);
+		_exit(0);
+	}
+	r = close(pip[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	sr = read(pip[0], &st, sizeof(st));
+	ATF_REQUIRE_EQ((ssize_t)sizeof(st), sr);
+	ATF_CHECK_EQ(REAPER_STATUS_OWNED,
+	    st.rs_flags & (REAPER_STATUS_OWNED | REAPER_STATUS_REALINIT));
+	ATF_CHECK_EQ(1, st.rs_children);
+	ATF_CHECK_EQ(1, st.rs_descendants);
+	ATF_CHECK(st.rs_reaper == parent);
+	ATF_CHECK_EQ(child, st.rs_pid);
+	sr = read(pip[0], &st, sizeof(st));
+	ATF_REQUIRE_EQ((ssize_t)sizeof(st), sr);
+	ATF_CHECK_EQ(0,
+	    st.rs_flags & (REAPER_STATUS_OWNED | REAPER_STATUS_REALINIT));
+	ATF_CHECK_EQ(1, st.rs_children);
+	ATF_CHECK_EQ(1, st.rs_descendants);
+	ATF_CHECK(st.rs_reaper == parent);
+	ATF_CHECK_EQ(child, st.rs_pid);
+
+	r = close(pip[0]);
+	ATF_REQUIRE_EQ(0, r);
+	pid = waitpid(child, &status, 0);
+	ATF_REQUIRE_EQ(child, pid);
+	ATF_CHECK_EQ(0, status);
+
+	r = procctl(P_PID, parent, PROC_REAP_STATUS, &st);
+	ATF_REQUIRE_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_STATUS_OWNED,
+	    st.rs_flags & (REAPER_STATUS_OWNED | REAPER_STATUS_REALINIT));
+	ATF_CHECK_EQ(0, st.rs_children);
+	ATF_CHECK_EQ(0, st.rs_descendants);
+	ATF_CHECK(st.rs_reaper == parent);
+	ATF_CHECK_EQ(-1, st.rs_pid);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_getpids);
+ATF_TC_BODY(reaper_getpids, tc)
+{
+	struct procctl_reaper_pidinfo info[10];
+	ssize_t sr;
+	pid_t parent, child, grandchild, pid;
+	int r, status, childidx;
+	int pipa[2], pipb[2];
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(0, info[0].pi_flags & REAPER_PIDINFO_VALID);
+
+	r = pipe(pipa);
+	ATF_REQUIRE_EQ(0, r);
+	r = pipe(pipb);
+	ATF_REQUIRE_EQ(0, r);
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pipa[1]) != 0)
+			_exit(100);
+		if (close(pipb[0]) != 0)
+			_exit(100);
+		if (read(pipa[0], &(uint8_t){ 0 }, 1) != 1)
+			_exit(101);
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(102);
+		if (grandchild == 0) {
+			if (write(pipb[1], &(uint8_t){ 0 }, 1) != 1)
+				_exit(103);
+			if (read(pipa[0], &(uint8_t){ 0 }, 1) != 1)
+				_exit(104);
+			_exit(0);
+		}
+		for (;;)
+			pause();
+	}
+	r = close(pipa[0]);
+	ATF_REQUIRE_EQ(0, r);
+	r = close(pipb[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_PIDINFO_VALID | REAPER_PIDINFO_CHILD,
+	    info[0].pi_flags & (REAPER_PIDINFO_VALID | REAPER_PIDINFO_CHILD));
+	ATF_CHECK_EQ(child, info[0].pi_pid);
+	ATF_CHECK_EQ(child, info[0].pi_subtree);
+	ATF_CHECK_EQ(0, info[1].pi_flags & REAPER_PIDINFO_VALID);
+
+	sr = write(pipa[1], &(uint8_t){ 0 }, 1);
+	ATF_REQUIRE_EQ(1, sr);
+	sr = read(pipb[0], &(uint8_t){ 0 }, 1);
+	ATF_REQUIRE_EQ(1, sr);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_PIDINFO_VALID,
+	    info[0].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(REAPER_PIDINFO_VALID,
+	    info[1].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(0, info[2].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(child, info[0].pi_subtree);
+	ATF_CHECK_EQ(child, info[1].pi_subtree);
+	childidx = info[1].pi_pid == child ? 1 : 0;
+	ATF_CHECK_EQ(REAPER_PIDINFO_CHILD,
+	    info[childidx].pi_flags & REAPER_PIDINFO_CHILD);
+	ATF_CHECK_EQ(0, info[childidx ^ 1].pi_flags & REAPER_PIDINFO_CHILD);
+	ATF_CHECK(info[childidx].pi_pid == child);
+	grandchild = info[childidx ^ 1].pi_pid;
+	ATF_CHECK(grandchild > 0);
+	ATF_CHECK(grandchild != child);
+	ATF_CHECK(grandchild != parent);
+
+	r = kill(child, SIGTERM);
+	ATF_REQUIRE_EQ(0, r);
+
+	pid = waitpid(child, &status, 0);
+	ATF_REQUIRE_EQ(child, pid);
+	ATF_CHECK(WIFSIGNALED(status) && WTERMSIG(status) == SIGTERM);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_PIDINFO_VALID,
+	    info[0].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(0, info[1].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(child, info[0].pi_subtree);
+	ATF_CHECK_EQ(REAPER_PIDINFO_CHILD,
+	    info[0].pi_flags & REAPER_PIDINFO_CHILD);
+	ATF_CHECK_EQ(grandchild, info[0].pi_pid);
+
+	sr = write(pipa[1], &(uint8_t){ 0 }, 1);
+	ATF_REQUIRE_EQ(1, sr);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(REAPER_PIDINFO_VALID,
+	    info[0].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(0, info[1].pi_flags & REAPER_PIDINFO_VALID);
+	ATF_CHECK_EQ(child, info[0].pi_subtree);
+	ATF_CHECK_EQ(REAPER_PIDINFO_CHILD,
+	    info[0].pi_flags & REAPER_PIDINFO_CHILD);
+	ATF_CHECK_EQ(grandchild, info[0].pi_pid);
+
+	pid = waitpid(grandchild, &status, 0);
+	ATF_REQUIRE_EQ(grandchild, pid);
+	ATF_CHECK_EQ(0, status);
+
+	memset(info, '\0', sizeof(info));
+	r = procctl(P_PID, parent, PROC_REAP_GETPIDS,
+	    &(struct procctl_reaper_pids){
+	    .rp_count = sizeof(info) / sizeof(info[0]),
+	    .rp_pids = info
+	    });
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(0, info[0].pi_flags & REAPER_PIDINFO_VALID);
+
+	r = close(pipa[1]);
+	ATF_REQUIRE_EQ(0, r);
+	r = close(pipb[0]);
+	ATF_REQUIRE_EQ(0, r);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_kill_badsig);
+ATF_TC_BODY(reaper_kill_badsig, tc)
+{
+	struct procctl_reaper_kill params;
+	pid_t parent;
+	int r;
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	params.rk_sig = -1;
+	params.rk_flags = 0;
+	r = procctl(P_PID, parent, PROC_REAP_KILL, &params);
+	ATF_CHECK(r == -1 && errno == EINVAL);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_kill_sigzero);
+ATF_TC_BODY(reaper_kill_sigzero, tc)
+{
+	struct procctl_reaper_kill params;
+	pid_t parent;
+	int r;
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	params.rk_sig = 0;
+	params.rk_flags = 0;
+	r = procctl(P_PID, parent, PROC_REAP_KILL, &params);
+	ATF_CHECK(r == -1 && errno == EINVAL);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_kill_empty);
+ATF_TC_BODY(reaper_kill_empty, tc)
+{
+	struct procctl_reaper_kill params;
+	pid_t parent;
+	int r;
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	params.rk_sig = SIGTERM;
+	params.rk_flags = 0;
+	params.rk_killed = 77;
+	r = procctl(P_PID, parent, PROC_REAP_KILL, &params);
+	ATF_CHECK(r == -1 && errno == ESRCH);
+	ATF_CHECK_EQ(0, params.rk_killed);
+}
+
+ATF_TC_WITHOUT_HEAD(reaper_kill_normal);
+ATF_TC_BODY(reaper_kill_normal, tc)
+{
+	struct procctl_reaper_kill params;
+	ssize_t sr;
+	pid_t parent, child, grandchild, pid;
+	int r, status;
+	int pip[2];
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = pipe(pip);
+	ATF_REQUIRE_EQ(0, r);
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pip[0]) != 0)
+			_exit(100);
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		if (grandchild == 0) {
+			if (write(pip[1], &(uint8_t){ 0 }, 1) != 1)
+				_exit(102);
+			for (;;)
+				pause();
+		}
+		for (;;)
+			pause();
+	}
+	r = close(pip[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	sr = read(pip[0], &(uint8_t){ 0 }, 1);
+	ATF_REQUIRE_EQ(1, sr);
+
+	params.rk_sig = SIGTERM;
+	params.rk_flags = 0;
+	params.rk_killed = 77;
+	r = procctl(P_PID, parent, PROC_REAP_KILL, &params);
+	ATF_CHECK_EQ(0, r);
+	ATF_CHECK_EQ(2, params.rk_killed);
+
+	pid = waitpid(child, &status, 0);
+	ATF_REQUIRE_EQ(child, pid);
+	ATF_CHECK(WIFSIGNALED(status) && WTERMSIG(status) == SIGTERM);
+
+	pid = waitpid(-1, &status, 0);
+	ATF_REQUIRE(pid > 0);
+	ATF_CHECK(pid != parent);
+	ATF_CHECK(pid != child);
+	ATF_CHECK(WIFSIGNALED(status) && WTERMSIG(status) == SIGTERM);
+
+	r = close(pip[0]);
+	ATF_REQUIRE_EQ(0, r);
+}
+
+ATF_TP_ADD_TCS(tp)
+{
+
+	ATF_TP_ADD_TC(tp, reaper_wait_child_first);
+	ATF_TP_ADD_TC(tp, reaper_wait_grandchild_first);
+	ATF_TP_ADD_TC(tp, reaper_status);
+	ATF_TP_ADD_TC(tp, reaper_getpids);
+	ATF_TP_ADD_TC(tp, reaper_kill_badsig);
+	ATF_TP_ADD_TC(tp, reaper_kill_sigzero);
+	ATF_TP_ADD_TC(tp, reaper_kill_empty);
+	ATF_TP_ADD_TC(tp, reaper_kill_normal);
+	return (atf_no_error());
+}

From owner-svn-src-all@freebsd.org  Mon Dec 26 01:18:09 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5641EC90AB6;
 Mon, 26 Dec 2016 01:18:09 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 16E7819A0;
 Mon, 26 Dec 2016 01:18:09 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ1I8Zv015292;
 Mon, 26 Dec 2016 01:18:08 GMT (envelope-from hselasky@FreeBSD.org)
Received: (from hselasky@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ1I8Dm015288;
 Mon, 26 Dec 2016 01:18:08 GMT (envelope-from hselasky@FreeBSD.org)
Message-Id: <201612260118.uBQ1I8Dm015288@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: hselasky set sender to
 hselasky@FreeBSD.org using -f
From: Hans Petter Selasky <hselasky@FreeBSD.org>
Date: Mon, 26 Dec 2016 01:18:08 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310559 - in head/sys/compat/linuxkpi/common:
 include/linux src
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 01:18:09 -0000

Author: hselasky
Date: Mon Dec 26 01:18:07 2016
New Revision: 310559
URL: https://svnweb.freebsd.org/changeset/base/310559

Log:
  Implement register and unregister chrdev in the LinuxKPI.
  
  Obtained from:	kmacy @
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/cdev.h
  head/sys/compat/linuxkpi/common/include/linux/fs.h
  head/sys/compat/linuxkpi/common/src/linux_compat.c

Modified: head/sys/compat/linuxkpi/common/include/linux/cdev.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/cdev.h	Sun Dec 25 22:32:16 2016	(r310558)
+++ head/sys/compat/linuxkpi/common/include/linux/cdev.h	Mon Dec 26 01:18:07 2016	(r310559)
@@ -95,7 +95,7 @@ cdev_add(struct linux_cdev *cdev, dev_t 
 	args.mda_gid = 0;
 	args.mda_mode = 0700;
 	args.mda_si_drv1 = cdev;
-	args.mda_unit = MINOR(dev);
+	args.mda_unit = dev;
 
 	error = make_dev_s(&args, &cdev->cdev, "%s",
 	    kobject_name(&cdev->kobj));
@@ -121,7 +121,7 @@ cdev_add_ext(struct linux_cdev *cdev, de
 	args.mda_gid = gid;
 	args.mda_mode = mode;
 	args.mda_si_drv1 = cdev;
-	args.mda_unit = MINOR(dev);
+	args.mda_unit = dev;
 
 	error = make_dev_s(&args, &cdev->cdev, "%s/%d",
 	    kobject_name(&cdev->kobj), MINOR(dev));
@@ -142,6 +142,8 @@ cdev_del(struct linux_cdev *cdev)
 	kobject_put(&cdev->kobj);
 }
 
+struct linux_cdev *linux_find_cdev(const char *name, unsigned major, unsigned minor);
+
 #define	cdev	linux_cdev
 
 #endif	/* _LINUX_CDEV_H_ */

Modified: head/sys/compat/linuxkpi/common/include/linux/fs.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/fs.h	Sun Dec 25 22:32:16 2016	(r310558)
+++ head/sys/compat/linuxkpi/common/include/linux/fs.h	Mon Dec 26 01:18:07 2016	(r310559)
@@ -2,7 +2,7 @@
  * Copyright (c) 2010 Isilon Systems, Inc.
  * Copyright (c) 2010 iX Systems, Inc.
  * Copyright (c) 2010 Panasas, Inc.
- * Copyright (c) 2013 Mellanox Technologies, Ltd.
+ * Copyright (c) 2013-2016 Mellanox Technologies, Ltd.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -151,6 +151,39 @@ struct file_operations {
 #define	FMODE_WRITE	FWRITE
 #define	FMODE_EXEC	FEXEC
 
+int __register_chrdev(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name,
+    const struct file_operations *fops);
+int __register_chrdev_p(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name,
+    const struct file_operations *fops, uid_t uid,
+    gid_t gid, int mode);
+void __unregister_chrdev(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name);
+
+static inline void
+unregister_chrdev(unsigned int major, const char *name)
+{
+
+	__unregister_chrdev(major, 0, 256, name);
+}
+
+static inline int
+register_chrdev(unsigned int major, const char *name,
+    const struct file_operations *fops)
+{
+
+	return (__register_chrdev(major, 0, 256, name, fops));
+}
+
+static inline int
+register_chrdev_p(unsigned int major, const char *name,
+    const struct file_operations *fops, uid_t uid, gid_t gid, int mode)
+{
+
+	return (__register_chrdev_p(major, 0, 256, name, fops, uid, gid, mode));
+}
+
 static inline int
 register_chrdev_region(dev_t dev, unsigned range, const char *name)
 {
@@ -184,7 +217,7 @@ static inline dev_t
 iminor(struct inode *inode)
 {
 
-	return dev2unit(inode->v_rdev);
+	return (MINOR(dev2unit(inode->v_rdev)));
 }
 
 static inline struct inode *

Modified: head/sys/compat/linuxkpi/common/src/linux_compat.c
==============================================================================
--- head/sys/compat/linuxkpi/common/src/linux_compat.c	Sun Dec 25 22:32:16 2016	(r310558)
+++ head/sys/compat/linuxkpi/common/src/linux_compat.c	Mon Dec 26 01:18:07 2016	(r310559)
@@ -1418,6 +1418,82 @@ linux_irq_handler(void *ent)
 	irqe->handler(irqe->irq, irqe->arg);
 }
 
+struct linux_cdev *
+linux_find_cdev(const char *name, unsigned major, unsigned minor)
+{
+	int unit = MKDEV(major, minor);
+	struct cdev *cdev;
+
+	dev_lock();
+	LIST_FOREACH(cdev, &linuxcdevsw.d_devs, si_list) {
+		struct linux_cdev *ldev = cdev->si_drv1;
+		if (dev2unit(cdev) == unit &&
+		    strcmp(kobject_name(&ldev->kobj), name) == 0) {
+			break;
+		}
+	}
+	dev_unlock();
+
+	return (cdev != NULL ? cdev->si_drv1 : NULL);
+}
+
+int
+__register_chrdev(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name,
+    const struct file_operations *fops)
+{
+	struct linux_cdev *cdev;
+	int ret = 0;
+	int i;
+
+	for (i = baseminor; i < baseminor + count; i++) {
+		cdev = cdev_alloc();
+		cdev_init(cdev, fops);
+		kobject_set_name(&cdev->kobj, name);
+
+		ret = cdev_add(cdev, makedev(major, i), 1);
+		if (ret != 0)
+			break;
+	}
+	return (ret);
+}
+
+int
+__register_chrdev_p(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name,
+    const struct file_operations *fops, uid_t uid,
+    gid_t gid, int mode)
+{
+	struct linux_cdev *cdev;
+	int ret = 0;
+	int i;
+
+	for (i = baseminor; i < baseminor + count; i++) {
+		cdev = cdev_alloc();
+		cdev_init(cdev, fops);
+		kobject_set_name(&cdev->kobj, name);
+
+		ret = cdev_add_ext(cdev, makedev(major, i), uid, gid, mode);
+		if (ret != 0)
+			break;
+	}
+	return (ret);
+}
+
+void
+__unregister_chrdev(unsigned int major, unsigned int baseminor,
+    unsigned int count, const char *name)
+{
+	struct linux_cdev *cdevp;
+	int i;
+
+	for (i = baseminor; i < baseminor + count; i++) {
+		cdevp = linux_find_cdev(name, major, i);
+		if (cdevp != NULL)
+			cdev_del(cdevp);
+	}
+}
+
 #if defined(__i386__) || defined(__amd64__)
 bool linux_cpu_has_clflush;
 #endif

From owner-svn-src-all@freebsd.org  Mon Dec 26 02:51:04 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4D645C901BA;
 Mon, 26 Dec 2016 02:51:04 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 1CC7814B8;
 Mon, 26 Dec 2016 02:51:04 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ2p3iV052299;
 Mon, 26 Dec 2016 02:51:03 GMT (envelope-from gonzo@FreeBSD.org)
Received: (from gonzo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ2p3iX052298;
 Mon, 26 Dec 2016 02:51:03 GMT (envelope-from gonzo@FreeBSD.org)
Message-Id: <201612260251.uBQ2p3iX052298@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: gonzo set sender to
 gonzo@FreeBSD.org using -f
From: Oleksandr Tymoshenko <gonzo@FreeBSD.org>
Date: Mon, 26 Dec 2016 02:51:03 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310560 - head/sys/contrib/vchiq/interface/vchiq_arm
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 02:51:04 -0000

Author: gonzo
Date: Mon Dec 26 02:51:03 2016
New Revision: 310560
URL: https://svnweb.freebsd.org/changeset/base/310560

Log:
  [vchi] replace non-reproducible __DATE__/__TIME__ with hardcoded string
  
  Although vchiq_build_date and vchiq_build_time are not used in current
  vchi driver at the moment, make sure these value will not leak into
  build later on if at some point they will be refered in some new
  imported code
  
  PR:		215494
  Reported by:	emaste
  MFC after:	1 week

Modified:
  head/sys/contrib/vchiq/interface/vchiq_arm/vchiq_version.c

Modified: head/sys/contrib/vchiq/interface/vchiq_arm/vchiq_version.c
==============================================================================
--- head/sys/contrib/vchiq/interface/vchiq_arm/vchiq_version.c	Mon Dec 26 01:18:07 2016	(r310559)
+++ head/sys/contrib/vchiq/interface/vchiq_arm/vchiq_version.c	Mon Dec 26 02:51:03 2016	(r310560)
@@ -35,8 +35,8 @@
 
 VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_hostname, "dc4-arm-01" );
 VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_version, "9245b4c35b99b3870e1f7dc598c5692b3c66a6f0 (tainted)" );
-VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_time,    __TIME__ );
-VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_date,    __DATE__ );
+VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_time,    "not available" );
+VC_DEBUG_DECLARE_STRING_VAR( vchiq_build_date,    "not available" );
 
 const char *vchiq_get_build_hostname( void )
 {

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:02:46 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id AC13DC843BE;
 Mon, 26 Dec 2016 06:02:46 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 7A4D0DFD;
 Mon, 26 Dec 2016 06:02:46 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ62jTb033377;
 Mon, 26 Dec 2016 06:02:45 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ62jrg033376;
 Mon, 26 Dec 2016 06:02:45 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260602.uBQ62jrg033376@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:02:45 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310561 - stable/11/usr.sbin/bsnmpd/tools/bsnmptools
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:02:46 -0000

Author: ngie
Date: Mon Dec 26 06:02:45 2016
New Revision: 310561
URL: https://svnweb.freebsd.org/changeset/base/310561

Log:
  MFC r310203:
  
  Clean up parse_ip(..)
  
  - Clean up trailing whitespace
  - Fix variable alignment

Modified:
  stable/11/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c
==============================================================================
--- stable/11/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c	Mon Dec 26 02:51:03 2016	(r310560)
+++ stable/11/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c	Mon Dec 26 06:02:45 2016	(r310561)
@@ -603,9 +603,9 @@ parse_oid_string(struct snmp_toolinfo *s
 static int32_t
 parse_ip(struct snmp_value * value, char * val)
 {
-	uint32_t v;
-	int32_t i;
 	char *endptr, *str;
+	int32_t i;
+	uint32_t v;
 
 	str = val;
 	for (i = 0; i < 4; i++) {
@@ -617,8 +617,8 @@ parse_ip(struct snmp_value * value, char
 		str = endptr + 1;
 		value->v.ipaddress[i] = (uint8_t) v;
 	}
-
 	value->syntax = SNMP_SYNTAX_IPADDRESS;
+
 	return (0);
 }
 

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:04:11 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 93616C8446E;
 Mon, 26 Dec 2016 06:04:11 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 62631F65;
 Mon, 26 Dec 2016 06:04:11 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ64Aw1033507;
 Mon, 26 Dec 2016 06:04:10 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ64Aae033506;
 Mon, 26 Dec 2016 06:04:10 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260604.uBQ64Aae033506@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:04:10 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310562 - stable/10/usr.sbin/bsnmpd/tools/bsnmptools
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:04:11 -0000

Author: ngie
Date: Mon Dec 26 06:04:10 2016
New Revision: 310562
URL: https://svnweb.freebsd.org/changeset/base/310562

Log:
  MFstable/11 r310561:
  
  MFC r310203:
  
  Clean up parse_ip(..)
  
  - Clean up trailing whitespace
  - Fix variable alignment

Modified:
  stable/10/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c
==============================================================================
--- stable/10/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c	Mon Dec 26 06:02:45 2016	(r310561)
+++ stable/10/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c	Mon Dec 26 06:04:10 2016	(r310562)
@@ -603,9 +603,9 @@ parse_oid_string(struct snmp_toolinfo *s
 static int32_t
 parse_ip(struct snmp_value * value, char * val)
 {
-	uint32_t v;
-	int32_t i;
 	char *endptr, *str;
+	int32_t i;
+	uint32_t v;
 
 	str = val;
 	for (i = 0; i < 4; i++) {
@@ -617,8 +617,8 @@ parse_ip(struct snmp_value * value, char
 		str = endptr + 1;
 		value->v.ipaddress[i] = (uint8_t) v;
 	}
-
 	value->syntax = SNMP_SYNTAX_IPADDRESS;
+
 	return (0);
 }
 

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:05:48 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E38B9C844F1;
 Mon, 26 Dec 2016 06:05:48 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 98AFB10D0;
 Mon, 26 Dec 2016 06:05:48 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ65lso033623;
 Mon, 26 Dec 2016 06:05:47 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ65lpf033622;
 Mon, 26 Dec 2016 06:05:47 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260605.uBQ65lpf033622@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:05:47 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310563 - stable/11/usr.sbin/bsnmpd/modules/snmp_bridge
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:05:49 -0000

Author: ngie
Date: Mon Dec 26 06:05:47 2016
New Revision: 310563
URL: https://svnweb.freebsd.org/changeset/base/310563

Log:
  MFC r310196:
  
  Fix some minor typos with begemotBridgeTpLearnedEntryDiscards and
  begemotBridgeTpMaxAddresses
  
  Bump LAST-UPDATED for the MIB, per the change

Modified:
  stable/11/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt
==============================================================================
--- stable/11/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt	Mon Dec 26 06:04:10 2016	(r310562)
+++ stable/11/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt	Mon Dec 26 06:05:47 2016	(r310563)
@@ -41,7 +41,7 @@ IMPORTS
 	FROM BEGEMOT-MIB;
 
 begemotBridge MODULE-IDENTITY
-    LAST-UPDATED "200708060000Z"
+    LAST-UPDATED "201612170000Z"
     ORGANIZATION "Sofia University St. Kliment Ohridski"
     CONTACT-INFO
 	    "		Shteryana Shopova
@@ -56,6 +56,9 @@ begemotBridge MODULE-IDENTITY
 	     E-Mail:	syrinx@FreeBSD.org"
     DESCRIPTION
 	    "The Begemot MIB for managing bridge interfaces."
+    REVISION     "201612170000Z"
+    DESCRIPTION
+    	     "Address some minor typos and grammar mistakes."
     REVISION     "200708060000Z"
     DESCRIPTION
 	     "Third revision adds begemotBridgeBasePortPrivate
@@ -856,7 +859,7 @@ begemotBridgeTpLearnedEntryDiscards OBJE
     DESCRIPTION
 	"The total number of Forwarding Database entries that would
 	have been learnt, but have been discarded due to Forwarding
-	Address Table having reached it's maximum entries limit."
+	Address Table having reached its maximum entries limit."
     ::= { begemotBridgeTpEntry 1 }
 
 begemotBridgeTpAgingTime OBJECT-TYPE
@@ -874,7 +877,7 @@ begemotBridgeTpMaxAddresses OBJECT-TYPE
     MAX-ACCESS	read-write
     STATUS	current
     DESCRIPTION
-	"The maximum number of entires that this bridge can
+	"The maximum number of entries that this bridge can
 	learn in it's Forwarding Address Table and use for
 	making forwarding decisions."
     ::= { begemotBridgeTpEntry 3 }

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:06:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 58CF5C8457D;
 Mon, 26 Dec 2016 06:06:56 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 0DF991287;
 Mon, 26 Dec 2016 06:06:55 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ66tE9033719;
 Mon, 26 Dec 2016 06:06:55 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ66tqB033718;
 Mon, 26 Dec 2016 06:06:55 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260606.uBQ66tqB033718@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:06:55 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310564 - stable/10/usr.sbin/bsnmpd/modules/snmp_bridge
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:06:56 -0000

Author: ngie
Date: Mon Dec 26 06:06:55 2016
New Revision: 310564
URL: https://svnweb.freebsd.org/changeset/base/310564

Log:
  MFstable/11 r310563:
  
  MFC r310196:
  
  Fix some minor typos with begemotBridgeTpLearnedEntryDiscards and
  begemotBridgeTpMaxAddresses
  
  Bump LAST-UPDATED for the MIB, per the change

Modified:
  stable/10/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt
==============================================================================
--- stable/10/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt	Mon Dec 26 06:05:47 2016	(r310563)
+++ stable/10/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt	Mon Dec 26 06:06:55 2016	(r310564)
@@ -41,7 +41,7 @@ IMPORTS
 	FROM BEGEMOT-MIB;
 
 begemotBridge MODULE-IDENTITY
-    LAST-UPDATED "200708060000Z"
+    LAST-UPDATED "201612170000Z"
     ORGANIZATION "Sofia University St. Kliment Ohridski"
     CONTACT-INFO
 	    "		Shteryana Shopova
@@ -56,6 +56,9 @@ begemotBridge MODULE-IDENTITY
 	     E-Mail:	syrinx@FreeBSD.org"
     DESCRIPTION
 	    "The Begemot MIB for managing bridge interfaces."
+    REVISION     "201612170000Z"
+    DESCRIPTION
+    	     "Address some minor typos and grammar mistakes."
     REVISION     "200708060000Z"
     DESCRIPTION
 	     "Third revision adds begemotBridgeBasePortPrivate
@@ -856,7 +859,7 @@ begemotBridgeTpLearnedEntryDiscards OBJE
     DESCRIPTION
 	"The total number of Forwarding Database entries that would
 	have been learnt, but have been discarded due to Forwarding
-	Address Table having reached it's maximum entries limit."
+	Address Table having reached its maximum entries limit."
     ::= { begemotBridgeTpEntry 1 }
 
 begemotBridgeTpAgingTime OBJECT-TYPE
@@ -874,7 +877,7 @@ begemotBridgeTpMaxAddresses OBJECT-TYPE
     MAX-ACCESS	read-write
     STATUS	current
     DESCRIPTION
-	"The maximum number of entires that this bridge can
+	"The maximum number of entries that this bridge can
 	learn in it's Forwarding Address Table and use for
 	making forwarding decisions."
     ::= { begemotBridgeTpEntry 3 }

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:08:21 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E281AC84616;
 Mon, 26 Dec 2016 06:08:21 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A34F1142A;
 Mon, 26 Dec 2016 06:08:21 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ68K6M033830;
 Mon, 26 Dec 2016 06:08:20 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ68KUu033829;
 Mon, 26 Dec 2016 06:08:20 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260608.uBQ68KUu033829@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:08:20 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310565 - stable/11/contrib/bsnmp/lib
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:08:22 -0000

Author: ngie
Date: Mon Dec 26 06:08:20 2016
New Revision: 310565
URL: https://svnweb.freebsd.org/changeset/base/310565

Log:
  MFC r310202:
  
  Clean up trailing and leading whitespace
  
  Fix variable type alignment in snmp_dialog(..)

Modified:
  stable/11/contrib/bsnmp/lib/snmpclient.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/bsnmp/lib/snmpclient.c
==============================================================================
--- stable/11/contrib/bsnmp/lib/snmpclient.c	Mon Dec 26 06:06:55 2016	(r310564)
+++ stable/11/contrib/bsnmp/lib/snmpclient.c	Mon Dec 26 06:08:20 2016	(r310565)
@@ -8,7 +8,7 @@
  *
  * Author: Harti Brandt <harti@freebsd.org>
  *         Kendy Kutzner
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -17,7 +17,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -1236,23 +1236,23 @@ snmp_send_packet(struct snmp_pdu * pdu)
 		return (-1);
 	}
 
-        pdu->request_id = snmp_next_reqid(&snmp_client);
+	pdu->request_id = snmp_next_reqid(&snmp_client);
 
-        b.asn_ptr = buf; 
-        b.asn_len = snmp_client.txbuflen;
-        if (snmp_pdu_encode(pdu, &b)) {
+	b.asn_ptr = buf;
+	b.asn_len = snmp_client.txbuflen;
+	if (snmp_pdu_encode(pdu, &b)) {
 		seterr(&snmp_client, "%s", strerror(errno));
 		free(buf);
 		return (-1);
 	}
 
-        if (snmp_client.dump_pdus)
-                snmp_pdu_dump(pdu);
+	if (snmp_client.dump_pdus)
+		snmp_pdu_dump(pdu);
 
-        if ((ret = send(snmp_client.fd, buf, b.asn_ptr - buf, 0)) == -1) {
+	if ((ret = send(snmp_client.fd, buf, b.asn_ptr - buf, 0)) == -1) {
 		seterr(&snmp_client, "%s", strerror(errno));
 		free(buf);
-                return (-1);
+		return (-1);
 	}
 	free(buf);
 
@@ -1269,7 +1269,7 @@ snmp_timeout(void * listentry_ptr)
 
 #if 0
 	warnx("snmp request %i timed out, attempt (%i/%i)",
-	    listentry->reqid, listentry->retrycount, snmp_client.retries); 
+	    listentry->reqid, listentry->retrycount, snmp_client.retries);
 #endif
 
 	listentry->retrycount++;
@@ -1314,7 +1314,7 @@ snmp_pdu_send(struct snmp_pdu *pdu, snmp
 	listentry->callback = func;
 	listentry->arg = arg;
 	listentry->retrycount=1;
-	listentry->timeout_id = 
+	listentry->timeout_id =
 	    snmp_client.timeout_start(&snmp_client.timeout, snmp_timeout,
 	    listentry);
 
@@ -1463,7 +1463,7 @@ snmp_receive_packet(struct snmp_pdu *pdu
 	return (+1);
 }
 
-static int 
+static int
 snmp_deliver_packet(struct snmp_pdu * resp)
 {
 	struct sent_pdu *listentry;
@@ -1548,7 +1548,7 @@ ok_getnext(const struct snmp_pdu * req, 
 		    &resp->bindings[i].var)) {
 			if (i != 0)
 				warnx("SNMP GETNEXT: inconsistent table "
-				      "response");
+				    "response");
 			return (0);
 		}
 		if (resp->version != SNMP_V1 &&
@@ -1654,7 +1654,7 @@ ok_set(const struct snmp_pdu * req, cons
 
 /*
  * Simple checks for response PDUs against request PDUs. Return values: 1=ok,
- * 0=nosuchname or similar, -1=failure, -2=no response at all 
+ * 0=nosuchname or similar, -1=failure, -2=no response at all
  */
 int
 snmp_pdu_check(const struct snmp_pdu *req,
@@ -1681,12 +1681,12 @@ snmp_pdu_check(const struct snmp_pdu *re
 int
 snmp_dialog(struct snmp_v1_pdu *req, struct snmp_v1_pdu *resp)
 {
-        u_int i;
-        int32_t reqid;
-	int ret;
-        struct timeval tv = snmp_client.timeout;
+	struct timeval tv = snmp_client.timeout;
 	struct timeval end;
 	struct snmp_pdu pdu;
+	u_int i;
+	int32_t reqid;
+	int ret;
 
 	/*
 	 * Make a copy of the request and replace the syntaxes by NULL
@@ -1698,11 +1698,11 @@ snmp_dialog(struct snmp_v1_pdu *req, str
 		for (i = 0; i < pdu.nbindings; i++)
 			pdu.bindings[i].syntax = SNMP_SYNTAX_NULL;
 	}
-	
-        for (i = 0; i <= snmp_client.retries; i++) {
+
+	for (i = 0; i <= snmp_client.retries; i++) {
 		(void)gettimeofday(&end, NULL);
 		timeradd(&end, &snmp_client.timeout, &end);
-                if ((reqid = snmp_send_packet(&pdu)) == -1)
+		if ((reqid = snmp_send_packet(&pdu)) == -1)
 			return (-1);
 		for (;;) {
 			(void)gettimeofday(&tv, NULL);
@@ -1717,16 +1717,16 @@ snmp_dialog(struct snmp_v1_pdu *req, str
 				if (reqid == resp->request_id)
 					return (0);
 				/* not for us */
-				(void)snmp_deliver_packet(resp);  
+				(void)snmp_deliver_packet(resp);
 			}
 			if (ret < 0 && errno == EPIPE)
 				/* stream closed */
 				return (-1);
 		}
-        }
+	}
 	errno = ETIMEDOUT;
 	seterr(&snmp_client, "retry count exceeded");
-        return (-1);
+	return (-1);
 }
 
 int

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:09:10 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 67774C84698;
 Mon, 26 Dec 2016 06:09:10 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 267C915D5;
 Mon, 26 Dec 2016 06:09:10 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ699oN033921;
 Mon, 26 Dec 2016 06:09:09 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ699rf033920;
 Mon, 26 Dec 2016 06:09:09 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260609.uBQ699rf033920@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:09:09 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310566 - stable/10/contrib/bsnmp/lib
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:09:10 -0000

Author: ngie
Date: Mon Dec 26 06:09:09 2016
New Revision: 310566
URL: https://svnweb.freebsd.org/changeset/base/310566

Log:
  MFstable/11 r310565:
  
  MFC r310202:
  
  Clean up trailing and leading whitespace
  
  Fix variable type alignment in snmp_dialog(..)

Modified:
  stable/10/contrib/bsnmp/lib/snmpclient.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/bsnmp/lib/snmpclient.c
==============================================================================
--- stable/10/contrib/bsnmp/lib/snmpclient.c	Mon Dec 26 06:08:20 2016	(r310565)
+++ stable/10/contrib/bsnmp/lib/snmpclient.c	Mon Dec 26 06:09:09 2016	(r310566)
@@ -8,7 +8,7 @@
  *
  * Author: Harti Brandt <harti@freebsd.org>
  *         Kendy Kutzner
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -17,7 +17,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -1236,23 +1236,23 @@ snmp_send_packet(struct snmp_pdu * pdu)
 		return (-1);
 	}
 
-        pdu->request_id = snmp_next_reqid(&snmp_client);
+	pdu->request_id = snmp_next_reqid(&snmp_client);
 
-        b.asn_ptr = buf; 
-        b.asn_len = snmp_client.txbuflen;
-        if (snmp_pdu_encode(pdu, &b)) {
+	b.asn_ptr = buf;
+	b.asn_len = snmp_client.txbuflen;
+	if (snmp_pdu_encode(pdu, &b)) {
 		seterr(&snmp_client, "%s", strerror(errno));
 		free(buf);
 		return (-1);
 	}
 
-        if (snmp_client.dump_pdus)
-                snmp_pdu_dump(pdu);
+	if (snmp_client.dump_pdus)
+		snmp_pdu_dump(pdu);
 
-        if ((ret = send(snmp_client.fd, buf, b.asn_ptr - buf, 0)) == -1) {
+	if ((ret = send(snmp_client.fd, buf, b.asn_ptr - buf, 0)) == -1) {
 		seterr(&snmp_client, "%s", strerror(errno));
 		free(buf);
-                return (-1);
+		return (-1);
 	}
 	free(buf);
 
@@ -1269,7 +1269,7 @@ snmp_timeout(void * listentry_ptr)
 
 #if 0
 	warnx("snmp request %i timed out, attempt (%i/%i)",
-	    listentry->reqid, listentry->retrycount, snmp_client.retries); 
+	    listentry->reqid, listentry->retrycount, snmp_client.retries);
 #endif
 
 	listentry->retrycount++;
@@ -1314,7 +1314,7 @@ snmp_pdu_send(struct snmp_pdu *pdu, snmp
 	listentry->callback = func;
 	listentry->arg = arg;
 	listentry->retrycount=1;
-	listentry->timeout_id = 
+	listentry->timeout_id =
 	    snmp_client.timeout_start(&snmp_client.timeout, snmp_timeout,
 	    listentry);
 
@@ -1463,7 +1463,7 @@ snmp_receive_packet(struct snmp_pdu *pdu
 	return (+1);
 }
 
-static int 
+static int
 snmp_deliver_packet(struct snmp_pdu * resp)
 {
 	struct sent_pdu *listentry;
@@ -1548,7 +1548,7 @@ ok_getnext(const struct snmp_pdu * req, 
 		    &resp->bindings[i].var)) {
 			if (i != 0)
 				warnx("SNMP GETNEXT: inconsistent table "
-				      "response");
+				    "response");
 			return (0);
 		}
 		if (resp->version != SNMP_V1 &&
@@ -1654,7 +1654,7 @@ ok_set(const struct snmp_pdu * req, cons
 
 /*
  * Simple checks for response PDUs against request PDUs. Return values: 1=ok,
- * 0=nosuchname or similar, -1=failure, -2=no response at all 
+ * 0=nosuchname or similar, -1=failure, -2=no response at all
  */
 int
 snmp_pdu_check(const struct snmp_pdu *req,
@@ -1681,12 +1681,12 @@ snmp_pdu_check(const struct snmp_pdu *re
 int
 snmp_dialog(struct snmp_v1_pdu *req, struct snmp_v1_pdu *resp)
 {
-        u_int i;
-        int32_t reqid;
-	int ret;
-        struct timeval tv = snmp_client.timeout;
+	struct timeval tv = snmp_client.timeout;
 	struct timeval end;
 	struct snmp_pdu pdu;
+	u_int i;
+	int32_t reqid;
+	int ret;
 
 	/*
 	 * Make a copy of the request and replace the syntaxes by NULL
@@ -1698,11 +1698,11 @@ snmp_dialog(struct snmp_v1_pdu *req, str
 		for (i = 0; i < pdu.nbindings; i++)
 			pdu.bindings[i].syntax = SNMP_SYNTAX_NULL;
 	}
-	
-        for (i = 0; i <= snmp_client.retries; i++) {
+
+	for (i = 0; i <= snmp_client.retries; i++) {
 		(void)gettimeofday(&end, NULL);
 		timeradd(&end, &snmp_client.timeout, &end);
-                if ((reqid = snmp_send_packet(&pdu)) == -1)
+		if ((reqid = snmp_send_packet(&pdu)) == -1)
 			return (-1);
 		for (;;) {
 			(void)gettimeofday(&tv, NULL);
@@ -1717,16 +1717,16 @@ snmp_dialog(struct snmp_v1_pdu *req, str
 				if (reqid == resp->request_id)
 					return (0);
 				/* not for us */
-				(void)snmp_deliver_packet(resp);  
+				(void)snmp_deliver_packet(resp);
 			}
 			if (ret < 0 && errno == EPIPE)
 				/* stream closed */
 				return (-1);
 		}
-        }
+	}
 	errno = ETIMEDOUT;
 	seterr(&snmp_client, "retry count exceeded");
-        return (-1);
+	return (-1);
 }
 
 int

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:10:22 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id AD2AFC84721;
 Mon, 26 Dec 2016 06:10:22 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 78F4F1733;
 Mon, 26 Dec 2016 06:10:22 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6ALjk034042;
 Mon, 26 Dec 2016 06:10:21 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6ALHc034041;
 Mon, 26 Dec 2016 06:10:21 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260610.uBQ6ALHc034041@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:10:21 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310567 - stable/11/etc
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:10:22 -0000

Author: ngie
Date: Mon Dec 26 06:10:21 2016
New Revision: 310567
URL: https://svnweb.freebsd.org/changeset/base/310567

Log:
  MFC r310457:
  
  Clean up trailing whitespace
  
  No functional change

Modified:
  stable/11/etc/snmpd.config
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/etc/snmpd.config
==============================================================================
--- stable/11/etc/snmpd.config	Mon Dec 26 06:09:09 2016	(r310566)
+++ stable/11/etc/snmpd.config	Mon Dec 26 06:10:21 2016	(r310567)
@@ -127,7 +127,7 @@ snmpEnableAuthenTraps = 2
 # The following block creates a user with name "bsnmp" and sets privacy
 # and encryption options to SHA256 message digests and AES encryption
 # for this user.
-# 
+#
 # usmUserStatus.$(engine).$(user1) = 5
 # usmUserAuthProtocol.$(engine).$(user1) = $(HMACSHAAuthProtocol)
 # usmUserAuthKeyChange.$(engine).$(user1) = $(user1passwd)
@@ -170,7 +170,7 @@ snmpEnableAuthenTraps = 2
 # vacmSecurityToGroupStatus.$(securityModelUSM).$(read) = 4
 # vacmGroupName.$(securityModelUSM).$(read) = $(write)
 
-# 
+#
 # The OID of the .iso.org.dod.internet subtree
 #
 # internetoid := 1.3.6.1
@@ -193,7 +193,7 @@ snmpEnableAuthenTraps = 2
 # vacmAccessReadViewName.$(read)."".$(securityModelSNMPv1).$(noAuthNoPriv) = "internet"
 
 #
-# Read-write access for SNMPv2 users 
+# Read-write access for SNMPv2 users
 #
 # vacmAccessStatus.$(write)."".$(securityModelSNMPv2c).$(noAuthNoPriv) = 4
 # vacmAccessReadViewName.$(write)."".$(securityModelSNMPv2c).$(noAuthNoPriv) = "internet"

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:11:44 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E7A51C84795;
 Mon, 26 Dec 2016 06:11:44 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B706D19B0;
 Mon, 26 Dec 2016 06:11:44 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6BhXI034833;
 Mon, 26 Dec 2016 06:11:43 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6Bhs6034832;
 Mon, 26 Dec 2016 06:11:43 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260611.uBQ6Bhs6034832@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:11:43 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310568 - stable/10/etc
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:11:45 -0000

Author: ngie
Date: Mon Dec 26 06:11:43 2016
New Revision: 310568
URL: https://svnweb.freebsd.org/changeset/base/310568

Log:
  MFstable/11 r310567:
  
  MFC r310457:
  
  Clean up trailing whitespace
  
  No functional change

Modified:
  stable/10/etc/snmpd.config
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/etc/snmpd.config
==============================================================================
--- stable/10/etc/snmpd.config	Mon Dec 26 06:10:21 2016	(r310567)
+++ stable/10/etc/snmpd.config	Mon Dec 26 06:11:43 2016	(r310568)
@@ -127,7 +127,7 @@ snmpEnableAuthenTraps = 2
 # The following block creates a user with name "bsnmp" and sets privacy
 # and encryption options to SHA256 message digests and AES encryption
 # for this user.
-# 
+#
 # usmUserStatus.$(engine).$(user1) = 5
 # usmUserAuthProtocol.$(engine).$(user1) = $(HMACSHAAuthProtocol)
 # usmUserAuthKeyChange.$(engine).$(user1) = $(user1passwd)
@@ -170,7 +170,7 @@ snmpEnableAuthenTraps = 2
 # vacmSecurityToGroupStatus.$(securityModelUSM).$(read) = 4
 # vacmGroupName.$(securityModelUSM).$(read) = $(write)
 
-# 
+#
 # The OID of the .iso.org.dod.internet subtree
 #
 # internetoid := 1.3.6.1
@@ -193,7 +193,7 @@ snmpEnableAuthenTraps = 2
 # vacmAccessReadViewName.$(read)."".$(securityModelSNMPv1).$(noAuthNoPriv) = "internet"
 
 #
-# Read-write access for SNMPv2 users 
+# Read-write access for SNMPv2 users
 #
 # vacmAccessStatus.$(write)."".$(securityModelSNMPv2c).$(noAuthNoPriv) = 4
 # vacmAccessReadViewName.$(write)."".$(securityModelSNMPv2c).$(noAuthNoPriv) = "internet"

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:16:32 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1455FC849A3;
 Mon, 26 Dec 2016 06:16:32 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A581D1CF0;
 Mon, 26 Dec 2016 06:16:31 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6GUdY037904;
 Mon, 26 Dec 2016 06:16:30 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6GS1x037876;
 Mon, 26 Dec 2016 06:16:28 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260616.uBQ6GS1x037876@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:16:28 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310569 - in stable/11/contrib/libarchive: cpio/test
 libarchive/test tar/test
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:16:32 -0000

Author: ngie
Date: Mon Dec 26 06:16:27 2016
New Revision: 310569
URL: https://svnweb.freebsd.org/changeset/base/310569

Log:
  MFC r309869:
  
  Merge changes from vendor to address several Coverity issues with
  contrib/libarchive's tests
  
  Obtained from:	libarchive (ebe29c, fd0ea2, f9e3de)

Modified:
  stable/11/contrib/libarchive/cpio/test/test_option_J_upper.c
  stable/11/contrib/libarchive/cpio/test/test_option_Z_upper.c
  stable/11/contrib/libarchive/cpio/test/test_option_u.c
  stable/11/contrib/libarchive/cpio/test/test_option_y.c
  stable/11/contrib/libarchive/libarchive/test/read_open_memory.c
  stable/11/contrib/libarchive/libarchive/test/test_fuzz.c
  stable/11/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
  stable/11/contrib/libarchive/libarchive/test/test_read_set_format.c
  stable/11/contrib/libarchive/tar/test/main.c
  stable/11/contrib/libarchive/tar/test/test_leading_slash.c
  stable/11/contrib/libarchive/tar/test/test_option_a.c
  stable/11/contrib/libarchive/tar/test/test_option_b.c
  stable/11/contrib/libarchive/tar/test/test_option_b64encode.c
  stable/11/contrib/libarchive/tar/test/test_option_gid_gname.c
  stable/11/contrib/libarchive/tar/test/test_option_grzip.c
  stable/11/contrib/libarchive/tar/test/test_option_j.c
  stable/11/contrib/libarchive/tar/test/test_option_lrzip.c
  stable/11/contrib/libarchive/tar/test/test_option_lz4.c
  stable/11/contrib/libarchive/tar/test/test_option_lzma.c
  stable/11/contrib/libarchive/tar/test/test_option_lzop.c
  stable/11/contrib/libarchive/tar/test/test_option_r.c
  stable/11/contrib/libarchive/tar/test/test_option_uid_uname.c
  stable/11/contrib/libarchive/tar/test/test_option_uuencode.c
  stable/11/contrib/libarchive/tar/test/test_option_xz.c
  stable/11/contrib/libarchive/tar/test/test_option_z.c
  stable/11/contrib/libarchive/tar/test/test_stdio.c
  stable/11/contrib/libarchive/tar/test/test_version.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/libarchive/cpio/test/test_option_J_upper.c
==============================================================================
--- stable/11/contrib/libarchive/cpio/test/test_option_J_upper.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/cpio/test/test_option_J_upper.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -47,10 +47,13 @@ DEFINE_TEST(test_option_J_upper)
 		}
 		failure("-J option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an xz signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\3757zXZ", 5);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/cpio/test/test_option_Z_upper.c
==============================================================================
--- stable/11/contrib/libarchive/cpio/test/test_option_Z_upper.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/cpio/test/test_option_Z_upper.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -47,10 +47,13 @@ DEFINE_TEST(test_option_Z_upper)
 		}
 		failure("-Z option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has a compress signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x1f\x9d", 2);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/cpio/test/test_option_u.c
==============================================================================
--- stable/11/contrib/libarchive/cpio/test/test_option_u.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/cpio/test/test_option_u.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -49,6 +49,7 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "a", 1);
+	free(p);
 
 	/* Recreate the file with a single "b" */
 	assertMakeFile("f", 0644, "b");
@@ -68,6 +69,7 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "a", 1);
+	free(p);
 
 	/* Copy the file to the "copy" dir with -u (force) */
 	r = systemf("echo f| %s -pud copy >copy.out 2>copy.err",
@@ -78,4 +80,5 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "b", 1);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/cpio/test/test_option_y.c
==============================================================================
--- stable/11/contrib/libarchive/cpio/test/test_option_y.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/cpio/test/test_option_y.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -46,11 +46,14 @@ DEFINE_TEST(test_option_y)
 		}
 		failure("-y option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
 	assertTextFileContents("1 block\n", "archive.err");
 	/* Check that the archive file has a bzip2 signature. */
+	free(p);
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "BZh9", 4);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/libarchive/test/read_open_memory.c
==============================================================================
--- stable/11/contrib/libarchive/libarchive/test/read_open_memory.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/libarchive/test/read_open_memory.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -86,21 +86,7 @@ static int
 read_open_memory_internal(struct archive *a, const void *buff,
     size_t size, size_t read_size, int level)
 {
-	struct read_memory_data *mine;
-
-	mine = (struct read_memory_data *)malloc(sizeof(*mine));
-	if (mine == NULL) {
-		archive_set_error(a, ENOMEM, "No memory");
-		return (ARCHIVE_FATAL);
-	}
-	memset(mine, 0, sizeof(*mine));
-	mine->start = mine->p = (const unsigned char *)buff;
-	mine->end = mine->start + size;
-	mine->read_size = read_size;
-	mine->copy_buff_offset = 32;
-	mine->copy_buff_size = read_size + mine->copy_buff_offset * 2;
-	mine->copy_buff = malloc(mine->copy_buff_size);
-	memset(mine->copy_buff, 0xA5, mine->copy_buff_size);
+	struct read_memory_data *mine = NULL;
 
 	switch (level) {
 	case 3:
@@ -109,6 +95,20 @@ read_open_memory_internal(struct archive
 		archive_read_set_open_callback(a, memory_read_open);
 		archive_read_set_skip_callback(a, memory_read_skip);
 	case 1:
+		mine = malloc(sizeof(*mine));
+		if (mine == NULL) {
+			archive_set_error(a, ENOMEM, "No memory");
+			return (ARCHIVE_FATAL);
+		}
+		memset(mine, 0, sizeof(*mine));
+		mine->start = mine->p = (const unsigned char *)buff;
+		mine->end = mine->start + size;
+		mine->read_size = read_size;
+		mine->copy_buff_offset = 32;
+		mine->copy_buff_size = read_size + mine->copy_buff_offset * 2;
+		mine->copy_buff = malloc(mine->copy_buff_size);
+		memset(mine->copy_buff, 0xA5, mine->copy_buff_size);
+
 		archive_read_set_read_callback(a, memory_read);
 		archive_read_set_close_callback(a, memory_read_close);
 		archive_read_set_callback_data(a, mine);
@@ -213,7 +213,8 @@ memory_read_close(struct archive *a, voi
 {
 	struct read_memory_data *mine = (struct read_memory_data *)client_data;
 	(void)a; /* UNUSED */
-	free(mine->copy_buff);
+	if (mine != NULL)
+		free(mine->copy_buff);
 	free(mine);
 	return (ARCHIVE_OK);
 }

Modified: stable/11/contrib/libarchive/libarchive/test/test_fuzz.c
==============================================================================
--- stable/11/contrib/libarchive/libarchive/test/test_fuzz.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/libarchive/test/test_fuzz.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -104,16 +104,19 @@ test_fuzz(const struct files *filesets)
 			}
 			if (!assert(size < buffsize)) {
 				free(rawimage);
+				rawimage = NULL;
 				continue;
 			}
 		} else {
 			for (i = 0; filesets[n].names[i] != NULL; ++i)
 			{
 				tmp = slurpfile(&size, filesets[n].names[i]);
-				char *newraw = (char *)realloc(rawimage, oldsize + size);
+				char *newraw = realloc(rawimage, oldsize + size);
 				if (!assert(newraw != NULL))
 				{
 					free(rawimage);
+					rawimage = NULL;
+					free(tmp);
 					continue;
 				}
 				rawimage = newraw;
@@ -123,14 +126,21 @@ test_fuzz(const struct files *filesets)
 				free(tmp);
 			}
 		}
-		if (size == 0)
+		if (size == 0) {
+			free(rawimage);
+			rawimage = NULL;
 			continue;
+		}
 		image = malloc(size);
 		assert(image != NULL);
 		if (image == NULL) {
 			free(rawimage);
+			rawimage = NULL;
 			return;
 		}
+
+		assert(rawimage != NULL);
+
 		srand((unsigned)time(NULL));
 
 		for (i = 0; i < 1000; ++i) {
@@ -162,6 +172,7 @@ test_fuzz(const struct files *filesets)
 				Sleep(100);
 #endif
 			}
+			assert(f != NULL);
 			assertEqualInt((size_t)size, fwrite(image, 1, (size_t)size, f));
 			fclose(f);
 
@@ -195,7 +206,7 @@ test_fuzz(const struct files *filesets)
 				archive_read_close(a);
 			}
 			archive_read_free(a);
-}
+		}
 		free(image);
 		free(rawimage);
 	}

Modified: stable/11/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
==============================================================================
--- stable/11/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -1327,6 +1327,7 @@ test_callbacks(void)
 	if (assert((m = archive_match_new()) != NULL)) {
 		archive_entry_free(ae);
 		archive_read_free(a);
+		archive_match_free(m);
 		return;
 	}
 

Modified: stable/11/contrib/libarchive/libarchive/test/test_read_set_format.c
==============================================================================
--- stable/11/contrib/libarchive/libarchive/test/test_read_set_format.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/libarchive/test/test_read_set_format.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -219,8 +219,8 @@ DEFINE_TEST(test_read_append_filter_wron
   /* bunzip2 will write to stderr, redirect it to a file */
   fflush(stderr);
   fgetpos(stderr, &pos);
-  fd = dup(fileno(stderr));
-  fp = freopen("stderr1", "w", stderr); 
+  assert((fd = dup(fileno(stderr))) != -1);
+  fp = freopen("stderr1", "w", stderr);
 #endif
 
   assert((a = archive_read_new()) != NULL);
@@ -238,10 +238,10 @@ DEFINE_TEST(test_read_append_filter_wron
   if (fp != NULL) {
     fflush(stderr);
     dup2(fd, fileno(stderr));
-    close(fd);
     clearerr(stderr);
-    fsetpos(stderr, &pos);
+    (void)fsetpos(stderr, &pos);
   }
+  close(fd);
   assertTextFileContents("bunzip2: (stdin) is not a bzip2 file.\n", "stderr1");
 #endif
 }

Modified: stable/11/contrib/libarchive/tar/test/main.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/main.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/main.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -1060,7 +1060,7 @@ assertion_file_contains_lines_any_order(
 	char **expected = NULL;
 	char *p, **actual = NULL;
 	char c;
-	int expected_failure = 0, actual_failure = 0;
+	int expected_failure = 0, actual_failure = 0, retval = 0;
 
 	assertion_count(file, line);
 
@@ -1081,8 +1081,7 @@ assertion_file_contains_lines_any_order(
 		if (expected == NULL) {
 			failure_start(pathname, line, "Can't allocate memory");
 			failure_finish(NULL);
-			free(expected);
-			return (0);
+			goto done;
 		}
 		for (i = 0; lines[i] != NULL; ++i) {
 			expected[i] = strdup(lines[i]);
@@ -1103,8 +1102,7 @@ assertion_file_contains_lines_any_order(
 		if (actual == NULL) {
 			failure_start(pathname, line, "Can't allocate memory");
 			failure_finish(NULL);
-			free(expected);
-			return (0);
+			goto done;
 		}
 		for (j = 0, p = buff; p < buff + buff_size;
 		    p += 1 + strlen(p)) {
@@ -1141,27 +1139,27 @@ assertion_file_contains_lines_any_order(
 			++actual_failure;
 	}
 	if (expected_failure == 0 && actual_failure == 0) {
-		free(buff);
-		free(expected);
-		free(actual);
-		return (1);
+		retval = 1;
+		goto done;
 	}
 	failure_start(file, line, "File doesn't match: %s", pathname);
 	for (i = 0; i < expected_count; ++i) {
-		if (expected[i] != NULL) {
+		if (expected[i] != NULL)
 			logprintf("  Expected but not present: %s\n", expected[i]);
-			free(expected[i]);
-		}
 	}
 	for (j = 0; j < actual_count; ++j) {
 		if (actual[j] != NULL)
 			logprintf("  Present but not expected: %s\n", actual[j]);
 	}
 	failure_finish(NULL);
+done:
+	free(actual);
 	free(buff);
+	for (i = 0; i < expected_count; ++i)
+		free(expected[i]);
 	free(expected);
-	free(actual);
-	return (0);
+
+	return (retval);
 }
 
 /* Verify that a text file does not contains the specified strings */
@@ -1590,7 +1588,7 @@ is_symlink(const char *file, int line,
 	 * really not much point in bothering with this. */
 	return (0);
 #else
-	char buff[300];
+	char buff[301];
 	struct stat st;
 	ssize_t linklen;
 	int r;
@@ -1607,7 +1605,7 @@ is_symlink(const char *file, int line,
 		return (0);
 	if (contents == NULL)
 		return (1);
-	linklen = readlink(pathname, buff, sizeof(buff));
+	linklen = readlink(pathname, buff, sizeof(buff) - 1);
 	if (linklen < 0) {
 		failure_start(file, line, "Can't read symlink %s", pathname);
 		failure_finish(NULL);
@@ -2324,7 +2322,7 @@ extract_reference_file(const char *name)
 	for (;;) {
 		if (fgets(buff, sizeof(buff), in) == NULL) {
 			/* TODO: This is a failure. */
-			return;
+			goto done;
 		}
 		if (memcmp(buff, "begin ", 6) == 0)
 			break;
@@ -2365,6 +2363,7 @@ extract_reference_file(const char *name)
 		}
 	}
 	fclose(out);
+done:
 	fclose(in);
 }
 
@@ -2958,8 +2957,8 @@ main(int argc, char **argv)
 		strftime(tmpdir_timestamp, sizeof(tmpdir_timestamp),
 		    "%Y-%m-%dT%H.%M.%S",
 		    localtime(&now));
-		sprintf(tmpdir, "%s/%s.%s-%03d", tmp, progname,
-		    tmpdir_timestamp, i);
+		snprintf(tmpdir, sizeof(tmpdir), "%s/%s.%s-%03d", tmp,
+		    progname, tmpdir_timestamp, i);
 		if (assertMakeDir(tmpdir,0755))
 			break;
 		if (i >= 999) {

Modified: stable/11/contrib/libarchive/tar/test/test_leading_slash.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_leading_slash.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_leading_slash.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -44,6 +44,7 @@ DEFINE_TEST(test_leading_slash)
 	if (assertFileExists("test.err")) {
 		errfile = slurpfile(&errfile_size, "test.err");
 		assert(strstr(errfile, expected_errmsg) != NULL);
+		free(errfile);
 	}
 }
 

Modified: stable/11/contrib/libarchive/tar/test/test_option_a.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_a.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_a.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -43,6 +43,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test2: archive it with .taZ suffix. */
 	assertEqualInt(0,
@@ -53,6 +54,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test3: archive it with .tar.Z.uu suffix. */
 	assertEqualInt(0,
@@ -63,6 +65,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 12);
 	failure("The archive should be uuencoded");
 	assertEqualMem(p, "begin 644 -\n", 12);
+	free(p);
 
 	/* Test4: archive it with .zip suffix. */
 	assertEqualInt(0,
@@ -73,6 +76,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 4);
 	failure("The archive should be zipped");
 	assertEqualMem(p, "\x50\x4b\x03\x04", 4);
+	free(p);
 
 	/* Test5: archive it with .tar.Z suffix and --uuencode option. */
 	assertEqualInt(0,
@@ -84,6 +88,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed, ignoring --uuencode option");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test6: archive it with .xxx suffix(unknown suffix) and
 	 * --uuencode option. */
@@ -96,6 +101,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 12);
 	failure("The archive should be uuencoded");
 	assertEqualMem(p, "begin 644 -\n", 12);
+	free(p);
 
 	/* Test7: archive it with .tar.Z suffix using a long-name option. */
 	assertEqualInt(0,
@@ -107,4 +113,5 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_b.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_b.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_b.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -78,4 +78,6 @@ DEFINE_TEST(test_option_b)
 	 * Note: It's not possible to verify at this level that blocks
 	 * are getting written with the
 	 */
+
+	free(testprog_ustar);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_b64encode.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_b64encode.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_b64encode.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -42,6 +42,7 @@ DEFINE_TEST(test_option_b64encode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin-base64 644", 16);
+	free(p);
 
 	/* Archive it with uuencode only. */
 	assertEqualInt(0,
@@ -51,4 +52,5 @@ DEFINE_TEST(test_option_b64encode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin-base64 644", 16);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_gid_gname.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_gid_gname.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_gid_gname.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -53,6 +53,7 @@ DEFINE_TEST(test_option_gid_gname)
 	/* Should force gid and gname fields in ustar header. */
 	assertEqualMem(data + 116, "000021 \0", 8);
 	assertEqualMem(data + 297, "foofoofoo\0", 10);
+	free(data);
 
 	/* Again with just --gname */
 	failure("Error invoking %s c", testprog);
@@ -65,6 +66,8 @@ DEFINE_TEST(test_option_gid_gname)
 	/* Gid should be unchanged from original reference. */
 	assertEqualMem(data + 116, reference + 116, 8);
 	assertEqualMem(data + 297, "foofoofoo\0", 10);
+	free(data);
+	free(reference);
 
 	/* Again with --gid  and force gname to empty. */
 	failure("Error invoking %s c", testprog);
@@ -77,6 +80,7 @@ DEFINE_TEST(test_option_gid_gname)
 	assertEqualMem(data + 116, "000021 \0", 8);
 	/* Gname field in ustar header should be empty. */
 	assertEqualMem(data + 297, "\0", 1);
+	free(data);
 
 	/* TODO: It would be nice to verify that --gid= by itself
 	 * will look up the associated gname and use that, but

Modified: stable/11/contrib/libarchive/tar/test/test_option_grzip.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_grzip.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_grzip.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -45,8 +45,11 @@ DEFINE_TEST(test_option_grzip)
 	    testprog));
 	p = slurpfile(&s, "archive.err");
 	p[s] = '\0';
+	free(p);
+
 	/* Check that the archive file has an grzip signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "GRZipII\x00\x02\x04:)", 12);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_j.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_j.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_j.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -42,15 +42,18 @@ DEFINE_TEST(test_option_j)
 	if (r != 0) {
 		if (!canBzip2()) {
 			skipping("bzip2 is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("-j option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	assertEmptyFile("archive.err");
 	/* Check that the archive file has a bzip2 signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "BZh9", 4);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_lrzip.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_lrzip.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_lrzip.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -45,8 +45,10 @@ DEFINE_TEST(test_option_lrzip)
 	    testprog));
 	p = slurpfile(&s, "archive.err");
 	p[s] = '\0';
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "LRZI\x00", 5);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_lz4.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_lz4.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_lz4.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -43,7 +43,7 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Unsupported compression") != NULL) {
 			skipping("This version of bsdtar was compiled "
 			    "without lz4 support");
-			return;
+			goto done;
 		}
 		/* POSIX permits different handling of the spawnp
 		 * system call used to launch the subsidiary
@@ -52,7 +52,7 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Can't launch") != NULL && !canLz4()) {
 			skipping("This version of bsdtar uses an external lz4 program "
 			    "but no such program is available on this system.");
-			return;
+			goto done;
 		}
 		/* Some systems successfully spawn the new process,
 		 * but fail to exec a program within that process.
@@ -61,14 +61,18 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Can't write") != NULL && !canLz4()) {
 			skipping("This version of bsdtar uses an external lz4 program "
 			    "but no such program is available on this system.");
-			return;
+			goto done;
 		}
 		failure("--lz4 option is broken: %s", p);
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lz4 signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x04\x22\x4d\x18", 4);
+
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_lzma.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_lzma.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_lzma.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -48,10 +48,13 @@ DEFINE_TEST(test_option_lzma)
 		}
 		failure("--lzma option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x5d\00\00", 3);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_lzop.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_lzop.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_lzop.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -42,14 +42,17 @@ DEFINE_TEST(test_option_lzop)
 	if (r != 0) {
 		if (!canLzop()) {
 			skipping("lzop is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("--lzop option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x89\x4c\x5a\x4f\x00\x0d\x0a\x1a\x0a", 9);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_r.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_r.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_r.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -36,6 +36,10 @@ DEFINE_TEST(test_option_r)
 	size_t s, buff_size_rounded;
 	int r, i;
 
+	buff = NULL;
+	p0 = NULL;
+	p1 = NULL;
+
 	/* Create an archive with one file. */
 	assertMakeFile("f1", 0644, "abc");
 	r = systemf("%s cf archive.tar --format=ustar f1 >step1.out 2>step1.err", testprog);
@@ -47,11 +51,9 @@ DEFINE_TEST(test_option_r)
 	/* Do some basic validation of the constructed archive. */
 	p0 = slurpfile(&s, "archive.tar");
 	if (!assert(p0 != NULL))
-		return;
-	if (!assert(s >= 2048)) {
-		free(p0);
-		return;
-	}
+		goto done;
+	if (!assert(s >= 2048))
+		goto done;
 	assertEqualMem(p0 + 0, "f1", 3);
 	assertEqualMem(p0 + 512, "abc", 3);
 	assertEqualMem(p0 + 1024, "\0\0\0\0\0\0\0\0", 8);
@@ -60,10 +62,8 @@ DEFINE_TEST(test_option_r)
 	/* Edit that file with a lot more data and update the archive with a new copy. */
 	buff = malloc(buff_size);
 	assert(buff != NULL);
-	if (buff == NULL) {
-		free(p0);
-		return;
-	}
+	if (buff == NULL)
+		goto done;
 
 	for (i = 0; i < (int)buff_size; ++i)
 		buff[i] = "abcdefghijklmnopqrstuvwxyz"[rand() % 26];
@@ -77,10 +77,8 @@ DEFINE_TEST(test_option_r)
 
 	/* The constructed archive should just have the new entry appended. */
 	p1 = slurpfile(&s, "archive.tar");
-	if (!assert(p1 != NULL)) {
-		free(p0);
-		return;
-	}
+	if (!assert(p1 != NULL))
+		goto done;
 	buff_size_rounded = ((buff_size + 511) / 512) * 512;
 	assert(s >= 2560 + buff_size_rounded);
 	/* Verify first entry is unchanged. */
@@ -105,10 +103,8 @@ DEFINE_TEST(test_option_r)
 
 	/* Validate the constructed archive. */
 	p1 = slurpfile(&s, "archive.tar");
-	if (!assert(p1 != NULL)) {
-		free(p0);
-		return;
-	}
+	if (!assert(p1 != NULL))
+		goto done;
 	assert(s >= 3584 + buff_size_rounded);
 	/* Verify first two entries are unchanged. */
 	assertEqualMem(p0, p1, 1536 + buff_size_rounded);
@@ -118,7 +114,6 @@ DEFINE_TEST(test_option_r)
 	/* Verify end-of-archive marker. */
 	assertEqualMem(p1 + 2560 + buff_size_rounded, "\0\0\0\0\0\0\0\0", 8);
 	assertEqualMem(p1 + 3072 + buff_size_rounded, "\0\0\0\0\0\0\0\0", 8);
-	free(p0);
 	free(p1);
 
 	/* Unpack everything */
@@ -132,4 +127,7 @@ DEFINE_TEST(test_option_r)
 
 	/* Verify that the second copy of f1 overwrote the first. */
 	assertFileContents(buff, (int)strlen(buff), "f1");
+done:
+	free(buff);
+	free(p0);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_uid_uname.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_uid_uname.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_uid_uname.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -53,6 +53,7 @@ DEFINE_TEST(test_option_uid_uname)
 	/* Should force uid and uname fields in ustar header. */
 	assertEqualMem(data + 108, "000021 \0", 8);
 	assertEqualMem(data + 265, "foofoofoo\0", 10);
+	free(data);
 
 	/* Again with just --uid */
 	failure("Error invoking %s c", testprog);
@@ -65,6 +66,7 @@ DEFINE_TEST(test_option_uid_uname)
 	assertEqualMem(data + 108, "000021 \0", 8);
 	/* Uname field in ustar header should be empty. */
 	assertEqualMem(data + 265, "\0", 1);
+	free(data);
 
 	/* Again with just --uname */
 	failure("Error invoking %s c", testprog);
@@ -77,4 +79,7 @@ DEFINE_TEST(test_option_uid_uname)
 	/* Uid should be unchanged from original reference. */
 	assertEqualMem(data + 108, reference + 108, 8);
 	assertEqualMem(data + 265, "foofoofoo\0", 10);
+	free(data);
+
+	free(reference);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_uuencode.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_uuencode.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_uuencode.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -42,6 +42,7 @@ DEFINE_TEST(test_option_uuencode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin 644", 9);
+	free(p);
 
 	/* Archive it with uuencode only. */
 	assertEqualInt(0,
@@ -51,4 +52,5 @@ DEFINE_TEST(test_option_uuencode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin 644", 9);
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_xz.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_xz.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_xz.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -44,14 +44,17 @@ DEFINE_TEST(test_option_xz)
 		if (strstr(p, "Unsupported compression") != NULL) {
 			skipping("This version of bsdtar was compiled "
 			    "without xz support");
-			return;
+			goto done;
 		}
 		failure("--xz option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an xz signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\xFD\x37\x7A\x58\x5A\x00", 6);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_option_z.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_option_z.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_option_z.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -42,14 +42,17 @@ DEFINE_TEST(test_option_z)
 	if (r != 0) {
 		if (!canGzip()) {
 			skipping("gzip is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("-z option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has a gzip signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 4);
 	assertEqualMem(p, "\x1f\x8b\x08\x00", 4);
+done:
+	free(p);
 }

Modified: stable/11/contrib/libarchive/tar/test/test_stdio.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_stdio.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_stdio.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -116,6 +116,7 @@ DEFINE_TEST(test_stdio)
 	assertEqualInt((int)s, 3);
 	assertEqualMem(p, "abc", 3);
 	/* TODO: Verify xvf.err */
+	free(p);
 
 	/* 'xvf -' should generate list on stderr, empty stdout. */
 	r = systemf("%s xvf - < archive >xvf-.out 2>xvf-.err", testprog);

Modified: stable/11/contrib/libarchive/tar/test/test_version.c
==============================================================================
--- stable/11/contrib/libarchive/tar/test/test_version.c	Mon Dec 26 06:11:43 2016	(r310568)
+++ stable/11/contrib/libarchive/tar/test/test_version.c	Mon Dec 26 06:16:27 2016	(r310569)
@@ -53,7 +53,7 @@ DEFINE_TEST(test_version)
 	assert(s > 6);
 	failure("Version must start with 'bsdtar': ``%s''", p);
 	if (!assertEqualMem(q, "bsdtar ", 7))
-		return;
+		goto done;
 	q += 7; s -= 7;
 	/* Version number is a series of digits and periods. */
 	while (s > 0 && (*q == '.' || (*q >= '0' && *q <= '9'))) {
@@ -98,5 +98,6 @@ DEFINE_TEST(test_version)
 	failure("Version output must end with \\n or \\r\\n");
 	if (*q == '\r') { ++q; --s; }
 	assertEqualMem(q, "\n", 1);
+done:
 	free(p);
 }

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:25:43 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D5DBFC84CEF;
 Mon, 26 Dec 2016 06:25:43 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6CCCF1F5;
 Mon, 26 Dec 2016 06:25:43 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6Pgpl041783;
 Mon, 26 Dec 2016 06:25:42 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6Pd3l041756;
 Mon, 26 Dec 2016 06:25:39 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260625.uBQ6Pd3l041756@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:25:39 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310570 - in stable/10/contrib/libarchive: cpio/test
 libarchive/test tar/test
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:25:43 -0000

Author: ngie
Date: Mon Dec 26 06:25:39 2016
New Revision: 310570
URL: https://svnweb.freebsd.org/changeset/base/310570

Log:
  MFstable/11 r310569:
  
  MFC r309869:
  
  Merge changes from vendor to address several Coverity issues with
  contrib/libarchive's tests
  
  Obtained from:	libarchive (ebe29c, fd0ea2, f9e3de)

Modified:
  stable/10/contrib/libarchive/cpio/test/test_option_J_upper.c
  stable/10/contrib/libarchive/cpio/test/test_option_Z_upper.c
  stable/10/contrib/libarchive/cpio/test/test_option_u.c
  stable/10/contrib/libarchive/cpio/test/test_option_y.c
  stable/10/contrib/libarchive/libarchive/test/read_open_memory.c
  stable/10/contrib/libarchive/libarchive/test/test_fuzz.c
  stable/10/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
  stable/10/contrib/libarchive/libarchive/test/test_read_set_format.c
  stable/10/contrib/libarchive/tar/test/main.c
  stable/10/contrib/libarchive/tar/test/test_leading_slash.c
  stable/10/contrib/libarchive/tar/test/test_option_a.c
  stable/10/contrib/libarchive/tar/test/test_option_b.c
  stable/10/contrib/libarchive/tar/test/test_option_b64encode.c
  stable/10/contrib/libarchive/tar/test/test_option_gid_gname.c
  stable/10/contrib/libarchive/tar/test/test_option_grzip.c
  stable/10/contrib/libarchive/tar/test/test_option_j.c
  stable/10/contrib/libarchive/tar/test/test_option_lrzip.c
  stable/10/contrib/libarchive/tar/test/test_option_lz4.c
  stable/10/contrib/libarchive/tar/test/test_option_lzma.c
  stable/10/contrib/libarchive/tar/test/test_option_lzop.c
  stable/10/contrib/libarchive/tar/test/test_option_r.c
  stable/10/contrib/libarchive/tar/test/test_option_uid_uname.c
  stable/10/contrib/libarchive/tar/test/test_option_uuencode.c
  stable/10/contrib/libarchive/tar/test/test_option_xz.c
  stable/10/contrib/libarchive/tar/test/test_option_z.c
  stable/10/contrib/libarchive/tar/test/test_stdio.c
  stable/10/contrib/libarchive/tar/test/test_version.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/libarchive/cpio/test/test_option_J_upper.c
==============================================================================
--- stable/10/contrib/libarchive/cpio/test/test_option_J_upper.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/cpio/test/test_option_J_upper.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -47,10 +47,13 @@ DEFINE_TEST(test_option_J_upper)
 		}
 		failure("-J option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an xz signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\3757zXZ", 5);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/cpio/test/test_option_Z_upper.c
==============================================================================
--- stable/10/contrib/libarchive/cpio/test/test_option_Z_upper.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/cpio/test/test_option_Z_upper.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -47,10 +47,13 @@ DEFINE_TEST(test_option_Z_upper)
 		}
 		failure("-Z option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has a compress signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x1f\x9d", 2);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/cpio/test/test_option_u.c
==============================================================================
--- stable/10/contrib/libarchive/cpio/test/test_option_u.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/cpio/test/test_option_u.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -49,6 +49,7 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "a", 1);
+	free(p);
 
 	/* Recreate the file with a single "b" */
 	assertMakeFile("f", 0644, "b");
@@ -68,6 +69,7 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "a", 1);
+	free(p);
 
 	/* Copy the file to the "copy" dir with -u (force) */
 	r = systemf("echo f| %s -pud copy >copy.out 2>copy.err",
@@ -78,4 +80,5 @@ DEFINE_TEST(test_option_u)
 	p = slurpfile(&s, "copy/f");
 	assertEqualInt(s, 1);
 	assertEqualMem(p, "b", 1);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/cpio/test/test_option_y.c
==============================================================================
--- stable/10/contrib/libarchive/cpio/test/test_option_y.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/cpio/test/test_option_y.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -46,11 +46,14 @@ DEFINE_TEST(test_option_y)
 		}
 		failure("-y option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
 	assertTextFileContents("1 block\n", "archive.err");
 	/* Check that the archive file has a bzip2 signature. */
+	free(p);
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "BZh9", 4);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/libarchive/test/read_open_memory.c
==============================================================================
--- stable/10/contrib/libarchive/libarchive/test/read_open_memory.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/libarchive/test/read_open_memory.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -86,21 +86,7 @@ static int
 read_open_memory_internal(struct archive *a, const void *buff,
     size_t size, size_t read_size, int level)
 {
-	struct read_memory_data *mine;
-
-	mine = (struct read_memory_data *)malloc(sizeof(*mine));
-	if (mine == NULL) {
-		archive_set_error(a, ENOMEM, "No memory");
-		return (ARCHIVE_FATAL);
-	}
-	memset(mine, 0, sizeof(*mine));
-	mine->start = mine->p = (const unsigned char *)buff;
-	mine->end = mine->start + size;
-	mine->read_size = read_size;
-	mine->copy_buff_offset = 32;
-	mine->copy_buff_size = read_size + mine->copy_buff_offset * 2;
-	mine->copy_buff = malloc(mine->copy_buff_size);
-	memset(mine->copy_buff, 0xA5, mine->copy_buff_size);
+	struct read_memory_data *mine = NULL;
 
 	switch (level) {
 	case 3:
@@ -109,6 +95,20 @@ read_open_memory_internal(struct archive
 		archive_read_set_open_callback(a, memory_read_open);
 		archive_read_set_skip_callback(a, memory_read_skip);
 	case 1:
+		mine = malloc(sizeof(*mine));
+		if (mine == NULL) {
+			archive_set_error(a, ENOMEM, "No memory");
+			return (ARCHIVE_FATAL);
+		}
+		memset(mine, 0, sizeof(*mine));
+		mine->start = mine->p = (const unsigned char *)buff;
+		mine->end = mine->start + size;
+		mine->read_size = read_size;
+		mine->copy_buff_offset = 32;
+		mine->copy_buff_size = read_size + mine->copy_buff_offset * 2;
+		mine->copy_buff = malloc(mine->copy_buff_size);
+		memset(mine->copy_buff, 0xA5, mine->copy_buff_size);
+
 		archive_read_set_read_callback(a, memory_read);
 		archive_read_set_close_callback(a, memory_read_close);
 		archive_read_set_callback_data(a, mine);
@@ -213,7 +213,8 @@ memory_read_close(struct archive *a, voi
 {
 	struct read_memory_data *mine = (struct read_memory_data *)client_data;
 	(void)a; /* UNUSED */
-	free(mine->copy_buff);
+	if (mine != NULL)
+		free(mine->copy_buff);
 	free(mine);
 	return (ARCHIVE_OK);
 }

Modified: stable/10/contrib/libarchive/libarchive/test/test_fuzz.c
==============================================================================
--- stable/10/contrib/libarchive/libarchive/test/test_fuzz.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/libarchive/test/test_fuzz.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -104,16 +104,19 @@ test_fuzz(const struct files *filesets)
 			}
 			if (!assert(size < buffsize)) {
 				free(rawimage);
+				rawimage = NULL;
 				continue;
 			}
 		} else {
 			for (i = 0; filesets[n].names[i] != NULL; ++i)
 			{
 				tmp = slurpfile(&size, filesets[n].names[i]);
-				char *newraw = (char *)realloc(rawimage, oldsize + size);
+				char *newraw = realloc(rawimage, oldsize + size);
 				if (!assert(newraw != NULL))
 				{
 					free(rawimage);
+					rawimage = NULL;
+					free(tmp);
 					continue;
 				}
 				rawimage = newraw;
@@ -123,14 +126,21 @@ test_fuzz(const struct files *filesets)
 				free(tmp);
 			}
 		}
-		if (size == 0)
+		if (size == 0) {
+			free(rawimage);
+			rawimage = NULL;
 			continue;
+		}
 		image = malloc(size);
 		assert(image != NULL);
 		if (image == NULL) {
 			free(rawimage);
+			rawimage = NULL;
 			return;
 		}
+
+		assert(rawimage != NULL);
+
 		srand((unsigned)time(NULL));
 
 		for (i = 0; i < 1000; ++i) {
@@ -162,6 +172,7 @@ test_fuzz(const struct files *filesets)
 				Sleep(100);
 #endif
 			}
+			assert(f != NULL);
 			assertEqualInt((size_t)size, fwrite(image, 1, (size_t)size, f));
 			fclose(f);
 
@@ -195,7 +206,7 @@ test_fuzz(const struct files *filesets)
 				archive_read_close(a);
 			}
 			archive_read_free(a);
-}
+		}
 		free(image);
 		free(rawimage);
 	}

Modified: stable/10/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
==============================================================================
--- stable/10/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -1327,6 +1327,7 @@ test_callbacks(void)
 	if (assert((m = archive_match_new()) != NULL)) {
 		archive_entry_free(ae);
 		archive_read_free(a);
+		archive_match_free(m);
 		return;
 	}
 

Modified: stable/10/contrib/libarchive/libarchive/test/test_read_set_format.c
==============================================================================
--- stable/10/contrib/libarchive/libarchive/test/test_read_set_format.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/libarchive/test/test_read_set_format.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -219,8 +219,8 @@ DEFINE_TEST(test_read_append_filter_wron
   /* bunzip2 will write to stderr, redirect it to a file */
   fflush(stderr);
   fgetpos(stderr, &pos);
-  fd = dup(fileno(stderr));
-  fp = freopen("stderr1", "w", stderr); 
+  assert((fd = dup(fileno(stderr))) != -1);
+  fp = freopen("stderr1", "w", stderr);
 #endif
 
   assert((a = archive_read_new()) != NULL);
@@ -238,10 +238,10 @@ DEFINE_TEST(test_read_append_filter_wron
   if (fp != NULL) {
     fflush(stderr);
     dup2(fd, fileno(stderr));
-    close(fd);
     clearerr(stderr);
-    fsetpos(stderr, &pos);
+    (void)fsetpos(stderr, &pos);
   }
+  close(fd);
   assertTextFileContents("bunzip2: (stdin) is not a bzip2 file.\n", "stderr1");
 #endif
 }

Modified: stable/10/contrib/libarchive/tar/test/main.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/main.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/main.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -1060,7 +1060,7 @@ assertion_file_contains_lines_any_order(
 	char **expected = NULL;
 	char *p, **actual = NULL;
 	char c;
-	int expected_failure = 0, actual_failure = 0;
+	int expected_failure = 0, actual_failure = 0, retval = 0;
 
 	assertion_count(file, line);
 
@@ -1081,8 +1081,7 @@ assertion_file_contains_lines_any_order(
 		if (expected == NULL) {
 			failure_start(pathname, line, "Can't allocate memory");
 			failure_finish(NULL);
-			free(expected);
-			return (0);
+			goto done;
 		}
 		for (i = 0; lines[i] != NULL; ++i) {
 			expected[i] = strdup(lines[i]);
@@ -1103,8 +1102,7 @@ assertion_file_contains_lines_any_order(
 		if (actual == NULL) {
 			failure_start(pathname, line, "Can't allocate memory");
 			failure_finish(NULL);
-			free(expected);
-			return (0);
+			goto done;
 		}
 		for (j = 0, p = buff; p < buff + buff_size;
 		    p += 1 + strlen(p)) {
@@ -1141,27 +1139,27 @@ assertion_file_contains_lines_any_order(
 			++actual_failure;
 	}
 	if (expected_failure == 0 && actual_failure == 0) {
-		free(buff);
-		free(expected);
-		free(actual);
-		return (1);
+		retval = 1;
+		goto done;
 	}
 	failure_start(file, line, "File doesn't match: %s", pathname);
 	for (i = 0; i < expected_count; ++i) {
-		if (expected[i] != NULL) {
+		if (expected[i] != NULL)
 			logprintf("  Expected but not present: %s\n", expected[i]);
-			free(expected[i]);
-		}
 	}
 	for (j = 0; j < actual_count; ++j) {
 		if (actual[j] != NULL)
 			logprintf("  Present but not expected: %s\n", actual[j]);
 	}
 	failure_finish(NULL);
+done:
+	free(actual);
 	free(buff);
+	for (i = 0; i < expected_count; ++i)
+		free(expected[i]);
 	free(expected);
-	free(actual);
-	return (0);
+
+	return (retval);
 }
 
 /* Verify that a text file does not contains the specified strings */
@@ -1590,7 +1588,7 @@ is_symlink(const char *file, int line,
 	 * really not much point in bothering with this. */
 	return (0);
 #else
-	char buff[300];
+	char buff[301];
 	struct stat st;
 	ssize_t linklen;
 	int r;
@@ -1607,7 +1605,7 @@ is_symlink(const char *file, int line,
 		return (0);
 	if (contents == NULL)
 		return (1);
-	linklen = readlink(pathname, buff, sizeof(buff));
+	linklen = readlink(pathname, buff, sizeof(buff) - 1);
 	if (linklen < 0) {
 		failure_start(file, line, "Can't read symlink %s", pathname);
 		failure_finish(NULL);
@@ -2324,7 +2322,7 @@ extract_reference_file(const char *name)
 	for (;;) {
 		if (fgets(buff, sizeof(buff), in) == NULL) {
 			/* TODO: This is a failure. */
-			return;
+			goto done;
 		}
 		if (memcmp(buff, "begin ", 6) == 0)
 			break;
@@ -2365,6 +2363,7 @@ extract_reference_file(const char *name)
 		}
 	}
 	fclose(out);
+done:
 	fclose(in);
 }
 
@@ -2958,8 +2957,8 @@ main(int argc, char **argv)
 		strftime(tmpdir_timestamp, sizeof(tmpdir_timestamp),
 		    "%Y-%m-%dT%H.%M.%S",
 		    localtime(&now));
-		sprintf(tmpdir, "%s/%s.%s-%03d", tmp, progname,
-		    tmpdir_timestamp, i);
+		snprintf(tmpdir, sizeof(tmpdir), "%s/%s.%s-%03d", tmp,
+		    progname, tmpdir_timestamp, i);
 		if (assertMakeDir(tmpdir,0755))
 			break;
 		if (i >= 999) {

Modified: stable/10/contrib/libarchive/tar/test/test_leading_slash.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_leading_slash.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_leading_slash.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -44,6 +44,7 @@ DEFINE_TEST(test_leading_slash)
 	if (assertFileExists("test.err")) {
 		errfile = slurpfile(&errfile_size, "test.err");
 		assert(strstr(errfile, expected_errmsg) != NULL);
+		free(errfile);
 	}
 }
 

Modified: stable/10/contrib/libarchive/tar/test/test_option_a.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_a.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_a.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -43,6 +43,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test2: archive it with .taZ suffix. */
 	assertEqualInt(0,
@@ -53,6 +54,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test3: archive it with .tar.Z.uu suffix. */
 	assertEqualInt(0,
@@ -63,6 +65,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 12);
 	failure("The archive should be uuencoded");
 	assertEqualMem(p, "begin 644 -\n", 12);
+	free(p);
 
 	/* Test4: archive it with .zip suffix. */
 	assertEqualInt(0,
@@ -73,6 +76,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 4);
 	failure("The archive should be zipped");
 	assertEqualMem(p, "\x50\x4b\x03\x04", 4);
+	free(p);
 
 	/* Test5: archive it with .tar.Z suffix and --uuencode option. */
 	assertEqualInt(0,
@@ -84,6 +88,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed, ignoring --uuencode option");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 
 	/* Test6: archive it with .xxx suffix(unknown suffix) and
 	 * --uuencode option. */
@@ -96,6 +101,7 @@ DEFINE_TEST(test_option_a)
 	assert(s > 12);
 	failure("The archive should be uuencoded");
 	assertEqualMem(p, "begin 644 -\n", 12);
+	free(p);
 
 	/* Test7: archive it with .tar.Z suffix using a long-name option. */
 	assertEqualInt(0,
@@ -107,4 +113,5 @@ DEFINE_TEST(test_option_a)
 	assert(s > 2);
 	failure("The archive should be compressed");
 	assertEqualMem(p, "\x1f\x9d", 2);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_b.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_b.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_b.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -78,4 +78,6 @@ DEFINE_TEST(test_option_b)
 	 * Note: It's not possible to verify at this level that blocks
 	 * are getting written with the
 	 */
+
+	free(testprog_ustar);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_b64encode.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_b64encode.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_b64encode.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -42,6 +42,7 @@ DEFINE_TEST(test_option_b64encode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin-base64 644", 16);
+	free(p);
 
 	/* Archive it with uuencode only. */
 	assertEqualInt(0,
@@ -51,4 +52,5 @@ DEFINE_TEST(test_option_b64encode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin-base64 644", 16);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_gid_gname.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_gid_gname.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_gid_gname.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -53,6 +53,7 @@ DEFINE_TEST(test_option_gid_gname)
 	/* Should force gid and gname fields in ustar header. */
 	assertEqualMem(data + 116, "000021 \0", 8);
 	assertEqualMem(data + 297, "foofoofoo\0", 10);
+	free(data);
 
 	/* Again with just --gname */
 	failure("Error invoking %s c", testprog);
@@ -65,6 +66,8 @@ DEFINE_TEST(test_option_gid_gname)
 	/* Gid should be unchanged from original reference. */
 	assertEqualMem(data + 116, reference + 116, 8);
 	assertEqualMem(data + 297, "foofoofoo\0", 10);
+	free(data);
+	free(reference);
 
 	/* Again with --gid  and force gname to empty. */
 	failure("Error invoking %s c", testprog);
@@ -77,6 +80,7 @@ DEFINE_TEST(test_option_gid_gname)
 	assertEqualMem(data + 116, "000021 \0", 8);
 	/* Gname field in ustar header should be empty. */
 	assertEqualMem(data + 297, "\0", 1);
+	free(data);
 
 	/* TODO: It would be nice to verify that --gid= by itself
 	 * will look up the associated gname and use that, but

Modified: stable/10/contrib/libarchive/tar/test/test_option_grzip.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_grzip.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_grzip.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -45,8 +45,11 @@ DEFINE_TEST(test_option_grzip)
 	    testprog));
 	p = slurpfile(&s, "archive.err");
 	p[s] = '\0';
+	free(p);
+
 	/* Check that the archive file has an grzip signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "GRZipII\x00\x02\x04:)", 12);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_j.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_j.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_j.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -42,15 +42,18 @@ DEFINE_TEST(test_option_j)
 	if (r != 0) {
 		if (!canBzip2()) {
 			skipping("bzip2 is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("-j option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	assertEmptyFile("archive.err");
 	/* Check that the archive file has a bzip2 signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "BZh9", 4);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_lrzip.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_lrzip.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_lrzip.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -45,8 +45,10 @@ DEFINE_TEST(test_option_lrzip)
 	    testprog));
 	p = slurpfile(&s, "archive.err");
 	p[s] = '\0';
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "LRZI\x00", 5);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_lz4.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_lz4.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_lz4.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -43,7 +43,7 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Unsupported compression") != NULL) {
 			skipping("This version of bsdtar was compiled "
 			    "without lz4 support");
-			return;
+			goto done;
 		}
 		/* POSIX permits different handling of the spawnp
 		 * system call used to launch the subsidiary
@@ -52,7 +52,7 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Can't launch") != NULL && !canLz4()) {
 			skipping("This version of bsdtar uses an external lz4 program "
 			    "but no such program is available on this system.");
-			return;
+			goto done;
 		}
 		/* Some systems successfully spawn the new process,
 		 * but fail to exec a program within that process.
@@ -61,14 +61,18 @@ DEFINE_TEST(test_option_lz4)
 		if (strstr(p, "Can't write") != NULL && !canLz4()) {
 			skipping("This version of bsdtar uses an external lz4 program "
 			    "but no such program is available on this system.");
-			return;
+			goto done;
 		}
 		failure("--lz4 option is broken: %s", p);
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lz4 signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x04\x22\x4d\x18", 4);
+
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_lzma.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_lzma.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_lzma.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -48,10 +48,13 @@ DEFINE_TEST(test_option_lzma)
 		}
 		failure("--lzma option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x5d\00\00", 3);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_lzop.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_lzop.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_lzop.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -42,14 +42,17 @@ DEFINE_TEST(test_option_lzop)
 	if (r != 0) {
 		if (!canLzop()) {
 			skipping("lzop is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("--lzop option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an lzma signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\x89\x4c\x5a\x4f\x00\x0d\x0a\x1a\x0a", 9);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_r.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_r.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_r.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -36,6 +36,10 @@ DEFINE_TEST(test_option_r)
 	size_t s, buff_size_rounded;
 	int r, i;
 
+	buff = NULL;
+	p0 = NULL;
+	p1 = NULL;
+
 	/* Create an archive with one file. */
 	assertMakeFile("f1", 0644, "abc");
 	r = systemf("%s cf archive.tar --format=ustar f1 >step1.out 2>step1.err", testprog);
@@ -47,11 +51,9 @@ DEFINE_TEST(test_option_r)
 	/* Do some basic validation of the constructed archive. */
 	p0 = slurpfile(&s, "archive.tar");
 	if (!assert(p0 != NULL))
-		return;
-	if (!assert(s >= 2048)) {
-		free(p0);
-		return;
-	}
+		goto done;
+	if (!assert(s >= 2048))
+		goto done;
 	assertEqualMem(p0 + 0, "f1", 3);
 	assertEqualMem(p0 + 512, "abc", 3);
 	assertEqualMem(p0 + 1024, "\0\0\0\0\0\0\0\0", 8);
@@ -60,10 +62,8 @@ DEFINE_TEST(test_option_r)
 	/* Edit that file with a lot more data and update the archive with a new copy. */
 	buff = malloc(buff_size);
 	assert(buff != NULL);
-	if (buff == NULL) {
-		free(p0);
-		return;
-	}
+	if (buff == NULL)
+		goto done;
 
 	for (i = 0; i < (int)buff_size; ++i)
 		buff[i] = "abcdefghijklmnopqrstuvwxyz"[rand() % 26];
@@ -77,10 +77,8 @@ DEFINE_TEST(test_option_r)
 
 	/* The constructed archive should just have the new entry appended. */
 	p1 = slurpfile(&s, "archive.tar");
-	if (!assert(p1 != NULL)) {
-		free(p0);
-		return;
-	}
+	if (!assert(p1 != NULL))
+		goto done;
 	buff_size_rounded = ((buff_size + 511) / 512) * 512;
 	assert(s >= 2560 + buff_size_rounded);
 	/* Verify first entry is unchanged. */
@@ -105,10 +103,8 @@ DEFINE_TEST(test_option_r)
 
 	/* Validate the constructed archive. */
 	p1 = slurpfile(&s, "archive.tar");
-	if (!assert(p1 != NULL)) {
-		free(p0);
-		return;
-	}
+	if (!assert(p1 != NULL))
+		goto done;
 	assert(s >= 3584 + buff_size_rounded);
 	/* Verify first two entries are unchanged. */
 	assertEqualMem(p0, p1, 1536 + buff_size_rounded);
@@ -118,7 +114,6 @@ DEFINE_TEST(test_option_r)
 	/* Verify end-of-archive marker. */
 	assertEqualMem(p1 + 2560 + buff_size_rounded, "\0\0\0\0\0\0\0\0", 8);
 	assertEqualMem(p1 + 3072 + buff_size_rounded, "\0\0\0\0\0\0\0\0", 8);
-	free(p0);
 	free(p1);
 
 	/* Unpack everything */
@@ -132,4 +127,7 @@ DEFINE_TEST(test_option_r)
 
 	/* Verify that the second copy of f1 overwrote the first. */
 	assertFileContents(buff, (int)strlen(buff), "f1");
+done:
+	free(buff);
+	free(p0);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_uid_uname.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_uid_uname.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_uid_uname.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -53,6 +53,7 @@ DEFINE_TEST(test_option_uid_uname)
 	/* Should force uid and uname fields in ustar header. */
 	assertEqualMem(data + 108, "000021 \0", 8);
 	assertEqualMem(data + 265, "foofoofoo\0", 10);
+	free(data);
 
 	/* Again with just --uid */
 	failure("Error invoking %s c", testprog);
@@ -65,6 +66,7 @@ DEFINE_TEST(test_option_uid_uname)
 	assertEqualMem(data + 108, "000021 \0", 8);
 	/* Uname field in ustar header should be empty. */
 	assertEqualMem(data + 265, "\0", 1);
+	free(data);
 
 	/* Again with just --uname */
 	failure("Error invoking %s c", testprog);
@@ -77,4 +79,7 @@ DEFINE_TEST(test_option_uid_uname)
 	/* Uid should be unchanged from original reference. */
 	assertEqualMem(data + 108, reference + 108, 8);
 	assertEqualMem(data + 265, "foofoofoo\0", 10);
+	free(data);
+
+	free(reference);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_uuencode.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_uuencode.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_uuencode.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -42,6 +42,7 @@ DEFINE_TEST(test_option_uuencode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin 644", 9);
+	free(p);
 
 	/* Archive it with uuencode only. */
 	assertEqualInt(0,
@@ -51,4 +52,5 @@ DEFINE_TEST(test_option_uuencode)
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "begin 644", 9);
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_xz.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_xz.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_xz.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -44,14 +44,17 @@ DEFINE_TEST(test_option_xz)
 		if (strstr(p, "Unsupported compression") != NULL) {
 			skipping("This version of bsdtar was compiled "
 			    "without xz support");
-			return;
+			goto done;
 		}
 		failure("--xz option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has an xz signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 2);
 	assertEqualMem(p, "\xFD\x37\x7A\x58\x5A\x00", 6);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_option_z.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_option_z.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_option_z.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -42,14 +42,17 @@ DEFINE_TEST(test_option_z)
 	if (r != 0) {
 		if (!canGzip()) {
 			skipping("gzip is not supported on this platform");
-			return;
+			goto done;
 		}
 		failure("-z option is broken");
 		assertEqualInt(r, 0);
-		return;
+		goto done;
 	}
+	free(p);
 	/* Check that the archive file has a gzip signature. */
 	p = slurpfile(&s, "archive.out");
 	assert(s > 4);
 	assertEqualMem(p, "\x1f\x8b\x08\x00", 4);
+done:
+	free(p);
 }

Modified: stable/10/contrib/libarchive/tar/test/test_stdio.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_stdio.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_stdio.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -116,6 +116,7 @@ DEFINE_TEST(test_stdio)
 	assertEqualInt((int)s, 3);
 	assertEqualMem(p, "abc", 3);
 	/* TODO: Verify xvf.err */
+	free(p);
 
 	/* 'xvf -' should generate list on stderr, empty stdout. */
 	r = systemf("%s xvf - < archive >xvf-.out 2>xvf-.err", testprog);

Modified: stable/10/contrib/libarchive/tar/test/test_version.c
==============================================================================
--- stable/10/contrib/libarchive/tar/test/test_version.c	Mon Dec 26 06:16:27 2016	(r310569)
+++ stable/10/contrib/libarchive/tar/test/test_version.c	Mon Dec 26 06:25:39 2016	(r310570)
@@ -53,7 +53,7 @@ DEFINE_TEST(test_version)
 	assert(s > 6);
 	failure("Version must start with 'bsdtar': ``%s''", p);
 	if (!assertEqualMem(q, "bsdtar ", 7))
-		return;
+		goto done;
 	q += 7; s -= 7;
 	/* Version number is a series of digits and periods. */
 	while (s > 0 && (*q == '.' || (*q >= '0' && *q <= '9'))) {
@@ -98,5 +98,6 @@ DEFINE_TEST(test_version)
 	failure("Version output must end with \\n or \\r\\n");
 	if (*q == '\r') { ++q; --s; }
 	assertEqualMem(q, "\n", 1);
+done:
 	free(p);
 }

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:32:43 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id CE6F0C91100;
 Mon, 26 Dec 2016 06:32:43 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 9D9D0A14;
 Mon, 26 Dec 2016 06:32:43 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6WgZT045603;
 Mon, 26 Dec 2016 06:32:42 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6WgNd045602;
 Mon, 26 Dec 2016 06:32:42 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260632.uBQ6WgNd045602@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:32:42 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310571 - stable/11/contrib/bsnmp/snmpd
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:32:43 -0000

Author: ngie
Date: Mon Dec 26 06:32:42 2016
New Revision: 310571
URL: https://svnweb.freebsd.org/changeset/base/310571

Log:
  MFC r310459:
  
  Sort #includes per style(9)
  
  No functional change

Modified:
  stable/11/contrib/bsnmp/snmpd/action.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/bsnmp/snmpd/action.c
==============================================================================
--- stable/11/contrib/bsnmp/snmpd/action.c	Mon Dec 26 06:25:39 2016	(r310570)
+++ stable/11/contrib/bsnmp/snmpd/action.c	Mon Dec 26 06:32:42 2016	(r310571)
@@ -38,12 +38,12 @@
 #include <sys/sysctl.h>
 #include <sys/un.h>
 #include <sys/utsname.h>
+#include <ctype.h>
+#include <errno.h>
+#include <stdarg.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <stdarg.h>
 #include <string.h>
-#include <ctype.h>
-#include <errno.h>
 #include <syslog.h>
 
 #include "snmpmod.h"

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:33:44 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E915C91164;
 Mon, 26 Dec 2016 06:33:44 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6D954B7F;
 Mon, 26 Dec 2016 06:33:44 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6XhQr045720;
 Mon, 26 Dec 2016 06:33:43 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6XhIk045719;
 Mon, 26 Dec 2016 06:33:43 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260633.uBQ6XhIk045719@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:33:43 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310572 - stable/10/contrib/bsnmp/snmpd
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:33:44 -0000

Author: ngie
Date: Mon Dec 26 06:33:43 2016
New Revision: 310572
URL: https://svnweb.freebsd.org/changeset/base/310572

Log:
  MFstable/11 r310571:
  
  MFC r310459:
  
  Sort #includes per style(9)
  
  No functional change

Modified:
  stable/10/contrib/bsnmp/snmpd/action.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/bsnmp/snmpd/action.c
==============================================================================
--- stable/10/contrib/bsnmp/snmpd/action.c	Mon Dec 26 06:32:42 2016	(r310571)
+++ stable/10/contrib/bsnmp/snmpd/action.c	Mon Dec 26 06:33:43 2016	(r310572)
@@ -38,12 +38,12 @@
 #include <sys/sysctl.h>
 #include <sys/un.h>
 #include <sys/utsname.h>
+#include <ctype.h>
+#include <errno.h>
+#include <stdarg.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <stdarg.h>
 #include <string.h>
-#include <ctype.h>
-#include <errno.h>
 #include <syslog.h>
 
 #include "snmpmod.h"

From owner-svn-src-all@freebsd.org  Mon Dec 26 06:59:24 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4D0DEC91665;
 Mon, 26 Dec 2016 06:59:24 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 00FFE86B;
 Mon, 26 Dec 2016 06:59:23 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ6xN8J054594;
 Mon, 26 Dec 2016 06:59:23 GMT (envelope-from sephe@FreeBSD.org)
Received: (from sephe@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ6xNM7054592;
 Mon, 26 Dec 2016 06:59:23 GMT (envelope-from sephe@FreeBSD.org)
Message-Id: <201612260659.uBQ6xNM7054592@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: sephe set sender to
 sephe@FreeBSD.org using -f
From: Sepherosa Ziehau <sephe@FreeBSD.org>
Date: Mon, 26 Dec 2016 06:59:23 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310573 - stable/11/sys/dev/hyperv/vmbus
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 06:59:24 -0000

Author: sephe
Date: Mon Dec 26 06:59:22 2016
New Revision: 310573
URL: https://svnweb.freebsd.org/changeset/base/310573

Log:
  r310348
  
      hyperv: Unbreak EARLY_AP_STARUP Hyper-V bootstrap by using intrhook
  
      Properly working pause and friends are required.
  
      Sponsored by:   Microsoft

Modified:
  stable/11/sys/dev/hyperv/vmbus/vmbus.c
  stable/11/sys/dev/hyperv/vmbus/vmbus_var.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/dev/hyperv/vmbus/vmbus.c
==============================================================================
--- stable/11/sys/dev/hyperv/vmbus/vmbus.c	Mon Dec 26 06:33:43 2016	(r310572)
+++ stable/11/sys/dev/hyperv/vmbus/vmbus.c	Mon Dec 26 06:59:22 2016	(r310573)
@@ -97,6 +97,9 @@ static int			vmbus_probe_guid_method(dev
 				    const struct hyperv_guid *);
 static uint32_t			vmbus_get_vcpu_id_method(device_t bus,
 				    device_t dev, int cpu);
+#ifdef EARLY_AP_STARTUP
+static void			vmbus_intrhook(void *);
+#endif
 
 static int			vmbus_init(struct vmbus_softc *);
 static int			vmbus_connect(struct vmbus_softc *, uint32_t);
@@ -1369,6 +1372,21 @@ vmbus_event_proc_dummy(struct vmbus_soft
 {
 }
 
+#ifdef EARLY_AP_STARTUP
+
+static void
+vmbus_intrhook(void *xsc)
+{
+	struct vmbus_softc *sc = xsc;
+
+	if (bootverbose)
+		device_printf(sc->vmbus_dev, "intrhook\n");
+	vmbus_doattach(sc);
+	config_intrhook_disestablish(&sc->vmbus_intrhook);
+}
+
+#endif	/* EARLY_AP_STARTUP */
+
 static int
 vmbus_attach(device_t dev)
 {
@@ -1383,7 +1401,14 @@ vmbus_attach(device_t dev)
 	 */
 	vmbus_sc->vmbus_event_proc = vmbus_event_proc_dummy;
 
-#ifndef EARLY_AP_STARTUP
+#ifdef EARLY_AP_STARTUP
+	/*
+	 * Defer the real attach until the pause(9) works as expected.
+	 */
+	vmbus_sc->vmbus_intrhook.ich_func = vmbus_intrhook;
+	vmbus_sc->vmbus_intrhook.ich_arg = vmbus_sc;
+	config_intrhook_establish(&vmbus_sc->vmbus_intrhook);
+#else	/* !EARLY_AP_STARTUP */
 	/* 
 	 * If the system has already booted and thread
 	 * scheduling is possible indicated by the global
@@ -1391,8 +1416,8 @@ vmbus_attach(device_t dev)
 	 * initialization directly.
 	 */
 	if (!cold)
-#endif
 		vmbus_doattach(vmbus_sc);
+#endif	/* EARLY_AP_STARTUP */
 
 	return (0);
 }

Modified: stable/11/sys/dev/hyperv/vmbus/vmbus_var.h
==============================================================================
--- stable/11/sys/dev/hyperv/vmbus/vmbus_var.h	Mon Dec 26 06:33:43 2016	(r310572)
+++ stable/11/sys/dev/hyperv/vmbus/vmbus_var.h	Mon Dec 26 06:59:22 2016	(r310573)
@@ -30,6 +30,7 @@
 #define _VMBUS_VAR_H_
 
 #include <sys/param.h>
+#include <sys/kernel.h>
 #include <sys/taskqueue.h>
 #include <sys/rman.h>
 
@@ -128,6 +129,8 @@ struct vmbus_softc {
 	struct mtx		vmbus_chan_lock;
 	TAILQ_HEAD(, vmbus_channel) vmbus_chans;
 
+	struct intr_config_hook	vmbus_intrhook;
+
 #ifdef NEW_PCIB
 	/* The list of usable MMIO ranges for PCIe pass-through */
 	struct pcib_host_resources vmbus_mmio_res;

From owner-svn-src-all@freebsd.org  Mon Dec 26 07:31:17 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5AD38C91DFD;
 Mon, 26 Dec 2016 07:31:17 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 2A9EC8E0;
 Mon, 26 Dec 2016 07:31:17 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ7VGYG070313;
 Mon, 26 Dec 2016 07:31:16 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ7VGTZ070312;
 Mon, 26 Dec 2016 07:31:16 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612260731.uBQ7VGTZ070312@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 07:31:16 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310574 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 07:31:17 -0000

Author: ngie
Date: Mon Dec 26 07:31:16 2016
New Revision: 310574
URL: https://svnweb.freebsd.org/changeset/base/310574

Log:
  Fix style(9)
  
  - Sort #includes
  - Delete trailing whitespace
  
  No functional change
  
  MFC after:	3 days

Modified:
  head/contrib/bsnmp/snmpd/trans_lsock.c

Modified: head/contrib/bsnmp/snmpd/trans_lsock.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_lsock.c	Mon Dec 26 06:59:22 2016	(r310573)
+++ head/contrib/bsnmp/snmpd/trans_lsock.c	Mon Dec 26 07:31:16 2016	(r310574)
@@ -32,15 +32,15 @@
  */
 #include <sys/types.h>
 #include <sys/queue.h>
-#include <sys/un.h>
 #include <sys/stat.h>
+#include <sys/un.h>
 
+#include <errno.h>
+#include <stddef.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <stddef.h>
-#include <syslog.h>
 #include <string.h>
-#include <errno.h>
+#include <syslog.h>
 #include <unistd.h>
 
 #include "snmpmod.h"
@@ -417,7 +417,7 @@ lsock_send(struct tport *tp, const u_cha
 			return (-1);
 		}
 	}
-	
+
 	return (sendto(peer->input.fd, buf, len, 0, addr, addrlen));
 }
 

From owner-svn-src-all@freebsd.org  Mon Dec 26 08:47:36 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A79E6C9148B;
 Mon, 26 Dec 2016 08:47:36 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 708E5DF7;
 Mon, 26 Dec 2016 08:47:36 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ8lZ5A098832;
 Mon, 26 Dec 2016 08:47:35 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ8lZoD098831;
 Mon, 26 Dec 2016 08:47:35 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612260847.uBQ8lZoD098831@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Mon, 26 Dec 2016 08:47:35 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310575 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 08:47:36 -0000

Author: mav
Date: Mon Dec 26 08:47:35 2016
New Revision: 310575
URL: https://svnweb.freebsd.org/changeset/base/310575

Log:
  Fix improperly used nexus.targ_lun.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Mon Dec 26 07:31:16 2016	(r310574)
+++ head/sys/cam/ctl/ctl.c	Mon Dec 26 08:47:35 2016	(r310575)
@@ -1024,7 +1024,7 @@ ctl_isc_ua(struct ctl_softc *softc, unio
 	uint32_t iid = ctl_get_initindex(&msg->hdr.nexus);
 
 	mtx_lock(&softc->ctl_lock);
-	if (msg->hdr.nexus.targ_lun >= CTL_MAX_LUNS ||
+	if (msg->hdr.nexus.targ_mapped_lun >= CTL_MAX_LUNS ||
 	    (lun = softc->ctl_luns[msg->hdr.nexus.targ_mapped_lun]) == NULL) {
 		mtx_unlock(&softc->ctl_lock);
 		return;
@@ -1074,7 +1074,7 @@ ctl_isc_lun_sync(struct ctl_softc *softc
 	    memcmp(&msg->lun.data[0], lun->lun_devid->data, i) != 0)) {
 		mtx_unlock(&lun->lun_lock);
 		printf("%s: Received conflicting HA LUN %d\n",
-		    __func__, msg->hdr.nexus.targ_lun);
+		    __func__, targ_lun);
 		return;
 	} else {
 		/* Record whether peer is primary. */
@@ -1108,7 +1108,7 @@ ctl_isc_lun_sync(struct ctl_softc *softc
 
 		mtx_unlock(&lun->lun_lock);
 		CTL_DEBUG_PRINT(("%s: Known LUN %d, peer is %s\n",
-		    __func__, msg->hdr.nexus.targ_lun,
+		    __func__, targ_lun,
 		    (msg->lun.flags & CTL_LUN_PRIMARY_SC) ?
 		    "primary" : "secondary"));
 

From owner-svn-src-all@freebsd.org  Mon Dec 26 09:38:19 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E0B3EC8F57C;
 Mon, 26 Dec 2016 09:38:19 +0000 (UTC)
 (envelope-from melounmichal@gmail.com)
Received: from mail-wj0-x244.google.com (mail-wj0-x244.google.com
 [IPv6:2a00:1450:400c:c01::244])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id 73D3696A;
 Mon, 26 Dec 2016 09:38:19 +0000 (UTC)
 (envelope-from melounmichal@gmail.com)
Received: by mail-wj0-x244.google.com with SMTP id kp2so47922540wjc.0;
 Mon, 26 Dec 2016 01:38:19 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:subject:references:to:reply-to:message-id:date:user-agent
 :mime-version:in-reply-to:content-transfer-encoding;
 bh=cLpnfGCTbT6hTiYY5njmZI0jRQPReR+3bvfUyfDIy4M=;
 b=d7RVxtFINEYv1MEZO44LOeNWvbzFklrVddnI3XkkwClFV1vkG4aIrqV+6xw9otMDXQ
 f9fPBsY9ahqwl8yrxtZvSVgEmhN5LzXGVBI1UyAHGtzhosvekq8wI0SDtl0we/PSQw9M
 f5cCky5rkuG8Sv54smymrtLf7oV7GqEuD4tID4gn0EQ9e7aNqrqvncblVZqCeFJSL1YQ
 4Mah/l09PuR5SUz/T00V5Tl65eiC+6SexP13FzkQmL0gZINLJ5amdEJX7gr6svmvxN5D
 MWUA1O/DEbkx2/s93dwqwxo+kOB3JlsUNNG0P6WmjuE+m1TiiT7zsUK7YrBQUbGshesF
 iNGw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:subject:references:to:reply-to:message-id
 :date:user-agent:mime-version:in-reply-to:content-transfer-encoding;
 bh=cLpnfGCTbT6hTiYY5njmZI0jRQPReR+3bvfUyfDIy4M=;
 b=CG7UZbbWWqiji2nr5KA7HkpO7sofuGgbVBwKGgW//b0jEq9rx0lZCBAcAn/YHa6AJK
 zVJ2nypTqsEtzoaYO4USp7Ul065HZKTkVgTjbYUCm+xgWJGOOZGsHBVDrFAnSbPDwT9p
 71Ke/hmIGApk9sLggi63W67b3d+AvG85phJ3R3VuBgyvpSFUbCA0LJB+brJousEMxw9D
 lmRUFSY96D4VdogrN0vCGs5WO+Q04z1LFIubAPqZlL7Zc+PPNHxNEjsy8ymjGr6yRBoi
 PIeUiMf3aVdyYdRr5fxiSol+VROF/w598PApvvusbmjvDG5tq9SW/3A20RHDs2M/d2b6
 A8QA==
X-Gm-Message-State: AIkVDXL6RlHCvwx9JhoHOi1ninXdJ0fq1TezK8Z/nOVA4SUvK1x3P1P+P+6RE2N0rzo5GA==
X-Received: by 10.194.249.72 with SMTP id ys8mr26319681wjc.92.1482745097380;
 Mon, 26 Dec 2016 01:38:17 -0800 (PST)
Received: from [88.208.79.100] (halouny.humusoft.cz. [88.208.79.100])
 by smtp.gmail.com with ESMTPSA id t194sm29580406wmd.1.2016.12.26.01.38.16
 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Mon, 26 Dec 2016 01:38:16 -0800 (PST)
From: Michal Meloun <melounmichal@gmail.com>
X-Google-Original-From: Michal Meloun <mmel@freebsd.org>
Subject: Re: svn commit: r310559 - in head/sys/compat/linuxkpi/common:
 include/linux src
References: <201612260118.uBQ1I8Dm015288@repo.freebsd.org>
To: Hans Petter Selasky <hselasky@FreeBSD.org>, src-committers@freebsd.org,
 svn-src-all@freebsd.org, svn-src-head@freebsd.org
Reply-To: mmel@freebsd.org
Message-ID: <eb3ae7ea-0881-d76f-788e-c200aa22fc45@freebsd.org>
Date: Mon, 26 Dec 2016 10:38:30 +0100
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101
 Thunderbird/45.5.1
MIME-Version: 1.0
In-Reply-To: <201612260118.uBQ1I8Dm015288@repo.freebsd.org>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 09:38:20 -0000



On 26.12.2016 2:18, Hans Petter Selasky wrote:
> Author: hselasky
> Date: Mon Dec 26 01:18:07 2016
> New Revision: 310559
> URL: https://svnweb.freebsd.org/changeset/base/310559
> 
> Log:
>   Implement register and unregister chrdev in the LinuxKPI.
>   
>   Obtained from:	kmacy @
>   MFC after:	1 week
>   Sponsored by:	Mellanox Technologies
> 
> Modified:
>   head/sys/compat/linuxkpi/common/include/linux/cdev.h
>   head/sys/compat/linuxkpi/common/include/linux/fs.h
>   head/sys/compat/linuxkpi/common/src/linux_compat.c
> 
> Modified: head/sys/compat/linuxkpi/common/include/linux/cdev.h
> ==============================================================================
> --- head/sys/compat/linuxkpi/common/include/linux/cdev.h	Sun Dec 25 22:32:16 2016	(r310558)
> +++ head/sys/compat/linuxkpi/common/include/linux/cdev.h	Mon Dec 26 01:18:07 2016	(r310559)
> @@ -95,7 +95,7 @@ cdev_add(struct linux_cdev *cdev, dev_t 
>  	args.mda_gid = 0;
>  	args.mda_mode = 0700;
>  	args.mda_si_drv1 = cdev;
> -	args.mda_unit = MINOR(dev);
> +	args.mda_unit = dev;
>  
>  	error = make_dev_s(&args, &cdev->cdev, "%s",
>  	    kobject_name(&cdev->kobj));
> @@ -121,7 +121,7 @@ cdev_add_ext(struct linux_cdev *cdev, de
>  	args.mda_gid = gid;
>  	args.mda_mode = mode;
>  	args.mda_si_drv1 = cdev;
> -	args.mda_unit = MINOR(dev);
> +	args.mda_unit = dev;
>  
>  	error = make_dev_s(&args, &cdev->cdev, "%s/%d",
>  	    kobject_name(&cdev->kobj), MINOR(dev));
> @@ -142,6 +142,8 @@ cdev_del(struct linux_cdev *cdev)
>  	kobject_put(&cdev->kobj);
>  }
>  
> +struct linux_cdev *linux_find_cdev(const char *name, unsigned major, unsigned minor);
> +
>  #define	cdev	linux_cdev
>  
>  #endif	/* _LINUX_CDEV_H_ */
> 
> Modified: head/sys/compat/linuxkpi/common/include/linux/fs.h
> ==============================================================================
> --- head/sys/compat/linuxkpi/common/include/linux/fs.h	Sun Dec 25 22:32:16 2016	(r310558)
> +++ head/sys/compat/linuxkpi/common/include/linux/fs.h	Mon Dec 26 01:18:07 2016	(r310559)
> @@ -2,7 +2,7 @@
>   * Copyright (c) 2010 Isilon Systems, Inc.
>   * Copyright (c) 2010 iX Systems, Inc.
>   * Copyright (c) 2010 Panasas, Inc.
> - * Copyright (c) 2013 Mellanox Technologies, Ltd.
> + * Copyright (c) 2013-2016 Mellanox Technologies, Ltd.
>   * All rights reserved.
>   *
>   * Redistribution and use in source and binary forms, with or without
> @@ -151,6 +151,39 @@ struct file_operations {
>  #define	FMODE_WRITE	FWRITE
>  #define	FMODE_EXEC	FEXEC
>  
> +int __register_chrdev(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name,
> +    const struct file_operations *fops);
> +int __register_chrdev_p(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name,
> +    const struct file_operations *fops, uid_t uid,
> +    gid_t gid, int mode);
> +void __unregister_chrdev(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name);
> +
> +static inline void
> +unregister_chrdev(unsigned int major, const char *name)
> +{
> +
> +	__unregister_chrdev(major, 0, 256, name);
> +}
> +
> +static inline int
> +register_chrdev(unsigned int major, const char *name,
> +    const struct file_operations *fops)
> +{
> +
> +	return (__register_chrdev(major, 0, 256, name, fops));
> +}
> +
> +static inline int
> +register_chrdev_p(unsigned int major, const char *name,
> +    const struct file_operations *fops, uid_t uid, gid_t gid, int mode)
> +{
> +
> +	return (__register_chrdev_p(major, 0, 256, name, fops, uid, gid, mode));
> +}
> +
>  static inline int
>  register_chrdev_region(dev_t dev, unsigned range, const char *name)
>  {
> @@ -184,7 +217,7 @@ static inline dev_t
>  iminor(struct inode *inode)
>  {
>  
> -	return dev2unit(inode->v_rdev);
> +	return (MINOR(dev2unit(inode->v_rdev)));

This breaks many kernels:

 --- all_subdir_ibcore ---
 In file included from
/usr2/Meloun/svn/src/sys/modules/ibcore/../../ofed/drivers/infiniband/core/ucma.c:34:
 In file included from
/usr2/Meloun/svn/src/sys/modules/ibcore/../../compat/linuxkpi/common/include/linux/file.h:41:
 /usr2/Meloun/svn/src/sys/modules/ibcore/../../compat/linuxkpi/common/include/linux/fs.h:220:10: error: implicit declaration of function 'MINOR' is invalid in C99
 [-Werror,-Wimplicit-function-declaration]
         return (MINOR(dev2unit(inode->v_rdev)));
                 ^



>  }
>  
>  static inline struct inode *
> 
> Modified: head/sys/compat/linuxkpi/common/src/linux_compat.c
> ==============================================================================
> --- head/sys/compat/linuxkpi/common/src/linux_compat.c	Sun Dec 25 22:32:16 2016	(r310558)
> +++ head/sys/compat/linuxkpi/common/src/linux_compat.c	Mon Dec 26 01:18:07 2016	(r310559)
> @@ -1418,6 +1418,82 @@ linux_irq_handler(void *ent)
>  	irqe->handler(irqe->irq, irqe->arg);
>  }
>  
> +struct linux_cdev *
> +linux_find_cdev(const char *name, unsigned major, unsigned minor)
> +{
> +	int unit = MKDEV(major, minor);
> +	struct cdev *cdev;
> +
> +	dev_lock();
> +	LIST_FOREACH(cdev, &linuxcdevsw.d_devs, si_list) {
> +		struct linux_cdev *ldev = cdev->si_drv1;
> +		if (dev2unit(cdev) == unit &&
> +		    strcmp(kobject_name(&ldev->kobj), name) == 0) {
> +			break;
> +		}
> +	}
> +	dev_unlock();
> +
> +	return (cdev != NULL ? cdev->si_drv1 : NULL);
> +}
> +
> +int
> +__register_chrdev(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name,
> +    const struct file_operations *fops)
> +{
> +	struct linux_cdev *cdev;
> +	int ret = 0;
> +	int i;
> +
> +	for (i = baseminor; i < baseminor + count; i++) {
> +		cdev = cdev_alloc();
> +		cdev_init(cdev, fops);
> +		kobject_set_name(&cdev->kobj, name);
> +
> +		ret = cdev_add(cdev, makedev(major, i), 1);
> +		if (ret != 0)
> +			break;
> +	}
> +	return (ret);
> +}
> +
> +int
> +__register_chrdev_p(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name,
> +    const struct file_operations *fops, uid_t uid,
> +    gid_t gid, int mode)
> +{
> +	struct linux_cdev *cdev;
> +	int ret = 0;
> +	int i;
> +
> +	for (i = baseminor; i < baseminor + count; i++) {
> +		cdev = cdev_alloc();
> +		cdev_init(cdev, fops);
> +		kobject_set_name(&cdev->kobj, name);
> +
> +		ret = cdev_add_ext(cdev, makedev(major, i), uid, gid, mode);
> +		if (ret != 0)
> +			break;
> +	}
> +	return (ret);
> +}
> +
> +void
> +__unregister_chrdev(unsigned int major, unsigned int baseminor,
> +    unsigned int count, const char *name)
> +{
> +	struct linux_cdev *cdevp;
> +	int i;
> +
> +	for (i = baseminor; i < baseminor + count; i++) {
> +		cdevp = linux_find_cdev(name, major, i);
> +		if (cdevp != NULL)
> +			cdev_del(cdevp);
> +	}
> +}
> +
>  #if defined(__i386__) || defined(__amd64__)
>  bool linux_cpu_has_clflush;
>  #endif
> 

From owner-svn-src-all@freebsd.org  Mon Dec 26 09:48:37 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D2876C8F87A;
 Mon, 26 Dec 2016 09:48:37 +0000 (UTC) (envelope-from hps@selasky.org)
Received: from mail.turbocat.net (turbocat.net [IPv6:2a01:4f8:c17:6c4b::2])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 85795103F;
 Mon, 26 Dec 2016 09:48:37 +0000 (UTC) (envelope-from hps@selasky.org)
Received: from hps2016.home.selasky.org (unknown [62.141.129.119])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (No client certificate requested)
 by mail.turbocat.net (Postfix) with ESMTPSA id 5F2641FE157;
 Mon, 26 Dec 2016 10:48:27 +0100 (CET)
Subject: Re: svn commit: r310559 - in head/sys/compat/linuxkpi/common:
 include/linux src
To: mmel@freebsd.org, src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
References: <201612260118.uBQ1I8Dm015288@repo.freebsd.org>
 <eb3ae7ea-0881-d76f-788e-c200aa22fc45@freebsd.org>
From: Hans Petter Selasky <hps@selasky.org>
Message-ID: <4cd92dee-4cb2-954d-7157-6fcd122131c2@selasky.org>
Date: Mon, 26 Dec 2016 10:48:03 +0100
User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101
 Thunderbird/45.4.0
MIME-Version: 1.0
In-Reply-To: <eb3ae7ea-0881-d76f-788e-c200aa22fc45@freebsd.org>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 09:48:37 -0000

On 12/26/16 10:38, Michal Meloun wrote:
>
>
> On 26.12.2016 2:18, Hans Petter Selasky wrote:
>> Author: hselasky
>> Date: Mon Dec 26 01:18:07 2016
>> New Revision: 310559
>> URL: https://svnweb.freebsd.org/changeset/base/310559
>>
>> Log:
>>   Implement register and unregister chrdev in the LinuxKPI.
>>
>>   Obtained from:	kmacy @
>>   MFC after:	1 week
>>   Sponsored by:	Mellanox Technologies
>>
>> Modified:
>>   head/sys/compat/linuxkpi/common/include/linux/cdev.h
>>   head/sys/compat/linuxkpi/common/include/linux/fs.h
>>   head/sys/compat/linuxkpi/common/src/linux_compat.c
>>
>> Modified: head/sys/compat/linuxkpi/common/include/linux/cdev.h
>> ==============================================================================
>> --- head/sys/compat/linuxkpi/common/include/linux/cdev.h	Sun Dec 25 22:32:16 2016	(r310558)
>> +++ head/sys/compat/linuxkpi/common/include/linux/cdev.h	Mon Dec 26 01:18:07 2016	(r310559)
>> @@ -95,7 +95,7 @@ cdev_add(struct linux_cdev *cdev, dev_t
>>  	args.mda_gid = 0;
>>  	args.mda_mode = 0700;
>>  	args.mda_si_drv1 = cdev;
>> -	args.mda_unit = MINOR(dev);
>> +	args.mda_unit = dev;
>>
>>  	error = make_dev_s(&args, &cdev->cdev, "%s",
>>  	    kobject_name(&cdev->kobj));
>> @@ -121,7 +121,7 @@ cdev_add_ext(struct linux_cdev *cdev, de
>>  	args.mda_gid = gid;
>>  	args.mda_mode = mode;
>>  	args.mda_si_drv1 = cdev;
>> -	args.mda_unit = MINOR(dev);
>> +	args.mda_unit = dev;
>>
>>  	error = make_dev_s(&args, &cdev->cdev, "%s/%d",
>>  	    kobject_name(&cdev->kobj), MINOR(dev));
>> @@ -142,6 +142,8 @@ cdev_del(struct linux_cdev *cdev)
>>  	kobject_put(&cdev->kobj);
>>  }
>>
>> +struct linux_cdev *linux_find_cdev(const char *name, unsigned major, unsigned minor);
>> +
>>  #define	cdev	linux_cdev
>>
>>  #endif	/* _LINUX_CDEV_H_ */
>>
>> Modified: head/sys/compat/linuxkpi/common/include/linux/fs.h
>> ==============================================================================
>> --- head/sys/compat/linuxkpi/common/include/linux/fs.h	Sun Dec 25 22:32:16 2016	(r310558)
>> +++ head/sys/compat/linuxkpi/common/include/linux/fs.h	Mon Dec 26 01:18:07 2016	(r310559)
>> @@ -2,7 +2,7 @@
>>   * Copyright (c) 2010 Isilon Systems, Inc.
>>   * Copyright (c) 2010 iX Systems, Inc.
>>   * Copyright (c) 2010 Panasas, Inc.
>> - * Copyright (c) 2013 Mellanox Technologies, Ltd.
>> + * Copyright (c) 2013-2016 Mellanox Technologies, Ltd.
>>   * All rights reserved.
>>   *
>>   * Redistribution and use in source and binary forms, with or without
>> @@ -151,6 +151,39 @@ struct file_operations {
>>  #define	FMODE_WRITE	FWRITE
>>  #define	FMODE_EXEC	FEXEC
>>
>> +int __register_chrdev(unsigned int major, unsigned int baseminor,
>> +    unsigned int count, const char *name,
>> +    const struct file_operations *fops);
>> +int __register_chrdev_p(unsigned int major, unsigned int baseminor,
>> +    unsigned int count, const char *name,
>> +    const struct file_operations *fops, uid_t uid,
>> +    gid_t gid, int mode);
>> +void __unregister_chrdev(unsigned int major, unsigned int baseminor,
>> +    unsigned int count, const char *name);
>> +
>> +static inline void
>> +unregister_chrdev(unsigned int major, const char *name)
>> +{
>> +
>> +	__unregister_chrdev(major, 0, 256, name);
>> +}
>> +
>> +static inline int
>> +register_chrdev(unsigned int major, const char *name,
>> +    const struct file_operations *fops)
>> +{
>> +
>> +	return (__register_chrdev(major, 0, 256, name, fops));
>> +}
>> +
>> +static inline int
>> +register_chrdev_p(unsigned int major, const char *name,
>> +    const struct file_operations *fops, uid_t uid, gid_t gid, int mode)
>> +{
>> +
>> +	return (__register_chrdev_p(major, 0, 256, name, fops, uid, gid, mode));
>> +}
>> +
>>  static inline int
>>  register_chrdev_region(dev_t dev, unsigned range, const char *name)
>>  {
>> @@ -184,7 +217,7 @@ static inline dev_t
>>  iminor(struct inode *inode)
>>  {
>>
>> -	return dev2unit(inode->v_rdev);
>> +	return (MINOR(dev2unit(inode->v_rdev)));
>
> This breaks many kernels:
>
>  --- all_subdir_ibcore ---
>  In file included from
> /usr2/Meloun/svn/src/sys/modules/ibcore/../../ofed/drivers/infiniband/core/ucma.c:34:
>  In file included from
> /usr2/Meloun/svn/src/sys/modules/ibcore/../../compat/linuxkpi/common/include/linux/file.h:41:
>  /usr2/Meloun/svn/src/sys/modules/ibcore/../../compat/linuxkpi/common/include/linux/fs.h:220:10: error: implicit declaration of function 'MINOR' is invalid in C99
>  [-Werror,-Wimplicit-function-declaration]
>          return (MINOR(dev2unit(inode->v_rdev)));
>                  ^
>

I'll fix shortly.

--HPS

From owner-svn-src-all@freebsd.org  Mon Dec 26 09:52:20 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 507D9C8FBF4;
 Mon, 26 Dec 2016 09:52:20 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 15DB015D9;
 Mon, 26 Dec 2016 09:52:20 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ9qJV2025010;
 Mon, 26 Dec 2016 09:52:19 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ9qJcC025009;
 Mon, 26 Dec 2016 09:52:19 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612260952.uBQ9qJcC025009@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 09:52:19 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310578 - stable/11/sys/kern
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 09:52:20 -0000

Author: kib
Date: Mon Dec 26 09:52:19 2016
New Revision: 310578
URL: https://svnweb.freebsd.org/changeset/base/310578

Log:
  MFC r310302:
  Do not clear KN_INFLUX when not owning influx state.
  
  PR:	214923

Modified:
  stable/11/sys/kern/kern_event.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/kern/kern_event.c
==============================================================================
--- stable/11/sys/kern/kern_event.c	Mon Dec 26 09:46:55 2016	(r310577)
+++ stable/11/sys/kern/kern_event.c	Mon Dec 26 09:52:19 2016	(r310578)
@@ -2006,6 +2006,7 @@ knote(struct knlist *list, long hint, in
 	struct kqueue *kq;
 	struct knote *kn, *tkn;
 	int error;
+	bool own_influx;
 
 	if (list == NULL)
 		return;
@@ -2036,11 +2037,14 @@ knote(struct knlist *list, long hint, in
 			 */
 			KQ_UNLOCK(kq);
 		} else if ((lockflags & KNF_NOKQLOCK) != 0) {
-			kn->kn_status |= KN_INFLUX;
+			own_influx = (kn->kn_status & KN_INFLUX) == 0;
+			if (own_influx)
+				kn->kn_status |= KN_INFLUX;
 			KQ_UNLOCK(kq);
 			error = kn->kn_fop->f_event(kn, hint);
 			KQ_LOCK(kq);
-			kn->kn_status &= ~KN_INFLUX;
+			if (own_influx)
+				kn->kn_status &= ~KN_INFLUX;
 			if (error)
 				KNOTE_ACTIVATE(kn, 1);
 			KQ_UNLOCK_FLUX(kq);

From owner-svn-src-all@freebsd.org  Mon Dec 26 09:56:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D18B7C8FD3A;
 Mon, 26 Dec 2016 09:56:53 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A0D961932;
 Mon, 26 Dec 2016 09:56:53 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQ9uqDo027371;
 Mon, 26 Dec 2016 09:56:52 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQ9uq25027370;
 Mon, 26 Dec 2016 09:56:52 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612260956.uBQ9uq25027370@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 09:56:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310580 - stable/11/sys/kern
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 09:56:53 -0000

Author: kib
Date: Mon Dec 26 09:56:52 2016
New Revision: 310580
URL: https://svnweb.freebsd.org/changeset/base/310580

Log:
  MFC r309887:
  Enable lookup_cap_dotdot and lookup_cap_dotdot_nonlocal.

Modified:
  stable/11/sys/kern/vfs_lookup.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/kern/vfs_lookup.c
==============================================================================
--- stable/11/sys/kern/vfs_lookup.c	Mon Dec 26 09:54:37 2016	(r310579)
+++ stable/11/sys/kern/vfs_lookup.c	Mon Dec 26 09:56:52 2016	(r310580)
@@ -106,16 +106,11 @@ static int lookup_shared = 1;
 SYSCTL_INT(_vfs, OID_AUTO, lookup_shared, CTLFLAG_RWTUN, &lookup_shared, 0,
     "enables shared locks for path name translation");
 
-/*
- * Intent is that lookup_cap_dotdot becomes unconditionally enabled,
- * but it defaults to the disabled state until verification efforts
- * are complete.
- */
-static int lookup_cap_dotdot = 0;
+static int lookup_cap_dotdot = 1;
 SYSCTL_INT(_vfs, OID_AUTO, lookup_cap_dotdot, CTLFLAG_RWTUN,
     &lookup_cap_dotdot, 0,
     "enables \"..\" components in path lookup in capability mode");
-static int lookup_cap_dotdot_nonlocal = 0;
+static int lookup_cap_dotdot_nonlocal = 1;
 SYSCTL_INT(_vfs, OID_AUTO, lookup_cap_dotdot_nonlocal, CTLFLAG_RWTUN,
     &lookup_cap_dotdot_nonlocal, 0,
     "enables \"..\" components in path lookup in capability mode "

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:01:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A078EC900DA;
 Mon, 26 Dec 2016 10:01:53 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 68E6D1E3D;
 Mon, 26 Dec 2016 10:01:53 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQA1qtR028448;
 Mon, 26 Dec 2016 10:01:52 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQA1qAS028447;
 Mon, 26 Dec 2016 10:01:52 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261001.uBQA1qAS028447@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:01:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310581 - stable/11/sys/kern
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:01:53 -0000

Author: kib
Date: Mon Dec 26 10:01:52 2016
New Revision: 310581
URL: https://svnweb.freebsd.org/changeset/base/310581

Log:
  MFC r309886:
  When a zombie gets reparented due to the parent exit, send SIGCHLD to
  the reaper.

Modified:
  stable/11/sys/kern/kern_exit.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/kern/kern_exit.c
==============================================================================
--- stable/11/sys/kern/kern_exit.c	Mon Dec 26 09:56:52 2016	(r310580)
+++ stable/11/sys/kern/kern_exit.c	Mon Dec 26 10:01:52 2016	(r310581)
@@ -455,6 +455,11 @@ exit1(struct thread *td, int rval, int s
 
 		if (!(q->p_flag & P_TRACED)) {
 			proc_reparent(q, q->p_reaper);
+			if (q->p_state == PRS_ZOMBIE) {
+				PROC_LOCK(q->p_reaper);
+				pksignal(q->p_reaper, SIGCHLD, q->p_ksi);
+				PROC_UNLOCK(q->p_reaper);
+			}
 		} else {
 			/*
 			 * Traced processes are killed since their existence

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:03:34 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4BE8FC90176;
 Mon, 26 Dec 2016 10:03:34 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 1AB0E1AE;
 Mon, 26 Dec 2016 10:03:34 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQA3Xb4031402;
 Mon, 26 Dec 2016 10:03:33 GMT (envelope-from hselasky@FreeBSD.org)
Received: (from hselasky@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQA3XnI031401;
 Mon, 26 Dec 2016 10:03:33 GMT (envelope-from hselasky@FreeBSD.org)
Message-Id: <201612261003.uBQA3XnI031401@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: hselasky set sender to
 hselasky@FreeBSD.org using -f
From: Hans Petter Selasky <hselasky@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:03:33 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310583 - head/sys/compat/linuxkpi/common/include/linux
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:03:34 -0000

Author: hselasky
Date: Mon Dec 26 10:03:33 2016
New Revision: 310583
URL: https://svnweb.freebsd.org/changeset/base/310583

Log:
  Fix LINT build.
  
  Found by:	mmel @
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/fs.h

Modified: head/sys/compat/linuxkpi/common/include/linux/fs.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/fs.h	Mon Dec 26 10:02:02 2016	(r310582)
+++ head/sys/compat/linuxkpi/common/include/linux/fs.h	Mon Dec 26 10:03:33 2016	(r310583)
@@ -217,7 +217,7 @@ static inline dev_t
 iminor(struct inode *inode)
 {
 
-	return (MINOR(dev2unit(inode->v_rdev)));
+	return (minor(dev2unit(inode->v_rdev)));
 }
 
 static inline struct inode *

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:05:03 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id C9B55C9034A;
 Mon, 26 Dec 2016 10:05:03 +0000 (UTC) (envelope-from hps@selasky.org)
Received: from mail.turbocat.net (turbocat.net [88.99.82.50])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 9119D7AD;
 Mon, 26 Dec 2016 10:05:03 +0000 (UTC) (envelope-from hps@selasky.org)
Received: from hps2016.home.selasky.org (unknown [62.141.129.119])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (No client certificate requested)
 by mail.turbocat.net (Postfix) with ESMTPSA id 4F03C1FE157;
 Mon, 26 Dec 2016 11:04:53 +0100 (CET)
Subject: Re: svn commit: r310559 - in head/sys/compat/linuxkpi/common:
 include/linux src
To: mmel@freebsd.org, src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
References: <201612260118.uBQ1I8Dm015288@repo.freebsd.org>
 <eb3ae7ea-0881-d76f-788e-c200aa22fc45@freebsd.org>
 <4cd92dee-4cb2-954d-7157-6fcd122131c2@selasky.org>
From: Hans Petter Selasky <hps@selasky.org>
Message-ID: <97224f13-5334-f6f0-4917-0b32a3e3ecca@selasky.org>
Date: Mon, 26 Dec 2016 11:04:30 +0100
User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101
 Thunderbird/45.4.0
MIME-Version: 1.0
In-Reply-To: <4cd92dee-4cb2-954d-7157-6fcd122131c2@selasky.org>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:05:03 -0000

Hi,

Looks like this build error slipped under my -DNO_CLEAN flag. Sorry .

Fixed in r310583 .

--HPS

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:13:54 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6901CC906CB;
 Mon, 26 Dec 2016 10:13:54 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 2D773CAB;
 Mon, 26 Dec 2016 10:13:54 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQADrqM035437;
 Mon, 26 Dec 2016 10:13:53 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQADrGG035436;
 Mon, 26 Dec 2016 10:13:53 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261013.uBQADrGG035436@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:13:53 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310584 - stable/10/sys/kern
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:13:54 -0000

Author: kib
Date: Mon Dec 26 10:13:53 2016
New Revision: 310584
URL: https://svnweb.freebsd.org/changeset/base/310584

Log:
  MFC r310302:
  Do not clear KN_INFLUX when not owning influx state.
  
  PR:	214923

Modified:
  stable/10/sys/kern/kern_event.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/kern/kern_event.c
==============================================================================
--- stable/10/sys/kern/kern_event.c	Mon Dec 26 10:03:33 2016	(r310583)
+++ stable/10/sys/kern/kern_event.c	Mon Dec 26 10:13:53 2016	(r310584)
@@ -1935,6 +1935,7 @@ knote(struct knlist *list, long hint, in
 	struct kqueue *kq;
 	struct knote *kn, *tkn;
 	int error;
+	bool own_influx;
 
 	if (list == NULL)
 		return;
@@ -1965,11 +1966,14 @@ knote(struct knlist *list, long hint, in
 			 */
 			KQ_UNLOCK(kq);
 		} else if ((lockflags & KNF_NOKQLOCK) != 0) {
-			kn->kn_status |= KN_INFLUX;
+			own_influx = (kn->kn_status & KN_INFLUX) == 0;
+			if (own_influx)
+				kn->kn_status |= KN_INFLUX;
 			KQ_UNLOCK(kq);
 			error = kn->kn_fop->f_event(kn, hint);
 			KQ_LOCK(kq);
-			kn->kn_status &= ~KN_INFLUX;
+			if (own_influx)
+				kn->kn_status &= ~KN_INFLUX;
 			if (error)
 				KNOTE_ACTIVATE(kn, 1);
 			KQ_UNLOCK_FLUX(kq);

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:16:06 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A9696C907C3;
 Mon, 26 Dec 2016 10:16:06 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 78A20E9E;
 Mon, 26 Dec 2016 10:16:06 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQAG5KJ035581;
 Mon, 26 Dec 2016 10:16:05 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQAG563035580;
 Mon, 26 Dec 2016 10:16:05 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261016.uBQAG563035580@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:16:05 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310585 - stable/10/sys/kern
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:16:06 -0000

Author: kib
Date: Mon Dec 26 10:16:05 2016
New Revision: 310585
URL: https://svnweb.freebsd.org/changeset/base/310585

Log:
  MFC r309886:
  When a zombie gets reparented due to the parent exit, send SIGCHLD to
  the reaper.

Modified:
  stable/10/sys/kern/kern_exit.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/kern/kern_exit.c
==============================================================================
--- stable/10/sys/kern/kern_exit.c	Mon Dec 26 10:13:53 2016	(r310584)
+++ stable/10/sys/kern/kern_exit.c	Mon Dec 26 10:16:05 2016	(r310585)
@@ -499,6 +499,11 @@ exit1(struct thread *td, int rv)
 
 		if (!(q->p_flag & P_TRACED)) {
 			proc_reparent(q, q->p_reaper);
+			if (q->p_state == PRS_ZOMBIE) {
+				PROC_LOCK(q->p_reaper);
+				pksignal(q->p_reaper, SIGCHLD, q->p_ksi);
+				PROC_UNLOCK(q->p_reaper);
+			}
 		} else {
 			/*
 			 * Traced processes are killed since their existence

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:17:23 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D3212C9085D;
 Mon, 26 Dec 2016 10:17:23 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id AD38A83;
 Mon, 26 Dec 2016 10:17:23 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQAHMQp035681;
 Mon, 26 Dec 2016 10:17:22 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQAHMnE035676;
 Mon, 26 Dec 2016 10:17:22 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612261017.uBQAHMnE035676@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:17:22 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310586 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:17:23 -0000

Author: ngie
Date: Mon Dec 26 10:17:22 2016
New Revision: 310586
URL: https://svnweb.freebsd.org/changeset/base/310586

Log:
  Refactor transport sources a bit to facilitate changes coming down pipeline
  
  Add recv callback to transport layer to better facilitate code reuse and
  readability and for symmetry with send callback. Move recv_dgram and
  recv_stream to udp_recv and lsock_recv, respectively, and make the
  beforementioned functions recv callbacks for the udp and lsock transports,
  respectively.
  
  Consolidate the check_priv* functions in their relevant trans*.c source to
  limit scope/use.
  
  Note: this code is roughly based content from the submitter, although this
  was modified to be more of a direct move from snmpd/main.c to the trans_*.c
  sources, and to reduce unnecessary static function declarations.
  
  MFC after:	2 weeks
  Submitted by:	Thor Steingrimsson <thor.steingrimsson@isilon.com>
  Sponsored by:	Dell EMC Isilon

Modified:
  head/contrib/bsnmp/snmpd/main.c
  head/contrib/bsnmp/snmpd/snmpd.h
  head/contrib/bsnmp/snmpd/trans_lsock.c
  head/contrib/bsnmp/snmpd/trans_udp.c

Modified: head/contrib/bsnmp/snmpd/main.c
==============================================================================
--- head/contrib/bsnmp/snmpd/main.c	Mon Dec 26 10:16:05 2016	(r310585)
+++ head/contrib/bsnmp/snmpd/main.c	Mon Dec 26 10:17:22 2016	(r310586)
@@ -1024,154 +1024,6 @@ snmp_input_consume(struct port_input *pi
 	pi->length -= pi->consumed;
 }
 
-static void
-check_priv_dgram(struct port_input *pi, struct sockcred *cred)
-{
-
-	/* process explicitly sends credentials */
-	if (cred)
-		pi->priv = (cred->sc_euid == 0);
-	else
-		pi->priv = 0;
-}
-
-static void
-check_priv_stream(struct port_input *pi)
-{
-	struct xucred ucred;
-	socklen_t ucredlen;
-
-	/* obtain the accept time credentials */
-	ucredlen = sizeof(ucred);
-
-	if (getsockopt(pi->fd, 0, LOCAL_PEERCRED, &ucred, &ucredlen) == 0 &&
-	    ucredlen >= sizeof(ucred) && ucred.cr_version == XUCRED_VERSION)
-		pi->priv = (ucred.cr_uid == 0);
-	else
-		pi->priv = 0;
-}
-
-/*
- * Input from a stream socket.
- */
-static int
-recv_stream(struct port_input *pi)
-{
-	struct msghdr msg;
-	struct iovec iov[1];
-	ssize_t len;
-
-	if (pi->buf == NULL) {
-		/* no buffer yet - allocate one */
-		if ((pi->buf = buf_alloc(0)) == NULL) {
-			/* ups - could not get buffer. Return an error
-			 * the caller must close the transport. */
-			return (-1);
-		}
-		pi->buflen = buf_size(0);
-		pi->consumed = 0;
-		pi->length = 0;
-	}
-
-	/* try to get a message */
-	msg.msg_name = pi->peer;
-	msg.msg_namelen = pi->peerlen;
-	msg.msg_iov = iov;
-	msg.msg_iovlen = 1;
-	msg.msg_control = NULL;
-	msg.msg_controllen = 0;
-	msg.msg_flags = 0;
-
-	iov[0].iov_base = pi->buf + pi->length;
-	iov[0].iov_len = pi->buflen - pi->length;
-
-	len = recvmsg(pi->fd, &msg, 0);
-
-	if (len == -1 || len == 0)
-		/* receive error */
-		return (-1);
-
-	pi->length += len;
-
-	if (pi->cred)
-		check_priv_stream(pi);
-
-	return (0);
-}
-
-/*
- * Input from a datagram socket.
- * Each receive should return one datagram.
- */
-static int
-recv_dgram(struct port_input *pi, struct in_addr *laddr)
-{
-	u_char embuf[1000];
-	char cbuf[CMSG_SPACE(SOCKCREDSIZE(CMGROUP_MAX)) +
-	    CMSG_SPACE(sizeof(struct in_addr))];
-	struct msghdr msg;
-	struct iovec iov[1];
-	ssize_t len;
-	struct cmsghdr *cmsg;
-	struct sockcred *cred = NULL;
-
-	if (pi->buf == NULL) {
-		/* no buffer yet - allocate one */
-		if ((pi->buf = buf_alloc(0)) == NULL) {
-			/* ups - could not get buffer. Read away input
-			 * and drop it */
-			(void)recvfrom(pi->fd, embuf, sizeof(embuf),
-			    0, NULL, NULL);
-			/* return error */
-			return (-1);
-		}
-		pi->buflen = buf_size(0);
-	}
-
-	/* try to get a message */
-	msg.msg_name = pi->peer;
-	msg.msg_namelen = pi->peerlen;
-	msg.msg_iov = iov;
-	msg.msg_iovlen = 1;
-	memset(cbuf, 0, sizeof(cbuf));
-	msg.msg_control = cbuf;
-	msg.msg_controllen = sizeof(cbuf);
-	msg.msg_flags = 0;
-
-	iov[0].iov_base = pi->buf;
-	iov[0].iov_len = pi->buflen;
-
-	len = recvmsg(pi->fd, &msg, 0);
-
-	if (len == -1 || len == 0)
-		/* receive error */
-		return (-1);
-
-	if (msg.msg_flags & MSG_TRUNC) {
-		/* truncated - drop */
-		snmpd_stats.silentDrops++;
-		snmpd_stats.inTooLong++;
-		return (-1);
-	}
-
-	pi->length = (size_t)len;
-
-	for (cmsg = CMSG_FIRSTHDR(&msg); cmsg != NULL;
-	    cmsg = CMSG_NXTHDR(&msg, cmsg)) {
-		if (cmsg->cmsg_level == IPPROTO_IP &&
-		    cmsg->cmsg_type == IP_RECVDSTADDR)
-			memcpy(laddr, CMSG_DATA(cmsg), sizeof(struct in_addr));
-		if (cmsg->cmsg_level == SOL_SOCKET &&
-		    cmsg->cmsg_type == SCM_CREDS)
-			cred = (struct sockcred *)CMSG_DATA(cmsg);
-	}
-
-	if (pi->cred)
-		check_priv_dgram(pi, cred);
-
-	return (0);
-}
-
 /*
  * Input from a socket
  */
@@ -1191,35 +1043,8 @@ snmpd_input(struct port_input *pi, struc
 #endif
 	struct msghdr msg;
 	struct iovec iov[1];
-	char cbuf[CMSG_SPACE(sizeof(struct in_addr))];
-	struct cmsghdr *cmsgp;
-
-	/* get input depending on the transport */
-	if (pi->stream) {
-		msg.msg_control = NULL;
-		msg.msg_controllen = 0;
-
-		ret = recv_stream(pi);
-	} else {
-		struct in_addr *laddr;
-
-		memset(cbuf, 0, CMSG_SPACE(sizeof(struct in_addr)));
-		msg.msg_control = cbuf;
-		msg.msg_controllen = CMSG_SPACE(sizeof(struct in_addr));
-		cmsgp = CMSG_FIRSTHDR(&msg);
-		cmsgp->cmsg_len = CMSG_LEN(sizeof(struct in_addr));
-		cmsgp->cmsg_level = IPPROTO_IP;
-		cmsgp->cmsg_type = IP_SENDSRCADDR;
-		laddr = (struct in_addr *)CMSG_DATA(cmsgp);
-		
-		ret = recv_dgram(pi, laddr);
-
-		if (laddr->s_addr == 0) {
-			msg.msg_control = NULL;
-			msg.msg_controllen = 0;
-		}
-	}
 
+	ret = tport->transport->vtab->recv(pi);
 	if (ret == -1)
 		return (-1);
 

Modified: head/contrib/bsnmp/snmpd/snmpd.h
==============================================================================
--- head/contrib/bsnmp/snmpd/snmpd.h	Mon Dec 26 10:16:05 2016	(r310585)
+++ head/contrib/bsnmp/snmpd/snmpd.h	Mon Dec 26 10:17:22 2016	(r310586)
@@ -193,6 +193,7 @@ struct transport_def {
 
 	ssize_t		(*send)(struct tport *, const u_char *, size_t,
 			    const struct sockaddr *, size_t);
+	ssize_t         (*recv)(struct port_input *);
 };
 struct transport {
 	struct asn_oid	index;		/* transport table index */

Modified: head/contrib/bsnmp/snmpd/trans_lsock.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_lsock.c	Mon Dec 26 10:16:05 2016	(r310585)
+++ head/contrib/bsnmp/snmpd/trans_lsock.c	Mon Dec 26 10:17:22 2016	(r310586)
@@ -33,6 +33,7 @@
 #include <sys/types.h>
 #include <sys/queue.h>
 #include <sys/stat.h>
+#include <sys/ucred.h>
 #include <sys/un.h>
 
 #include <errno.h>
@@ -58,6 +59,7 @@ static void lsock_close_port(struct tpor
 static int lsock_init_port(struct tport *);
 static ssize_t lsock_send(struct tport *, const u_char *, size_t,
     const struct sockaddr *, size_t);
+static ssize_t lsock_recv(struct port_input *);
 
 /* exported */
 const struct transport_def lsock_trans = {
@@ -67,7 +69,8 @@ const struct transport_def lsock_trans =
 	lsock_stop,
 	lsock_close_port,
 	lsock_init_port,
-	lsock_send
+	lsock_send,
+	lsock_recv
 };
 static struct transport *my_trans;
 
@@ -421,6 +424,73 @@ lsock_send(struct tport *tp, const u_cha
 	return (sendto(peer->input.fd, buf, len, 0, addr, addrlen));
 }
 
+static void
+check_priv_stream(struct port_input *pi)
+{
+	struct xucred ucred;
+	socklen_t ucredlen;
+
+	/* obtain the accept time credentials */
+	ucredlen = sizeof(ucred);
+
+	if (getsockopt(pi->fd, 0, LOCAL_PEERCRED, &ucred, &ucredlen) == 0 &&
+	    ucredlen >= sizeof(ucred) && ucred.cr_version == XUCRED_VERSION)
+		pi->priv = (ucred.cr_uid == 0);
+	else
+		pi->priv = 0;
+}
+
+/*
+ * Receive something
+ */
+static ssize_t
+lsock_recv(struct port_input *pi)
+{
+	struct msghdr msg;
+	struct iovec iov[1];
+	ssize_t len;
+
+	msg.msg_control = NULL;
+	msg.msg_controllen = 0;
+
+	if (pi->buf == NULL) {
+		/* no buffer yet - allocate one */
+		if ((pi->buf = buf_alloc(0)) == NULL) {
+			/* ups - could not get buffer. Return an error
+			 * the caller must close the transport. */
+			return (-1);
+		}
+		pi->buflen = buf_size(0);
+		pi->consumed = 0;
+		pi->length = 0;
+	}
+
+	/* try to get a message */
+	msg.msg_name = pi->peer;
+	msg.msg_namelen = pi->peerlen;
+	msg.msg_iov = iov;
+	msg.msg_iovlen = 1;
+	msg.msg_control = NULL;
+	msg.msg_controllen = 0;
+	msg.msg_flags = 0;
+
+	iov[0].iov_base = pi->buf + pi->length;
+	iov[0].iov_len = pi->buflen - pi->length;
+
+	len = recvmsg(pi->fd, &msg, 0);
+
+	if (len == -1 || len == 0)
+		/* receive error */
+		return (-1);
+
+	pi->length += len;
+
+	if (pi->cred)
+		check_priv_stream(pi);
+
+	return (0);
+}
+
 /*
  * Dependency to create a lsock port
  */

Modified: head/contrib/bsnmp/snmpd/trans_udp.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_udp.c	Mon Dec 26 10:16:05 2016	(r310585)
+++ head/contrib/bsnmp/snmpd/trans_udp.c	Mon Dec 26 10:17:22 2016	(r310586)
@@ -32,6 +32,7 @@
  */
 #include <sys/types.h>
 #include <sys/queue.h>
+#include <sys/ucred.h>
 
 #include <stdlib.h>
 #include <syslog.h>
@@ -54,6 +55,7 @@ static void udp_close_port(struct tport 
 static int udp_init_port(struct tport *);
 static ssize_t udp_send(struct tport *, const u_char *, size_t,
     const struct sockaddr *, size_t);
+static ssize_t udp_recv(struct port_input *);
 
 /* exported */
 const struct transport_def udp_trans = {
@@ -63,7 +65,8 @@ const struct transport_def udp_trans = {
 	udp_stop,
 	udp_close_port,
 	udp_init_port,
-	udp_send
+	udp_send,
+	udp_recv
 };
 static struct transport *my_trans;
 
@@ -218,6 +221,123 @@ udp_send(struct tport *tp, const u_char 
 	return (sendto(p->input.fd, buf, len, 0, addr, addrlen));
 }
 
+static void
+check_priv_dgram(struct port_input *pi, struct sockcred *cred)
+{
+
+	/* process explicitly sends credentials */
+	if (cred)
+		pi->priv = (cred->sc_euid == 0);
+	else
+		pi->priv = 0;
+}
+
+/*
+ * Input from a datagram socket.
+ * Each receive should return one datagram.
+ */
+static int
+recv_dgram(struct port_input *pi, struct in_addr *laddr)
+{
+	u_char embuf[1000];
+	char cbuf[CMSG_SPACE(SOCKCREDSIZE(CMGROUP_MAX)) +
+	    CMSG_SPACE(sizeof(struct in_addr))];
+	struct msghdr msg;
+	struct iovec iov[1];
+	ssize_t len;
+	struct cmsghdr *cmsg;
+	struct sockcred *cred = NULL;
+
+	if (pi->buf == NULL) {
+		/* no buffer yet - allocate one */
+		if ((pi->buf = buf_alloc(0)) == NULL) {
+			/* ups - could not get buffer. Read away input
+			 * and drop it */
+			(void)recvfrom(pi->fd, embuf, sizeof(embuf),
+			    0, NULL, NULL);
+			/* return error */
+			return (-1);
+		}
+		pi->buflen = buf_size(0);
+	}
+
+	/* try to get a message */
+	msg.msg_name = pi->peer;
+	msg.msg_namelen = pi->peerlen;
+	msg.msg_iov = iov;
+	msg.msg_iovlen = 1;
+	memset(cbuf, 0, sizeof(cbuf));
+	msg.msg_control = cbuf;
+	msg.msg_controllen = sizeof(cbuf);
+	msg.msg_flags = 0;
+
+	iov[0].iov_base = pi->buf;
+	iov[0].iov_len = pi->buflen;
+
+	len = recvmsg(pi->fd, &msg, 0);
+
+	if (len == -1 || len == 0)
+		/* receive error */
+		return (-1);
+
+	if (msg.msg_flags & MSG_TRUNC) {
+		/* truncated - drop */
+		snmpd_stats.silentDrops++;
+		snmpd_stats.inTooLong++;
+		return (-1);
+	}
+
+	pi->length = (size_t)len;
+
+	for (cmsg = CMSG_FIRSTHDR(&msg); cmsg != NULL;
+	    cmsg = CMSG_NXTHDR(&msg, cmsg)) {
+		if (cmsg->cmsg_level == IPPROTO_IP &&
+		    cmsg->cmsg_type == IP_RECVDSTADDR)
+			memcpy(laddr, CMSG_DATA(cmsg), sizeof(struct in_addr));
+		if (cmsg->cmsg_level == SOL_SOCKET &&
+		    cmsg->cmsg_type == SCM_CREDS)
+			cred = (struct sockcred *)CMSG_DATA(cmsg);
+	}
+
+	if (pi->cred)
+		check_priv_dgram(pi, cred);
+
+	return (0);
+}
+
+/*
+ * Receive something
+ */
+static ssize_t
+udp_recv(struct port_input *pi)
+{
+	struct in_addr *laddr;
+	struct msghdr msg;
+	char cbuf[CMSG_SPACE(sizeof(struct in_addr))];
+	struct cmsghdr *cmsgp;
+	ssize_t ret;
+
+	memset(cbuf, 0, sizeof(cbuf));
+
+	msg.msg_control = cbuf;
+	msg.msg_controllen = sizeof(cbuf);
+
+	cmsgp = CMSG_FIRSTHDR(&msg);
+	cmsgp->cmsg_len = CMSG_LEN(sizeof(struct in_addr));
+	cmsgp->cmsg_level = IPPROTO_IP;
+	cmsgp->cmsg_type = IP_SENDSRCADDR;
+	laddr = (struct in_addr *)CMSG_DATA(cmsgp);
+
+	ret = recv_dgram(pi, laddr);
+
+	if (laddr->s_addr == INADDR_ANY) {
+		msg.msg_control = NULL;
+		msg.msg_controllen = 0;
+	}
+
+	return (ret);
+}
+
 /*
  * Port table
  */

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:21:29 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id AA428C909F7;
 Mon, 26 Dec 2016 10:21:29 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 79C0E6A2;
 Mon, 26 Dec 2016 10:21:29 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQALSBL038147;
 Mon, 26 Dec 2016 10:21:28 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQALSFf038146;
 Mon, 26 Dec 2016 10:21:28 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612261021.uBQALSFf038146@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:21:28 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310587 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:21:29 -0000

Author: ngie
Date: Mon Dec 26 10:21:28 2016
New Revision: 310587
URL: https://svnweb.freebsd.org/changeset/base/310587

Log:
  Fix definition for recv_dgram(..); it should be "ssize_t", not "int"
  
  I'm not sure why this wasn't flagged as an issue by the compiler, yet
  
  MFC after:	3 weeks
  X-MFC with:	r310586

Modified:
  head/contrib/bsnmp/snmpd/trans_udp.c

Modified: head/contrib/bsnmp/snmpd/trans_udp.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_udp.c	Mon Dec 26 10:17:22 2016	(r310586)
+++ head/contrib/bsnmp/snmpd/trans_udp.c	Mon Dec 26 10:21:28 2016	(r310587)
@@ -236,7 +236,7 @@ check_priv_dgram(struct port_input *pi, 
  * Input from a datagram socket.
  * Each receive should return one datagram.
  */
-static int
+static ssize_t
 recv_dgram(struct port_input *pi, struct in_addr *laddr)
 {
 	u_char embuf[1000];

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:24:49 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9D625C90C92;
 Mon, 26 Dec 2016 10:24:49 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6A30EA1A;
 Mon, 26 Dec 2016 10:24:49 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQAOm0K040030;
 Mon, 26 Dec 2016 10:24:48 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQAOmhD040029;
 Mon, 26 Dec 2016 10:24:48 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612261024.uBQAOmhD040029@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:24:48 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310588 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:24:49 -0000

Author: ngie
Date: Mon Dec 26 10:24:48 2016
New Revision: 310588
URL: https://svnweb.freebsd.org/changeset/base/310588

Log:
  Fix return type for `ret` (recv callback) and sort variables by alignment
  
  Again, for reasons I don't yet understand, this is not being flagged by the
  compiler. Unlike the issue addressed in r310587, this problem existed prior
  to r310586
  
  MFC after:	2 weeks
  X-MFC with:	r310586, r310587

Modified:
  head/contrib/bsnmp/snmpd/main.c

Modified: head/contrib/bsnmp/snmpd/main.c
==============================================================================
--- head/contrib/bsnmp/snmpd/main.c	Mon Dec 26 10:21:28 2016	(r310587)
+++ head/contrib/bsnmp/snmpd/main.c	Mon Dec 26 10:24:48 2016	(r310588)
@@ -1035,9 +1035,8 @@ snmpd_input(struct port_input *pi, struc
 	struct snmp_pdu pdu;
 	enum snmpd_input_err ierr, ferr;
 	enum snmpd_proxy_err perr;
+	ssize_t ret, slen;
 	int32_t vi;
-	int ret;
-	ssize_t slen;
 #ifdef USE_TCPWRAPPERS
 	char client[16];
 #endif

From owner-svn-src-all@freebsd.org  Mon Dec 26 10:41:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 52CA8C0B32E;
 Mon, 26 Dec 2016 10:41:53 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 03EF3875;
 Mon, 26 Dec 2016 10:41:52 +0000 (UTC)
 (envelope-from hselasky@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQAfqAB047026;
 Mon, 26 Dec 2016 10:41:52 GMT (envelope-from hselasky@FreeBSD.org)
Received: (from hselasky@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQAfqCs047025;
 Mon, 26 Dec 2016 10:41:52 GMT (envelope-from hselasky@FreeBSD.org)
Message-Id: <201612261041.uBQAfqCs047025@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: hselasky set sender to
 hselasky@FreeBSD.org using -f
From: Hans Petter Selasky <hselasky@FreeBSD.org>
Date: Mon, 26 Dec 2016 10:41:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310589 - head/sys/compat/linuxkpi/common/include/linux
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 10:41:53 -0000

Author: hselasky
Date: Mon Dec 26 10:41:51 2016
New Revision: 310589
URL: https://svnweb.freebsd.org/changeset/base/310589

Log:
  Implement more list header file functions.
  Add definition guard for the list_head structure.
  
  Obtained from:	kmacy @
  MFC after:	1 week
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/list.h

Modified: head/sys/compat/linuxkpi/common/include/linux/list.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/list.h	Mon Dec 26 10:24:48 2016	(r310588)
+++ head/sys/compat/linuxkpi/common/include/linux/list.h	Mon Dec 26 10:41:51 2016	(r310589)
@@ -72,10 +72,18 @@
 
 #define	prefetch(x)
 
+#define LINUX_LIST_HEAD_INIT(name) { &(name), &(name) }
+
+#define LINUX_LIST_HEAD(name) \
+	struct list_head name = LINUX_LIST_HEAD_INIT(name)
+
+#ifndef LIST_HEAD_DEF
+#define	LIST_HEAD_DEF
 struct list_head {
 	struct list_head *next;
 	struct list_head *prev;
 };
+#endif
 
 static inline void
 INIT_LIST_HEAD(struct list_head *list)
@@ -91,12 +99,26 @@ list_empty(const struct list_head *head)
 	return (head->next == head);
 }
 
+static inline int
+list_empty_careful(const struct list_head *head)
+{
+	struct list_head *next = head->next;
+
+	return ((next == head) && (next == head->prev));
+}
+
+static inline void
+__list_del(struct list_head *prev, struct list_head *next)
+{
+	next->prev = prev;
+	WRITE_ONCE(prev->next, next);
+}
+
 static inline void
 list_del(struct list_head *entry)
 {
 
-	entry->next->prev = entry->prev;
-	entry->prev->next = entry->next;
+	__list_del(entry->prev, entry->next);
 }
 
 static inline void
@@ -183,6 +205,11 @@ list_del_init(struct list_head *entry)
 	for (p = list_entry((h)->prev, typeof(*p), field); &(p)->field != (h); \
 	    p = list_entry((p)->field.prev, typeof(*p), field))
 
+#define	list_for_each_entry_safe_reverse(p, n, h, field)		\
+	for (p = list_entry((h)->prev, typeof(*p), field), 		\
+	    n = list_entry((p)->field.prev, typeof(*p), field); &(p)->field != (h); \
+	    p = n, n = list_entry(n->field.prev, typeof(*n), field))
+
 #define	list_for_each_entry_continue_reverse(p, h, field) \
 	for (p = list_entry((p)->field.prev, typeof(*p), field); &(p)->field != (h); \
 	    p = list_entry((p)->field.prev, typeof(*p), field))

From owner-svn-src-all@freebsd.org  Mon Dec 26 11:06:43 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9C779C0BB75;
 Mon, 26 Dec 2016 11:06:43 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 38D1A1337;
 Mon, 26 Dec 2016 11:06:43 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQB6gUZ056166;
 Mon, 26 Dec 2016 11:06:42 GMT (envelope-from tuexen@FreeBSD.org)
Received: (from tuexen@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQB6fi0056159;
 Mon, 26 Dec 2016 11:06:41 GMT (envelope-from tuexen@FreeBSD.org)
Message-Id: <201612261106.uBQB6fi0056159@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: tuexen set sender to
 tuexen@FreeBSD.org using -f
From: Michael Tuexen <tuexen@FreeBSD.org>
Date: Mon, 26 Dec 2016 11:06:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310590 - in head/sys: netinet netinet6
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 11:06:43 -0000

Author: tuexen
Date: Mon Dec 26 11:06:41 2016
New Revision: 310590
URL: https://svnweb.freebsd.org/changeset/base/310590

Log:
  Whitespace changes.
  
  The toolchain for processing the sources has been updated. No functional
  change.
  
  MFC after:	3 days

Modified:
  head/sys/netinet/sctp_asconf.c
  head/sys/netinet/sctp_auth.c
  head/sys/netinet/sctp_auth.h
  head/sys/netinet/sctp_bsd_addr.c
  head/sys/netinet/sctp_bsd_addr.h
  head/sys/netinet/sctp_cc_functions.c
  head/sys/netinet/sctp_crc32.c
  head/sys/netinet/sctp_indata.c
  head/sys/netinet/sctp_indata.h
  head/sys/netinet/sctp_input.c
  head/sys/netinet/sctp_input.h
  head/sys/netinet/sctp_output.c
  head/sys/netinet/sctp_output.h
  head/sys/netinet/sctp_pcb.c
  head/sys/netinet/sctp_pcb.h
  head/sys/netinet/sctp_ss_functions.c
  head/sys/netinet/sctp_structs.h
  head/sys/netinet/sctp_sysctl.c
  head/sys/netinet/sctp_timer.c
  head/sys/netinet/sctp_usrreq.c
  head/sys/netinet/sctputil.c
  head/sys/netinet/sctputil.h
  head/sys/netinet6/sctp6_usrreq.c

Modified: head/sys/netinet/sctp_asconf.c
==============================================================================
--- head/sys/netinet/sctp_asconf.c	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_asconf.c	Mon Dec 26 11:06:41 2016	(r310590)
@@ -97,7 +97,7 @@ sctp_asconf_success_response(uint32_t id
 }
 
 static struct mbuf *
-sctp_asconf_error_response(uint32_t id, uint16_t cause, uint8_t * error_tlv,
+sctp_asconf_error_response(uint32_t id, uint16_t cause, uint8_t *error_tlv,
     uint16_t tlv_length)
 {
 	struct mbuf *m_reply = NULL;
@@ -132,7 +132,7 @@ sctp_asconf_error_response(uint32_t id, 
 		return (NULL);
 	}
 	if (error_tlv != NULL) {
-		tlv = (uint8_t *) (error + 1);
+		tlv = (uint8_t *)(error + 1);
 		memcpy(tlv, error_tlv, tlv_length);
 	}
 	SCTP_BUF_LEN(m_reply) = aph->ph.param_length;
@@ -222,7 +222,7 @@ sctp_process_asconf_add_ip(struct sockad
 #endif
 	default:
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_INVALID_PARAM, (uint8_t *) aph,
+		    SCTP_CAUSE_INVALID_PARAM, (uint8_t *)aph,
 		    aparam_length);
 		return (m_reply);
 	}			/* end switch */
@@ -237,7 +237,7 @@ sctp_process_asconf_add_ip(struct sockad
 	/* add the address */
 	if (bad_address) {
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_INVALID_PARAM, (uint8_t *) aph,
+		    SCTP_CAUSE_INVALID_PARAM, (uint8_t *)aph,
 		    aparam_length);
 	} else if (sctp_add_remote_addr(stcb, sa, &net, stcb->asoc.port,
 		    SCTP_DONOT_SETSCOPE,
@@ -245,7 +245,7 @@ sctp_process_asconf_add_ip(struct sockad
 		SCTPDBG(SCTP_DEBUG_ASCONF1,
 		    "process_asconf_add_ip: error adding address\n");
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_RESOURCE_SHORTAGE, (uint8_t *) aph,
+		    SCTP_CAUSE_RESOURCE_SHORTAGE, (uint8_t *)aph,
 		    aparam_length);
 	} else {
 		/* notify upper layer */
@@ -367,7 +367,7 @@ sctp_process_asconf_delete_ip(struct soc
 #endif
 	default:
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *) aph,
+		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *)aph,
 		    aparam_length);
 		return (m_reply);
 	}
@@ -377,7 +377,7 @@ sctp_process_asconf_delete_ip(struct soc
 		/* trying to delete the source address! */
 		SCTPDBG(SCTP_DEBUG_ASCONF1, "process_asconf_delete_ip: tried to delete source addr\n");
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_DELETING_SRC_ADDR, (uint8_t *) aph,
+		    SCTP_CAUSE_DELETING_SRC_ADDR, (uint8_t *)aph,
 		    aparam_length);
 		return (m_reply);
 	}
@@ -391,7 +391,7 @@ sctp_process_asconf_delete_ip(struct soc
 			/* what error to reply with?? */
 			m_reply =
 			    sctp_asconf_error_response(aph->correlation_id,
-			    SCTP_CAUSE_REQUEST_REFUSED, (uint8_t *) aph,
+			    SCTP_CAUSE_REQUEST_REFUSED, (uint8_t *)aph,
 			    aparam_length);
 		} else if (response_required) {
 			m_reply =
@@ -410,7 +410,7 @@ sctp_process_asconf_delete_ip(struct soc
 		/* only one address in the asoc */
 		SCTPDBG(SCTP_DEBUG_ASCONF1, "process_asconf_delete_ip: tried to delete last IP addr!\n");
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_DELETING_LAST_ADDR, (uint8_t *) aph,
+		    SCTP_CAUSE_DELETING_LAST_ADDR, (uint8_t *)aph,
 		    aparam_length);
 	} else {
 		if (response_required) {
@@ -492,7 +492,7 @@ sctp_process_asconf_set_primary(struct s
 #endif
 	default:
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *) aph,
+		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *)aph,
 		    aparam_length);
 		return (m_reply);
 	}
@@ -563,7 +563,7 @@ sctp_process_asconf_set_primary(struct s
 		    "process_asconf_set_primary: set primary failed!\n");
 		/* must have been an invalid address, so report */
 		m_reply = sctp_asconf_error_response(aph->correlation_id,
-		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *) aph,
+		    SCTP_CAUSE_UNRESOLVABLE_ADDR, (uint8_t *)aph,
 		    aparam_length);
 	}
 
@@ -658,7 +658,7 @@ sctp_handle_asconf(struct mbuf *m, unsig
 
 	/* skip the lookup address parameter */
 	offset += sizeof(struct sctp_asconf_chunk);
-	p_addr = (struct sctp_ipv6addr_param *)sctp_m_getptr(m, offset, sizeof(struct sctp_paramhdr), (uint8_t *) & aparam_buf);
+	p_addr = (struct sctp_ipv6addr_param *)sctp_m_getptr(m, offset, sizeof(struct sctp_paramhdr), (uint8_t *)&aparam_buf);
 	if (p_addr == NULL) {
 		SCTPDBG(SCTP_DEBUG_ASCONF1,
 		    "handle_asconf: couldn't get lookup addr!\n");
@@ -668,7 +668,7 @@ sctp_handle_asconf(struct mbuf *m, unsig
 	/* param_length is already validated in process_control... */
 	offset += ntohs(p_addr->ph.param_length);	/* skip lookup addr */
 	/* get pointer to first asconf param in ASCONF */
-	aph = (struct sctp_asconf_paramhdr *)sctp_m_getptr(m, offset, sizeof(struct sctp_asconf_paramhdr), (uint8_t *) & aparam_buf);
+	aph = (struct sctp_asconf_paramhdr *)sctp_m_getptr(m, offset, sizeof(struct sctp_asconf_paramhdr), (uint8_t *)&aparam_buf);
 	if (aph == NULL) {
 		SCTPDBG(SCTP_DEBUG_ASCONF1, "Empty ASCONF received?\n");
 		goto send_reply;
@@ -765,7 +765,7 @@ sctp_handle_asconf(struct mbuf *m, unsig
 		/* get pointer to next asconf param */
 		aph = (struct sctp_asconf_paramhdr *)sctp_m_getptr(m, offset,
 		    sizeof(struct sctp_asconf_paramhdr),
-		    (uint8_t *) & aparam_buf);
+		    (uint8_t *)&aparam_buf);
 		if (aph == NULL) {
 			/* can't get an asconf paramhdr */
 			SCTPDBG(SCTP_DEBUG_ASCONF1, "handle_asconf: can't get asconf param hdr!\n");
@@ -1094,7 +1094,7 @@ sctp_path_check_and_react(struct sctp_tc
 		 * NOT corresponding to the current nexthop, the path will
 		 * not be changed.
 		 */
-		SCTP_RTALLOC((sctp_route_t *) & net->ro,
+		SCTP_RTALLOC((sctp_route_t *)&net->ro,
 		    stcb->sctp_ep->def_vrf_id,
 		    stcb->sctp_ep->fibnum);
 		if (net->ro.ro_rt == NULL)
@@ -1104,7 +1104,7 @@ sctp_path_check_and_react(struct sctp_tc
 		switch (net->ro._l_addr.sa.sa_family) {
 #ifdef INET
 		case AF_INET:
-			if (sctp_v4src_match_nexthop(newifa, (sctp_route_t *) & net->ro)) {
+			if (sctp_v4src_match_nexthop(newifa, (sctp_route_t *)&net->ro)) {
 				changed = 1;
 			}
 			break;
@@ -1112,7 +1112,7 @@ sctp_path_check_and_react(struct sctp_tc
 #ifdef INET6
 		case AF_INET6:
 			if (sctp_v6src_match_nexthop(
-			    &newifa->address.sin6, (sctp_route_t *) & net->ro)) {
+			    &newifa->address.sin6, (sctp_route_t *)&net->ro)) {
 				changed = 1;
 			}
 			break;
@@ -2419,8 +2419,10 @@ sctp_is_addr_pending(struct sctp_tcb *st
 		}
 	}
 
-	/* we want to find the sequences which consist of ADD -> DEL -> ADD
-	 * or DEL -> ADD */
+	/*
+	 * we want to find the sequences which consist of ADD -> DEL -> ADD
+	 * or DEL -> ADD
+	 */
 	if (add_cnt > del_cnt ||
 	    (add_cnt == del_cnt && last_param_type == SCTP_ADD_IP_ADDRESS)) {
 		return (1);
@@ -2472,8 +2474,10 @@ sctp_find_valid_localaddr(struct sctp_tc
 					if (sctp_is_addr_restricted(stcb, sctp_ifa) &&
 					    (!sctp_is_addr_pending(stcb, sctp_ifa)))
 						continue;
-					/* found a valid local v4 address to
-					 * use */
+					/*
+					 * found a valid local v4 address to
+					 * use
+					 */
 					if (addr_locked == SCTP_ADDR_NOT_LOCKED)
 						SCTP_IPI_ADDR_RUNLOCK();
 					return (&sctp_ifa->address.sa);
@@ -2490,8 +2494,10 @@ sctp_find_valid_localaddr(struct sctp_tc
 					}
 					sin6 = &sctp_ifa->address.sin6;
 					if (IN6_IS_ADDR_UNSPECIFIED(&sin6->sin6_addr)) {
-						/* we skip unspecifed
-						 * addresses */
+						/*
+						 * we skip unspecifed
+						 * addresses
+						 */
 						continue;
 					}
 					if (prison_check_ip6(stcb->sctp_ep->ip_inp.inp.inp_cred,
@@ -2508,8 +2514,10 @@ sctp_find_valid_localaddr(struct sctp_tc
 					if (sctp_is_addr_restricted(stcb, sctp_ifa) &&
 					    (!sctp_is_addr_pending(stcb, sctp_ifa)))
 						continue;
-					/* found a valid local v6 address to
-					 * use */
+					/*
+					 * found a valid local v6 address to
+					 * use
+					 */
 					if (addr_locked == SCTP_ADDR_NOT_LOCKED)
 						SCTP_IPI_ADDR_RUNLOCK();
 					return (&sctp_ifa->address.sa);
@@ -2777,7 +2785,7 @@ sctp_process_initack_addresses(struct sc
 	/* go through the addresses in the init-ack */
 	ph = (struct sctp_paramhdr *)
 	    sctp_m_getptr(m, offset, sizeof(struct sctp_paramhdr),
-	    (uint8_t *) & tmp_param);
+	    (uint8_t *)&tmp_param);
 	while (ph != NULL) {
 		ptype = ntohs(ph->param_type);
 		plen = ntohs(ph->param_length);
@@ -2791,7 +2799,7 @@ sctp_process_initack_addresses(struct sc
 				a6p = (struct sctp_ipv6addr_param *)
 				    sctp_m_getptr(m, offset,
 				    sizeof(struct sctp_ipv6addr_param),
-				    (uint8_t *) & addr6_store);
+				    (uint8_t *)&addr6_store);
 				if (plen != sizeof(struct sctp_ipv6addr_param) ||
 				    a6p == NULL) {
 					return;
@@ -2812,7 +2820,7 @@ sctp_process_initack_addresses(struct sc
 				/* get the entire IPv4 address param */
 				a4p = (struct sctp_ipv4addr_param *)sctp_m_getptr(m, offset,
 				    sizeof(struct sctp_ipv4addr_param),
-				    (uint8_t *) & addr4_store);
+				    (uint8_t *)&addr4_store);
 				if (plen != sizeof(struct sctp_ipv4addr_param) ||
 				    a4p == NULL) {
 					return;
@@ -2874,7 +2882,7 @@ next_addr:
 		if ((offset + sizeof(struct sctp_paramhdr)) > length)
 			return;
 		ph = (struct sctp_paramhdr *)sctp_m_getptr(m, offset,
-		    sizeof(struct sctp_paramhdr), (uint8_t *) & tmp_param);
+		    sizeof(struct sctp_paramhdr), (uint8_t *)&tmp_param);
 	}			/* while */
 }
 
@@ -2925,7 +2933,7 @@ sctp_addr_in_initack(struct mbuf *m, uin
 	}
 	/* go through the addresses in the init-ack */
 	ph = (struct sctp_paramhdr *)sctp_m_getptr(m, offset,
-	    sizeof(struct sctp_paramhdr), (uint8_t *) & tmp_param);
+	    sizeof(struct sctp_paramhdr), (uint8_t *)&tmp_param);
 	while (ph != NULL) {
 		ptype = ntohs(ph->param_type);
 		plen = ntohs(ph->param_length);
@@ -2941,7 +2949,7 @@ sctp_addr_in_initack(struct mbuf *m, uin
 				a6p = (struct sctp_ipv6addr_param *)
 				    sctp_m_getptr(m, offset,
 				    sizeof(struct sctp_ipv6addr_param),
-				    (uint8_t *) & addr6_store);
+				    (uint8_t *)&addr6_store);
 				if (a6p == NULL) {
 					return (0);
 				}
@@ -2971,7 +2979,7 @@ sctp_addr_in_initack(struct mbuf *m, uin
 				a4p = (struct sctp_ipv4addr_param *)
 				    sctp_m_getptr(m, offset,
 				    sizeof(struct sctp_ipv4addr_param),
-				    (uint8_t *) & addr4_store);
+				    (uint8_t *)&addr4_store);
 				if (a4p == NULL) {
 					return (0);
 				}
@@ -2993,7 +3001,7 @@ sctp_addr_in_initack(struct mbuf *m, uin
 		}
 		ph = (struct sctp_paramhdr *)
 		    sctp_m_getptr(m, offset, sizeof(struct sctp_paramhdr),
-		    (uint8_t *) & tmp_param);
+		    (uint8_t *)&tmp_param);
 	}			/* while */
 	/* not found! */
 	return (0);

Modified: head/sys/netinet/sctp_auth.c
==============================================================================
--- head/sys/netinet/sctp_auth.c	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_auth.c	Mon Dec 26 11:06:41 2016	(r310590)
@@ -51,7 +51,7 @@ __FBSDID("$FreeBSD$");
 
 
 void
-sctp_clear_chunklist(sctp_auth_chklist_t * chklist)
+sctp_clear_chunklist(sctp_auth_chklist_t *chklist)
 {
 	bzero(chklist, sizeof(*chklist));
 	/* chklist->num_chunks = 0; */
@@ -73,14 +73,14 @@ sctp_alloc_chunklist(void)
 }
 
 void
-sctp_free_chunklist(sctp_auth_chklist_t * list)
+sctp_free_chunklist(sctp_auth_chklist_t *list)
 {
 	if (list != NULL)
 		SCTP_FREE(list, SCTP_M_AUTH_CL);
 }
 
 sctp_auth_chklist_t *
-sctp_copy_chunklist(sctp_auth_chklist_t * list)
+sctp_copy_chunklist(sctp_auth_chklist_t *list)
 {
 	sctp_auth_chklist_t *new_list;
 
@@ -102,7 +102,7 @@ sctp_copy_chunklist(sctp_auth_chklist_t 
  * add a chunk to the required chunks list
  */
 int
-sctp_auth_add_chunk(uint8_t chunk, sctp_auth_chklist_t * list)
+sctp_auth_add_chunk(uint8_t chunk, sctp_auth_chklist_t *list)
 {
 	if (list == NULL)
 		return (-1);
@@ -128,7 +128,7 @@ sctp_auth_add_chunk(uint8_t chunk, sctp_
  * delete a chunk from the required chunks list
  */
 int
-sctp_auth_delete_chunk(uint8_t chunk, sctp_auth_chklist_t * list)
+sctp_auth_delete_chunk(uint8_t chunk, sctp_auth_chklist_t *list)
 {
 	if (list == NULL)
 		return (-1);
@@ -144,7 +144,7 @@ sctp_auth_delete_chunk(uint8_t chunk, sc
 }
 
 size_t
-sctp_auth_get_chklist_size(const sctp_auth_chklist_t * list)
+sctp_auth_get_chklist_size(const sctp_auth_chklist_t *list)
 {
 	if (list == NULL)
 		return (0);
@@ -157,7 +157,7 @@ sctp_auth_get_chklist_size(const sctp_au
  * guarantee ptr has space for up to 256 bytes
  */
 int
-sctp_serialize_auth_chunks(const sctp_auth_chklist_t * list, uint8_t * ptr)
+sctp_serialize_auth_chunks(const sctp_auth_chklist_t *list, uint8_t *ptr)
 {
 	int i, count = 0;
 
@@ -174,7 +174,7 @@ sctp_serialize_auth_chunks(const sctp_au
 }
 
 int
-sctp_pack_auth_chunks(const sctp_auth_chklist_t * list, uint8_t * ptr)
+sctp_pack_auth_chunks(const sctp_auth_chklist_t *list, uint8_t *ptr)
 {
 	int i, size = 0;
 
@@ -206,8 +206,8 @@ sctp_pack_auth_chunks(const sctp_auth_ch
 }
 
 int
-sctp_unpack_auth_chunks(const uint8_t * ptr, uint8_t num_chunks,
-    sctp_auth_chklist_t * list)
+sctp_unpack_auth_chunks(const uint8_t *ptr, uint8_t num_chunks,
+    sctp_auth_chklist_t *list)
 {
 	int i;
 	int size;
@@ -257,14 +257,14 @@ sctp_alloc_key(uint32_t keylen)
 }
 
 void
-sctp_free_key(sctp_key_t * key)
+sctp_free_key(sctp_key_t *key)
 {
 	if (key != NULL)
 		SCTP_FREE(key, SCTP_M_AUTH_KY);
 }
 
 void
-sctp_print_key(sctp_key_t * key, const char *str)
+sctp_print_key(sctp_key_t *key, const char *str)
 {
 	uint32_t i;
 
@@ -283,7 +283,7 @@ sctp_print_key(sctp_key_t * key, const c
 }
 
 void
-sctp_show_key(sctp_key_t * key, const char *str)
+sctp_show_key(sctp_key_t *key, const char *str)
 {
 	uint32_t i;
 
@@ -302,7 +302,7 @@ sctp_show_key(sctp_key_t * key, const ch
 }
 
 static uint32_t
-sctp_get_keylen(sctp_key_t * key)
+sctp_get_keylen(sctp_key_t *key)
 {
 	if (key != NULL)
 		return (key->keylen);
@@ -329,7 +329,7 @@ sctp_generate_random_key(uint32_t keylen
 }
 
 sctp_key_t *
-sctp_set_key(uint8_t * key, uint32_t keylen)
+sctp_set_key(uint8_t *key, uint32_t keylen)
 {
 	sctp_key_t *new_key;
 
@@ -349,7 +349,7 @@ sctp_set_key(uint8_t * key, uint32_t key
  *           0 if key1 = key2
  */
 static int
-sctp_compare_key(sctp_key_t * key1, sctp_key_t * key2)
+sctp_compare_key(sctp_key_t *key1, sctp_key_t *key2)
 {
 	uint32_t maxlen;
 	uint32_t i;
@@ -400,7 +400,7 @@ sctp_compare_key(sctp_key_t * key1, sctp
  * order for concatenation
  */
 sctp_key_t *
-sctp_compute_hashkey(sctp_key_t * key1, sctp_key_t * key2, sctp_key_t * shared)
+sctp_compute_hashkey(sctp_key_t *key1, sctp_key_t *key2, sctp_key_t *shared)
 {
 	uint32_t keylen;
 	sctp_key_t *new_key;
@@ -474,7 +474,7 @@ sctp_alloc_sharedkey(void)
 }
 
 void
-sctp_free_sharedkey(sctp_sharedkey_t * skey)
+sctp_free_sharedkey(sctp_sharedkey_t *skey)
 {
 	if (skey == NULL)
 		return;
@@ -500,7 +500,7 @@ sctp_find_sharedkey(struct sctp_keyhead 
 
 int
 sctp_insert_sharedkey(struct sctp_keyhead *shared_keys,
-    sctp_sharedkey_t * new_skey)
+    sctp_sharedkey_t *new_skey)
 {
 	sctp_sharedkey_t *skey;
 
@@ -594,7 +594,7 @@ sctp_auth_key_release(struct sctp_tcb *s
 }
 
 static sctp_sharedkey_t *
-sctp_copy_sharedkey(const sctp_sharedkey_t * skey)
+sctp_copy_sharedkey(const sctp_sharedkey_t *skey)
 {
 	sctp_sharedkey_t *new_skey;
 
@@ -652,7 +652,7 @@ sctp_alloc_hmaclist(uint16_t num_hmacs)
 }
 
 void
-sctp_free_hmaclist(sctp_hmaclist_t * list)
+sctp_free_hmaclist(sctp_hmaclist_t *list)
 {
 	if (list != NULL) {
 		SCTP_FREE(list, SCTP_M_AUTH_HL);
@@ -661,7 +661,7 @@ sctp_free_hmaclist(sctp_hmaclist_t * lis
 }
 
 int
-sctp_auth_add_hmacid(sctp_hmaclist_t * list, uint16_t hmac_id)
+sctp_auth_add_hmacid(sctp_hmaclist_t *list, uint16_t hmac_id)
 {
 	int i;
 
@@ -689,7 +689,7 @@ sctp_auth_add_hmacid(sctp_hmaclist_t * l
 }
 
 sctp_hmaclist_t *
-sctp_copy_hmaclist(sctp_hmaclist_t * list)
+sctp_copy_hmaclist(sctp_hmaclist_t *list)
 {
 	sctp_hmaclist_t *new_list;
 	int i;
@@ -727,7 +727,7 @@ sctp_default_supported_hmaclist(void)
  * find the best HMAC id to use for the peer based on local support
  */
 uint16_t
-sctp_negotiate_hmacid(sctp_hmaclist_t * peer, sctp_hmaclist_t * local)
+sctp_negotiate_hmacid(sctp_hmaclist_t *peer, sctp_hmaclist_t *local)
 {
 	int i, j;
 
@@ -754,7 +754,7 @@ sctp_negotiate_hmacid(sctp_hmaclist_t * 
  * caller must guarantee ptr has appropriate space
  */
 int
-sctp_serialize_hmaclist(sctp_hmaclist_t * list, uint8_t * ptr)
+sctp_serialize_hmaclist(sctp_hmaclist_t *list, uint8_t *ptr)
 {
 	int i;
 	uint16_t hmac_id;
@@ -800,7 +800,7 @@ sctp_alloc_authinfo(void)
 }
 
 void
-sctp_free_authinfo(sctp_authinfo_t * authinfo)
+sctp_free_authinfo(sctp_authinfo_t *authinfo)
 {
 	if (authinfo == NULL)
 		return;
@@ -858,7 +858,7 @@ sctp_get_hmac_block_len(uint16_t hmac_al
 }
 
 static void
-sctp_hmac_init(uint16_t hmac_algo, sctp_hash_context_t * ctx)
+sctp_hmac_init(uint16_t hmac_algo, sctp_hash_context_t *ctx)
 {
 	switch (hmac_algo) {
 	case SCTP_AUTH_HMAC_ID_SHA1:
@@ -875,8 +875,8 @@ sctp_hmac_init(uint16_t hmac_algo, sctp_
 }
 
 static void
-sctp_hmac_update(uint16_t hmac_algo, sctp_hash_context_t * ctx,
-    uint8_t * text, uint32_t textlen)
+sctp_hmac_update(uint16_t hmac_algo, sctp_hash_context_t *ctx,
+    uint8_t *text, uint32_t textlen)
 {
 	switch (hmac_algo) {
 	case SCTP_AUTH_HMAC_ID_SHA1:
@@ -893,8 +893,8 @@ sctp_hmac_update(uint16_t hmac_algo, sct
 }
 
 static void
-sctp_hmac_final(uint16_t hmac_algo, sctp_hash_context_t * ctx,
-    uint8_t * digest)
+sctp_hmac_final(uint16_t hmac_algo, sctp_hash_context_t *ctx,
+    uint8_t *digest)
 {
 	switch (hmac_algo) {
 	case SCTP_AUTH_HMAC_ID_SHA1:
@@ -921,8 +921,8 @@ sctp_hmac_final(uint16_t hmac_algo, sctp
  * resultant digest.
  */
 uint32_t
-sctp_hmac(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    uint8_t * text, uint32_t textlen, uint8_t * digest)
+sctp_hmac(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    uint8_t *text, uint32_t textlen, uint8_t *digest)
 {
 	uint32_t digestlen;
 	uint32_t blocklen;
@@ -981,8 +981,8 @@ sctp_hmac(uint16_t hmac_algo, uint8_t * 
 
 /* mbuf version */
 uint32_t
-sctp_hmac_m(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    struct mbuf *m, uint32_t m_offset, uint8_t * digest, uint32_t trailer)
+sctp_hmac_m(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    struct mbuf *m, uint32_t m_offset, uint8_t *digest, uint32_t trailer)
 {
 	uint32_t digestlen;
 	uint32_t blocklen;
@@ -1029,17 +1029,17 @@ sctp_hmac_m(uint16_t hmac_algo, uint8_t 
 	sctp_hmac_update(hmac_algo, &ctx, ipad, blocklen);
 	/* find the correct starting mbuf and offset (get start of text) */
 	m_tmp = m;
-	while ((m_tmp != NULL) && (m_offset >= (uint32_t) SCTP_BUF_LEN(m_tmp))) {
+	while ((m_tmp != NULL) && (m_offset >= (uint32_t)SCTP_BUF_LEN(m_tmp))) {
 		m_offset -= SCTP_BUF_LEN(m_tmp);
 		m_tmp = SCTP_BUF_NEXT(m_tmp);
 	}
 	/* now use the rest of the mbuf chain for the text */
 	while (m_tmp != NULL) {
 		if ((SCTP_BUF_NEXT(m_tmp) == NULL) && trailer) {
-			sctp_hmac_update(hmac_algo, &ctx, mtod(m_tmp, uint8_t *) + m_offset,
+			sctp_hmac_update(hmac_algo, &ctx, mtod(m_tmp, uint8_t *)+m_offset,
 			    SCTP_BUF_LEN(m_tmp) - (trailer + m_offset));
 		} else {
-			sctp_hmac_update(hmac_algo, &ctx, mtod(m_tmp, uint8_t *) + m_offset,
+			sctp_hmac_update(hmac_algo, &ctx, mtod(m_tmp, uint8_t *)+m_offset,
 			    SCTP_BUF_LEN(m_tmp) - m_offset);
 		}
 
@@ -1064,9 +1064,9 @@ sctp_hmac_m(uint16_t hmac_algo, uint8_t 
  * Returns -1 on error, 0 on success.
  */
 int
-sctp_verify_hmac(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    uint8_t * text, uint32_t textlen,
-    uint8_t * digest, uint32_t digestlen)
+sctp_verify_hmac(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    uint8_t *text, uint32_t textlen,
+    uint8_t *digest, uint32_t digestlen)
 {
 	uint32_t len;
 	uint8_t temp[SCTP_AUTH_DIGEST_LEN_MAX];
@@ -1097,8 +1097,8 @@ sctp_verify_hmac(uint16_t hmac_algo, uin
  * the keylen exceeds the HMAC block len).
  */
 uint32_t
-sctp_compute_hmac(uint16_t hmac_algo, sctp_key_t * key, uint8_t * text,
-    uint32_t textlen, uint8_t * digest)
+sctp_compute_hmac(uint16_t hmac_algo, sctp_key_t *key, uint8_t *text,
+    uint32_t textlen, uint8_t *digest)
 {
 	uint32_t digestlen;
 	uint32_t blocklen;
@@ -1132,8 +1132,8 @@ sctp_compute_hmac(uint16_t hmac_algo, sc
 
 /* mbuf version */
 uint32_t
-sctp_compute_hmac_m(uint16_t hmac_algo, sctp_key_t * key, struct mbuf *m,
-    uint32_t m_offset, uint8_t * digest)
+sctp_compute_hmac_m(uint16_t hmac_algo, sctp_key_t *key, struct mbuf *m,
+    uint32_t m_offset, uint8_t *digest)
 {
 	uint32_t digestlen;
 	uint32_t blocklen;
@@ -1164,7 +1164,7 @@ sctp_compute_hmac_m(uint16_t hmac_algo, 
 }
 
 int
-sctp_auth_is_supported_hmac(sctp_hmaclist_t * list, uint16_t id)
+sctp_auth_is_supported_hmac(sctp_hmaclist_t *list, uint16_t id)
 {
 	int i;
 
@@ -1422,7 +1422,7 @@ sctp_auth_get_cookie_params(struct sctp_
 	length += offset;
 
 	phdr = (struct sctp_paramhdr *)sctp_m_getptr(m, offset,
-	    sizeof(struct sctp_paramhdr), (uint8_t *) & tmp_param);
+	    sizeof(struct sctp_paramhdr), (uint8_t *)&tmp_param);
 	while (phdr != NULL) {
 		ptype = ntohs(phdr->param_type);
 		plen = ntohs(phdr->param_length);
@@ -1489,7 +1489,7 @@ sctp_auth_get_cookie_params(struct sctp_
 		if (offset + sizeof(struct sctp_paramhdr) > length)
 			break;
 		phdr = (struct sctp_paramhdr *)sctp_m_getptr(m, offset, sizeof(struct sctp_paramhdr),
-		    (uint8_t *) & tmp_param);
+		    (uint8_t *)&tmp_param);
 	}
 	/* concatenate the full random key */
 	keylen = sizeof(*p_random) + random_len + sizeof(*hmacs) + hmacs_len;
@@ -1599,14 +1599,14 @@ sctp_bzero_m(struct mbuf *m, uint32_t m_
 
 	/* find the correct starting mbuf and offset (get start position) */
 	m_tmp = m;
-	while ((m_tmp != NULL) && (m_offset >= (uint32_t) SCTP_BUF_LEN(m_tmp))) {
+	while ((m_tmp != NULL) && (m_offset >= (uint32_t)SCTP_BUF_LEN(m_tmp))) {
 		m_offset -= SCTP_BUF_LEN(m_tmp);
 		m_tmp = SCTP_BUF_NEXT(m_tmp);
 	}
 	/* now use the rest of the mbuf chain */
 	while ((m_tmp != NULL) && (size > 0)) {
-		data = mtod(m_tmp, uint8_t *) + m_offset;
-		if (size > (uint32_t) SCTP_BUF_LEN(m_tmp)) {
+		data = mtod(m_tmp, uint8_t *)+m_offset;
+		if (size > (uint32_t)SCTP_BUF_LEN(m_tmp)) {
 			bzero(data, SCTP_BUF_LEN(m_tmp));
 			size -= SCTP_BUF_LEN(m_tmp);
 		} else {

Modified: head/sys/netinet/sctp_auth.h
==============================================================================
--- head/sys/netinet/sctp_auth.h	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_auth.h	Mon Dec 26 11:06:41 2016	(r310590)
@@ -51,12 +51,12 @@ __FBSDID("$FreeBSD$");
 typedef union sctp_hash_context {
 	SCTP_SHA1_CTX sha1;
 	SCTP_SHA256_CTX sha256;
-}                 sctp_hash_context_t;
+} sctp_hash_context_t;
 
 typedef struct sctp_key {
 	uint32_t keylen;
 	uint8_t key[];
-}        sctp_key_t;
+} sctp_key_t;
 
 typedef struct sctp_shared_key {
 	LIST_ENTRY(sctp_shared_key) next;
@@ -64,7 +64,7 @@ typedef struct sctp_shared_key {
 	uint32_t refcount;	/* reference count */
 	uint16_t keyid;		/* shared key ID */
 	uint8_t deactivated;	/* key is deactivated */
-}               sctp_sharedkey_t;
+} sctp_sharedkey_t;
 
 LIST_HEAD(sctp_keyhead, sctp_shared_key);
 
@@ -72,14 +72,14 @@ LIST_HEAD(sctp_keyhead, sctp_shared_key)
 typedef struct sctp_auth_chklist {
 	uint8_t chunks[256];
 	uint8_t num_chunks;
-}                 sctp_auth_chklist_t;
+} sctp_auth_chklist_t;
 
 /* hmac algos supported list */
 typedef struct sctp_hmaclist {
 	uint16_t max_algo;	/* max algorithms allocated */
 	uint16_t num_algo;	/* num algorithms used */
 	uint16_t hmac[];
-}             sctp_hmaclist_t;
+} sctp_hmaclist_t;
 
 /* authentication info */
 typedef struct sctp_authinformation {
@@ -91,7 +91,7 @@ typedef struct sctp_authinformation {
 	uint16_t active_keyid;	/* active send keyid */
 	uint16_t assoc_keyid;	/* current send keyid (cached) */
 	uint16_t recv_keyid;	/* last recv keyid (cached) */
-}                    sctp_authinfo_t;
+} sctp_authinfo_t;
 
 
 
@@ -106,42 +106,42 @@ typedef struct sctp_authinformation {
 
 /* socket option api functions */
 extern sctp_auth_chklist_t *sctp_alloc_chunklist(void);
-extern void sctp_free_chunklist(sctp_auth_chklist_t * chklist);
-extern void sctp_clear_chunklist(sctp_auth_chklist_t * chklist);
-extern sctp_auth_chklist_t *sctp_copy_chunklist(sctp_auth_chklist_t * chklist);
-extern int sctp_auth_add_chunk(uint8_t chunk, sctp_auth_chklist_t * list);
-extern int sctp_auth_delete_chunk(uint8_t chunk, sctp_auth_chklist_t * list);
-extern size_t sctp_auth_get_chklist_size(const sctp_auth_chklist_t * list);
+extern void sctp_free_chunklist(sctp_auth_chklist_t *chklist);
+extern void sctp_clear_chunklist(sctp_auth_chklist_t *chklist);
+extern sctp_auth_chklist_t *sctp_copy_chunklist(sctp_auth_chklist_t *chklist);
+extern int sctp_auth_add_chunk(uint8_t chunk, sctp_auth_chklist_t *list);
+extern int sctp_auth_delete_chunk(uint8_t chunk, sctp_auth_chklist_t *list);
+extern size_t sctp_auth_get_chklist_size(const sctp_auth_chklist_t *list);
 extern int 
-sctp_serialize_auth_chunks(const sctp_auth_chklist_t * list,
-    uint8_t * ptr);
+sctp_serialize_auth_chunks(const sctp_auth_chklist_t *list,
+    uint8_t *ptr);
 extern int 
-sctp_pack_auth_chunks(const sctp_auth_chklist_t * list,
-    uint8_t * ptr);
+sctp_pack_auth_chunks(const sctp_auth_chklist_t *list,
+    uint8_t *ptr);
 extern int 
-sctp_unpack_auth_chunks(const uint8_t * ptr, uint8_t num_chunks,
-    sctp_auth_chklist_t * list);
+sctp_unpack_auth_chunks(const uint8_t *ptr, uint8_t num_chunks,
+    sctp_auth_chklist_t *list);
 
 /* key handling */
 extern sctp_key_t *sctp_alloc_key(uint32_t keylen);
-extern void sctp_free_key(sctp_key_t * key);
-extern void sctp_print_key(sctp_key_t * key, const char *str);
-extern void sctp_show_key(sctp_key_t * key, const char *str);
+extern void sctp_free_key(sctp_key_t *key);
+extern void sctp_print_key(sctp_key_t *key, const char *str);
+extern void sctp_show_key(sctp_key_t *key, const char *str);
 extern sctp_key_t *sctp_generate_random_key(uint32_t keylen);
-extern sctp_key_t *sctp_set_key(uint8_t * key, uint32_t keylen);
+extern sctp_key_t *sctp_set_key(uint8_t *key, uint32_t keylen);
 extern sctp_key_t *
-sctp_compute_hashkey(sctp_key_t * key1, sctp_key_t * key2,
-    sctp_key_t * shared);
+sctp_compute_hashkey(sctp_key_t *key1, sctp_key_t *key2,
+    sctp_key_t *shared);
 
 /* shared key handling */
 extern sctp_sharedkey_t *sctp_alloc_sharedkey(void);
-extern void sctp_free_sharedkey(sctp_sharedkey_t * skey);
+extern void sctp_free_sharedkey(sctp_sharedkey_t *skey);
 extern sctp_sharedkey_t *
 sctp_find_sharedkey(struct sctp_keyhead *shared_keys,
     uint16_t key_id);
 extern int 
 sctp_insert_sharedkey(struct sctp_keyhead *shared_keys,
-    sctp_sharedkey_t * new_skey);
+    sctp_sharedkey_t *new_skey);
 extern int 
 sctp_copy_skeylist(const struct sctp_keyhead *src,
     struct sctp_keyhead *dest);
@@ -155,42 +155,42 @@ sctp_auth_key_release(struct sctp_tcb *s
 
 /* hmac list handling */
 extern sctp_hmaclist_t *sctp_alloc_hmaclist(uint16_t num_hmacs);
-extern void sctp_free_hmaclist(sctp_hmaclist_t * list);
-extern int sctp_auth_add_hmacid(sctp_hmaclist_t * list, uint16_t hmac_id);
-extern sctp_hmaclist_t *sctp_copy_hmaclist(sctp_hmaclist_t * list);
+extern void sctp_free_hmaclist(sctp_hmaclist_t *list);
+extern int sctp_auth_add_hmacid(sctp_hmaclist_t *list, uint16_t hmac_id);
+extern sctp_hmaclist_t *sctp_copy_hmaclist(sctp_hmaclist_t *list);
 extern sctp_hmaclist_t *sctp_default_supported_hmaclist(void);
 extern uint16_t 
-sctp_negotiate_hmacid(sctp_hmaclist_t * peer,
-    sctp_hmaclist_t * local);
-extern int sctp_serialize_hmaclist(sctp_hmaclist_t * list, uint8_t * ptr);
+sctp_negotiate_hmacid(sctp_hmaclist_t *peer,
+    sctp_hmaclist_t *local);
+extern int sctp_serialize_hmaclist(sctp_hmaclist_t *list, uint8_t *ptr);
 extern int 
 sctp_verify_hmac_param(struct sctp_auth_hmac_algo *hmacs,
     uint32_t num_hmacs);
 
 extern sctp_authinfo_t *sctp_alloc_authinfo(void);
-extern void sctp_free_authinfo(sctp_authinfo_t * authinfo);
+extern void sctp_free_authinfo(sctp_authinfo_t *authinfo);
 
 /* keyed-HMAC functions */
 extern uint32_t sctp_get_auth_chunk_len(uint16_t hmac_algo);
 extern uint32_t sctp_get_hmac_digest_len(uint16_t hmac_algo);
 extern uint32_t 
-sctp_hmac(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    uint8_t * text, uint32_t textlen, uint8_t * digest);
+sctp_hmac(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    uint8_t *text, uint32_t textlen, uint8_t *digest);
 extern int 
-sctp_verify_hmac(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    uint8_t * text, uint32_t textlen, uint8_t * digest, uint32_t digestlen);
+sctp_verify_hmac(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    uint8_t *text, uint32_t textlen, uint8_t *digest, uint32_t digestlen);
 extern uint32_t 
-sctp_compute_hmac(uint16_t hmac_algo, sctp_key_t * key,
-    uint8_t * text, uint32_t textlen, uint8_t * digest);
-extern int sctp_auth_is_supported_hmac(sctp_hmaclist_t * list, uint16_t id);
+sctp_compute_hmac(uint16_t hmac_algo, sctp_key_t *key,
+    uint8_t *text, uint32_t textlen, uint8_t *digest);
+extern int sctp_auth_is_supported_hmac(sctp_hmaclist_t *list, uint16_t id);
 
 /* mbuf versions */
 extern uint32_t 
-sctp_hmac_m(uint16_t hmac_algo, uint8_t * key, uint32_t keylen,
-    struct mbuf *m, uint32_t m_offset, uint8_t * digest, uint32_t trailer);
+sctp_hmac_m(uint16_t hmac_algo, uint8_t *key, uint32_t keylen,
+    struct mbuf *m, uint32_t m_offset, uint8_t *digest, uint32_t trailer);
 extern uint32_t 
-sctp_compute_hmac_m(uint16_t hmac_algo, sctp_key_t * key,
-    struct mbuf *m, uint32_t m_offset, uint8_t * digest);
+sctp_compute_hmac_m(uint16_t hmac_algo, sctp_key_t *key,
+    struct mbuf *m, uint32_t m_offset, uint8_t *digest);
 
 /*
  * authentication routines
@@ -212,7 +212,7 @@ sctp_fill_hmac_digest_m(struct mbuf *m, 
     struct sctp_auth_chunk *auth, struct sctp_tcb *stcb, uint16_t key_id);
 extern struct mbuf *
 sctp_add_auth_chunk(struct mbuf *m, struct mbuf **m_end,
-    struct sctp_auth_chunk **auth_ret, uint32_t * offset,
+    struct sctp_auth_chunk **auth_ret, uint32_t *offset,
     struct sctp_tcb *stcb, uint8_t chunk);
 extern int 
 sctp_handle_auth(struct sctp_tcb *stcb, struct sctp_auth_chunk *ch,

Modified: head/sys/netinet/sctp_bsd_addr.c
==============================================================================
--- head/sys/netinet/sctp_bsd_addr.c	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_bsd_addr.c	Mon Dec 26 11:06:41 2016	(r310590)
@@ -477,7 +477,7 @@ again_locked:
 	lenat++;
 	*lenat = value;
 	lenat++;
-	tick_tock = (uint32_t *) lenat;
+	tick_tock = (uint32_t *)lenat;
 	lenat++;
 	*tick_tock = sctp_get_tick_count();
 	copyto = (void *)lenat;
@@ -498,7 +498,7 @@ no_log:
 
 
 int
-sctp_copy_out_packet_log(uint8_t * target, int length)
+sctp_copy_out_packet_log(uint8_t *target, int length)
 {
 	/*
 	 * We wind through the packet log starting at start copying up to

Modified: head/sys/netinet/sctp_bsd_addr.h
==============================================================================
--- head/sys/netinet/sctp_bsd_addr.h	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_bsd_addr.h	Mon Dec 26 11:06:41 2016	(r310590)
@@ -53,7 +53,7 @@ void sctp_gather_internal_ifa_flags(stru
 #ifdef  SCTP_PACKET_LOGGING
 
 void sctp_packet_log(struct mbuf *m);
-int sctp_copy_out_packet_log(uint8_t * target, int length);
+int sctp_copy_out_packet_log(uint8_t *target, int length);
 
 #endif
 

Modified: head/sys/netinet/sctp_cc_functions.c
==============================================================================
--- head/sys/netinet/sctp_cc_functions.c	Mon Dec 26 10:41:51 2016	(r310589)
+++ head/sys/netinet/sctp_cc_functions.c	Mon Dec 26 11:06:41 2016	(r310590)
@@ -122,7 +122,7 @@ sctp_cwnd_update_after_fr(struct sctp_tc
 			t_ssthresh += net->ssthresh;
 			t_cwnd += net->cwnd;
 			if (net->lastsa > 0) {
-				t_ucwnd_sbw += (uint64_t) net->cwnd / (uint64_t) net->lastsa;
+				t_ucwnd_sbw += (uint64_t)net->cwnd / (uint64_t)net->lastsa;
 			}
 		}
 		if (t_ucwnd_sbw == 0) {
@@ -150,27 +150,31 @@ sctp_cwnd_update_after_fr(struct sctp_tc
 				if ((asoc->sctp_cmt_on_off == SCTP_CMT_RPV1) ||
 				    (asoc->sctp_cmt_on_off == SCTP_CMT_RPV2)) {
 					if (asoc->sctp_cmt_on_off == SCTP_CMT_RPV1) {
-						net->ssthresh = (uint32_t) (((uint64_t) 4 *
-						    (uint64_t) net->mtu *
-						    (uint64_t) net->ssthresh) /
-						    (uint64_t) t_ssthresh);
+						net->ssthresh = (uint32_t)(((uint64_t)4 *
+						    (uint64_t)net->mtu *
+						    (uint64_t)net->ssthresh) /
+						    (uint64_t)t_ssthresh);
 
 					}
 					if (asoc->sctp_cmt_on_off == SCTP_CMT_RPV2) {
 						uint32_t srtt;
 
 						srtt = net->lastsa;
-						/* lastsa>>3;  we don't need
-						 * to devide ... */
+						/*
+						 * lastsa>>3;  we don't need
+						 * to devide ...
+						 */
 						if (srtt == 0) {
 							srtt = 1;
 						}
-						/* Short Version => Equal to
-						 * Contel Version MBe */
-						net->ssthresh = (uint32_t) (((uint64_t) 4 *
-						    (uint64_t) net->mtu *
-						    (uint64_t) net->cwnd) /
-						    ((uint64_t) srtt *
+						/*
+						 * Short Version => Equal to
+						 * Contel Version MBe
+						 */
+						net->ssthresh = (uint32_t)(((uint64_t)4 *
+						    (uint64_t)net->mtu *
+						    (uint64_t)net->cwnd) /
+						    ((uint64_t)srtt *
 						    t_ucwnd_sbw));
 						 /* INCREASE FACTOR */ ;
 					}
@@ -249,7 +253,7 @@ cc_bw_same(struct sctp_tcb *stcb, struct
 {
 	uint64_t oth, probepoint;
 
-	probepoint = (((uint64_t) net->cwnd) << 32);
+	probepoint = (((uint64_t)net->cwnd) << 32);
 	if (net->rtt > net->cc_mod.rtcc.lbw_rtt + rtt_offset) {
 		/*
 		 * rtt increased we don't update bw.. so we don't update the
@@ -385,7 +389,7 @@ cc_bw_decrease(struct sctp_tcb *stcb, st
 	uint64_t oth, probepoint;
 
 	/* Bandwidth decreased. */
-	probepoint = (((uint64_t) net->cwnd) << 32);
+	probepoint = (((uint64_t)net->cwnd) << 32);
 	if (net->rtt > net->cc_mod.rtcc.lbw_rtt + rtt_offset) {
 		/* rtt increased */
 		/* Did we add more */
@@ -401,8 +405,10 @@ cc_bw_decrease(struct sctp_tcb *stcb, st
 			    net->flight_size,
 			    probepoint);
 			if (net->cc_mod.rtcc.ret_from_eq) {
-				/* Switch over to CA if we are less
-				 * aggressive */
+				/*
+				 * Switch over to CA if we are less
+				 * aggressive
+				 */
 				net->ssthresh = net->cwnd - 1;
 				net->partial_bytes_acked = 0;
 			}
@@ -528,7 +534,7 @@ cc_bw_increase(struct sctp_tcb *stcb, st
 	 * attention to the inst_ind since our overall sum is increasing.
 	 */
 	/* PROBE POINT 0 */
-	probepoint = (((uint64_t) net->cwnd) << 32);
+	probepoint = (((uint64_t)net->cwnd) << 32);
 	SDT_PROBE5(sctp, cwnd, net, rttvar,
 	    vtag,
 	    ((net->cc_mod.rtcc.lbw << 32) | nbw),
@@ -610,8 +616,8 @@ cc_bw_limit(struct sctp_tcb *stcb, struc
 	 */
 	bw_shift = SCTP_BASE_SYSCTL(sctp_rttvar_bw);
 	rtt = stcb->asoc.my_vtag;
-	vtag = (rtt << 32) | (((uint32_t) (stcb->sctp_ep->sctp_lport)) << 16) | (stcb->rport);
-	probepoint = (((uint64_t) net->cwnd) << 32);
+	vtag = (rtt << 32) | (((uint32_t)(stcb->sctp_ep->sctp_lport)) << 16) | (stcb->rport);
+	probepoint = (((uint64_t)net->cwnd) << 32);
 	rtt = net->rtt;
 	if (net->cc_mod.rtcc.rtt_set_this_sack) {
 		net->cc_mod.rtcc.rtt_set_this_sack = 0;
@@ -631,7 +637,7 @@ cc_bw_limit(struct sctp_tcb *stcb, struc
 				probepoint |= ((0xb << 16) | inst_ind);
 			} else {
 				inst_ind = net->cc_mod.rtcc.last_inst_ind;
-				inst_bw = bytes_for_this_rtt / (uint64_t) (net->rtt);
+				inst_bw = bytes_for_this_rtt / (uint64_t)(net->rtt);
 				/* Can't determine do not change */
 				probepoint |= ((0xc << 16) | inst_ind);
 			}
@@ -703,11 +709,11 @@ sctp_cwnd_update_after_sack_common(struc
 			if (srtt > 0) {
 				uint64_t tmp;
 
-				t_ucwnd_sbw += (uint64_t) net->cwnd / (uint64_t) srtt;
-				t_path_mptcp += (((uint64_t) net->cwnd) << SHIFT_MPTCP_MULTI_Z) /
-				    (((uint64_t) net->mtu) * (uint64_t) srtt);
-				tmp = (((uint64_t) net->cwnd) << SHIFT_MPTCP_MULTI_N) /
-				    ((uint64_t) net->mtu * (uint64_t) (srtt * srtt));

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Mon Dec 26 11:11:32 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2E932C0BF89;
 Mon, 26 Dec 2016 11:11:32 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id F28BB17E5;
 Mon, 26 Dec 2016 11:11:31 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQBBVKO057812;
 Mon, 26 Dec 2016 11:11:31 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQBBV0E057811;
 Mon, 26 Dec 2016 11:11:31 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612261111.uBQBBV0E057811@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 11:11:31 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310591 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 11:11:32 -0000

Author: ngie
Date: Mon Dec 26 11:11:30 2016
New Revision: 310591
URL: https://svnweb.freebsd.org/changeset/base/310591

Log:
  Update engine time using update_snmpd_engine_time(..)
  
  MFC after:	6 days
  X-MFC with:	r310498
  Sponsored by:	Dell EMC Isilon

Modified:
  head/contrib/bsnmp/snmpd/trap.c

Modified: head/contrib/bsnmp/snmpd/trap.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trap.c	Mon Dec 26 11:06:41 2016	(r310590)
+++ head/contrib/bsnmp/snmpd/trap.c	Mon Dec 26 11:11:30 2016	(r310591)
@@ -464,7 +464,6 @@ static void
 snmp_create_v3_trap(struct snmp_pdu *pdu, struct target_param *target,
     const struct asn_oid *trap_oid)
 {
-	uint64_t etime;
 	struct usm_user *usmuser;
 
 	memset(pdu, 0, sizeof(*pdu));
@@ -487,14 +486,7 @@ snmp_create_v3_trap(struct snmp_pdu *pdu
 
 	pdu->nbindings = 2;
 
-	etime = (get_ticks() - start_tick)  / 100ULL;
-	if (etime < INT32_MAX)
-		snmpd_engine.engine_time = etime;
-	else {
-		start_tick = get_ticks();
-		set_snmpd_engine();
-		snmpd_engine.engine_time = start_tick;
-	}
+	update_snmpd_engine_time();
 
 	memcpy(pdu->engine.engine_id, snmpd_engine.engine_id,
 	    snmpd_engine.engine_len);

From owner-svn-src-all@freebsd.org  Mon Dec 26 11:16:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 98000C910C6;
 Mon, 26 Dec 2016 11:16:56 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 66F0B1BBC;
 Mon, 26 Dec 2016 11:16:56 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQBGtaN060231;
 Mon, 26 Dec 2016 11:16:55 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQBGtHk060230;
 Mon, 26 Dec 2016 11:16:55 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612261116.uBQBGtHk060230@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Mon, 26 Dec 2016 11:16:55 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310592 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 11:16:56 -0000

Author: ngie
Date: Mon Dec 26 11:16:55 2016
New Revision: 310592
URL: https://svnweb.freebsd.org/changeset/base/310592

Log:
  style(9): fix trailing whitespace
  
  MFC after:	3 days

Modified:
  head/contrib/bsnmp/snmpd/trap.c

Modified: head/contrib/bsnmp/snmpd/trap.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trap.c	Mon Dec 26 11:11:30 2016	(r310591)
+++ head/contrib/bsnmp/snmpd/trap.c	Mon Dec 26 11:16:55 2016	(r310592)
@@ -214,7 +214,7 @@ trapsink_unmodify(struct trapsink *t, st
 		t->version = tdep->rb_version;
 	if (tdep->set & TDEP_COMM)
 		strcpy(t->comm, tdep->rb_comm);
-	
+
 	return (SNMP_ERR_NOERROR);
 }
 
@@ -538,7 +538,7 @@ snmp_send_trap(const struct asn_oid *tra
 	TAILQ_FOREACH(t, &trapsink_list, link) {
 		if (t->status != TRAPSINK_ACTIVE)
 			continue;
-	
+
 		if (t->version == TRAPSINK_V1)
 			snmp_create_v1_trap(&pdu, t->comm, trap_oid);
 		else

From owner-svn-src-all@freebsd.org  Mon Dec 26 11:20:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1F67AC911A5;
 Mon, 26 Dec 2016 11:20:42 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C3BB31DB0;
 Mon, 26 Dec 2016 11:20:41 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQBKeMl060417;
 Mon, 26 Dec 2016 11:20:40 GMT (envelope-from mmel@FreeBSD.org)
Received: (from mmel@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQBKefw060416;
 Mon, 26 Dec 2016 11:20:40 GMT (envelope-from mmel@FreeBSD.org)
Message-Id: <201612261120.uBQBKefw060416@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mmel set sender to
 mmel@FreeBSD.org using -f
From: Michal Meloun <mmel@FreeBSD.org>
Date: Mon, 26 Dec 2016 11:20:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310593 - head/sys/dev/drm2
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 11:20:42 -0000

Author: mmel
Date: Mon Dec 26 11:20:40 2016
New Revision: 310593
URL: https://svnweb.freebsd.org/changeset/base/310593

Log:
  Fix late monitor hotplug event.
  If system starts without attached monitor, DRM create framebuffer
  for VT console. Later, when monitor is attached, the hotplug event must
  issue full modeset procedure to setup CRTC.
  In original code, this was done in drm_fb_helper_set_par(), but we don't
  have this function implemented yet. Use unrolled version of
  drm_fb_helper_set_par() to ensure same functionality.
  
  MFC after: 1 month

Modified:
  head/sys/dev/drm2/drm_fb_helper.c

Modified: head/sys/dev/drm2/drm_fb_helper.c
==============================================================================
--- head/sys/dev/drm2/drm_fb_helper.c	Mon Dec 26 11:16:55 2016	(r310592)
+++ head/sys/dev/drm2/drm_fb_helper.c	Mon Dec 26 11:20:40 2016	(r310593)
@@ -339,6 +339,7 @@ bool drm_fb_helper_restore_fbdev_mode(st
 {
 	bool error = false;
 	int i, ret;
+
 	for (i = 0; i < fb_helper->crtc_count; i++) {
 		struct drm_mode_set *mode_set = &fb_helper->crtc_info[i].mode_set;
 		ret = mode_set->crtc->funcs->set_config(mode_set);
@@ -841,6 +842,9 @@ int drm_fb_helper_single_fb_probe(struct
 	struct drm_fb_helper_surface_size sizes;
 	int gamma_size = 0;
 #if defined(__FreeBSD__)
+	struct drm_crtc *crtc;
+	struct drm_device *dev;
+	int ret;
 	device_t kdev;
 #endif
 
@@ -942,6 +946,24 @@ int drm_fb_helper_single_fb_probe(struct
 		if (ret != 0)
 			DRM_ERROR("Failed to attach fbd device: %d\n", ret);
 #endif
+	} else {
+		/* Modified version of drm_fb_helper_set_par() */
+		dev = fb_helper->dev;
+		sx_xlock(&dev->mode_config.mutex);
+		for (i = 0; i < fb_helper->crtc_count; i++) {
+			crtc = fb_helper->crtc_info[i].mode_set.crtc;
+			ret = crtc->funcs->set_config(&fb_helper->crtc_info[i].mode_set);
+			if (ret) {
+				sx_xunlock(&dev->mode_config.mutex);
+				return ret;
+			}
+		}
+		sx_xunlock(&dev->mode_config.mutex);
+
+		if (fb_helper->delayed_hotplug) {
+			fb_helper->delayed_hotplug = false;
+			drm_fb_helper_hotplug_event(fb_helper);
+		}
 	}
 #else
 	if (new_fb) {

From owner-svn-src-all@freebsd.org  Mon Dec 26 13:20:25 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 72A44C91592;
 Mon, 26 Dec 2016 13:20:25 +0000 (UTC)
 (envelope-from garga.bsd@gmail.com)
Received: from mail-qt0-x242.google.com (mail-qt0-x242.google.com
 [IPv6:2607:f8b0:400d:c0d::242])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id 2A5F310B8;
 Mon, 26 Dec 2016 13:20:25 +0000 (UTC)
 (envelope-from garga.bsd@gmail.com)
Received: by mail-qt0-x242.google.com with SMTP id d22so10628121qtd.3;
 Mon, 26 Dec 2016 05:20:25 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=sender:from:message-id:mime-version:subject:date:in-reply-to:cc:to
 :references; bh=q3ctZqxznjooWMbLWf6hPPMeGXPKCnkl/rdCbEldtKE=;
 b=fa4Tsxhemi8Qb2dATWnyc+XN9jqStAwmWUD2kuXbkvrcjgRZDV+tvtexB6zf986p4B
 Dl13mwB0i3b7Wm+2vlcc9go+0zIjec7sguhP4vLuKRRn8G54EbRpZR9pw/4WAWvyi6RI
 Lze8llYDegNkKtqxCEcwvT85ex8nz9fnqn656XNFtSSbReHFATPQm/zsO7R3cCdkqePp
 1wJROYQeWSMJznxWEe9R5kwboi2MJqhzQ+iCZzuU126cq1ewzqem2oyuig13zXjrzJhK
 QNoUd9oRaJFIod4B3p7+kQYe4b5KJHfJqfgTw4y40MujM7u9+auTG73uk71Ei5KZJIej
 04dg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:sender:from:message-id:mime-version:subject:date
 :in-reply-to:cc:to:references;
 bh=q3ctZqxznjooWMbLWf6hPPMeGXPKCnkl/rdCbEldtKE=;
 b=YlWbUaswok5g7kewRvV2A/tOIOl5ZvrcQSxWoPGUJCQEqv/E0s4mULKCGVvMZ7/fq8
 5ibPCKZlmhGf/kqWdprc66Ax+JaczEEx+8kty2aTglgOozJe6WpWtD/sbJuFQLco9FDT
 k62AIJfglCCaxYv/ZEUUOQ42dxjx+XiuWCqU4augpz3YB3+qOS6okYQEEafCP+5SaHZA
 9htFnf+tcedd0qINNGtjTqhZpxUaLqY2299fkFQfsc0eKT+g5WHnAuUHh4nO4Fy09Rs+
 HAJk5e1TWQQvGyaigk/5+5LKHPTqMX3zZC+lugV10GjGIm+cgnqgqwPpkXEfX/0PJKkz
 6Mng==
X-Gm-Message-State: AIkVDXK3vGjf6NCkt6ZwVEa3AKuqFgSwq3L3IXW3/718GdRvfpNiF5ua669C0RljIwow1w==
X-Received: by 10.200.38.50 with SMTP id u47mr28434542qtu.288.1482758424114;
 Mon, 26 Dec 2016 05:20:24 -0800 (PST)
Received: from mbp.home ([187.94.175.146])
 by smtp.gmail.com with ESMTPSA id 16sm26289834qtn.33.2016.12.26.05.20.21
 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Mon, 26 Dec 2016 05:20:23 -0800 (PST)
Sender: Renato Botelho <garga.bsd@gmail.com>
From: Renato Botelho <garga@FreeBSD.org>
Message-Id: <31D36CA7-4D63-43F6-8845-57F6B68E1925@FreeBSD.org>
Mime-Version: 1.0 (Mac OS X Mail 10.2 \(3259\))
Subject: Re: svn commit: r293829 - head/sys/net
Date: Mon, 26 Dec 2016 11:20:19 -0200
In-Reply-To: <201601131432.u0DEWn2H088657@repo.freebsd.org>
Cc: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org, "Andrey V. Elsukov" <ae@freebsd.org>
To: "Alexander V. Chernikov" <melifaro@freebsd.org>
References: <201601131432.u0DEWn2H088657@repo.freebsd.org>
X-Mailer: Apple Mail (2.3259)
Content-Type: text/plain;
	charset=us-ascii
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.23
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 13:20:25 -0000

Alexander,

Looks like this change introduced a bug. It was reported at pfSense and =
a ticket was opened at bugzilla:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D215122

> On 13 Jan 2016, at 12:32, Alexander V. Chernikov =
<melifaro@freebsd.org> wrote:
>=20
> Author: melifaro
> Date: Wed Jan 13 14:32:48 2016
> New Revision: 293829
> URL: https://svnweb.freebsd.org/changeset/base/293829
>=20
> Log:
>  Remove RTF_RNH_LOCKED support from rtalloc1_fib().
>=20
>  Last caller using it was eliminated in r293471.
>=20
>  Sponsored by:	Yandex LLC
>=20
> Modified:
>  head/sys/net/route.c
>  head/sys/net/route.h
>=20
> Modified: head/sys/net/route.c
> =
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
> --- head/sys/net/route.c	Wed Jan 13 14:28:12 2016	=
(r293828)
> +++ head/sys/net/route.c	Wed Jan 13 14:32:48 2016	=
(r293829)
> @@ -409,7 +409,6 @@ rtalloc1_fib(struct sockaddr *dst, int r
> 	struct rtentry *newrt;
> 	struct rt_addrinfo info;
> 	int err =3D 0, msgtype =3D RTM_MISS;
> -	int needlock;
>=20
> 	KASSERT((fibnum < rt_numfibs), ("rtalloc1_fib: bad fibnum"));
> 	rnh =3D rt_tables_get_rnh(fibnum, dst->sa_family);
> @@ -420,23 +419,16 @@ rtalloc1_fib(struct sockaddr *dst, int r
> 	/*
> 	 * Look up the address in the table for that Address Family
> 	 */
> -	needlock =3D !(ignflags & RTF_RNH_LOCKED);
> -	if (needlock)
> -		RADIX_NODE_HEAD_RLOCK(rnh);
> -#ifdef INVARIANTS=09
> -	else
> -		RADIX_NODE_HEAD_LOCK_ASSERT(rnh);
> -#endif
> +	RADIX_NODE_HEAD_RLOCK(rnh);
> 	rn =3D rnh->rnh_matchaddr(dst, rnh);
> 	if (rn && ((rn->rn_flags & RNF_ROOT) =3D=3D 0)) {
> 		newrt =3D RNTORT(rn);
> 		RT_LOCK(newrt);
> 		RT_ADDREF(newrt);
> -		if (needlock)
> -			RADIX_NODE_HEAD_RUNLOCK(rnh);
> -		goto done;
> +		RADIX_NODE_HEAD_RUNLOCK(rnh);
> +		return (newrt);
>=20
> -	} else if (needlock)
> +	} else
> 		RADIX_NODE_HEAD_RUNLOCK(rnh);
> =09
> 	/*
> @@ -456,10 +448,7 @@ miss:
> 		bzero(&info, sizeof(info));
> 		info.rti_info[RTAX_DST] =3D dst;
> 		rt_missmsg_fib(msgtype, &info, 0, err, fibnum);
> -	}=09
> -done:
> -	if (newrt)
> -		RT_LOCK_ASSERT(newrt);
> +	}
> 	return (newrt);
> }
>=20
>=20
> Modified: head/sys/net/route.h
> =
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
> --- head/sys/net/route.h	Wed Jan 13 14:28:12 2016	=
(r293828)
> +++ head/sys/net/route.h	Wed Jan 13 14:32:48 2016	=
(r293829)
> @@ -175,7 +175,7 @@ struct rtentry {
> 					/* 0x8000000 and up unassigned =
*/
> #define	RTF_STICKY	 0x10000000	/* always route dst->src =
*/
>=20
> -#define	RTF_RNH_LOCKED	 0x40000000	/* radix node head is =
locked */
> +#define	RTF_RNH_LOCKED	 0x40000000	/* unused */
>=20
> #define	RTF_GWFLAG_COMPAT 0x80000000	/* a compatibility bit =
for interacting
> 					   with existing routing apps */
> _______________________________________________
> svn-src-head@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/svn-src-head
> To unsubscribe, send any mail to =
"svn-src-head-unsubscribe@freebsd.org"



--
Renato Botelho


From owner-svn-src-all@freebsd.org  Mon Dec 26 14:28:25 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 60A12C91B86;
 Mon, 26 Dec 2016 14:28:25 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 3B1721A12;
 Mon, 26 Dec 2016 14:28:25 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQESO1I041003;
 Mon, 26 Dec 2016 14:28:24 GMT (envelope-from mmel@FreeBSD.org)
Received: (from mmel@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQESOCT041000;
 Mon, 26 Dec 2016 14:28:24 GMT (envelope-from mmel@FreeBSD.org)
Message-Id: <201612261428.uBQESOCT041000@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mmel set sender to
 mmel@FreeBSD.org using -f
From: Michal Meloun <mmel@FreeBSD.org>
Date: Mon, 26 Dec 2016 14:28:24 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310599 - in head/sys: conf dev/drm2
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 14:28:25 -0000

Author: mmel
Date: Mon Dec 26 14:28:23 2016
New Revision: 310599
URL: https://svnweb.freebsd.org/changeset/base/310599

Log:
  Import drm_patform.c, an implementation of non-PCI based attachment
  for graphics drivers.
  It will be used in upcoming driver for Nvidia Tegra boards.
  
  MFC after: 1 month

Added:
  head/sys/dev/drm2/drm_platform.c   (contents, props changed)
Modified:
  head/sys/conf/files
  head/sys/dev/drm2/drmP.h

Modified: head/sys/conf/files
==============================================================================
--- head/sys/conf/files	Mon Dec 26 12:41:38 2016	(r310598)
+++ head/sys/conf/files	Mon Dec 26 14:28:23 2016	(r310599)
@@ -1544,6 +1544,7 @@ dev/drm2/drm_memory.c		optional drm2
 dev/drm2/drm_mm.c		optional drm2
 dev/drm2/drm_modes.c		optional drm2
 dev/drm2/drm_pci.c		optional drm2
+dev/drm2/drm_platform.c		optional drm2
 dev/drm2/drm_scatter.c		optional drm2
 dev/drm2/drm_stub.c		optional drm2
 dev/drm2/drm_sysctl.c		optional drm2

Modified: head/sys/dev/drm2/drmP.h
==============================================================================
--- head/sys/dev/drm2/drmP.h	Mon Dec 26 12:41:38 2016	(r310598)
+++ head/sys/dev/drm2/drmP.h	Mon Dec 26 14:28:23 2016	(r310599)
@@ -1576,6 +1576,10 @@ extern int drm_pcie_get_speed_cap_mask(s
 
 #define	drm_can_sleep()	(DRM_HZ & 1)
 
+/* Platform section */
+int drm_get_platform_dev(device_t kdev, struct drm_device *dev,
+			 struct drm_driver *driver);
+
 /* FreeBSD specific -- should be moved to drm_os_freebsd.h */
 
 #define	DRM_GEM_MAPPING_MASK	(3ULL << 62)

Added: head/sys/dev/drm2/drm_platform.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sys/dev/drm2/drm_platform.c	Mon Dec 26 14:28:23 2016	(r310599)
@@ -0,0 +1,183 @@
+/*
+ * Derived from drm_pci.c
+ *
+ * Copyright 2003 José Fonseca.
+ * Copyright 2003 Leif Delgass.
+ * Copyright (c) 2009, Code Aurora Forum.
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the next
+ * paragraph) shall be included in all copies or substantial portions of the
+ * Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
+ * AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
+ * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
+
+#include <dev/drm2/drmP.h>
+
+static void drm_platform_free_irq(struct drm_device *dev)
+{
+	if (dev->irqr == NULL)
+		return;
+
+	bus_release_resource(dev->dev, SYS_RES_IRQ,
+	    dev->irqrid, dev->irqr);
+
+	dev->irqr = NULL;
+	dev->irq = 0;
+}
+
+static const char *drm_platform_get_name(struct drm_device *dev)
+{
+	return dev->driver->name;
+}
+
+static int drm_platform_set_busid(struct drm_device *dev, struct drm_master *master)
+{
+	int len, ret, id;
+
+	master->unique_len = 13 + strlen(dev->driver->name);
+	master->unique_size = master->unique_len;
+	master->unique = malloc(master->unique_len + 1, DRM_MEM_DRIVER, M_NOWAIT);
+
+	if (master->unique == NULL)
+		return -ENOMEM;
+
+	id = 0; // XXX dev->driver->id;
+
+	/* if only a single instance of the platform device, id will be
+	 * set to -1.. use 0 instead to avoid a funny looking bus-id:
+	 */
+	if (id == -1)
+		id = 0;
+
+	len = snprintf(master->unique, master->unique_len,
+			"platform:%s:%02d", dev->driver->name, id);
+
+	if (len > master->unique_len) {
+		DRM_ERROR("Unique buffer overflowed\n");
+		ret = -EINVAL;
+		goto err;
+	}
+
+	return 0;
+err:
+	return ret;
+}
+
+static int drm_platform_get_irq(struct drm_device *dev)
+{
+	if (dev->irqr)
+		return (dev->irq);
+
+	dev->irqr = bus_alloc_resource_any(dev->dev, SYS_RES_IRQ,
+	    &dev->irqrid, RF_SHAREABLE);
+	if (!dev->irqr) {
+		dev_err(dev->dev, "Failed to allocate IRQ\n");
+		return (0);
+	}
+
+	dev->irq = (int) rman_get_start(dev->irqr);
+
+	return (dev->irq);
+}
+
+static struct drm_bus drm_platform_bus = {
+	.bus_type = DRIVER_BUS_PLATFORM,
+	.get_irq = drm_platform_get_irq,
+	.free_irq = drm_platform_free_irq,
+	.get_name = drm_platform_get_name,
+	.set_busid = drm_platform_set_busid,
+};
+
+/**
+ * Register.
+ *
+ * \param platdev - Platform device struture
+ * \return zero on success or a negative number on failure.
+ *
+ * Attempt to gets inter module "drm" information. If we are first
+ * then register the character device and inter module information.
+ * Try and register, if we fail to register, backout previous work.
+ */
+
+int drm_get_platform_dev(device_t kdev, struct drm_device *dev,
+			 struct drm_driver *driver)
+{
+	int ret;
+
+	DRM_DEBUG("\n");
+
+	driver->bus = &drm_platform_bus;
+
+	dev->dev = kdev;
+
+	sx_xlock(&drm_global_mutex);
+
+	ret = drm_fill_in_dev(dev, driver);
+
+	if (ret) {
+		printf("DRM: Fill_in_dev failed.\n");
+		goto err_g1;
+	}
+
+	if (drm_core_check_feature(dev, DRIVER_MODESET)) {
+		ret = drm_get_minor(dev, &dev->control, DRM_MINOR_CONTROL);
+		if (ret)
+			goto err_g1;
+	}
+
+	ret = drm_get_minor(dev, &dev->primary, DRM_MINOR_LEGACY);
+	if (ret)
+		goto err_g2;
+
+	if (dev->driver->load) {
+		ret = dev->driver->load(dev, 0);
+		if (ret)
+			goto err_g3;
+	}
+
+	/* setup the grouping for the legacy output */
+	if (drm_core_check_feature(dev, DRIVER_MODESET)) {
+		ret = drm_mode_group_init_legacy_group(dev,
+				&dev->primary->mode_group);
+		if (ret)
+			goto err_g3;
+	}
+
+#ifdef FREEBSD_NOTYET
+	list_add_tail(&dev->driver_item, &driver->device_list);
+#endif /* FREEBSD_NOTYET */
+
+	sx_xunlock(&drm_global_mutex);
+
+	DRM_INFO("Initialized %s %d.%d.%d %s on minor %d\n",
+		 driver->name, driver->major, driver->minor, driver->patchlevel,
+		 driver->date, dev->primary->index);
+
+	return 0;
+
+err_g3:
+	drm_put_minor(&dev->primary);
+err_g2:
+	if (drm_core_check_feature(dev, DRIVER_MODESET))
+		drm_put_minor(&dev->control);
+err_g1:
+	sx_xunlock(&drm_global_mutex);
+	return ret;
+}
+EXPORT_SYMBOL(drm_get_platform_dev);

From owner-svn-src-all@freebsd.org  Mon Dec 26 14:36:06 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8A876C91F8E;
 Mon, 26 Dec 2016 14:36:06 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 53139134A;
 Mon, 26 Dec 2016 14:36:06 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQEa5Kl045714;
 Mon, 26 Dec 2016 14:36:05 GMT (envelope-from mmel@FreeBSD.org)
Received: (from mmel@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQEa5vB045711;
 Mon, 26 Dec 2016 14:36:05 GMT (envelope-from mmel@FreeBSD.org)
Message-Id: <201612261436.uBQEa5vB045711@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mmel set sender to
 mmel@FreeBSD.org using -f
From: Michal Meloun <mmel@FreeBSD.org>
Date: Mon, 26 Dec 2016 14:36:05 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310600 - in head/sys/arm: conf nvidia/drm2
 nvidia/tegra124
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 14:36:06 -0000

Author: mmel
Date: Mon Dec 26 14:36:05 2016
New Revision: 310600
URL: https://svnweb.freebsd.org/changeset/base/310600

Log:
  Implement drivers for NVIDIA tegra124 display controller, HDMI source
  and host1x module. Unfortunately, tegra124 SoC doesn't have 2D acceleration
  engine and 3D requires not yet started nouveau driver.
  
  These drivers forms a first non-x86 DRM2 enabled graphic stack.
  
  Note, there are 2 outstanding issues:
   - The code uses gross hack in order to be comply with
     OBJT_MGTDEVICE pager. (See tegra_bo_init_pager() in tegra_bo.c)
   - Due to improper(probably) refcounting in drm_gem_mmap_single()
     (in drm_gem.c), the gem objects are never released.
  I hope that I will be able to address both issues in finite time,
  but I don't want to touch x86 world now.
  
  MFC after: 1 month

Added:
  head/sys/arm/nvidia/drm2/
  head/sys/arm/nvidia/drm2/hdmi.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/hdmi.h   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_bo.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_dc.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_dc_if.m   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_dc_reg.h   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_drm.h   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_drm_if.m   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_drm_subr.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_fb.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_hdmi.c   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_hdmi_reg.h   (contents, props changed)
  head/sys/arm/nvidia/drm2/tegra_host1x.c   (contents, props changed)
Modified:
  head/sys/arm/conf/TEGRA124
  head/sys/arm/nvidia/tegra124/files.tegra124

Modified: head/sys/arm/conf/TEGRA124
==============================================================================
--- head/sys/arm/conf/TEGRA124	Mon Dec 26 14:28:23 2016	(r310599)
+++ head/sys/arm/conf/TEGRA124	Mon Dec 26 14:36:05 2016	(r310600)
@@ -123,11 +123,10 @@ device		pci
 device		re			# RealTek 8139C+/8169/8169S/8110S
 
 # DRM2
-#device		fbd
-#device		vt
-#device		splash
-#device		kbdmux
-#device		drm2
+device		fbd
+device		vt
+device		kbdmux
+device		drm2
 
 # Sound
 #device		sound

Added: head/sys/arm/nvidia/drm2/hdmi.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sys/arm/nvidia/drm2/hdmi.c	Mon Dec 26 14:36:05 2016	(r310600)
@@ -0,0 +1,1229 @@
+/*
+ * Copyright (C) 2012 Avionic Design GmbH
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sub license,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ */
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
+
+#include <sys/param.h>
+#include <sys/systm.h>
+
+#include <arm/nvidia/drm2/hdmi.h>
+
+#define EXPORT_SYMBOL(x)
+#ifndef BIT
+#define BIT(x) (1U << (x))
+#endif
+#define hdmi_log(fmt, ...) printf(fmt, ##__VA_ARGS__)
+
+static uint8_t hdmi_infoframe_checksum(uint8_t *ptr, size_t size)
+{
+	uint8_t csum = 0;
+	size_t i;
+
+	/* compute checksum */
+	for (i = 0; i < size; i++)
+		csum += ptr[i];
+
+	return 256 - csum;
+}
+
+static void hdmi_infoframe_set_checksum(void *buffer, size_t size)
+{
+	uint8_t *ptr = buffer;
+
+	ptr[3] = hdmi_infoframe_checksum(buffer, size);
+}
+
+/**
+ * hdmi_avi_infoframe_init() - initialize an HDMI AVI infoframe
+ * @frame: HDMI AVI infoframe
+ *
+ * Returns 0 on success or a negative error code on failure.
+ */
+int hdmi_avi_infoframe_init(struct hdmi_avi_infoframe *frame)
+{
+	memset(frame, 0, sizeof(*frame));
+
+	frame->type = HDMI_INFOFRAME_TYPE_AVI;
+	frame->version = 2;
+	frame->length = HDMI_AVI_INFOFRAME_SIZE;
+
+	return 0;
+}
+EXPORT_SYMBOL(hdmi_avi_infoframe_init);
+
+/**
+ * hdmi_avi_infoframe_pack() - write HDMI AVI infoframe to binary buffer
+ * @frame: HDMI AVI infoframe
+ * @buffer: destination buffer
+ * @size: size of buffer
+ *
+ * Packs the information contained in the @frame structure into a binary
+ * representation that can be written into the corresponding controller
+ * registers. Also computes the checksum as required by section 5.3.5 of
+ * the HDMI 1.4 specification.
+ *
+ * Returns the number of bytes packed into the binary buffer or a negative
+ * error code on failure.
+ */
+ssize_t hdmi_avi_infoframe_pack(struct hdmi_avi_infoframe *frame, void *buffer,
+				size_t size)
+{
+	uint8_t *ptr = buffer;
+	size_t length;
+
+	length = HDMI_INFOFRAME_HEADER_SIZE + frame->length;
+
+	if (size < length)
+		return -ENOSPC;
+
+	memset(buffer, 0, size);
+
+	ptr[0] = frame->type;
+	ptr[1] = frame->version;
+	ptr[2] = frame->length;
+	ptr[3] = 0; /* checksum */
+
+	/* start infoframe payload */
+	ptr += HDMI_INFOFRAME_HEADER_SIZE;
+
+	ptr[0] = ((frame->colorspace & 0x3) << 5) | (frame->scan_mode & 0x3);
+
+	/*
+	 * Data byte 1, bit 4 has to be set if we provide the active format
+	 * aspect ratio
+	 */
+	if (frame->active_aspect & 0xf)
+		ptr[0] |= BIT(4);
+
+	/* Bit 3 and 2 indicate if we transmit horizontal/vertical bar data */
+	if (frame->top_bar || frame->bottom_bar)
+		ptr[0] |= BIT(3);
+
+	if (frame->left_bar || frame->right_bar)
+		ptr[0] |= BIT(2);
+
+	ptr[1] = ((frame->colorimetry & 0x3) << 6) |
+		 ((frame->picture_aspect & 0x3) << 4) |
+		 (frame->active_aspect & 0xf);
+
+	ptr[2] = ((frame->extended_colorimetry & 0x7) << 4) |
+		 ((frame->quantization_range & 0x3) << 2) |
+		 (frame->nups & 0x3);
+
+	if (frame->itc)
+		ptr[2] |= BIT(7);
+
+	ptr[3] = frame->video_code & 0x7f;
+
+	ptr[4] = ((frame->ycc_quantization_range & 0x3) << 6) |
+		 ((frame->content_type & 0x3) << 4) |
+		 (frame->pixel_repeat & 0xf);
+
+	ptr[5] = frame->top_bar & 0xff;
+	ptr[6] = (frame->top_bar >> 8) & 0xff;
+	ptr[7] = frame->bottom_bar & 0xff;
+	ptr[8] = (frame->bottom_bar >> 8) & 0xff;
+	ptr[9] = frame->left_bar & 0xff;
+	ptr[10] = (frame->left_bar >> 8) & 0xff;
+	ptr[11] = frame->right_bar & 0xff;
+	ptr[12] = (frame->right_bar >> 8) & 0xff;
+
+	hdmi_infoframe_set_checksum(buffer, length);
+
+	return length;
+}
+EXPORT_SYMBOL(hdmi_avi_infoframe_pack);
+
+/**
+ * hdmi_spd_infoframe_init() - initialize an HDMI SPD infoframe
+ * @frame: HDMI SPD infoframe
+ * @vendor: vendor string
+ * @product: product string
+ *
+ * Returns 0 on success or a negative error code on failure.
+ */
+int hdmi_spd_infoframe_init(struct hdmi_spd_infoframe *frame,
+			    const char *vendor, const char *product)
+{
+	memset(frame, 0, sizeof(*frame));
+
+	frame->type = HDMI_INFOFRAME_TYPE_SPD;
+	frame->version = 1;
+	frame->length = HDMI_SPD_INFOFRAME_SIZE;
+
+	strncpy(frame->vendor, vendor, sizeof(frame->vendor));
+	strncpy(frame->product, product, sizeof(frame->product));
+
+	return 0;
+}
+EXPORT_SYMBOL(hdmi_spd_infoframe_init);
+
+/**
+ * hdmi_spd_infoframe_pack() - write HDMI SPD infoframe to binary buffer
+ * @frame: HDMI SPD infoframe
+ * @buffer: destination buffer
+ * @size: size of buffer
+ *
+ * Packs the information contained in the @frame structure into a binary
+ * representation that can be written into the corresponding controller
+ * registers. Also computes the checksum as required by section 5.3.5 of
+ * the HDMI 1.4 specification.
+ *
+ * Returns the number of bytes packed into the binary buffer or a negative
+ * error code on failure.
+ */
+ssize_t hdmi_spd_infoframe_pack(struct hdmi_spd_infoframe *frame, void *buffer,
+				size_t size)
+{
+	uint8_t *ptr = buffer;
+	size_t length;
+
+	length = HDMI_INFOFRAME_HEADER_SIZE + frame->length;
+
+	if (size < length)
+		return -ENOSPC;
+
+	memset(buffer, 0, size);
+
+	ptr[0] = frame->type;
+	ptr[1] = frame->version;
+	ptr[2] = frame->length;
+	ptr[3] = 0; /* checksum */
+
+	/* start infoframe payload */
+	ptr += HDMI_INFOFRAME_HEADER_SIZE;
+
+	memcpy(ptr, frame->vendor, sizeof(frame->vendor));
+	memcpy(ptr + 8, frame->product, sizeof(frame->product));
+
+	ptr[24] = frame->sdi;
+
+	hdmi_infoframe_set_checksum(buffer, length);
+
+	return length;
+}
+EXPORT_SYMBOL(hdmi_spd_infoframe_pack);
+
+/**
+ * hdmi_audio_infoframe_init() - initialize an HDMI audio infoframe
+ * @frame: HDMI audio infoframe
+ *
+ * Returns 0 on success or a negative error code on failure.
+ */
+int hdmi_audio_infoframe_init(struct hdmi_audio_infoframe *frame)
+{
+	memset(frame, 0, sizeof(*frame));
+
+	frame->type = HDMI_INFOFRAME_TYPE_AUDIO;
+	frame->version = 1;
+	frame->length = HDMI_AUDIO_INFOFRAME_SIZE;
+
+	return 0;
+}
+EXPORT_SYMBOL(hdmi_audio_infoframe_init);
+
+/**
+ * hdmi_audio_infoframe_pack() - write HDMI audio infoframe to binary buffer
+ * @frame: HDMI audio infoframe
+ * @buffer: destination buffer
+ * @size: size of buffer
+ *
+ * Packs the information contained in the @frame structure into a binary
+ * representation that can be written into the corresponding controller
+ * registers. Also computes the checksum as required by section 5.3.5 of
+ * the HDMI 1.4 specification.
+ *
+ * Returns the number of bytes packed into the binary buffer or a negative
+ * error code on failure.
+ */
+ssize_t hdmi_audio_infoframe_pack(struct hdmi_audio_infoframe *frame,
+				  void *buffer, size_t size)
+{
+	unsigned char channels;
+	uint8_t *ptr = buffer;
+	size_t length;
+
+	length = HDMI_INFOFRAME_HEADER_SIZE + frame->length;
+
+	if (size < length)
+		return -ENOSPC;
+
+	memset(buffer, 0, size);
+
+	if (frame->channels >= 2)
+		channels = frame->channels - 1;
+	else
+		channels = 0;
+
+	ptr[0] = frame->type;
+	ptr[1] = frame->version;
+	ptr[2] = frame->length;
+	ptr[3] = 0; /* checksum */
+
+	/* start infoframe payload */
+	ptr += HDMI_INFOFRAME_HEADER_SIZE;
+
+	ptr[0] = ((frame->coding_type & 0xf) << 4) | (channels & 0x7);
+	ptr[1] = ((frame->sample_frequency & 0x7) << 2) |
+		 (frame->sample_size & 0x3);
+	ptr[2] = frame->coding_type_ext & 0x1f;
+	ptr[3] = frame->channel_allocation;
+	ptr[4] = (frame->level_shift_value & 0xf) << 3;
+
+	if (frame->downmix_inhibit)
+		ptr[4] |= BIT(7);
+
+	hdmi_infoframe_set_checksum(buffer, length);
+
+	return length;
+}
+EXPORT_SYMBOL(hdmi_audio_infoframe_pack);
+
+/**
+ * hdmi_vendor_infoframe_init() - initialize an HDMI vendor infoframe
+ * @frame: HDMI vendor infoframe
+ *
+ * Returns 0 on success or a negative error code on failure.
+ */
+int hdmi_vendor_infoframe_init(struct hdmi_vendor_infoframe *frame)
+{
+	memset(frame, 0, sizeof(*frame));
+
+	frame->type = HDMI_INFOFRAME_TYPE_VENDOR;
+	frame->version = 1;
+
+	frame->oui = HDMI_IEEE_OUI;
+
+	/*
+	 * 0 is a valid value for s3d_struct, so we use a special "not set"
+	 * value
+	 */
+	frame->s3d_struct = HDMI_3D_STRUCTURE_INVALID;
+
+	return 0;
+}
+EXPORT_SYMBOL(hdmi_vendor_infoframe_init);
+
+/**
+ * hdmi_vendor_infoframe_pack() - write a HDMI vendor infoframe to binary buffer
+ * @frame: HDMI infoframe
+ * @buffer: destination buffer
+ * @size: size of buffer
+ *
+ * Packs the information contained in the @frame structure into a binary
+ * representation that can be written into the corresponding controller
+ * registers. Also computes the checksum as required by section 5.3.5 of
+ * the HDMI 1.4 specification.
+ *
+ * Returns the number of bytes packed into the binary buffer or a negative
+ * error code on failure.
+ */
+ssize_t hdmi_vendor_infoframe_pack(struct hdmi_vendor_infoframe *frame,
+				 void *buffer, size_t size)
+{
+	uint8_t *ptr = buffer;
+	size_t length;
+
+	/* empty info frame */
+	if (frame->vic == 0 && frame->s3d_struct == HDMI_3D_STRUCTURE_INVALID)
+		return -EINVAL;
+
+	/* only one of those can be supplied */
+	if (frame->vic != 0 && frame->s3d_struct != HDMI_3D_STRUCTURE_INVALID)
+		return -EINVAL;
+
+	/* for side by side (half) we also need to provide 3D_Ext_Data */
+	if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
+		frame->length = 6;
+	else
+		frame->length = 5;
+
+	length = HDMI_INFOFRAME_HEADER_SIZE + frame->length;
+
+	if (size < length)
+		return -ENOSPC;
+
+	memset(buffer, 0, size);
+
+	ptr[0] = frame->type;
+	ptr[1] = frame->version;
+	ptr[2] = frame->length;
+	ptr[3] = 0; /* checksum */
+
+	/* HDMI OUI */
+	ptr[4] = 0x03;
+	ptr[5] = 0x0c;
+	ptr[6] = 0x00;
+
+	if (frame->vic) {
+		ptr[7] = 0x1 << 5;	/* video format */
+		ptr[8] = frame->vic;
+	} else {
+		ptr[7] = 0x2 << 5;	/* video format */
+		ptr[8] = (frame->s3d_struct & 0xf) << 4;
+		if (frame->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
+			ptr[9] = (frame->s3d_ext_data & 0xf) << 4;
+	}
+
+	hdmi_infoframe_set_checksum(buffer, length);
+
+	return length;
+}
+EXPORT_SYMBOL(hdmi_vendor_infoframe_pack);
+
+/*
+ * hdmi_vendor_any_infoframe_pack() - write a vendor infoframe to binary buffer
+ */
+static ssize_t
+hdmi_vendor_any_infoframe_pack(union hdmi_vendor_any_infoframe *frame,
+			   void *buffer, size_t size)
+{
+	/* we only know about HDMI vendor infoframes */
+	if (frame->any.oui != HDMI_IEEE_OUI)
+		return -EINVAL;
+
+	return hdmi_vendor_infoframe_pack(&frame->hdmi, buffer, size);
+}
+
+/**
+ * hdmi_infoframe_pack() - write a HDMI infoframe to binary buffer
+ * @frame: HDMI infoframe
+ * @buffer: destination buffer
+ * @size: size of buffer
+ *
+ * Packs the information contained in the @frame structure into a binary
+ * representation that can be written into the corresponding controller
+ * registers. Also computes the checksum as required by section 5.3.5 of
+ * the HDMI 1.4 specification.
+ *
+ * Returns the number of bytes packed into the binary buffer or a negative
+ * error code on failure.
+ */
+ssize_t
+hdmi_infoframe_pack(union hdmi_infoframe *frame, void *buffer, size_t size)
+{
+	ssize_t length;
+
+	switch (frame->any.type) {
+	case HDMI_INFOFRAME_TYPE_AVI:
+		length = hdmi_avi_infoframe_pack(&frame->avi, buffer, size);
+		break;
+	case HDMI_INFOFRAME_TYPE_SPD:
+		length = hdmi_spd_infoframe_pack(&frame->spd, buffer, size);
+		break;
+	case HDMI_INFOFRAME_TYPE_AUDIO:
+		length = hdmi_audio_infoframe_pack(&frame->audio, buffer, size);
+		break;
+	case HDMI_INFOFRAME_TYPE_VENDOR:
+		length = hdmi_vendor_any_infoframe_pack(&frame->vendor,
+							buffer, size);
+		break;
+	default:
+		printf("Bad infoframe type %d\n", frame->any.type);
+		length = -EINVAL;
+	}
+
+	return length;
+}
+EXPORT_SYMBOL(hdmi_infoframe_pack);
+
+static const char *hdmi_infoframe_type_get_name(enum hdmi_infoframe_type type)
+{
+	if (type < 0x80 || type > 0x9f)
+		return "Invalid";
+	switch (type) {
+	case HDMI_INFOFRAME_TYPE_VENDOR:
+		return "Vendor";
+	case HDMI_INFOFRAME_TYPE_AVI:
+		return "Auxiliary Video Information (AVI)";
+	case HDMI_INFOFRAME_TYPE_SPD:
+		return "Source Product Description (SPD)";
+	case HDMI_INFOFRAME_TYPE_AUDIO:
+		return "Audio";
+	}
+	return "Reserved";
+}
+
+static void hdmi_infoframe_log_header(struct hdmi_any_infoframe *frame)
+{
+	hdmi_log("HDMI infoframe: %s, version %u, length %u\n",
+		hdmi_infoframe_type_get_name(frame->type),
+		frame->version, frame->length);
+}
+
+static const char *hdmi_colorspace_get_name(enum hdmi_colorspace colorspace)
+{
+	switch (colorspace) {
+	case HDMI_COLORSPACE_RGB:
+		return "RGB";
+	case HDMI_COLORSPACE_YUV422:
+		return "YCbCr 4:2:2";
+	case HDMI_COLORSPACE_YUV444:
+		return "YCbCr 4:4:4";
+	case HDMI_COLORSPACE_YUV420:
+		return "YCbCr 4:2:0";
+	case HDMI_COLORSPACE_RESERVED4:
+		return "Reserved (4)";
+	case HDMI_COLORSPACE_RESERVED5:
+		return "Reserved (5)";
+	case HDMI_COLORSPACE_RESERVED6:
+		return "Reserved (6)";
+	case HDMI_COLORSPACE_IDO_DEFINED:
+		return "IDO Defined";
+	}
+	return "Invalid";
+}
+
+static const char *hdmi_scan_mode_get_name(enum hdmi_scan_mode scan_mode)
+{
+	switch (scan_mode) {
+	case HDMI_SCAN_MODE_NONE:
+		return "No Data";
+	case HDMI_SCAN_MODE_OVERSCAN:
+		return "Overscan";
+	case HDMI_SCAN_MODE_UNDERSCAN:
+		return "Underscan";
+	case HDMI_SCAN_MODE_RESERVED:
+		return "Reserved";
+	}
+	return "Invalid";
+}
+
+static const char *hdmi_colorimetry_get_name(enum hdmi_colorimetry colorimetry)
+{
+	switch (colorimetry) {
+	case HDMI_COLORIMETRY_NONE:
+		return "No Data";
+	case HDMI_COLORIMETRY_ITU_601:
+		return "ITU601";
+	case HDMI_COLORIMETRY_ITU_709:
+		return "ITU709";
+	case HDMI_COLORIMETRY_EXTENDED:
+		return "Extended";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_picture_aspect_get_name(enum hdmi_picture_aspect picture_aspect)
+{
+	switch (picture_aspect) {
+	case HDMI_PICTURE_ASPECT_NONE:
+		return "No Data";
+	case HDMI_PICTURE_ASPECT_4_3:
+		return "4:3";
+	case HDMI_PICTURE_ASPECT_16_9:
+		return "16:9";
+	case HDMI_PICTURE_ASPECT_RESERVED:
+		return "Reserved";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_active_aspect_get_name(enum hdmi_active_aspect active_aspect)
+{
+	if (active_aspect > 0xf)
+		return "Invalid";
+
+	switch (active_aspect) {
+	case HDMI_ACTIVE_ASPECT_16_9_TOP:
+		return "16:9 Top";
+	case HDMI_ACTIVE_ASPECT_14_9_TOP:
+		return "14:9 Top";
+	case HDMI_ACTIVE_ASPECT_16_9_CENTER:
+		return "16:9 Center";
+	case HDMI_ACTIVE_ASPECT_PICTURE:
+		return "Same as Picture";
+	case HDMI_ACTIVE_ASPECT_4_3:
+		return "4:3";
+	case HDMI_ACTIVE_ASPECT_16_9:
+		return "16:9";
+	case HDMI_ACTIVE_ASPECT_14_9:
+		return "14:9";
+	case HDMI_ACTIVE_ASPECT_4_3_SP_14_9:
+		return "4:3 SP 14:9";
+	case HDMI_ACTIVE_ASPECT_16_9_SP_14_9:
+		return "16:9 SP 14:9";
+	case HDMI_ACTIVE_ASPECT_16_9_SP_4_3:
+		return "16:9 SP 4:3";
+	}
+	return "Reserved";
+}
+
+static const char *
+hdmi_extended_colorimetry_get_name(enum hdmi_extended_colorimetry ext_col)
+{
+	switch (ext_col) {
+	case HDMI_EXTENDED_COLORIMETRY_XV_YCC_601:
+		return "xvYCC 601";
+	case HDMI_EXTENDED_COLORIMETRY_XV_YCC_709:
+		return "xvYCC 709";
+	case HDMI_EXTENDED_COLORIMETRY_S_YCC_601:
+		return "sYCC 601";
+	case HDMI_EXTENDED_COLORIMETRY_ADOBE_YCC_601:
+		return "Adobe YCC 601";
+	case HDMI_EXTENDED_COLORIMETRY_ADOBE_RGB:
+		return "Adobe RGB";
+	case HDMI_EXTENDED_COLORIMETRY_BT2020_CONST_LUM:
+		return "BT.2020 Constant Luminance";
+	case HDMI_EXTENDED_COLORIMETRY_BT2020:
+		return "BT.2020";
+	case HDMI_EXTENDED_COLORIMETRY_RESERVED:
+		return "Reserved";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_quantization_range_get_name(enum hdmi_quantization_range qrange)
+{
+	switch (qrange) {
+	case HDMI_QUANTIZATION_RANGE_DEFAULT:
+		return "Default";
+	case HDMI_QUANTIZATION_RANGE_LIMITED:
+		return "Limited";
+	case HDMI_QUANTIZATION_RANGE_FULL:
+		return "Full";
+	case HDMI_QUANTIZATION_RANGE_RESERVED:
+		return "Reserved";
+	}
+	return "Invalid";
+}
+
+static const char *hdmi_nups_get_name(enum hdmi_nups nups)
+{
+	switch (nups) {
+	case HDMI_NUPS_UNKNOWN:
+		return "Unknown Non-uniform Scaling";
+	case HDMI_NUPS_HORIZONTAL:
+		return "Horizontally Scaled";
+	case HDMI_NUPS_VERTICAL:
+		return "Vertically Scaled";
+	case HDMI_NUPS_BOTH:
+		return "Horizontally and Vertically Scaled";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_ycc_quantization_range_get_name(enum hdmi_ycc_quantization_range qrange)
+{
+	switch (qrange) {
+	case HDMI_YCC_QUANTIZATION_RANGE_LIMITED:
+		return "Limited";
+	case HDMI_YCC_QUANTIZATION_RANGE_FULL:
+		return "Full";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_content_type_get_name(enum hdmi_content_type content_type)
+{
+	switch (content_type) {
+	case HDMI_CONTENT_TYPE_GRAPHICS:
+		return "Graphics";
+	case HDMI_CONTENT_TYPE_PHOTO:
+		return "Photo";
+	case HDMI_CONTENT_TYPE_CINEMA:
+		return "Cinema";
+	case HDMI_CONTENT_TYPE_GAME:
+		return "Game";
+	}
+	return "Invalid";
+}
+
+/**
+ * hdmi_avi_infoframe_log() - log info of HDMI AVI infoframe
+ * @level: logging level
+ * @dev: device
+ * @frame: HDMI AVI infoframe
+ */
+static void hdmi_avi_infoframe_log(struct hdmi_avi_infoframe *frame)
+{
+	hdmi_infoframe_log_header((struct hdmi_any_infoframe *)frame);
+
+	hdmi_log("    colorspace: %s\n",
+			hdmi_colorspace_get_name(frame->colorspace));
+	hdmi_log("    scan mode: %s\n",
+			hdmi_scan_mode_get_name(frame->scan_mode));
+	hdmi_log("    colorimetry: %s\n",
+			hdmi_colorimetry_get_name(frame->colorimetry));
+	hdmi_log("    picture aspect: %s\n",
+			hdmi_picture_aspect_get_name(frame->picture_aspect));
+	hdmi_log("    active aspect: %s\n",
+			hdmi_active_aspect_get_name(frame->active_aspect));
+	hdmi_log("    itc: %s\n", frame->itc ? "IT Content" : "No Data");
+	hdmi_log("    extended colorimetry: %s\n",
+			hdmi_extended_colorimetry_get_name(frame->extended_colorimetry));
+	hdmi_log("    quantization range: %s\n",
+			hdmi_quantization_range_get_name(frame->quantization_range));
+	hdmi_log("    nups: %s\n", hdmi_nups_get_name(frame->nups));
+	hdmi_log("    video code: %u\n", frame->video_code);
+	hdmi_log("    ycc quantization range: %s\n",
+			hdmi_ycc_quantization_range_get_name(frame->ycc_quantization_range));
+	hdmi_log("    hdmi content type: %s\n",
+			hdmi_content_type_get_name(frame->content_type));
+	hdmi_log("    pixel repeat: %u\n", frame->pixel_repeat);
+	hdmi_log("    bar top %u, bottom %u, left %u, right %u\n",
+			frame->top_bar, frame->bottom_bar,
+			frame->left_bar, frame->right_bar);
+}
+
+static const char *hdmi_spd_sdi_get_name(enum hdmi_spd_sdi sdi)
+{
+;
+	switch (sdi) {
+	case HDMI_SPD_SDI_UNKNOWN:
+		return "Unknown";
+	case HDMI_SPD_SDI_DSTB:
+		return "Digital STB";
+	case HDMI_SPD_SDI_DVDP:
+		return "DVD Player";
+	case HDMI_SPD_SDI_DVHS:
+		return "D-VHS";
+	case HDMI_SPD_SDI_HDDVR:
+		return "HDD Videorecorder";
+	case HDMI_SPD_SDI_DVC:
+		return "DVC";
+	case HDMI_SPD_SDI_DSC:
+		return "DSC";
+	case HDMI_SPD_SDI_VCD:
+		return "Video CD";
+	case HDMI_SPD_SDI_GAME:
+		return "Game";
+	case HDMI_SPD_SDI_PC:
+		return "PC General";
+	case HDMI_SPD_SDI_BD:
+		return "Blu-Ray Disc (BD)";
+	case HDMI_SPD_SDI_SACD:
+		return "Super Audio CD";
+	case HDMI_SPD_SDI_HDDVD:
+		return "HD DVD";
+	case HDMI_SPD_SDI_PMP:
+		return "PMP";
+	}
+	return "Reserved";
+}
+
+/**
+ * hdmi_spd_infoframe_log() - log info of HDMI SPD infoframe
+ * @level: logging level
+ * @dev: device
+ * @frame: HDMI SPD infoframe
+ */
+static void hdmi_spd_infoframe_log(struct hdmi_spd_infoframe *frame)
+{
+	uint8_t buf[17];
+
+	hdmi_infoframe_log_header((struct hdmi_any_infoframe *)frame);
+
+	memset(buf, 0, sizeof(buf));
+
+	strncpy(buf, frame->vendor, 8);
+	hdmi_log("    vendor: %s\n", buf);
+	strncpy(buf, frame->product, 16);
+	hdmi_log("    product: %s\n", buf);
+	hdmi_log("    source device information: %s (0x%x)\n",
+		hdmi_spd_sdi_get_name(frame->sdi), frame->sdi);
+}
+
+static const char *
+hdmi_audio_coding_type_get_name(enum hdmi_audio_coding_type coding_type)
+{
+	switch (coding_type) {
+	case HDMI_AUDIO_CODING_TYPE_STREAM:
+		return "Refer to Stream Header";
+	case HDMI_AUDIO_CODING_TYPE_PCM:
+		return "PCM";
+	case HDMI_AUDIO_CODING_TYPE_AC3:
+		return "AC-3";
+	case HDMI_AUDIO_CODING_TYPE_MPEG1:
+		return "MPEG1";
+	case HDMI_AUDIO_CODING_TYPE_MP3:
+		return "MP3";
+	case HDMI_AUDIO_CODING_TYPE_MPEG2:
+		return "MPEG2";
+	case HDMI_AUDIO_CODING_TYPE_AAC_LC:
+		return "AAC";
+	case HDMI_AUDIO_CODING_TYPE_DTS:
+		return "DTS";
+	case HDMI_AUDIO_CODING_TYPE_ATRAC:
+		return "ATRAC";
+	case HDMI_AUDIO_CODING_TYPE_DSD:
+		return "One Bit Audio";
+	case HDMI_AUDIO_CODING_TYPE_EAC3:
+		return "Dolby Digital +";
+	case HDMI_AUDIO_CODING_TYPE_DTS_HD:
+		return "DTS-HD";
+	case HDMI_AUDIO_CODING_TYPE_MLP:
+		return "MAT (MLP)";
+	case HDMI_AUDIO_CODING_TYPE_DST:
+		return "DST";
+	case HDMI_AUDIO_CODING_TYPE_WMA_PRO:
+		return "WMA PRO";
+	case HDMI_AUDIO_CODING_TYPE_CXT:
+		return "Refer to CXT";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_audio_sample_size_get_name(enum hdmi_audio_sample_size sample_size)
+{
+	switch (sample_size) {
+	case HDMI_AUDIO_SAMPLE_SIZE_STREAM:
+		return "Refer to Stream Header";
+	case HDMI_AUDIO_SAMPLE_SIZE_16:
+		return "16 bit";
+	case HDMI_AUDIO_SAMPLE_SIZE_20:
+		return "20 bit";
+	case HDMI_AUDIO_SAMPLE_SIZE_24:
+		return "24 bit";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_audio_sample_frequency_get_name(enum hdmi_audio_sample_frequency freq)
+{
+	switch (freq) {
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_STREAM:
+		return "Refer to Stream Header";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_32000:
+		return "32 kHz";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_44100:
+		return "44.1 kHz (CD)";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_48000:
+		return "48 kHz";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_88200:
+		return "88.2 kHz";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_96000:
+		return "96 kHz";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_176400:
+		return "176.4 kHz";
+	case HDMI_AUDIO_SAMPLE_FREQUENCY_192000:
+		return "192 kHz";
+	}
+	return "Invalid";
+}
+
+static const char *
+hdmi_audio_coding_type_ext_get_name(enum hdmi_audio_coding_type_ext ctx)
+{
+
+	switch (ctx) {
+	case HDMI_AUDIO_CODING_TYPE_EXT_CT:
+		return "Refer to CT";
+	case HDMI_AUDIO_CODING_TYPE_EXT_HE_AAC:
+		return "HE AAC";
+	case HDMI_AUDIO_CODING_TYPE_EXT_HE_AAC_V2:
+		return "HE AAC v2";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG_SURROUND:
+		return "MPEG SURROUND";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG4_HE_AAC:
+		return "MPEG-4 HE AAC";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG4_HE_AAC_V2:
+		return "MPEG-4 HE AAC v2";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG4_AAC_LC:
+		return "MPEG-4 AAC LC";
+	case HDMI_AUDIO_CODING_TYPE_EXT_DRA:
+		return "DRA";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG4_HE_AAC_SURROUND:
+		return "MPEG-4 HE AAC + MPEG Surround";
+	case HDMI_AUDIO_CODING_TYPE_EXT_MPEG4_AAC_LC_SURROUND:
+		return "MPEG-4 AAC LC + MPEG Surround";
+	}
+	return "Reserved";
+}
+
+/**
+ * hdmi_audio_infoframe_log() - log info of HDMI AUDIO infoframe
+ * @level: logging level
+ * @dev: device
+ * @frame: HDMI AUDIO infoframe
+ */
+static void hdmi_audio_infoframe_log(struct hdmi_audio_infoframe *frame)
+{
+	hdmi_infoframe_log_header((struct hdmi_any_infoframe *)frame);
+
+	if (frame->channels)
+		hdmi_log("    channels: %u\n", frame->channels - 1);
+	else
+		hdmi_log("    channels: Refer to stream header\n");
+	hdmi_log("    coding type: %s\n",
+			hdmi_audio_coding_type_get_name(frame->coding_type));
+	hdmi_log("    sample size: %s\n",
+			hdmi_audio_sample_size_get_name(frame->sample_size));
+	hdmi_log("    sample frequency: %s\n",
+			hdmi_audio_sample_frequency_get_name(frame->sample_frequency));
+	hdmi_log("    coding type ext: %s\n",
+			hdmi_audio_coding_type_ext_get_name(frame->coding_type_ext));
+	hdmi_log("    channel allocation: 0x%x\n",
+			frame->channel_allocation);
+	hdmi_log("    level shift value: %u dB\n",
+			frame->level_shift_value);
+	hdmi_log("    downmix inhibit: %s\n",
+			frame->downmix_inhibit ? "Yes" : "No");
+}
+
+static const char *
+hdmi_3d_structure_get_name(enum hdmi_3d_structure s3d_struct)
+{
+	if (s3d_struct < 0 || s3d_struct > 0xf)
+		return "Invalid";
+
+	switch (s3d_struct) {
+	case HDMI_3D_STRUCTURE_FRAME_PACKING:
+		return "Frame Packing";
+	case HDMI_3D_STRUCTURE_FIELD_ALTERNATIVE:
+		return "Field Alternative";
+	case HDMI_3D_STRUCTURE_LINE_ALTERNATIVE:
+		return "Line Alternative";
+	case HDMI_3D_STRUCTURE_SIDE_BY_SIDE_FULL:
+		return "Side-by-side (Full)";
+	case HDMI_3D_STRUCTURE_L_DEPTH:
+		return "L + Depth";
+	case HDMI_3D_STRUCTURE_L_DEPTH_GFX_GFX_DEPTH:
+		return "L + Depth + Graphics + Graphics-depth";
+	case HDMI_3D_STRUCTURE_TOP_AND_BOTTOM:
+		return "Top-and-Bottom";
+	case HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF:
+		return "Side-by-side (Half)";
+	default:
+		break;
+	}
+	return "Reserved";
+}
+
+/**
+ * hdmi_vendor_infoframe_log() - log info of HDMI VENDOR infoframe
+ * @level: logging level
+ * @dev: device
+ * @frame: HDMI VENDOR infoframe
+ */
+static void
+hdmi_vendor_any_infoframe_log(union hdmi_vendor_any_infoframe *frame)
+{
+	struct hdmi_vendor_infoframe *hvf = &frame->hdmi;
+
+	hdmi_infoframe_log_header((struct hdmi_any_infoframe *)frame);
+
+	if (frame->any.oui != HDMI_IEEE_OUI) {
+		hdmi_log("    not a HDMI vendor infoframe\n");
+		return;
+	}
+	if (hvf->vic == 0 && hvf->s3d_struct == HDMI_3D_STRUCTURE_INVALID) {
+		hdmi_log("    empty frame\n");
+		return;
+	}
+
+	if (hvf->vic)
+		hdmi_log("    HDMI VIC: %u\n", hvf->vic);
+	if (hvf->s3d_struct != HDMI_3D_STRUCTURE_INVALID) {
+		hdmi_log("    3D structure: %s\n",
+				hdmi_3d_structure_get_name(hvf->s3d_struct));
+		if (hvf->s3d_struct >= HDMI_3D_STRUCTURE_SIDE_BY_SIDE_HALF)
+			hdmi_log("    3D extension data: %d\n",
+					hvf->s3d_ext_data);
+	}
+}
+
+/**
+ * hdmi_infoframe_log() - log info of HDMI infoframe
+ * @level: logging level
+ * @dev: device
+ * @frame: HDMI infoframe
+ */
+void hdmi_infoframe_log(union hdmi_infoframe *frame)
+{
+	switch (frame->any.type) {
+	case HDMI_INFOFRAME_TYPE_AVI:
+		hdmi_avi_infoframe_log(&frame->avi);
+		break;
+	case HDMI_INFOFRAME_TYPE_SPD:
+		hdmi_spd_infoframe_log(&frame->spd);
+		break;
+	case HDMI_INFOFRAME_TYPE_AUDIO:
+		hdmi_audio_infoframe_log(&frame->audio);
+		break;
+	case HDMI_INFOFRAME_TYPE_VENDOR:
+		hdmi_vendor_any_infoframe_log(&frame->vendor);
+		break;
+	}
+}
+EXPORT_SYMBOL(hdmi_infoframe_log);
+
+/**

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Mon Dec 26 14:39:06 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 79D82C9107A;
 Mon, 26 Dec 2016 14:39:06 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 3A43D166A;
 Mon, 26 Dec 2016 14:39:06 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQEd5b1045943;
 Mon, 26 Dec 2016 14:39:05 GMT (envelope-from jilles@FreeBSD.org)
Received: (from jilles@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQEd5n1045942;
 Mon, 26 Dec 2016 14:39:05 GMT (envelope-from jilles@FreeBSD.org)
Message-Id: <201612261439.uBQEd5n1045942@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jilles set sender to
 jilles@FreeBSD.org using -f
From: Jilles Tjoelker <jilles@FreeBSD.org>
Date: Mon, 26 Dec 2016 14:39:05 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310601 - stable/11/tests/sys/kern
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 14:39:06 -0000

Author: jilles
Date: Mon Dec 26 14:39:05 2016
New Revision: 310601
URL: https://svnweb.freebsd.org/changeset/base/310601

Log:
  MFC r309957: Add tests for reaper receiving SIGCHLD (r309886).
  
  PR:		213928

Modified:
  stable/11/tests/sys/kern/reaper.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/tests/sys/kern/reaper.c
==============================================================================
--- stable/11/tests/sys/kern/reaper.c	Mon Dec 26 14:36:05 2016	(r310600)
+++ stable/11/tests/sys/kern/reaper.c	Mon Dec 26 14:39:05 2016	(r310601)
@@ -35,6 +35,11 @@ __FBSDID("$FreeBSD$");
 #include <signal.h>
 #include <unistd.h>
 
+static void
+dummy_sighandler(int sig __unused, siginfo_t *info __unused, void *ctx __unused)
+{
+}
+
 ATF_TC_WITHOUT_HEAD(reaper_wait_child_first);
 ATF_TC_BODY(reaper_wait_child_first, tc)
 {
@@ -129,6 +134,161 @@ ATF_TC_BODY(reaper_wait_grandchild_first
 	ATF_CHECK_EQ(2, r);
 }
 
+ATF_TC(reaper_sigchld_child_first);
+ATF_TC_HEAD(reaper_sigchld_child_first, tc)
+{
+	atf_tc_set_md_var(tc, "timeout", "2");
+}
+ATF_TC_BODY(reaper_sigchld_child_first, tc)
+{
+	struct sigaction act;
+	sigset_t mask;
+	siginfo_t info;
+	pid_t parent, child, grandchild, pid;
+	int r;
+	int pip[2];
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	act.sa_sigaction = dummy_sighandler;
+	act.sa_flags = SA_SIGINFO | SA_RESTART;
+	r = sigemptyset(&act.sa_mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaction(SIGCHLD, &act, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigemptyset(&mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaddset(&mask, SIGCHLD);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigprocmask(SIG_BLOCK, &mask, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = pipe(pip);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pip[1]) != 0)
+			_exit(100);
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0) {
+			if (read(pip[0], &(uint8_t){ 0 }, 1) != 0)
+				_exit(102);
+			if (getppid() != parent)
+				_exit(103);
+			_exit(2);
+		} else
+			_exit(3);
+	}
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(3, info.si_status);
+	ATF_CHECK_EQ(child, info.si_pid);
+
+	pid = waitpid(child, NULL, 0);
+	ATF_REQUIRE_EQ(child, pid);
+
+	r = close(pip[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(2, info.si_status);
+	grandchild = info.si_pid;
+	ATF_REQUIRE(grandchild > 0);
+	ATF_REQUIRE(grandchild != parent);
+	ATF_REQUIRE(grandchild != child);
+
+	pid = waitpid(-1, NULL, 0);
+	ATF_REQUIRE_EQ(grandchild, pid);
+
+	r = close(pip[0]);
+	ATF_REQUIRE_EQ(0, r);
+}
+
+ATF_TC(reaper_sigchld_grandchild_first);
+ATF_TC_HEAD(reaper_sigchld_grandchild_first, tc)
+{
+	atf_tc_set_md_var(tc, "timeout", "2");
+}
+ATF_TC_BODY(reaper_sigchld_grandchild_first, tc)
+{
+	struct sigaction act;
+	sigset_t mask;
+	siginfo_t info;
+	pid_t parent, child, grandchild, pid;
+	int r;
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	act.sa_sigaction = dummy_sighandler;
+	act.sa_flags = SA_SIGINFO | SA_RESTART;
+	r = sigemptyset(&act.sa_mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaction(SIGCHLD, &act, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigemptyset(&mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaddset(&mask, SIGCHLD);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigprocmask(SIG_BLOCK, &mask, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0)
+			_exit(2);
+		else {
+			if (waitid(P_PID, grandchild, NULL,
+			    WNOWAIT | WEXITED) != 0)
+				_exit(102);
+			_exit(3);
+		}
+	}
+
+	pid = waitpid(child, NULL, 0);
+	ATF_REQUIRE_EQ(child, pid);
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(2, info.si_status);
+	grandchild = info.si_pid;
+	ATF_REQUIRE(grandchild > 0);
+	ATF_REQUIRE(grandchild != parent);
+	ATF_REQUIRE(grandchild != child);
+
+	pid = waitpid(-1, NULL, 0);
+	ATF_REQUIRE_EQ(grandchild, pid);
+}
+
 ATF_TC_WITHOUT_HEAD(reaper_status);
 ATF_TC_BODY(reaper_status, tc)
 {
@@ -484,6 +644,8 @@ ATF_TP_ADD_TCS(tp)
 
 	ATF_TP_ADD_TC(tp, reaper_wait_child_first);
 	ATF_TP_ADD_TC(tp, reaper_wait_grandchild_first);
+	ATF_TP_ADD_TC(tp, reaper_sigchld_child_first);
+	ATF_TP_ADD_TC(tp, reaper_sigchld_grandchild_first);
 	ATF_TP_ADD_TC(tp, reaper_status);
 	ATF_TP_ADD_TC(tp, reaper_getpids);
 	ATF_TP_ADD_TC(tp, reaper_kill_badsig);

From owner-svn-src-all@freebsd.org  Mon Dec 26 16:27:03 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 47C96C9169D;
 Mon, 26 Dec 2016 16:27:03 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E4F8411A6;
 Mon, 26 Dec 2016 16:27:02 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQGR2sK091032;
 Mon, 26 Dec 2016 16:27:02 GMT (envelope-from pfg@FreeBSD.org)
Received: (from pfg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQGR17F091029;
 Mon, 26 Dec 2016 16:27:01 GMT (envelope-from pfg@FreeBSD.org)
Message-Id: <201612261627.uBQGR17F091029@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org
 using -f
From: "Pedro F. Giffuni" <pfg@FreeBSD.org>
Date: Mon, 26 Dec 2016 16:27:01 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310604 - stable/11/bin/ed
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 16:27:03 -0000

Author: pfg
Date: Mon Dec 26 16:27:01 2016
New Revision: 310604
URL: https://svnweb.freebsd.org/changeset/base/310604

Log:
  MFC r309873:
  ed(1): Prevent possible overflows during allocation.
  
  Make sure the parameters used for malloc(3) can hold size_t sizes.
  This should help ed(1) handle bigger data in the future.

Modified:
  stable/11/bin/ed/ed.h
  stable/11/bin/ed/glbl.c
  stable/11/bin/ed/main.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/bin/ed/ed.h
==============================================================================
--- stable/11/bin/ed/ed.h	Mon Dec 26 15:24:12 2016	(r310603)
+++ stable/11/bin/ed/ed.h	Mon Dec 26 16:27:01 2016	(r310604)
@@ -115,7 +115,7 @@ if (--mutex == 0) { \
 /* REALLOC: assure at least a minimum size for buffer b */
 #define REALLOC(b,n,i,err) \
 if ((i) > (n)) { \
-	int ti = (n); \
+	size_t ti = (n); \
 	char *ts; \
 	SPL1(); \
 	if ((b) != NULL) { \
@@ -141,7 +141,7 @@ if ((i) > (n)) { \
 /* REALLOC: assure at least a minimum size for buffer b */
 #define REALLOC(b,n,i,err) \
 if ((i) > (n)) { \
-	int ti = (n); \
+	size_t ti = (n); \
 	char *ts; \
 	SPL1(); \
 	if ((ts = (char *) realloc((b), ti += max((i), MINBUFSZ))) == NULL) { \

Modified: stable/11/bin/ed/glbl.c
==============================================================================
--- stable/11/bin/ed/glbl.c	Mon Dec 26 15:24:12 2016	(r310603)
+++ stable/11/bin/ed/glbl.c	Mon Dec 26 16:27:01 2016	(r310604)
@@ -146,7 +146,7 @@ int
 set_active_node(line_t *lp)
 {
 	if (active_last + 1 > active_size) {
-		int ti = active_size;
+		size_t ti = active_size;
 		line_t **ts;
 		SPL1();
 #if defined(sun) || defined(NO_REALLOC_NULL)

Modified: stable/11/bin/ed/main.c
==============================================================================
--- stable/11/bin/ed/main.c	Mon Dec 26 15:24:12 2016	(r310603)
+++ stable/11/bin/ed/main.c	Mon Dec 26 16:27:01 2016	(r310604)
@@ -1356,7 +1356,7 @@ handle_hup(int signo)
 	char *hup = NULL;		/* hup filename */
 	char *s;
 	char ed_hup[] = "ed.hup";
-	int n;
+	size_t n;
 
 	if (!sigactive)
 		quit(1);

From owner-svn-src-all@freebsd.org  Mon Dec 26 16:42:39 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6D007C91C3B;
 Mon, 26 Dec 2016 16:42:39 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 37B7B1C23;
 Mon, 26 Dec 2016 16:42:39 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQGgc9b098983;
 Mon, 26 Dec 2016 16:42:38 GMT (envelope-from pfg@FreeBSD.org)
Received: (from pfg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQGgcIv098982;
 Mon, 26 Dec 2016 16:42:38 GMT (envelope-from pfg@FreeBSD.org)
Message-Id: <201612261642.uBQGgcIv098982@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org
 using -f
From: "Pedro F. Giffuni" <pfg@FreeBSD.org>
Date: Mon, 26 Dec 2016 16:42:38 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310605 - stable/11/bin/pax
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 16:42:39 -0000

Author: pfg
Date: Mon Dec 26 16:42:38 2016
New Revision: 310605
URL: https://svnweb.freebsd.org/changeset/base/310605

Log:
  MFC r310367:
  pax(1):	Fix a bug with archives smaller than 512 bytes.
  
  The problem here is that the archive is too short (< 512 bytes). The
  buffer routines, try to read at least 512 bytes, even when we try to
  determine what format file we have, which is wrong.
  
  Obtained from:	NetBSD (CVS rev 1.26)

Modified:
  stable/11/bin/pax/buf_subs.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/bin/pax/buf_subs.c
==============================================================================
--- stable/11/bin/pax/buf_subs.c	Mon Dec 26 16:27:01 2016	(r310604)
+++ stable/11/bin/pax/buf_subs.c	Mon Dec 26 16:42:38 2016	(r310605)
@@ -852,10 +852,13 @@ buf_fill(void)
 
 		/*
 		 * errors require resync, EOF goes to next archive
+		 * but in case we have not determined yet the format,
+		 * this means that we have a very short file, so we
+		 * are done again.
 		 */
 		if (cnt < 0)
 			break;
-		if (ar_next() < 0) {
+		if (frmt == NULL || ar_next() < 0) {
 			fini = 1;
 			return(0);
 		}

From owner-svn-src-all@freebsd.org  Mon Dec 26 16:43:41 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 54A9BC91E13;
 Mon, 26 Dec 2016 16:43:41 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id F2E5A1F74;
 Mon, 26 Dec 2016 16:43:40 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQGheRN099807;
 Mon, 26 Dec 2016 16:43:40 GMT (envelope-from pfg@FreeBSD.org)
Received: (from pfg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQGhexl099806;
 Mon, 26 Dec 2016 16:43:40 GMT (envelope-from pfg@FreeBSD.org)
Message-Id: <201612261643.uBQGhexl099806@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org
 using -f
From: "Pedro F. Giffuni" <pfg@FreeBSD.org>
Date: Mon, 26 Dec 2016 16:43:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310606 - stable/10/bin/pax
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 16:43:41 -0000

Author: pfg
Date: Mon Dec 26 16:43:39 2016
New Revision: 310606
URL: https://svnweb.freebsd.org/changeset/base/310606

Log:
  MFC r310367:
  pax(1):	Fix a bug with archives smaller than 512 bytes.
  
  The problem here is that the archive is too short (< 512 bytes). The
  buffer routines, try to read at least 512 bytes, even when we try to
  determine what format file we have, which is wrong.
  
  Obtained from:	NetBSD (CVS rev 1.26)

Modified:
  stable/10/bin/pax/buf_subs.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/bin/pax/buf_subs.c
==============================================================================
--- stable/10/bin/pax/buf_subs.c	Mon Dec 26 16:42:38 2016	(r310605)
+++ stable/10/bin/pax/buf_subs.c	Mon Dec 26 16:43:39 2016	(r310606)
@@ -852,10 +852,13 @@ buf_fill(void)
 
 		/*
 		 * errors require resync, EOF goes to next archive
+		 * but in case we have not determined yet the format,
+		 * this means that we have a very short file, so we
+		 * are done again.
 		 */
 		if (cnt < 0)
 			break;
-		if (ar_next() < 0) {
+		if (frmt == NULL || ar_next() < 0) {
 			fini = 1;
 			return(0);
 		}

From owner-svn-src-all@freebsd.org  Mon Dec 26 16:45:01 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 57BD7C920FA;
 Mon, 26 Dec 2016 16:45:01 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 1BF6F175B;
 Mon, 26 Dec 2016 16:45:01 +0000 (UTC) (envelope-from pfg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQGj04e000967;
 Mon, 26 Dec 2016 16:45:00 GMT (envelope-from pfg@FreeBSD.org)
Received: (from pfg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQGj03c000966;
 Mon, 26 Dec 2016 16:45:00 GMT (envelope-from pfg@FreeBSD.org)
Message-Id: <201612261645.uBQGj03c000966@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org
 using -f
From: "Pedro F. Giffuni" <pfg@FreeBSD.org>
Date: Mon, 26 Dec 2016 16:45:00 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject: svn commit: r310607 - stable/9/bin/pax
X-SVN-Group: stable-9
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 16:45:01 -0000

Author: pfg
Date: Mon Dec 26 16:45:00 2016
New Revision: 310607
URL: https://svnweb.freebsd.org/changeset/base/310607

Log:
  MFC r310367:
  pax(1):	Fix a bug with archives smaller than 512 bytes.
  
  The problem here is that the archive is too short (< 512 bytes). The
  buffer routines, try to read at least 512 bytes, even when we try to
  determine what format file we have, which is wrong.
  
  Obtained from:	NetBSD (CVS rev 1.26)

Modified:
  stable/9/bin/pax/buf_subs.c

Modified: stable/9/bin/pax/buf_subs.c
==============================================================================
--- stable/9/bin/pax/buf_subs.c	Mon Dec 26 16:43:39 2016	(r310606)
+++ stable/9/bin/pax/buf_subs.c	Mon Dec 26 16:45:00 2016	(r310607)
@@ -853,10 +853,13 @@ buf_fill(void)
 
 		/*
 		 * errors require resync, EOF goes to next archive
+		 * but in case we have not determined yet the format,
+		 * this means that we have a very short file, so we
+		 * are done again.
 		 */
 		if (cnt < 0)
 			break;
-		if (ar_next() < 0) {
+		if (frmt == NULL || ar_next() < 0) {
 			fini = 1;
 			return(0);
 		}

From owner-svn-src-all@freebsd.org  Mon Dec 26 17:10:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6073C92756;
 Mon, 26 Dec 2016 17:10:42 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 95A6419DA;
 Mon, 26 Dec 2016 17:10:42 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQHAfm1009808;
 Mon, 26 Dec 2016 17:10:41 GMT (envelope-from delphij@FreeBSD.org)
Received: (from delphij@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQHAfse009807;
 Mon, 26 Dec 2016 17:10:41 GMT (envelope-from delphij@FreeBSD.org)
Message-Id: <201612261710.uBQHAfse009807@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: delphij set sender to
 delphij@FreeBSD.org using -f
From: Xin LI <delphij@FreeBSD.org>
Date: Mon, 26 Dec 2016 17:10:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310608 - head/libexec/talkd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 17:10:42 -0000

Author: delphij
Date: Mon Dec 26 17:10:41 2016
New Revision: 310608
URL: https://svnweb.freebsd.org/changeset/base/310608

Log:
  Avoid use after free.
  
  Reported by:	Clang static code analyzer
  MFC after:	2 weeks

Modified:
  head/libexec/talkd/table.c

Modified: head/libexec/talkd/table.c
==============================================================================
--- head/libexec/talkd/table.c	Mon Dec 26 16:45:00 2016	(r310607)
+++ head/libexec/talkd/table.c	Mon Dec 26 17:10:41 2016	(r310608)
@@ -82,14 +82,15 @@ static TABLE_ENTRY *table = NIL;
 CTL_MSG *
 find_match(CTL_MSG *request)
 {
-	TABLE_ENTRY *ptr;
+	TABLE_ENTRY *ptr, *next;
 	time_t current_time;
 
 	gettimeofday(&tp, NULL);
 	current_time = tp.tv_sec;
 	if (debug)
 		print_request("find_match", request);
-	for (ptr = table; ptr != NIL; ptr = ptr->next) {
+	for (ptr = table; ptr != NIL; ptr = next) {
+		next = ptr->next;
 		if ((ptr->time - current_time) > MAX_LIFE) {
 			/* the entry is too old */
 			if (debug)
@@ -115,7 +116,7 @@ find_match(CTL_MSG *request)
 CTL_MSG *
 find_request(CTL_MSG *request)
 {
-	TABLE_ENTRY *ptr;
+	TABLE_ENTRY *ptr, *next;
 	time_t current_time;
 
 	gettimeofday(&tp, NULL);
@@ -126,7 +127,8 @@ find_request(CTL_MSG *request)
 	 */
 	if (debug)
 		print_request("find_request", request);
-	for (ptr = table; ptr != NIL; ptr = ptr->next) {
+	for (ptr = table; ptr != NIL; ptr = next) {
+		next = ptr->next;
 		if ((ptr->time - current_time) > MAX_LIFE) {
 			/* the entry is too old */
 			if (debug)

From owner-svn-src-all@freebsd.org  Mon Dec 26 17:23:11 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id F3FD3C92BD6;
 Mon, 26 Dec 2016 17:23:10 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C387413F0;
 Mon, 26 Dec 2016 17:23:10 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQHN9Sa017441;
 Mon, 26 Dec 2016 17:23:09 GMT (envelope-from delphij@FreeBSD.org)
Received: (from delphij@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQHN9WI017440;
 Mon, 26 Dec 2016 17:23:09 GMT (envelope-from delphij@FreeBSD.org)
Message-Id: <201612261723.uBQHN9WI017440@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: delphij set sender to
 delphij@FreeBSD.org using -f
From: Xin LI <delphij@FreeBSD.org>
Date: Mon, 26 Dec 2016 17:23:09 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310609 - head/libexec/talkd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 17:23:11 -0000

Author: delphij
Date: Mon Dec 26 17:23:09 2016
New Revision: 310609
URL: https://svnweb.freebsd.org/changeset/base/310609

Log:
  Don't use high precision clock for expiration as only second portion is
  used.
  
  MFC after:	2 weeks

Modified:
  head/libexec/talkd/table.c

Modified: head/libexec/talkd/table.c
==============================================================================
--- head/libexec/talkd/table.c	Mon Dec 26 17:10:41 2016	(r310608)
+++ head/libexec/talkd/table.c	Mon Dec 26 17:23:09 2016	(r310609)
@@ -60,7 +60,7 @@ static const char rcsid[] =
 
 #define NIL ((TABLE_ENTRY *)0)
 
-static struct timeval tp;
+static struct timespec ts;
 
 typedef struct table_entry TABLE_ENTRY;
 
@@ -85,8 +85,8 @@ find_match(CTL_MSG *request)
 	TABLE_ENTRY *ptr, *next;
 	time_t current_time;
 
-	gettimeofday(&tp, NULL);
-	current_time = tp.tv_sec;
+	clock_gettime(CLOCK_MONOTONIC_FAST, &ts);
+	current_time = ts.tv_sec;
 	if (debug)
 		print_request("find_match", request);
 	for (ptr = table; ptr != NIL; ptr = next) {
@@ -119,8 +119,8 @@ find_request(CTL_MSG *request)
 	TABLE_ENTRY *ptr, *next;
 	time_t current_time;
 
-	gettimeofday(&tp, NULL);
-	current_time = tp.tv_sec;
+	clock_gettime(CLOCK_MONOTONIC_FAST, &ts);
+	current_time = ts.tv_sec;
 	/*
 	 * See if this is a repeated message, and check for
 	 * out of date entries in the table while we are it.
@@ -157,8 +157,8 @@ insert_table(CTL_MSG *request, CTL_RESPO
 	TABLE_ENTRY *ptr;
 	time_t current_time;
 
-	gettimeofday(&tp, NULL);
-	current_time = tp.tv_sec;
+	clock_gettime(CLOCK_MONOTONIC_FAST, &ts);
+	current_time = ts.tv_sec;
 	request->id_num = new_id();
 	response->id_num = htonl(request->id_num);
 	/* insert a new entry into the top of the list */

From owner-svn-src-all@freebsd.org  Mon Dec 26 17:26:26 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id AD2A6C92C50;
 Mon, 26 Dec 2016 17:26:26 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6DBA11612;
 Mon, 26 Dec 2016 17:26:26 +0000 (UTC)
 (envelope-from jilles@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQHQPVr017603;
 Mon, 26 Dec 2016 17:26:25 GMT (envelope-from jilles@FreeBSD.org)
Received: (from jilles@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQHQPbp017602;
 Mon, 26 Dec 2016 17:26:25 GMT (envelope-from jilles@FreeBSD.org)
Message-Id: <201612261726.uBQHQPbp017602@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jilles set sender to
 jilles@FreeBSD.org using -f
From: Jilles Tjoelker <jilles@FreeBSD.org>
Date: Mon, 26 Dec 2016 17:26:25 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310610 - stable/10/tests/sys/kern
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 17:26:26 -0000

Author: jilles
Date: Mon Dec 26 17:26:25 2016
New Revision: 310610
URL: https://svnweb.freebsd.org/changeset/base/310610

Log:
  MFC r309957: Add tests for reaper receiving SIGCHLD (r309886).
  
  PR:		213928

Modified:
  stable/10/tests/sys/kern/reaper.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/tests/sys/kern/reaper.c
==============================================================================
--- stable/10/tests/sys/kern/reaper.c	Mon Dec 26 17:23:09 2016	(r310609)
+++ stable/10/tests/sys/kern/reaper.c	Mon Dec 26 17:26:25 2016	(r310610)
@@ -35,6 +35,11 @@ __FBSDID("$FreeBSD$");
 #include <signal.h>
 #include <unistd.h>
 
+static void
+dummy_sighandler(int sig __unused, siginfo_t *info __unused, void *ctx __unused)
+{
+}
+
 ATF_TC_WITHOUT_HEAD(reaper_wait_child_first);
 ATF_TC_BODY(reaper_wait_child_first, tc)
 {
@@ -129,6 +134,161 @@ ATF_TC_BODY(reaper_wait_grandchild_first
 	ATF_CHECK_EQ(2, r);
 }
 
+ATF_TC(reaper_sigchld_child_first);
+ATF_TC_HEAD(reaper_sigchld_child_first, tc)
+{
+	atf_tc_set_md_var(tc, "timeout", "2");
+}
+ATF_TC_BODY(reaper_sigchld_child_first, tc)
+{
+	struct sigaction act;
+	sigset_t mask;
+	siginfo_t info;
+	pid_t parent, child, grandchild, pid;
+	int r;
+	int pip[2];
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	act.sa_sigaction = dummy_sighandler;
+	act.sa_flags = SA_SIGINFO | SA_RESTART;
+	r = sigemptyset(&act.sa_mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaction(SIGCHLD, &act, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigemptyset(&mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaddset(&mask, SIGCHLD);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigprocmask(SIG_BLOCK, &mask, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = pipe(pip);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		if (close(pip[1]) != 0)
+			_exit(100);
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0) {
+			if (read(pip[0], &(uint8_t){ 0 }, 1) != 0)
+				_exit(102);
+			if (getppid() != parent)
+				_exit(103);
+			_exit(2);
+		} else
+			_exit(3);
+	}
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(3, info.si_status);
+	ATF_CHECK_EQ(child, info.si_pid);
+
+	pid = waitpid(child, NULL, 0);
+	ATF_REQUIRE_EQ(child, pid);
+
+	r = close(pip[1]);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(2, info.si_status);
+	grandchild = info.si_pid;
+	ATF_REQUIRE(grandchild > 0);
+	ATF_REQUIRE(grandchild != parent);
+	ATF_REQUIRE(grandchild != child);
+
+	pid = waitpid(-1, NULL, 0);
+	ATF_REQUIRE_EQ(grandchild, pid);
+
+	r = close(pip[0]);
+	ATF_REQUIRE_EQ(0, r);
+}
+
+ATF_TC(reaper_sigchld_grandchild_first);
+ATF_TC_HEAD(reaper_sigchld_grandchild_first, tc)
+{
+	atf_tc_set_md_var(tc, "timeout", "2");
+}
+ATF_TC_BODY(reaper_sigchld_grandchild_first, tc)
+{
+	struct sigaction act;
+	sigset_t mask;
+	siginfo_t info;
+	pid_t parent, child, grandchild, pid;
+	int r;
+
+	/* Be paranoid. */
+	pid = waitpid(-1, NULL, WNOHANG);
+	ATF_REQUIRE(pid == -1 && errno == ECHILD);
+
+	act.sa_sigaction = dummy_sighandler;
+	act.sa_flags = SA_SIGINFO | SA_RESTART;
+	r = sigemptyset(&act.sa_mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaction(SIGCHLD, &act, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	r = sigemptyset(&mask);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigaddset(&mask, SIGCHLD);
+	ATF_REQUIRE_EQ(0, r);
+	r = sigprocmask(SIG_BLOCK, &mask, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	parent = getpid();
+	r = procctl(P_PID, parent, PROC_REAP_ACQUIRE, NULL);
+	ATF_REQUIRE_EQ(0, r);
+
+	child = fork();
+	ATF_REQUIRE(child != -1);
+	if (child == 0) {
+		grandchild = fork();
+		if (grandchild == -1)
+			_exit(101);
+		else if (grandchild == 0)
+			_exit(2);
+		else {
+			if (waitid(P_PID, grandchild, NULL,
+			    WNOWAIT | WEXITED) != 0)
+				_exit(102);
+			_exit(3);
+		}
+	}
+
+	pid = waitpid(child, NULL, 0);
+	ATF_REQUIRE_EQ(child, pid);
+
+	r = sigwaitinfo(&mask, &info);
+	ATF_REQUIRE_EQ(SIGCHLD, r);
+	ATF_CHECK_EQ(SIGCHLD, info.si_signo);
+	ATF_CHECK_EQ(CLD_EXITED, info.si_code);
+	ATF_CHECK_EQ(2, info.si_status);
+	grandchild = info.si_pid;
+	ATF_REQUIRE(grandchild > 0);
+	ATF_REQUIRE(grandchild != parent);
+	ATF_REQUIRE(grandchild != child);
+
+	pid = waitpid(-1, NULL, 0);
+	ATF_REQUIRE_EQ(grandchild, pid);
+}
+
 ATF_TC_WITHOUT_HEAD(reaper_status);
 ATF_TC_BODY(reaper_status, tc)
 {
@@ -484,6 +644,8 @@ ATF_TP_ADD_TCS(tp)
 
 	ATF_TP_ADD_TC(tp, reaper_wait_child_first);
 	ATF_TP_ADD_TC(tp, reaper_wait_grandchild_first);
+	ATF_TP_ADD_TC(tp, reaper_sigchld_child_first);
+	ATF_TP_ADD_TC(tp, reaper_sigchld_grandchild_first);
 	ATF_TP_ADD_TC(tp, reaper_status);
 	ATF_TP_ADD_TC(tp, reaper_getpids);
 	ATF_TP_ADD_TC(tp, reaper_kill_badsig);

From owner-svn-src-all@freebsd.org  Mon Dec 26 17:34:29 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 217B2C92F22;
 Mon, 26 Dec 2016 17:34:29 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id D908F1E8A;
 Mon, 26 Dec 2016 17:34:28 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQHYSGA022121;
 Mon, 26 Dec 2016 17:34:28 GMT (envelope-from delphij@FreeBSD.org)
Received: (from delphij@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQHYS2x022120;
 Mon, 26 Dec 2016 17:34:28 GMT (envelope-from delphij@FreeBSD.org)
Message-Id: <201612261734.uBQHYS2x022120@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: delphij set sender to
 delphij@FreeBSD.org using -f
From: Xin LI <delphij@FreeBSD.org>
Date: Mon, 26 Dec 2016 17:34:28 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310611 - head/usr.sbin/pstat
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 17:34:29 -0000

Author: delphij
Date: Mon Dec 26 17:34:27 2016
New Revision: 310611
URL: https://svnweb.freebsd.org/changeset/base/310611

Log:
   - pstat(8) does not accept any arguments other than getopt() args,
     so don't bother to adjust argc/argv after getopt() loop.
   - Make a string pointer constant.
  
  MFC after:	2 weeks

Modified:
  head/usr.sbin/pstat/pstat.c

Modified: head/usr.sbin/pstat/pstat.c
==============================================================================
--- head/usr.sbin/pstat/pstat.c	Mon Dec 26 17:26:25 2016	(r310610)
+++ head/usr.sbin/pstat/pstat.c	Mon Dec 26 17:34:27 2016	(r310611)
@@ -174,8 +174,6 @@ main(int argc, char *argv[])
 		default:
 			usage();
 		}
-	argc -= optind;
-	argv += optind;
 
 	/*
 	 * Initialize symbol names list.
@@ -339,7 +337,7 @@ static void
 ttyprt(struct xtty *xt)
 {
 	int i, j;
-	char *name;
+	const char *name;
 
 	if (xt->xt_size != sizeof *xt)
 		errx(1, "struct xtty size mismatch");

From owner-svn-src-all@freebsd.org  Mon Dec 26 17:48:15 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3E6FDC91218;
 Mon, 26 Dec 2016 17:48:15 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 0CBA215BF;
 Mon, 26 Dec 2016 17:48:14 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQHmEWP026407;
 Mon, 26 Dec 2016 17:48:14 GMT (envelope-from gonzo@FreeBSD.org)
Received: (from gonzo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQHmEAx026406;
 Mon, 26 Dec 2016 17:48:14 GMT (envelope-from gonzo@FreeBSD.org)
Message-Id: <201612261748.uBQHmEAx026406@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: gonzo set sender to
 gonzo@FreeBSD.org using -f
From: Oleksandr Tymoshenko <gonzo@FreeBSD.org>
Date: Mon, 26 Dec 2016 17:48:14 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310612 - head/sys/dev/evdev
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 17:48:15 -0000

Author: gonzo
Date: Mon Dec 26 17:48:13 2016
New Revision: 310612
URL: https://svnweb.freebsd.org/changeset/base/310612

Log:
  [evdev] Fix build for older versions of clang
  
  There was report of stable/11 build failure on older versions of
  FreeBSD. The problem was a reference to static variable in inline
  function. Although fairly recent versions of clang can cope with this
  situation just fine there is no strict requirement to make functions
  in question inline, they're not in any time-critical codepath. So to
  keep HEAD and 11-STABLE buildable on older FreeBSDs some of the util
  functions were converted from inline to normal.
  
  Reported by:	hselasky
  MFC after:	3 days

Modified:
  head/sys/dev/evdev/evdev_utils.c

Modified: head/sys/dev/evdev/evdev_utils.c
==============================================================================
--- head/sys/dev/evdev/evdev_utils.c	Mon Dec 26 17:34:27 2016	(r310611)
+++ head/sys/dev/evdev/evdev_utils.c	Mon Dec 26 17:48:13 2016	(r310612)
@@ -206,13 +206,13 @@ static uint16_t evdev_led_codes[] = {
 	LED_SCROLLL,	/* SLKED */
 };
 
-inline uint16_t
+uint16_t
 evdev_hid2key(int scancode)
 {
 	return evdev_usb_scancodes[scancode];
 }
 
-inline void
+void
 evdev_support_all_known_keys(struct evdev_dev *evdev)
 {
 	size_t i;
@@ -222,7 +222,7 @@ evdev_support_all_known_keys(struct evde
 			evdev_support_key(evdev, evdev_at_set1_scancodes[i]);
 }
 
-inline uint16_t
+uint16_t
 evdev_scancode2key(int *state, int scancode)
 {
 	uint16_t keycode;

From owner-svn-src-all@freebsd.org  Mon Dec 26 19:26:41 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D6883C92C45;
 Mon, 26 Dec 2016 19:26:41 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A63FF1542;
 Mon, 26 Dec 2016 19:26:41 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQJQedH067288;
 Mon, 26 Dec 2016 19:26:40 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQJQeSG067287;
 Mon, 26 Dec 2016 19:26:40 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261926.uBQJQeSG067287@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 19:26:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310613 - head/sys/kern
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 19:26:41 -0000

Author: kib
Date: Mon Dec 26 19:26:40 2016
New Revision: 310613
URL: https://svnweb.freebsd.org/changeset/base/310613

Log:
  Style.
  
  Reviewed by:	markj
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week
  X-Differential revision:	https://reviews.freebsd.org/D8898

Modified:
  head/sys/kern/kern_event.c

Modified: head/sys/kern/kern_event.c
==============================================================================
--- head/sys/kern/kern_event.c	Mon Dec 26 17:48:13 2016	(r310612)
+++ head/sys/kern/kern_event.c	Mon Dec 26 19:26:40 2016	(r310613)
@@ -2123,12 +2123,12 @@ knlist_empty(struct knlist *knl)
 {
 
 	KNL_ASSERT_LOCKED(knl);
-	return SLIST_EMPTY(&knl->kl_list);
+	return (SLIST_EMPTY(&knl->kl_list));
 }
 
-static struct mtx	knlist_lock;
+static struct mtx knlist_lock;
 MTX_SYSINIT(knlist_lock, &knlist_lock, "knlist lock for lockless objects",
-	MTX_DEF);
+    MTX_DEF);
 static void knlist_mtx_lock(void *arg);
 static void knlist_mtx_unlock(void *arg);
 
@@ -2391,17 +2391,15 @@ knote_attach(struct knote *kn, struct kq
 
 	if (kn->kn_fop->f_isfd) {
 		if (kn->kn_id >= kq->kq_knlistsize)
-			return ENOMEM;
+			return (ENOMEM);
 		list = &kq->kq_knlist[kn->kn_id];
 	} else {
 		if (kq->kq_knhash == NULL)
-			return ENOMEM;
+			return (ENOMEM);
 		list = &kq->kq_knhash[KN_HASH(kn->kn_id, kq->kq_knhashmask)];
 	}
-
 	SLIST_INSERT_HEAD(list, kn, kn_link);
-
-	return 0;
+	return (0);
 }
 
 /*
@@ -2511,11 +2509,9 @@ kqfd_register(int fd, struct kevent *kev
 		goto noacquire;
 
 	error = kqueue_register(kq, kev, td, waitok);
-
 	kqueue_release(kq, 0);
 
 noacquire:
 	fdrop(fp, td);
-
-	return error;
+	return (error);
 }

From owner-svn-src-all@freebsd.org  Mon Dec 26 19:27:13 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 64F6EC92C97;
 Mon, 26 Dec 2016 19:27:13 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 34AD116C7;
 Mon, 26 Dec 2016 19:27:13 +0000 (UTC)
 (envelope-from delphij@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQJRCTw067361;
 Mon, 26 Dec 2016 19:27:12 GMT (envelope-from delphij@FreeBSD.org)
Received: (from delphij@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQJRCr6067360;
 Mon, 26 Dec 2016 19:27:12 GMT (envelope-from delphij@FreeBSD.org)
Message-Id: <201612261927.uBQJRCr6067360@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: delphij set sender to
 delphij@FreeBSD.org using -f
From: Xin LI <delphij@FreeBSD.org>
Date: Mon, 26 Dec 2016 19:27:12 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310614 - head/usr.sbin/jail
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 19:27:13 -0000

Author: delphij
Date: Mon Dec 26 19:27:12 2016
New Revision: 310614
URL: https://svnweb.freebsd.org/changeset/base/310614

Log:
  Don't assign rtjp twice.
  
  Reported by:	clang static analyzer
  MFC after:	2 weeks

Modified:
  head/usr.sbin/jail/jail.c

Modified: head/usr.sbin/jail/jail.c
==============================================================================
--- head/usr.sbin/jail/jail.c	Mon Dec 26 19:26:40 2016	(r310613)
+++ head/usr.sbin/jail/jail.c	Mon Dec 26 19:27:12 2016	(r310614)
@@ -806,8 +806,7 @@ rdtun_params(struct cfjail *j, int dofai
 	if (jailparam_get(rtparams, nrt,
 	    bool_param(j->intparams[IP_ALLOW_DYING]) ? JAIL_DYING : 0) > 0) {
 		rtjp = rtparams + 1;
-		for (jp = j->jp, rtjp = rtparams + 1; rtjp < rtparams + nrt;
-		     jp++) {
+		for (jp = j->jp; rtjp < rtparams + nrt; jp++) {
 			if (JP_RDTUN(jp) && strcmp(jp->jp_name, "jid")) {
 				if (!((jp->jp_flags & (JP_BOOL | JP_NOBOOL)) &&
 				    jp->jp_valuelen == 0 &&

From owner-svn-src-all@freebsd.org  Mon Dec 26 19:28:12 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0B02BC92CF6;
 Mon, 26 Dec 2016 19:28:12 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id CF0861869;
 Mon, 26 Dec 2016 19:28:11 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQJSBhR067450;
 Mon, 26 Dec 2016 19:28:11 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQJSBos067449;
 Mon, 26 Dec 2016 19:28:11 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261928.uBQJSBos067449@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 19:28:11 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310615 - head/sys/kern
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 19:28:12 -0000

Author: kib
Date: Mon Dec 26 19:28:10 2016
New Revision: 310615
URL: https://svnweb.freebsd.org/changeset/base/310615

Log:
  Change knlist_destroy() to assert that knlist is empty instead of
  accepting the wrong state and printing warning.  Do not obliterate
  kl_lock and kl_unlock pointers, they are often useful for post-mortem
  analysis.
  
  Reviewed by:	markj
  Tested by:	pho
  Sponsored by:	The FreeBSD Foundation
  MFC after:	2 weeks
  X-Differential revision:	https://reviews.freebsd.org/D8898

Modified:
  head/sys/kern/kern_event.c

Modified: head/sys/kern/kern_event.c
==============================================================================
--- head/sys/kern/kern_event.c	Mon Dec 26 19:27:12 2016	(r310614)
+++ head/sys/kern/kern_event.c	Mon Dec 26 19:28:10 2016	(r310615)
@@ -2249,17 +2249,8 @@ void
 knlist_destroy(struct knlist *knl)
 {
 
-#ifdef INVARIANTS
-	/*
-	 * if we run across this error, we need to find the offending
-	 * driver and have it call knlist_clear or knlist_delete.
-	 */
-	if (!SLIST_EMPTY(&knl->kl_list))
-		printf("WARNING: destroying knlist w/ knotes on it!\n");
-#endif
-
-	knl->kl_lockarg = knl->kl_lock = knl->kl_unlock = NULL;
-	SLIST_INIT(&knl->kl_list);
+	KASSERT(KNLIST_EMPTY(knl),
+	    ("destroying knlist %p with knotes on it", knl));
 }
 
 void

From owner-svn-src-all@freebsd.org  Mon Dec 26 19:29:05 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id DCC3BC92D56;
 Mon, 26 Dec 2016 19:29:05 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id AC7FE19EF;
 Mon, 26 Dec 2016 19:29:05 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQJT4s3067527;
 Mon, 26 Dec 2016 19:29:04 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQJT4Y8067526;
 Mon, 26 Dec 2016 19:29:04 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261929.uBQJT4Y8067526@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 19:29:04 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310616 - head/sys/vm
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 19:29:06 -0000

Author: kib
Date: Mon Dec 26 19:29:04 2016
New Revision: 310616
URL: https://svnweb.freebsd.org/changeset/base/310616

Log:
  Remove redundancy in vmtotal().
  
  There are two instances of inlined unlocks + continue in vmtotal()
  switch statements, which are ordinary expressed with break from the
  switch case and code after the switch.  Also, the combination of
  continue and break statement is redundand.
  
  Reviewed by:	alc
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week

Modified:
  head/sys/vm/vm_meter.c

Modified: head/sys/vm/vm_meter.c
==============================================================================
--- head/sys/vm/vm_meter.c	Mon Dec 26 19:28:10 2016	(r310615)
+++ head/sys/vm/vm_meter.c	Mon Dec 26 19:29:04 2016	(r310616)
@@ -121,15 +121,10 @@ vmtotal(SYSCTL_HANDLER_ARGS)
 	 */
 	sx_slock(&allproc_lock);
 	FOREACH_PROC_IN_SYSTEM(p) {
-		if (p->p_flag & P_SYSTEM)
+		if ((p->p_flag & P_SYSTEM) != 0)
 			continue;
 		PROC_LOCK(p);
-		switch (p->p_state) {
-		case PRS_NEW:
-			PROC_UNLOCK(p);
-			continue;
-			break;
-		default:
+		if (p->p_state != PRS_NEW) {
 			FOREACH_THREAD_IN_PROC(p, td) {
 				thread_lock(td);
 				switch (td->td_state) {
@@ -146,15 +141,13 @@ vmtotal(SYSCTL_HANDLER_ARGS)
 							total.t_pw++;
 					}
 					break;
-
 				case TDS_CAN_RUN:
 					total.t_sw++;
 					break;
 				case TDS_RUNQ:
 				case TDS_RUNNING:
 					total.t_rq++;
-					thread_unlock(td);
-					continue;
+					break;
 				default:
 					break;
 				}

From owner-svn-src-all@freebsd.org  Mon Dec 26 19:33:41 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id B9B86C92F8C;
 Mon, 26 Dec 2016 19:33:41 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 823AF1F44;
 Mon, 26 Dec 2016 19:33:41 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQJXeYo071335;
 Mon, 26 Dec 2016 19:33:40 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQJXe7T071333;
 Mon, 26 Dec 2016 19:33:40 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612261933.uBQJXe7T071333@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Mon, 26 Dec 2016 19:33:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310617 - in head/sys: kern sys
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 19:33:41 -0000

Author: kib
Date: Mon Dec 26 19:33:40 2016
New Revision: 310617
URL: https://svnweb.freebsd.org/changeset/base/310617

Log:
  Make knote KN_INFLUX state counted.  This is final fix for the issue
  closed by r310302 for knote().
  
  If KN_INFLUX | KN_SCAN flags are set for the note passed to knote() or
  knote_fork(), i.e. the knote is scanned, we might erronously clear
  INFLUX when finishing notification.  For normal knote() it was fixed
  in r310302 simply by remembering the fact that we do not own
  KN_INFLUX, since there we own knlist lock and scan thread cannot clear
  KN_INFLUX until we drop the lock.  For knote_fork(), the situation is
  more complicated, e must drop knlist lock AKA the process lock, since
  we need to register new knotes.
  
  Change KN_INFLUX into counter and allow shared ownership of the
  in-flux state between scan and knote_fork() or knote().  Both in-flux
  setters need to ensure that knote is not dropped in parallel.  Added
  assert about kn_influx == 1 in knote_drop() verifies that in-flux state
  is not shared when knote is destroyed.
  
  Since KBI of the struct knote is changed by addition of the int
  kn_influx field, reorder kn_hook and kn_hookid to fill pad on LP64
  arches [1].  This keeps sizeof(struct knote) to same 128 bytes as it
  was before addition of kn_influx, on amd64.
  
  Reviewed by:	markj
  Suggested by:	markj [1]
  Tested by:	pho (previous version)
  Sponsored by:	The FreeBSD Foundation
  Differential revision:	https://reviews.freebsd.org/D8898

Modified:
  head/sys/kern/kern_event.c
  head/sys/sys/event.h

Modified: head/sys/kern/kern_event.c
==============================================================================
--- head/sys/kern/kern_event.c	Mon Dec 26 19:29:04 2016	(r310616)
+++ head/sys/kern/kern_event.c	Mon Dec 26 19:33:40 2016	(r310617)
@@ -193,7 +193,7 @@ static unsigned int 	kq_calloutmax = 4 *
 SYSCTL_UINT(_kern, OID_AUTO, kq_calloutmax, CTLFLAG_RW,
     &kq_calloutmax, 0, "Maximum number of callouts allocated for kqueue");
 
-/* XXX - ensure not KN_INFLUX?? */
+/* XXX - ensure not influx ? */
 #define KNOTE_ACTIVATE(kn, islock) do { 				\
 	if ((islock))							\
 		mtx_assert(&(kn)->kn_kq->kq_lock, MA_OWNED);		\
@@ -254,6 +254,32 @@ kn_list_unlock(struct knlist *knl)
 	}
 }
 
+static bool
+kn_in_flux(struct knote *kn)
+{
+
+	return (kn->kn_influx > 0);
+}
+
+static void
+kn_enter_flux(struct knote *kn)
+{
+
+	KQ_OWNED(kn->kn_kq);
+	MPASS(kn->kn_influx < INT_MAX);
+	kn->kn_influx++;
+}
+
+static bool
+kn_leave_flux(struct knote *kn)
+{
+
+	KQ_OWNED(kn->kn_kq);
+	MPASS(kn->kn_influx > 0);
+	kn->kn_influx--;
+	return (kn->kn_influx == 0);
+}
+
 #define	KNL_ASSERT_LOCK(knl, islocked) do {				\
 	if (islocked)							\
 		KNL_ASSERT_LOCKED(knl);				\
@@ -498,7 +524,7 @@ knote_fork(struct knlist *list, int pid)
 	SLIST_FOREACH(kn, &list->kl_list, kn_selnext) {
 		kq = kn->kn_kq;
 		KQ_LOCK(kq);
-		if ((kn->kn_status & (KN_INFLUX | KN_SCAN)) == KN_INFLUX) {
+		if (kn_in_flux(kn) && (kn->kn_status & KN_SCAN) == 0) {
 			KQ_UNLOCK(kq);
 			continue;
 		}
@@ -521,7 +547,7 @@ knote_fork(struct knlist *list, int pid)
 		 * track the child. Drop the locks in preparation for
 		 * the call to kqueue_register().
 		 */
-		kn->kn_status |= KN_INFLUX;
+		kn_enter_flux(kn);
 		KQ_UNLOCK(kq);
 		list->kl_unlock(list->kl_lockarg);
 
@@ -561,7 +587,7 @@ knote_fork(struct knlist *list, int pid)
 		if (kn->kn_fop->f_event(kn, NOTE_FORK))
 			KNOTE_ACTIVATE(kn, 0);
 		KQ_LOCK(kq);
-		kn->kn_status &= ~KN_INFLUX;
+		kn_leave_flux(kn);
 		KQ_UNLOCK_FLUX(kq);
 		list->kl_lock(list->kl_lockarg);
 	}
@@ -1262,7 +1288,7 @@ findkn:
 	}
 
 	/* knote is in the process of changing, wait for it to stabilize. */
-	if (kn != NULL && (kn->kn_status & KN_INFLUX) == KN_INFLUX) {
+	if (kn != NULL && kn_in_flux(kn)) {
 		KQ_GLOBAL_UNLOCK(&kq_global, haskqglobal);
 		if (filedesc_unlock) {
 			FILEDESC_XUNLOCK(td->td_proc->p_fd);
@@ -1306,7 +1332,8 @@ findkn:
 			kn->kn_kevent = *kev;
 			kn->kn_kevent.flags &= ~(EV_ADD | EV_DELETE |
 			    EV_ENABLE | EV_DISABLE | EV_FORCEONESHOT);
-			kn->kn_status = KN_INFLUX|KN_DETACHED;
+			kn->kn_status = KN_DETACHED;
+			kn_enter_flux(kn);
 
 			error = knote_attach(kn, kq);
 			KQ_UNLOCK(kq);
@@ -1330,7 +1357,7 @@ findkn:
 	}
 	
 	if (kev->flags & EV_DELETE) {
-		kn->kn_status |= KN_INFLUX;
+		kn_enter_flux(kn);
 		KQ_UNLOCK(kq);
 		if (!(kn->kn_status & KN_DETACHED))
 			kn->kn_fop->f_detach(kn);
@@ -1348,7 +1375,8 @@ findkn:
 	 * but doing so will not reset any filter which has already been
 	 * triggered.
 	 */
-	kn->kn_status |= KN_INFLUX | KN_SCAN;
+	kn->kn_status |= KN_SCAN;
+	kn_enter_flux(kn);
 	KQ_UNLOCK(kq);
 	knl = kn_list_lock(kn);
 	kn->kn_kevent.udata = kev->udata;
@@ -1383,7 +1411,8 @@ done_ev_add:
 	if ((kn->kn_status & (KN_ACTIVE | KN_DISABLED | KN_QUEUED)) ==
 	    KN_ACTIVE)
 		knote_enqueue(kn);
-	kn->kn_status &= ~(KN_INFLUX | KN_SCAN);
+	kn->kn_status &= ~KN_SCAN;
+	kn_leave_flux(kn);
 	kn_list_unlock(knl);
 	KQ_UNLOCK_FLUX(kq);
 
@@ -1546,7 +1575,7 @@ kqueue_task(void *arg, int pending)
 
 /*
  * Scan, update kn_data (if not ONESHOT), and copyout triggered events.
- * We treat KN_MARKER knotes as if they are INFLUX.
+ * We treat KN_MARKER knotes as if they are in flux.
  */
 static int
 kqueue_scan(struct kqueue *kq, int maxevents, struct kevent_copyops *k_ops,
@@ -1620,7 +1649,7 @@ retry:
 		kn = TAILQ_FIRST(&kq->kq_head);
 
 		if ((kn->kn_status == KN_MARKER && kn != marker) ||
-		    (kn->kn_status & KN_INFLUX) == KN_INFLUX) {
+		    kn_in_flux(kn)) {
 			if (influx) {
 				influx = 0;
 				KQ_FLUX_WAKEUP(kq);
@@ -1643,17 +1672,17 @@ retry:
 				goto retry;
 			goto done;
 		}
-		KASSERT((kn->kn_status & KN_INFLUX) == 0,
-		    ("KN_INFLUX set when not suppose to be"));
+		KASSERT(!kn_in_flux(kn),
+		    ("knote %p is unexpectedly in flux", kn));
 
 		if ((kn->kn_flags & EV_DROP) == EV_DROP) {
 			kn->kn_status &= ~KN_QUEUED;
-			kn->kn_status |= KN_INFLUX;
+			kn_enter_flux(kn);
 			kq->kq_count--;
 			KQ_UNLOCK(kq);
 			/*
-			 * We don't need to lock the list since we've marked
-			 * it _INFLUX.
+			 * We don't need to lock the list since we've
+			 * marked it as in flux.
 			 */
 			if (!(kn->kn_status & KN_DETACHED))
 				kn->kn_fop->f_detach(kn);
@@ -1662,12 +1691,12 @@ retry:
 			continue;
 		} else if ((kn->kn_flags & EV_ONESHOT) == EV_ONESHOT) {
 			kn->kn_status &= ~KN_QUEUED;
-			kn->kn_status |= KN_INFLUX;
+			kn_enter_flux(kn);
 			kq->kq_count--;
 			KQ_UNLOCK(kq);
 			/*
-			 * We don't need to lock the list since we've marked
-			 * it _INFLUX.
+			 * We don't need to lock the list since we've
+			 * marked the knote as being in flux.
 			 */
 			*kevp = kn->kn_kevent;
 			if (!(kn->kn_status & KN_DETACHED))
@@ -1676,7 +1705,8 @@ retry:
 			KQ_LOCK(kq);
 			kn = NULL;
 		} else {
-			kn->kn_status |= KN_INFLUX | KN_SCAN;
+			kn->kn_status |= KN_SCAN;
+			kn_enter_flux(kn);
 			KQ_UNLOCK(kq);
 			if ((kn->kn_status & KN_KQUEUE) == KN_KQUEUE)
 				KQ_GLOBAL_LOCK(&kq_global, haskqglobal);
@@ -1684,9 +1714,9 @@ retry:
 			if (kn->kn_fop->f_event(kn, 0) == 0) {
 				KQ_LOCK(kq);
 				KQ_GLOBAL_UNLOCK(&kq_global, haskqglobal);
-				kn->kn_status &=
-				    ~(KN_QUEUED | KN_ACTIVE | KN_INFLUX |
+				kn->kn_status &= ~(KN_QUEUED | KN_ACTIVE |
 				    KN_SCAN);
+				kn_leave_flux(kn);
 				kq->kq_count--;
 				kn_list_unlock(knl);
 				influx = 1;
@@ -1716,7 +1746,8 @@ retry:
 			} else
 				TAILQ_INSERT_TAIL(&kq->kq_head, kn, kn_tqe);
 			
-			kn->kn_status &= ~(KN_INFLUX | KN_SCAN);
+			kn->kn_status &= ~KN_SCAN;
+			kn_leave_flux(kn);
 			kn_list_unlock(knl);
 			influx = 1;
 		}
@@ -1864,12 +1895,12 @@ kqueue_drain(struct kqueue *kq, struct t
 
 	for (i = 0; i < kq->kq_knlistsize; i++) {
 		while ((kn = SLIST_FIRST(&kq->kq_knlist[i])) != NULL) {
-			if ((kn->kn_status & KN_INFLUX) == KN_INFLUX) {
+			if (kn_in_flux(kn)) {
 				kq->kq_state |= KQ_FLUXWAIT;
 				msleep(kq, &kq->kq_lock, PSOCK, "kqclo1", 0);
 				continue;
 			}
-			kn->kn_status |= KN_INFLUX;
+			kn_enter_flux(kn);
 			KQ_UNLOCK(kq);
 			if (!(kn->kn_status & KN_DETACHED))
 				kn->kn_fop->f_detach(kn);
@@ -1880,13 +1911,13 @@ kqueue_drain(struct kqueue *kq, struct t
 	if (kq->kq_knhashmask != 0) {
 		for (i = 0; i <= kq->kq_knhashmask; i++) {
 			while ((kn = SLIST_FIRST(&kq->kq_knhash[i])) != NULL) {
-				if ((kn->kn_status & KN_INFLUX) == KN_INFLUX) {
+				if (kn_in_flux(kn)) {
 					kq->kq_state |= KQ_FLUXWAIT;
 					msleep(kq, &kq->kq_lock, PSOCK,
 					       "kqclo2", 0);
 					continue;
 				}
-				kn->kn_status |= KN_INFLUX;
+				kn_enter_flux(kn);
 				KQ_UNLOCK(kq);
 				if (!(kn->kn_status & KN_DETACHED))
 					kn->kn_fop->f_detach(kn);
@@ -2010,7 +2041,6 @@ knote(struct knlist *list, long hint, in
 	struct kqueue *kq;
 	struct knote *kn, *tkn;
 	int error;
-	bool own_influx;
 
 	if (list == NULL)
 		return;
@@ -2021,7 +2051,7 @@ knote(struct knlist *list, long hint, in
 		list->kl_lock(list->kl_lockarg); 
 
 	/*
-	 * If we unlock the list lock (and set KN_INFLUX), we can
+	 * If we unlock the list lock (and enter influx), we can
 	 * eliminate the kqueue scheduling, but this will introduce
 	 * four lock/unlock's for each knote to test.  Also, marker
 	 * would be needed to keep iteration position, since filters
@@ -2030,7 +2060,7 @@ knote(struct knlist *list, long hint, in
 	SLIST_FOREACH_SAFE(kn, &list->kl_list, kn_selnext, tkn) {
 		kq = kn->kn_kq;
 		KQ_LOCK(kq);
-		if ((kn->kn_status & (KN_INFLUX | KN_SCAN)) == KN_INFLUX) {
+		if (kn_in_flux(kn) && (kn->kn_status & KN_SCAN) == 0) {
 			/*
 			 * Do not process the influx notes, except for
 			 * the influx coming from the kq unlock in the
@@ -2041,14 +2071,11 @@ knote(struct knlist *list, long hint, in
 			 */
 			KQ_UNLOCK(kq);
 		} else if ((lockflags & KNF_NOKQLOCK) != 0) {
-			own_influx = (kn->kn_status & KN_INFLUX) == 0;
-			if (own_influx)
-				kn->kn_status |= KN_INFLUX;
+			kn_enter_flux(kn);
 			KQ_UNLOCK(kq);
 			error = kn->kn_fop->f_event(kn, hint);
 			KQ_LOCK(kq);
-			if (own_influx)
-				kn->kn_status &= ~KN_INFLUX;
+			kn_leave_flux(kn);
 			if (error)
 				KNOTE_ACTIVATE(kn, 1);
 			KQ_UNLOCK_FLUX(kq);
@@ -2070,10 +2097,12 @@ knote(struct knlist *list, long hint, in
 void
 knlist_add(struct knlist *knl, struct knote *kn, int islocked)
 {
+
 	KNL_ASSERT_LOCK(knl, islocked);
 	KQ_NOTOWNED(kn->kn_kq);
-	KASSERT((kn->kn_status & (KN_INFLUX|KN_DETACHED)) ==
-	    (KN_INFLUX|KN_DETACHED), ("knote not KN_INFLUX and KN_DETACHED"));
+	KASSERT(kn_in_flux(kn), ("knote %p not in flux", kn));
+	KASSERT((kn->kn_status & KN_DETACHED) != 0,
+	    ("knote %p was not detached", kn));
 	if (!islocked)
 		knl->kl_lock(knl->kl_lockarg);
 	SLIST_INSERT_HEAD(&knl->kl_list, kn, kn_selnext);
@@ -2089,12 +2118,13 @@ static void
 knlist_remove_kq(struct knlist *knl, struct knote *kn, int knlislocked,
     int kqislocked)
 {
-	KASSERT(!(!!kqislocked && !knlislocked), ("kq locked w/o knl locked"));
+
+	KASSERT(!kqislocked || knlislocked, ("kq locked w/o knl locked"));
 	KNL_ASSERT_LOCK(knl, knlislocked);
 	mtx_assert(&kn->kn_kq->kq_lock, kqislocked ? MA_OWNED : MA_NOTOWNED);
-	if (!kqislocked)
-		KASSERT((kn->kn_status & (KN_INFLUX|KN_DETACHED)) == KN_INFLUX,
-    ("knlist_remove called w/o knote being KN_INFLUX or already removed"));
+	KASSERT(kqislocked || kn_in_flux(kn), ("knote %p not in flux", kn));
+	KASSERT((kn->kn_status & KN_DETACHED) == 0,
+	    ("knote %p was already detached", kn));
 	if (!knlislocked)
 		knl->kl_lock(knl->kl_lockarg);
 	SLIST_REMOVE(&knl->kl_list, kn, knote, kn_selnext);
@@ -2287,30 +2317,30 @@ again:		/* need to reacquire lock since 
 	SLIST_FOREACH_SAFE(kn, &knl->kl_list, kn_selnext, kn2) {
 		kq = kn->kn_kq;
 		KQ_LOCK(kq);
-		if ((kn->kn_status & KN_INFLUX)) {
+		if (kn_in_flux(kn)) {
 			KQ_UNLOCK(kq);
 			continue;
 		}
 		knlist_remove_kq(knl, kn, 1, 1);
 		if (killkn) {
-			kn->kn_status |= KN_INFLUX | KN_DETACHED;
+			kn->kn_status |= KN_DETACHED;
+			kn_enter_flux(kn);
 			KQ_UNLOCK(kq);
 			knote_drop(kn, td);
 		} else {
 			/* Make sure cleared knotes disappear soon */
-			kn->kn_flags |= (EV_EOF | EV_ONESHOT);
+			kn->kn_flags |= EV_EOF | EV_ONESHOT;
 			KQ_UNLOCK(kq);
 		}
 		kq = NULL;
 	}
 
 	if (!SLIST_EMPTY(&knl->kl_list)) {
-		/* there are still KN_INFLUX remaining */
+		/* there are still in flux knotes remaining */
 		kn = SLIST_FIRST(&knl->kl_list);
 		kq = kn->kn_kq;
 		KQ_LOCK(kq);
-		KASSERT(kn->kn_status & KN_INFLUX,
-		    ("knote removed w/o list lock"));
+		KASSERT(kn_in_flux(kn), ("knote removed w/o list lock"));
 		knl->kl_unlock(knl->kl_lockarg);
 		kq->kq_state |= KQ_FLUXWAIT;
 		msleep(kq, &kq->kq_lock, PSOCK | PDROP, "kqkclr", 0);
@@ -2352,7 +2382,7 @@ again:
 		influx = 0;
 		while (kq->kq_knlistsize > fd &&
 		    (kn = SLIST_FIRST(&kq->kq_knlist[fd])) != NULL) {
-			if (kn->kn_status & KN_INFLUX) {
+			if (kn_in_flux(kn)) {
 				/* someone else might be waiting on our knote */
 				if (influx)
 					wakeup(kq);
@@ -2360,7 +2390,7 @@ again:
 				msleep(kq, &kq->kq_lock, PSOCK, "kqflxwt", 0);
 				goto again;
 			}
-			kn->kn_status |= KN_INFLUX;
+			kn_enter_flux(kn);
 			KQ_UNLOCK(kq);
 			if (!(kn->kn_status & KN_DETACHED))
 				kn->kn_fop->f_detach(kn);
@@ -2377,7 +2407,7 @@ knote_attach(struct knote *kn, struct kq
 {
 	struct klist *list;
 
-	KASSERT(kn->kn_status & KN_INFLUX, ("knote not marked INFLUX"));
+	KASSERT(kn_in_flux(kn), ("knote %p not marked influx", kn));
 	KQ_OWNED(kq);
 
 	if (kn->kn_fop->f_isfd) {
@@ -2395,7 +2425,7 @@ knote_attach(struct knote *kn, struct kq
 
 /*
  * knote must already have been detached using the f_detach method.
- * no lock need to be held, it is assumed that the KN_INFLUX flag is set
+ * no lock need to be held, it is assumed that the influx state is set
  * to prevent other removal.
  */
 static void
@@ -2407,10 +2437,10 @@ knote_drop(struct knote *kn, struct thre
 	kq = kn->kn_kq;
 
 	KQ_NOTOWNED(kq);
-	KASSERT((kn->kn_status & KN_INFLUX) == KN_INFLUX,
-	    ("knote_drop called without KN_INFLUX set in kn_status"));
-
 	KQ_LOCK(kq);
+	KASSERT(kn->kn_influx == 1,
+	    ("knote_drop called on %p with influx %d", kn, kn->kn_influx));
+
 	if (kn->kn_fop->f_isfd)
 		list = &kq->kq_knlist[kn->kn_id];
 	else

Modified: head/sys/sys/event.h
==============================================================================
--- head/sys/sys/event.h	Mon Dec 26 19:29:04 2016	(r310616)
+++ head/sys/sys/event.h	Mon Dec 26 19:33:40 2016	(r310617)
@@ -202,8 +202,11 @@ struct filterops {
 };
 
 /*
- * Setting the KN_INFLUX flag enables you to unlock the kq that this knote
- * is on, and modify kn_status as if you had the KQ lock.
+ * An in-flux knote cannot be dropped from its kq while the kq is
+ * unlocked.  If the KN_SCAN flag is not set, a thread can only set
+ * kn_influx when it is exclusive owner of the knote state, and can
+ * modify kn_status as if it had the KQ lock.  KN_SCAN must not be set
+ * on a knote which is already in flux.
  *
  * kn_sfflags, kn_sdata, and kn_kevent are protected by the knlist lock.
  */
@@ -214,16 +217,18 @@ struct knote {
 	TAILQ_ENTRY(knote)	kn_tqe;
 	struct			kqueue *kn_kq;	/* which queue we are on */
 	struct 			kevent kn_kevent;
+	void			*kn_hook;
+	int			kn_hookid;
 	int			kn_status;	/* protected by kq lock */
 #define KN_ACTIVE	0x01			/* event has been triggered */
 #define KN_QUEUED	0x02			/* event is on queue */
 #define KN_DISABLED	0x04			/* event is disabled */
 #define KN_DETACHED	0x08			/* knote is detached */
-#define KN_INFLUX	0x10			/* knote is in flux */
 #define KN_MARKER	0x20			/* ignore this knote */
 #define KN_KQUEUE	0x40			/* this knote belongs to a kq */
 #define KN_HASKQLOCK	0x80			/* for _inevent */
 #define	KN_SCAN		0x100			/* flux set in kqueue_scan() */
+	int			kn_influx;
 	int			kn_sfflags;	/* saved filter flags */
 	intptr_t		kn_sdata;	/* saved data field */
 	union {
@@ -234,8 +239,6 @@ struct knote {
 		void		*p_v;		/* generic other pointer */
 	} kn_ptr;
 	struct			filterops *kn_fop;
-	void			*kn_hook;
-	int			kn_hookid;
 
 #define kn_id		kn_kevent.ident
 #define kn_filter	kn_kevent.filter

From owner-svn-src-all@freebsd.org  Mon Dec 26 20:36:44 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF2CBC91F99;
 Mon, 26 Dec 2016 20:36:44 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6293417AB;
 Mon, 26 Dec 2016 20:36:43 +0000 (UTC) (envelope-from dim@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQKagLq095573;
 Mon, 26 Dec 2016 20:36:42 GMT (envelope-from dim@FreeBSD.org)
Received: (from dim@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQKae4U095552;
 Mon, 26 Dec 2016 20:36:40 GMT (envelope-from dim@FreeBSD.org)
Message-Id: <201612262036.uBQKae4U095552@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org
 using -f
From: Dimitry Andric <dim@FreeBSD.org>
Date: Mon, 26 Dec 2016 20:36:40 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310618 - in stable/11: . contrib/compiler-rt
 contrib/compiler-rt/include/sanitizer contrib/compiler-rt/lib/asan
 contrib/compiler-rt/lib/builtins contrib/compiler-rt/lib/builtins/arm co...
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 20:36:44 -0000

Author: dim
Date: Mon Dec 26 20:36:37 2016
New Revision: 310618
URL: https://svnweb.freebsd.org/changeset/base/310618

Log:
  MFC r309124:
  
  Upgrade our copies of clang, llvm, lldb, compiler-rt and libc++ to 3.9.0
  release, and add lld 3.9.0.  Also completely revamp the build system for
  clang, llvm, lldb and their related tools.
  
  Please note that from 3.5.0 onwards, clang, llvm and lldb require C++11
  support to build; see UPDATING for more information.
  
  Release notes for llvm, clang and lld are available here:
  <http://llvm.org/releases/3.9.0/docs/ReleaseNotes.html>
  <http://llvm.org/releases/3.9.0/tools/clang/docs/ReleaseNotes.html>
  <http://llvm.org/releases/3.9.0/tools/lld/docs/ReleaseNotes.html>
  
  Thanks to Ed Maste, Bryan Drewery, Andrew Turner, Antoine Brodin and Jan
  Beich for their help.
  
  Relnotes:	yes
  
  MFC r309147:
  
  Pull in r282174 from upstream llvm trunk (by Krzysztof Parzyszek):
  
    [PPC] Set SP after loading data from stack frame, if no red zone is
    present
  
    Follow-up to r280705: Make sure that the SP is only restored after
    all data is loaded from the stack frame, if there is no red zone.
  
    This completes the fix for
    https://llvm.org/bugs/show_bug.cgi?id=26519.
  
    Differential Revision: https://reviews.llvm.org/D24466
  
  Reported by:    Mark Millard
  PR:             214433
  
  MFC r309149:
  
  Pull in r283060 from upstream llvm trunk (by Hal Finkel):
  
    [PowerPC] Refactor soft-float support, and enable PPC64 soft float
  
    This change enables soft-float for PowerPC64, and also makes
    soft-float disable all vector instruction sets for both 32-bit and
    64-bit modes. This latter part is necessary because the PPC backend
    canonicalizes many Altivec vector types to floating-point types, and
    so soft-float breaks scalarization support for many operations. Both
    for embedded targets and for operating-system kernels desiring
    soft-float support, it seems reasonable that disabling hardware
    floating-point also disables vector instructions (embedded targets
    without hardware floating point support are unlikely to have Altivec,
    etc. and operating system kernels desiring not to use floating-point
    registers to lower syscall cost are unlikely to want to use vector
    registers either). If someone needs this to work, we'll need to
    change the fact that we promote many Altivec operations to act on
    v4f32. To make it possible to disable Altivec when soft-float is
    enabled, hardware floating-point support needs to be expressed as a
    positive feature, like the others, and not a negative feature,
    because target features cannot have dependencies on the disabling of
    some other feature. So +soft-float has now become -hard-float.
  
    Fixes PR26970.
  
  Pull in r283061 from upstream clang trunk (by Hal Finkel):
  
    [PowerPC] Enable soft-float for PPC64, and +soft-float -> -hard-float
  
    Enable soft-float support on PPC64, as the backend now supports it.
    Also, the backend now uses -hard-float instead of +soft-float, so set
    the target features accordingly.
  
    Fixes PR26970.
  
  Reported by:	Mark Millard
  PR:		214433
  
  MFC r309212:
  
  Add a few missed clang 3.9.0 files to OptionalObsoleteFiles.
  
  MFC r309262:
  
  Fix packaging for clang, lldb and lld 3.9.0
  
  During the upgrade of clang/llvm etc to 3.9.0 in r309124, the PACKAGE
  directive in the usr.bin/clang/*.mk files got dropped accidentally.
  
  Restore it, with a few minor changes and additions:
  * Correct license in clang.ucl to NCSA
  * Add PACKAGE=clang for clang and most of the "ll" tools
  * Put lldb in its own package
  * Put lld in its own package
  
  Reviewed by:	gjb, jmallett
  Differential Revision: https://reviews.freebsd.org/D8666
  
  MFC r309656:
  
  During the bootstrap phase, when building the minimal llvm library on
  PowerPC, add lib/Support/Atomic.cpp.  This is needed because upstream
  llvm revision r271821 disabled the use of std::call_once, which causes
  some fallback functions from Atomic.cpp to be used instead.
  
  Reported by:	Mark Millard
  PR:		214902
  
  MFC r309835:
  
  Tentatively apply https://reviews.llvm.org/D18730 to work around gcc PR
  70528 (bogus error: constructor required before non-static data member).
  This should fix buildworld with the external gcc package.
  
  Reported by:	https://jenkins.freebsd.org/job/FreeBSD_HEAD_amd64_gcc/
  
  MFC r310194:
  
  Upgrade our copies of clang, llvm, lld, lldb, compiler-rt and libc++ to
  3.9.1 release.
  
  Please note that from 3.5.0 onwards, clang, llvm and lldb require C++11
  support to build; see UPDATING for more information.
  
  Release notes for llvm, clang and lld will be available here:
  <http://releases.llvm.org/3.9.1/docs/ReleaseNotes.html>
  <http://releases.llvm.org/3.9.1/tools/clang/docs/ReleaseNotes.html>
  <http://releases.llvm.org/3.9.1/tools/lld/docs/ReleaseNotes.html>
  
  Relnotes:	yes

Added:
  stable/11/contrib/compiler-rt/include/sanitizer/esan_interface.h
     - copied unchanged from r309124, head/contrib/compiler-rt/include/sanitizer/esan_interface.h
  stable/11/contrib/compiler-rt/lib/asan/asan_memory_profile.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/asan/asan_memory_profile.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_scariness_score.h
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/asan/asan_scariness_score.h
  stable/11/contrib/compiler-rt/lib/builtins/cpu_model.c
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/builtins/cpu_model.c
  stable/11/contrib/compiler-rt/lib/builtins/unwind-ehabi-helpers.h
     - copied unchanged from r310194, head/contrib/compiler-rt/lib/builtins/unwind-ehabi-helpers.h
  stable/11/contrib/compiler-rt/lib/esan/
     - copied from r309124, head/contrib/compiler-rt/lib/esan/
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingMerge.c
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/profile/InstrProfilingMerge.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingMergeFile.c
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/profile/InstrProfilingMergeFile.c
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux_s390.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux_s390.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux_x86_64.S
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux_x86_64.S
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_termination.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_termination.cc
  stable/11/contrib/compiler-rt/lib/scudo/
     - copied from r309124, head/contrib/compiler-rt/lib/scudo/
  stable/11/contrib/compiler-rt/lib/stats/
     - copied from r309124, head/contrib/compiler-rt/lib/stats/
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_debugging.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/tsan/rtl/tsan_debugging.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_preinit.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/tsan/rtl/tsan_preinit.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl_proc.cc
     - copied unchanged from r309124, head/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl_proc.cc
  stable/11/contrib/libc++/include/__bsd_locale_defaults.h
     - copied unchanged from r309124, head/contrib/libc++/include/__bsd_locale_defaults.h
  stable/11/contrib/libc++/include/__bsd_locale_fallbacks.h
     - copied unchanged from r309124, head/contrib/libc++/include/__bsd_locale_fallbacks.h
  stable/11/contrib/libc++/include/__threading_support
     - copied unchanged from r309124, head/contrib/libc++/include/__threading_support
  stable/11/contrib/libc++/include/experimental/__memory
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/__memory
  stable/11/contrib/libc++/include/experimental/deque
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/deque
  stable/11/contrib/libc++/include/experimental/filesystem
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/filesystem
  stable/11/contrib/libc++/include/experimental/forward_list
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/forward_list
  stable/11/contrib/libc++/include/experimental/iterator
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/iterator
  stable/11/contrib/libc++/include/experimental/list
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/list
  stable/11/contrib/libc++/include/experimental/map
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/map
  stable/11/contrib/libc++/include/experimental/memory_resource
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/memory_resource
  stable/11/contrib/libc++/include/experimental/propagate_const
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/propagate_const
  stable/11/contrib/libc++/include/experimental/regex
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/regex
  stable/11/contrib/libc++/include/experimental/set
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/set
  stable/11/contrib/libc++/include/experimental/string
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/string
  stable/11/contrib/libc++/include/experimental/unordered_map
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/unordered_map
  stable/11/contrib/libc++/include/experimental/unordered_set
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/unordered_set
  stable/11/contrib/libc++/include/experimental/vector
     - copied unchanged from r309124, head/contrib/libc++/include/experimental/vector
  stable/11/contrib/libc++/include/stdbool.h
     - copied unchanged from r309124, head/contrib/libc++/include/stdbool.h
  stable/11/contrib/libc++/include/string.h
     - copied unchanged from r309124, head/contrib/libc++/include/string.h
  stable/11/contrib/libc++/src/experimental/
     - copied from r309124, head/contrib/libc++/src/experimental/
  stable/11/contrib/llvm/include/llvm/ADT/BitmaskEnum.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/ADT/BitmaskEnum.h
  stable/11/contrib/llvm/include/llvm/ADT/PriorityWorklist.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/ADT/PriorityWorklist.h
  stable/11/contrib/llvm/include/llvm/ADT/Sequence.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/ADT/Sequence.h
  stable/11/contrib/llvm/include/llvm/Analysis/AliasAnalysisEvaluator.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/AliasAnalysisEvaluator.h
  stable/11/contrib/llvm/include/llvm/Analysis/CFLAndersAliasAnalysis.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/CFLAndersAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/CFLSteensAliasAnalysis.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/CFLSteensAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/IndirectCallPromotionAnalysis.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/IndirectCallPromotionAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/IndirectCallSiteVisitor.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/IndirectCallSiteVisitor.h
  stable/11/contrib/llvm/include/llvm/Analysis/LazyBlockFrequencyInfo.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/LazyBlockFrequencyInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopPassManager.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/LoopPassManager.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopUnrollAnalyzer.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/LoopUnrollAnalyzer.h
  stable/11/contrib/llvm/include/llvm/Analysis/ModuleSummaryAnalysis.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/ModuleSummaryAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/OptimizationDiagnosticInfo.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/OptimizationDiagnosticInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/ProfileSummaryInfo.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/ProfileSummaryInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/TypeMetadataUtils.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Analysis/TypeMetadataUtils.h
  stable/11/contrib/llvm/include/llvm/CodeGen/GlobalISel/
     - copied from r309124, head/contrib/llvm/include/llvm/CodeGen/GlobalISel/
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineInstrBundleIterator.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/MachineInstrBundleIterator.h
  stable/11/contrib/llvm/include/llvm/CodeGen/PreISelIntrinsicLowering.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/PreISelIntrinsicLowering.h
  stable/11/contrib/llvm/include/llvm/CodeGen/RegisterUsageInfo.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/RegisterUsageInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ScheduleDAGMutation.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/ScheduleDAGMutation.h
  stable/11/contrib/llvm/include/llvm/CodeGen/SelectionDAGTargetInfo.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/SelectionDAGTargetInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/TailDuplicator.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/TailDuplicator.h
  stable/11/contrib/llvm/include/llvm/CodeGen/TargetPassConfig.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/TargetPassConfig.h
  stable/11/contrib/llvm/include/llvm/CodeGen/UnreachableBlockElim.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/CodeGen/UnreachableBlockElim.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/ByteStream.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/ByteStream.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CVRecord.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/CVRecord.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CVSymbolTypes.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/CVSymbolTypes.def
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CVSymbolVisitor.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/CVSymbolVisitor.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CVTypeVisitor.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/CVTypeVisitor.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CodeViewError.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/CodeViewError.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/EnumTables.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/EnumTables.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/ModuleSubstream.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/ModuleSubstream.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/ModuleSubstreamVisitor.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/ModuleSubstreamVisitor.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/RecordSerialization.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/RecordSerialization.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamArray.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamArray.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamInterface.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamInterface.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamReader.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamReader.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamRef.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamRef.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamWriter.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/StreamWriter.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolDumpDelegate.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolDumpDelegate.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolDumper.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolDumper.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolRecord.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolRecord.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolVisitorDelegate.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/SymbolVisitorDelegate.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeDumper.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeDumper.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeRecords.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeRecords.def
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeStreamMerger.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeStreamMerger.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeVisitorCallbacks.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeVisitorCallbacks.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAError.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAError.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/GenericError.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/DebugInfo/PDB/GenericError.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/Raw/
     - copied from r309124, head/contrib/llvm/include/llvm/DebugInfo/PDB/Raw/
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcABISupport.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcABISupport.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalIFunc.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/IR/GlobalIFunc.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalIndirectSymbol.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/IR/GlobalIndirectSymbol.h
  stable/11/contrib/llvm/include/llvm/IR/ModuleSummaryIndex.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/IR/ModuleSummaryIndex.h
  stable/11/contrib/llvm/include/llvm/IR/OptBisect.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/IR/OptBisect.h
  stable/11/contrib/llvm/include/llvm/IR/ProfileSummary.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/IR/ProfileSummary.h
  stable/11/contrib/llvm/include/llvm/LTO/LTO.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/LTO/LTO.h
  stable/11/contrib/llvm/include/llvm/LTO/legacy/
     - copied from r309124, head/contrib/llvm/include/llvm/LTO/legacy/
  stable/11/contrib/llvm/include/llvm/MC/MCCodeView.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/MC/MCCodeView.h
  stable/11/contrib/llvm/include/llvm/MC/MCDisassembler/
     - copied from r309124, head/contrib/llvm/include/llvm/MC/MCDisassembler/
  stable/11/contrib/llvm/include/llvm/MC/MCParser/MCTargetAsmParser.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/MC/MCParser/MCTargetAsmParser.h
  stable/11/contrib/llvm/include/llvm/Object/ModuleSummaryIndexObjectFile.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Object/ModuleSummaryIndexObjectFile.h
  stable/11/contrib/llvm/include/llvm/ObjectYAML/
     - copied from r309124, head/contrib/llvm/include/llvm/ObjectYAML/
  stable/11/contrib/llvm/include/llvm/ProfileData/Coverage/
     - copied from r309124, head/contrib/llvm/include/llvm/ProfileData/Coverage/
  stable/11/contrib/llvm/include/llvm/ProfileData/ProfileCommon.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/ProfileData/ProfileCommon.h
  stable/11/contrib/llvm/include/llvm/Support/AArch64TargetParser.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/AArch64TargetParser.def
  stable/11/contrib/llvm/include/llvm/Support/AtomicOrdering.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/AtomicOrdering.h
  stable/11/contrib/llvm/include/llvm/Support/CachePruning.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/CachePruning.h
  stable/11/contrib/llvm/include/llvm/Support/CodeGenCWrappers.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/CodeGenCWrappers.h
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/AMDGPU.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/ELFRelocs/AMDGPU.def
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/BPF.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/ELFRelocs/BPF.def
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/Lanai.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/ELFRelocs/Lanai.def
  stable/11/contrib/llvm/include/llvm/Support/Error.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/Error.h
  stable/11/contrib/llvm/include/llvm/Support/MachO.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/MachO.def
  stable/11/contrib/llvm/include/llvm/Support/SHA1.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/SHA1.h
  stable/11/contrib/llvm/include/llvm/Support/ScopedPrinter.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/ScopedPrinter.h
  stable/11/contrib/llvm/include/llvm/Support/TypeName.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/TypeName.h
  stable/11/contrib/llvm/include/llvm/Support/raw_sha1_ostream.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Support/raw_sha1_ostream.h
  stable/11/contrib/llvm/include/llvm/TableGen/SearchableTable.td
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/TableGen/SearchableTable.td
  stable/11/contrib/llvm/include/llvm/Target/GenericOpcodes.td
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Target/GenericOpcodes.td
  stable/11/contrib/llvm/include/llvm/Target/TargetOpcodes.def
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Target/TargetOpcodes.def
  stable/11/contrib/llvm/include/llvm/Transforms/GCOVProfiler.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/GCOVProfiler.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/ConstantMerge.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/ConstantMerge.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/CrossDSOCFI.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/CrossDSOCFI.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/DeadArgumentElimination.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/DeadArgumentElimination.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/ElimAvailExtern.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/ElimAvailExtern.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/FunctionAttrs.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/FunctionAttrs.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/GlobalDCE.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/GlobalDCE.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/GlobalOpt.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/GlobalOpt.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/Internalize.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/Internalize.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/LowerTypeTests.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/LowerTypeTests.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/PartialInlining.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/PartialInlining.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/SCCP.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/SCCP.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/WholeProgramDevirt.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/IPO/WholeProgramDevirt.h
  stable/11/contrib/llvm/include/llvm/Transforms/InstrProfiling.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/InstrProfiling.h
  stable/11/contrib/llvm/include/llvm/Transforms/PGOInstrumentation.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/PGOInstrumentation.h
  stable/11/contrib/llvm/include/llvm/Transforms/SampleProfile.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/SampleProfile.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/AlignmentFromAssumptions.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/AlignmentFromAssumptions.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/BDCE.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/BDCE.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/ConstantHoisting.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/ConstantHoisting.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/CorrelatedValuePropagation.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/CorrelatedValuePropagation.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/DCE.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/DCE.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/DeadStoreElimination.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/DeadStoreElimination.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/Float2Int.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/Float2Int.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/GVN.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/GVN.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/GuardWidening.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/GuardWidening.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/IndVarSimplify.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/IndVarSimplify.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/JumpThreading.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/JumpThreading.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LICM.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LICM.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopDeletion.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopDeletion.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopDistribute.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopDistribute.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopIdiomRecognize.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopIdiomRecognize.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopInstSimplify.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopInstSimplify.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopRotation.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopRotation.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LoopSimplifyCFG.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LoopSimplifyCFG.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LowerAtomic.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/LowerAtomic.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/MemCpyOptimizer.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/MemCpyOptimizer.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/MergedLoadStoreMotion.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/MergedLoadStoreMotion.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/PartiallyInlineLibCalls.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/PartiallyInlineLibCalls.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/Reassociate.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/Reassociate.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/SCCP.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/SCCP.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/Sink.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/Sink.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/TailRecursionElimination.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Scalar/TailRecursionElimination.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/AddDiscriminators.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/AddDiscriminators.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/Evaluator.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/Evaluator.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/FunctionImportUtils.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/FunctionImportUtils.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/LCSSA.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/LCSSA.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/LoopSimplify.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/LoopSimplify.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/Mem2Reg.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/Mem2Reg.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/MemorySSA.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/MemorySSA.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SanitizerStats.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/SanitizerStats.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SimplifyInstructions.h
     - copied unchanged from r309124, head/contrib/llvm/include/llvm/Transforms/Utils/SimplifyInstructions.h
  stable/11/contrib/llvm/include/llvm/Transforms/Vectorize/
     - copied from r309124, head/contrib/llvm/include/llvm/Transforms/Vectorize/
  stable/11/contrib/llvm/lib/Analysis/AliasAnalysisSummary.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/AliasAnalysisSummary.cpp
  stable/11/contrib/llvm/lib/Analysis/AliasAnalysisSummary.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/AliasAnalysisSummary.h
  stable/11/contrib/llvm/lib/Analysis/CFLAndersAliasAnalysis.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/CFLAndersAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/CFLGraph.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/CFLGraph.h
  stable/11/contrib/llvm/lib/Analysis/CFLSteensAliasAnalysis.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/CFLSteensAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/IndirectCallPromotionAnalysis.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/IndirectCallPromotionAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/LazyBlockFrequencyInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/LazyBlockFrequencyInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/LoopPassManager.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/LoopPassManager.cpp
  stable/11/contrib/llvm/lib/Analysis/LoopUnrollAnalyzer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/LoopUnrollAnalyzer.cpp
  stable/11/contrib/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/ModuleSummaryAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/OptimizationDiagnosticInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/ProfileSummaryInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/ProfileSummaryInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/TypeMetadataUtils.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Analysis/TypeMetadataUtils.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.h
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.h
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/AsmPrinter/DebugHandlerBase.h
  stable/11/contrib/llvm/lib/CodeGen/BuiltinGCs.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/BuiltinGCs.cpp
  stable/11/contrib/llvm/lib/CodeGen/DetectDeadLanes.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/DetectDeadLanes.cpp
  stable/11/contrib/llvm/lib/CodeGen/GlobalISel/
     - copied from r309124, head/contrib/llvm/lib/CodeGen/GlobalISel/
  stable/11/contrib/llvm/lib/CodeGen/LiveRangeUtils.h
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/LiveRangeUtils.h
  stable/11/contrib/llvm/lib/CodeGen/LowerEmuTLS.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/LowerEmuTLS.cpp
  stable/11/contrib/llvm/lib/CodeGen/PatchableFunction.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/PatchableFunction.cpp
  stable/11/contrib/llvm/lib/CodeGen/PostRAHazardRecognizer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/PostRAHazardRecognizer.cpp
  stable/11/contrib/llvm/lib/CodeGen/PreISelIntrinsicLowering.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/PreISelIntrinsicLowering.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/RegUsageInfoCollector.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/RegUsageInfoPropagate.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegisterUsageInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/RegisterUsageInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/RenameIndependentSubregs.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/RenameIndependentSubregs.cpp
  stable/11/contrib/llvm/lib/CodeGen/SafeStack.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SafeStack.cpp
  stable/11/contrib/llvm/lib/CodeGen/SafeStackColoring.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SafeStackColoring.cpp
  stable/11/contrib/llvm/lib/CodeGen/SafeStackColoring.h
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SafeStackColoring.h
  stable/11/contrib/llvm/lib/CodeGen/SafeStackLayout.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SafeStackLayout.cpp
  stable/11/contrib/llvm/lib/CodeGen/SafeStackLayout.h
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SafeStackLayout.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGTargetInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGTargetInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/TailDuplicator.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/TailDuplicator.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetPassConfig.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/TargetPassConfig.cpp
  stable/11/contrib/llvm/lib/CodeGen/XRayInstrumentation.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/CodeGen/XRayInstrumentation.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/ByteStream.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/ByteStream.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/CVTypeVisitor.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/CVTypeVisitor.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/CodeViewError.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/CodeViewError.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/ModuleSubstreamVisitor.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/ModuleSubstreamVisitor.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/RecordSerialization.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/RecordSerialization.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/StreamReader.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/StreamReader.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/StreamWriter.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/StreamWriter.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/SymbolDumper.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/SymbolDumper.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/TypeDumper.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/TypeDumper.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/TypeRecord.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/TypeRecord.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/TypeStreamMerger.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/CodeView/TypeStreamMerger.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAError.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAError.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/GenericError.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/DebugInfo/PDB/GenericError.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/Raw/
     - copied from r309124, head/contrib/llvm/lib/DebugInfo/PDB/Raw/
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcABISupport.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/ExecutionEngine/Orc/OrcABISupport.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFThumb.h
     - copied unchanged from r309124, head/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFThumb.h
  stable/11/contrib/llvm/lib/IR/AttributeSetNode.h
     - copied unchanged from r309124, head/contrib/llvm/lib/IR/AttributeSetNode.h
  stable/11/contrib/llvm/lib/IR/ModuleSummaryIndex.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/IR/ModuleSummaryIndex.cpp
  stable/11/contrib/llvm/lib/IR/OptBisect.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/IR/OptBisect.cpp
  stable/11/contrib/llvm/lib/IR/ProfileSummary.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/IR/ProfileSummary.cpp
  stable/11/contrib/llvm/lib/LTO/LTO.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/LTO/LTO.cpp
  stable/11/contrib/llvm/lib/LTO/ThinLTOCodeGenerator.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/LTO/ThinLTOCodeGenerator.cpp
  stable/11/contrib/llvm/lib/LTO/UpdateCompilerUsed.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/LTO/UpdateCompilerUsed.cpp
  stable/11/contrib/llvm/lib/MC/MCCodeView.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/MC/MCCodeView.cpp
  stable/11/contrib/llvm/lib/MC/MCDisassembler/MCSymbolizer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/MC/MCDisassembler/MCSymbolizer.cpp
  stable/11/contrib/llvm/lib/Object/ModuleSummaryIndexObjectFile.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Object/ModuleSummaryIndexObjectFile.cpp
  stable/11/contrib/llvm/lib/ObjectYAML/
     - copied from r309124, head/contrib/llvm/lib/ObjectYAML/
  stable/11/contrib/llvm/lib/ProfileData/Coverage/
     - copied from r309124, head/contrib/llvm/lib/ProfileData/Coverage/
  stable/11/contrib/llvm/lib/ProfileData/ProfileSummaryBuilder.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/ProfileData/ProfileSummaryBuilder.cpp
  stable/11/contrib/llvm/lib/Support/CachePruning.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Support/CachePruning.cpp
  stable/11/contrib/llvm/lib/Support/Error.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Support/Error.cpp
  stable/11/contrib/llvm/lib/Support/SHA1.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Support/SHA1.cpp
  stable/11/contrib/llvm/lib/Support/ScopedPrinter.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Support/ScopedPrinter.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64CallLowering.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64CallLowering.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64CallLowering.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64CallLowering.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64RedundantCopyElimination.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64RedundantCopyElimination.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64RegisterBankInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64RegisterBankInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64RegisterBankInfo.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64RegisterBankInfo.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedKryo.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64SchedKryo.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedKryoDetails.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64SchedKryoDetails.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedVulcan.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64SchedVulcan.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SystemOperands.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AArch64/AArch64SystemOperands.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUCallLowering.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/AMDGPUCallLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUCallLowering.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/AMDGPUCallLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUCodeGenPrepare.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/AMDGPUCodeGenPrepare.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPURuntimeMetadata.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/AMDGPURuntimeMetadata.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/Disassembler/
     - copied from r309124, head/contrib/llvm/lib/Target/AMDGPU/Disassembler/
  stable/11/contrib/llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/GCNHazardRecognizer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/GCNHazardRecognizer.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/GCNHazardRecognizer.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600FrameLowering.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/R600FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600FrameLowering.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/R600FrameLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIDebuggerInsertNops.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/SIDebuggerInsertNops.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIWholeQuadMode.cpp
     - copied, changed from r309124, head/contrib/llvm/lib/Target/AMDGPU/SIWholeQuadMode.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUAsmUtils.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTInfo.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRFrameLowering.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRFrameLowering.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRISelLowering.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRISelLowering.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRInstrFormats.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRInstrFormats.td
  stable/11/contrib/llvm/lib/Target/AVR/AVRInstrInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/AVR/AVRInstrInfo.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRInstrInfo.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRInstrInfo.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRInstrInfo.td
  stable/11/contrib/llvm/lib/Target/AVR/AVRRegisterInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/AVR/AVRRegisterInfo.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRSubtarget.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/AVR/AVRSubtarget.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRSubtarget.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRTargetMachine.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/AVRTargetMachine.h
  stable/11/contrib/llvm/lib/Target/AVR/MCTargetDesc/
     - copied from r309124, head/contrib/llvm/lib/Target/AVR/MCTargetDesc/
  stable/11/contrib/llvm/lib/Target/AVR/TODO.md
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/AVR/TODO.md
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBlockRanges.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Hexagon/HexagonBlockRanges.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBlockRanges.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Hexagon/HexagonBlockRanges.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBranchRelaxation.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Hexagon/HexagonBranchRelaxation.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonOptAddrMode.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Hexagon/HexagonOptAddrMode.cpp
  stable/11/contrib/llvm/lib/Target/Lanai/
     - copied from r309124, head/contrib/llvm/lib/Target/Lanai/
  stable/11/contrib/llvm/lib/Target/Mips/MipsHazardSchedule.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Mips/MipsHazardSchedule.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVVMIntrRange.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/NVPTX/NVVMIntrRange.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCCCState.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/PowerPC/PPCCCState.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCCCState.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/PowerPC/PPCCCState.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCQPXLoadSplat.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/PowerPC/PPCQPXLoadSplat.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/README_P9.txt
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/PowerPC/README_P9.txt
  stable/11/contrib/llvm/lib/Target/PowerPC/p9-instrs.txt
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/PowerPC/p9-instrs.txt
  stable/11/contrib/llvm/lib/Target/Sparc/LeonFeatures.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Sparc/LeonFeatures.td
  stable/11/contrib/llvm/lib/Target/Sparc/LeonPasses.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Sparc/LeonPasses.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/LeonPasses.h
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Sparc/LeonPasses.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcSchedule.td
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/Sparc/SparcSchedule.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZTDC.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/SystemZ/SystemZTDC.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyOptimizeLiveIntervals.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/WebAssembly/WebAssemblyOptimizeLiveIntervals.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyPrepareForLiveIntervals.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/WebAssembly/WebAssemblyPrepareForLiveIntervals.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyReplacePhysRegs.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/WebAssembly/WebAssemblyReplacePhysRegs.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblySetP2AlignOperands.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/WebAssembly/WebAssemblySetP2AlignOperands.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FixupBWInsts.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/X86/X86FixupBWInsts.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FixupSetCC.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/X86/X86FixupSetCC.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86WinAllocaExpander.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Target/X86/X86WinAllocaExpander.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/LowerTypeTests.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/IPO/LowerTypeTests.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/WholeProgramDevirt.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/IPO/WholeProgramDevirt.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Instrumentation/EfficiencySanitizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Instrumentation/IndirectCallPromotion.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/GVNHoist.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/GVNHoist.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/GuardWidening.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/GuardWidening.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopDataPrefetch.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/LoopDataPrefetch.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/LoopSimplifyCFG.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopVersioningLICM.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/LoopVersioningLICM.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LowerGuardIntrinsic.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Scalar/LowerGuardIntrinsic.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/Evaluator.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Utils/Evaluator.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/MemorySSA.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Utils/MemorySSA.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/NameAnonFunctions.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Utils/NameAnonFunctions.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SanitizerStats.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Utils/SanitizerStats.cpp
  stable/11/contrib/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp
     - copied unchanged from r309124, head/contrib/llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Availability.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/AST/Availability.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/LocInfoType.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/AST/LocInfoType.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/OperationKinds.def
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/AST/OperationKinds.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Cuda.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Basic/Cuda.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DebugInfoOptions.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Basic/DebugInfoOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/OpenCLImageTypes.def
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Basic/OpenCLImageTypes.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/OpenCLOptions.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Basic/OpenCLOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/PragmaKinds.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Basic/PragmaKinds.h
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/SwiftCallingConv.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/CodeGen/SwiftCallingConv.h
  stable/11/contrib/llvm/tools/clang/include/clang/Index/CodegenNameGenerator.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Index/CodegenNameGenerator.h
  stable/11/contrib/llvm/tools/clang/include/clang/Index/IndexDataConsumer.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Index/IndexDataConsumer.h
  stable/11/contrib/llvm/tools/clang/include/clang/Index/IndexSymbol.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Index/IndexSymbol.h
  stable/11/contrib/llvm/tools/clang/include/clang/Index/IndexingAction.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Index/IndexingAction.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/HeaderMapTypes.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Lex/HeaderMapTypes.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/CleanupInfo.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Sema/CleanupInfo.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/Checkers.td
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/Checkers.td
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/SValExplainer.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Checkers/SValExplainer.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Regions.def
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Regions.def
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValVisitor.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValVisitor.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.def
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.def
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymExpr.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymExpr.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Symbols.def
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Symbols.def
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/Core/QualTypeNames.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Tooling/Core/QualTypeNames.h
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/FixIt.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/include/clang/Tooling/FixIt.h
  stable/11/contrib/llvm/tools/clang/lib/Basic/Cuda.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Basic/Cuda.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCUDABuiltin.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/CodeGen/CGCUDABuiltin.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/SwiftCallingConv.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/CodeGen/SwiftCallingConv.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/AffectedRangeManager.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/AffectedRangeManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/AffectedRangeManager.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/AffectedRangeManager.h
  stable/11/contrib/llvm/tools/clang/lib/Format/FormatTokenLexer.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/FormatTokenLexer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/FormatTokenLexer.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/FormatTokenLexer.h
  stable/11/contrib/llvm/tools/clang/lib/Format/SortJavaScriptImports.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/SortJavaScriptImports.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/SortJavaScriptImports.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/SortJavaScriptImports.h
  stable/11/contrib/llvm/tools/clang/lib/Format/TokenAnalyzer.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/TokenAnalyzer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/TokenAnalyzer.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Format/TokenAnalyzer.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_cmath.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_cmath.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_intrinsics.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_intrinsics.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_math_forward_declares.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_math_forward_declares.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512ifmaintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512ifmaintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512ifmavlintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512ifmavlintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512pfintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512pfintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vbmiintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512vbmiintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vbmivlintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512vbmivlintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vlcdintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/avx512vlcdintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/clflushoptintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/clflushoptintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/intrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/intrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/msa.h
     - copied unchanged from r310194, head/contrib/llvm/tools/clang/lib/Headers/msa.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/mwaitxintrin.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/mwaitxintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/opencl-c.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Headers/opencl-c.h
  stable/11/contrib/llvm/tools/clang/lib/Index/CodegenNameGenerator.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/CodegenNameGenerator.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexBody.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexBody.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexDecl.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexSymbol.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexSymbol.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexTypeSourceInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexTypeSourceInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexingAction.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexingAction.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexingContext.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexingContext.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/IndexingContext.h
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Index/IndexingContext.h
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MPI-Checker/
     - copied from r309124, head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MPI-Checker/
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCSuperDeallocChecker.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCSuperDeallocChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/Core/QualTypeNames.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Tooling/Core/QualTypeNames.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/FixIt.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/clang/lib/Tooling/FixIt.cpp
  stable/11/contrib/llvm/tools/lld/
     - copied from r309124, head/contrib/llvm/tools/lld/
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBMemoryRegionInfo.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/API/SBMemoryRegionInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBMemoryRegionInfoList.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/API/SBMemoryRegionInfoList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ThreadSafeSTLVector.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/Core/ThreadSafeSTLVector.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/DiagnosticManager.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/Expression/DiagnosticManager.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandAlias.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandAlias.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/ClangUtil.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/Symbol/ClangUtil.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/JavaASTContext.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/Symbol/JavaASTContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-private-defines.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/include/lldb/lldb-private-defines.h
  stable/11/contrib/llvm/tools/lldb/source/API/SBMemoryRegionInfo.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/API/SBMemoryRegionInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBMemoryRegionInfoList.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/API/SBMemoryRegionInfoList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/DiagnosticManager.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Expression/DiagnosticManager.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/CommandAlias.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Interpreter/CommandAlias.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-s390x/
     - copied from r309124, head/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-s390x/
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangDiagnostic.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangDiagnostic.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/InstrumentationRuntime/ThreadSanitizer/
     - copied from r309124, head/contrib/llvm/tools/lldb/source/Plugins/InstrumentationRuntime/ThreadSanitizer/
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/BlockPointer.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/BlockPointer.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxAtomic.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxAtomic.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxAtomic.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxAtomic.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/Java/
     - copied from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Language/Java/
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/Java/
     - copied from r309124, head/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/Java/
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_s390x.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_s390x.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_s390x.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_s390x.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextNetBSD_x86_64.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextNetBSD_x86_64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextNetBSD_x86_64.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextNetBSD_x86_64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_s390x.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_s390x.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_s390x.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_s390x.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContext_s390x.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContext_s390x.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_s390x.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_s390x.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/lldb-s390x-register-enums.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/lldb-s390x-register-enums.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_s390x.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_s390x.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_s390x.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_s390x.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserJava.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserJava.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserJava.h
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserJava.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/PDB/
     - copied from r309124, head/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/PDB/
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ClangUtil.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Symbol/ClangUtil.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/JavaASTContext.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/lldb/source/Symbol/JavaASTContext.cpp
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageViewHTML.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-cov/SourceCoverageViewHTML.cpp
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageViewHTML.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-cov/SourceCoverageViewHTML.h
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-cov/SourceCoverageViewText.cpp
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageViewText.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-cov/SourceCoverageViewText.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/LLVMOutputStyle.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/LLVMOutputStyle.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/LLVMOutputStyle.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/LLVMOutputStyle.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/OutputStyle.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/OutputStyle.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/PdbYaml.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/PdbYaml.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/PdbYaml.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/PdbYaml.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/YAMLOutputStyle.cpp
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/YAMLOutputStyle.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/YAMLOutputStyle.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-pdbdump/YAMLOutputStyle.h
  stable/11/contrib/llvm/tools/llvm-readobj/CodeView.h
     - copied unchanged from r309124, head/contrib/llvm/tools/llvm-readobj/CodeView.h
  stable/11/contrib/llvm/utils/TableGen/SearchableTableEmitter.cpp
     - copied unchanged from r309124, head/contrib/llvm/utils/TableGen/SearchableTableEmitter.cpp
  stable/11/lib/clang/clang.pre.mk
     - copied unchanged from r309124, head/lib/clang/clang.pre.mk
  stable/11/lib/clang/headers/
     - copied from r309124, head/lib/clang/headers/
  stable/11/lib/clang/include/lld/
     - copied from r309124, head/lib/clang/include/lld/
  stable/11/lib/clang/libclang/
     - copied from r309124, head/lib/clang/libclang/
  stable/11/lib/clang/libllvm/
     - copied from r309124, head/lib/clang/libllvm/
  stable/11/lib/clang/libllvmminimal/
     - copied from r309124, head/lib/clang/libllvmminimal/
  stable/11/lib/clang/lldb.pre.mk
     - copied unchanged from r309124, head/lib/clang/lldb.pre.mk
  stable/11/lib/clang/llvm.build.mk
     - copied, changed from r309124, head/lib/clang/llvm.build.mk
  stable/11/lib/clang/llvm.pre.mk
     - copied unchanged from r309124, head/lib/clang/llvm.pre.mk
  stable/11/lib/libclang_rt/stats/
     - copied from r309124, head/lib/libclang_rt/stats/
  stable/11/lib/libclang_rt/stats_client/
     - copied from r309124, head/lib/libclang_rt/stats_client/
  stable/11/release/packages/lld.ucl
     - copied unchanged from r309262, head/release/packages/lld.ucl
  stable/11/release/packages/lldb.ucl
     - copied unchanged from r309262, head/release/packages/lldb.ucl
  stable/11/tools/build/options/WITHOUT_LLD
     - copied unchanged from r309124, head/tools/build/options/WITHOUT_LLD
  stable/11/tools/build/options/WITH_LLD
     - copied unchanged from r309124, head/tools/build/options/WITH_LLD
  stable/11/usr.bin/clang/Makefile.inc
     - copied unchanged from r309124, head/usr.bin/clang/Makefile.inc
  stable/11/usr.bin/clang/clang-tblgen/Makefile.depend.host
     - copied unchanged from r309124, head/usr.bin/clang/clang-tblgen/Makefile.depend.host
  stable/11/usr.bin/clang/lld/
     - copied from r309124, head/usr.bin/clang/lld/
  stable/11/usr.bin/clang/llvm-tblgen/Makefile.depend.host
     - copied unchanged from r309124, head/usr.bin/clang/llvm-tblgen/Makefile.depend.host
  stable/11/usr.bin/clang/llvm.prog.mk
     - copied, changed from r309124, head/usr.bin/clang/llvm.prog.mk
Replaced:
  stable/11/lib/clang/liblldb/Makefile.depend
     - copied unchanged from r309124, head/lib/clang/liblldb/Makefile.depend
  stable/11/lib/libcompiler_rt/Makefile.inc
     - copied, changed from r306377, head/lib/libcompiler_rt/Makefile.inc
  stable/11/usr.bin/clang/bugpoint/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/bugpoint/Makefile.depend
  stable/11/usr.bin/clang/clang-format/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/clang-format/Makefile.depend
  stable/11/usr.bin/clang/clang-tblgen/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/clang-tblgen/Makefile.depend
  stable/11/usr.bin/clang/clang/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/clang/Makefile.depend
  stable/11/usr.bin/clang/llc/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llc/Makefile.depend
  stable/11/usr.bin/clang/lldb/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/lldb/Makefile.depend
  stable/11/usr.bin/clang/lli/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/lli/Makefile.depend
  stable/11/usr.bin/clang/llvm-ar/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-ar/Makefile.depend
  stable/11/usr.bin/clang/llvm-as/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-as/Makefile.depend
  stable/11/usr.bin/clang/llvm-bcanalyzer/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-bcanalyzer/Makefile.depend
  stable/11/usr.bin/clang/llvm-cov/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-cov/Makefile.depend
  stable/11/usr.bin/clang/llvm-cxxdump/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-cxxdump/Makefile.depend
  stable/11/usr.bin/clang/llvm-diff/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-diff/Makefile.depend
  stable/11/usr.bin/clang/llvm-dis/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-dis/Makefile.depend
  stable/11/usr.bin/clang/llvm-dwarfdump/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-dwarfdump/Makefile.depend
  stable/11/usr.bin/clang/llvm-extract/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-extract/Makefile.depend
  stable/11/usr.bin/clang/llvm-link/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-link/Makefile.depend
  stable/11/usr.bin/clang/llvm-lto/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-lto/Makefile.depend
  stable/11/usr.bin/clang/llvm-mc/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-mc/Makefile.depend
  stable/11/usr.bin/clang/llvm-nm/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-nm/Makefile.depend
  stable/11/usr.bin/clang/llvm-objdump/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-objdump/Makefile.depend
  stable/11/usr.bin/clang/llvm-pdbdump/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-pdbdump/Makefile.depend
  stable/11/usr.bin/clang/llvm-profdata/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-profdata/Makefile.depend
  stable/11/usr.bin/clang/llvm-rtdyld/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-rtdyld/Makefile.depend
  stable/11/usr.bin/clang/llvm-symbolizer/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-symbolizer/Makefile.depend
  stable/11/usr.bin/clang/llvm-tblgen/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/llvm-tblgen/Makefile.depend
  stable/11/usr.bin/clang/opt/Makefile.depend
     - copied unchanged from r309124, head/usr.bin/clang/opt/Makefile.depend
Deleted:
  stable/11/contrib/llvm/include/llvm/Analysis/CFLAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcArchitectureSupport.h
  stable/11/contrib/llvm/include/llvm/IR/FunctionInfo.h
  stable/11/contrib/llvm/include/llvm/LTO/LTOCodeGenerator.h
  stable/11/contrib/llvm/include/llvm/LTO/LTOModule.h
  stable/11/contrib/llvm/include/llvm/MC/MCCodeGenInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCDisassembler.h
  stable/11/contrib/llvm/include/llvm/MC/MCExternalSymbolizer.h
  stable/11/contrib/llvm/include/llvm/MC/MCRelocationInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCSymbolizer.h
  stable/11/contrib/llvm/include/llvm/MC/MCTargetAsmParser.h
  stable/11/contrib/llvm/include/llvm/MC/YAML.h
  stable/11/contrib/llvm/include/llvm/Object/COFFYAML.h
  stable/11/contrib/llvm/include/llvm/Object/ELFYAML.h
  stable/11/contrib/llvm/include/llvm/Object/FunctionIndexObjectFile.h
  stable/11/contrib/llvm/include/llvm/ProfileData/CoverageMapping.h
  stable/11/contrib/llvm/include/llvm/ProfileData/CoverageMappingReader.h
  stable/11/contrib/llvm/include/llvm/ProfileData/CoverageMappingWriter.h
  stable/11/contrib/llvm/include/llvm/Support/AIXDataTypesFix.h
  stable/11/contrib/llvm/include/llvm/Support/DataTypes.h.in
  stable/11/contrib/llvm/include/llvm/Support/RegistryParser.h
  stable/11/contrib/llvm/include/llvm/Target/TargetSelectionDAGInfo.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/LowerBitSets.h
  stable/11/contrib/llvm/lib/Analysis/CFLAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/AsmParser/module.modulemap
  stable/11/contrib/llvm/lib/Bitcode/module.modulemap
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/WinCodeViewLineTables.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/WinCodeViewLineTables.h
  stable/11/contrib/llvm/lib/CodeGen/CoreCLRGC.cpp
  stable/11/contrib/llvm/lib/CodeGen/ErlangGC.cpp
  stable/11/contrib/llvm/lib/CodeGen/OcamlGC.cpp
  stable/11/contrib/llvm/lib/CodeGen/Passes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/TargetSelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/ShadowStackGC.cpp
  stable/11/contrib/llvm/lib/CodeGen/StatepointExampleGC.cpp
  stable/11/contrib/llvm/lib/CodeGen/module.modulemap
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/module.modulemap
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcArchitectureSupport.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcCBindingsStack.cpp
  stable/11/contrib/llvm/lib/IR/FunctionInfo.cpp
  stable/11/contrib/llvm/lib/IR/module.modulemap
  stable/11/contrib/llvm/lib/MC/MCCodeGenInfo.cpp
  stable/11/contrib/llvm/lib/MC/MCSymbolizer.cpp
  stable/11/contrib/llvm/lib/MC/YAML.cpp
  stable/11/contrib/llvm/lib/Object/COFFYAML.cpp
  stable/11/contrib/llvm/lib/Object/ELFYAML.cpp
  stable/11/contrib/llvm/lib/Object/FunctionIndexObjectFile.cpp
  stable/11/contrib/llvm/lib/ProfileData/CoverageMapping.cpp
  stable/11/contrib/llvm/lib/ProfileData/CoverageMappingReader.cpp
  stable/11/contrib/llvm/lib/ProfileData/CoverageMappingWriter.cpp
  stable/11/contrib/llvm/lib/TableGen/module.modulemap
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUDiagnosticInfoUnsupported.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600TextureIntrinsicsReplacer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIFixSGPRLiveRanges.cpp
  stable/11/contrib/llvm/lib/Target/AVR/AVRConfig.h
  stable/11/contrib/llvm/lib/Target/CppBackend/
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonExpandPredSpillCode.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCLoopDataPrefetch.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/Disassembler/CMakeLists.txt
  stable/11/contrib/llvm/lib/Target/WebAssembly/Disassembler/LLVMBuild.txt
  stable/11/contrib/llvm/lib/Target/WebAssembly/Disassembler/Makefile
  stable/11/contrib/llvm/lib/Target/WebAssembly/Relooper.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/Relooper.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyPEI.cpp
  stable/11/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.h
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86ELFRelocationInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MachORelocationInfo.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/LowerBitSets.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/SafeStack.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/LocInfoType.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/Intrin.h
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/Checkers.td
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/Platform.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/StreamWriter.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/StreamWriter.h
  stable/11/contrib/llvm/utils/TableGen/module.modulemap
  stable/11/lib/clang/clang.lib.mk
  stable/11/lib/clang/include/AArch64GenAsmMatcher.inc
  stable/11/lib/clang/include/AArch64GenAsmWriter.inc
  stable/11/lib/clang/include/AArch64GenAsmWriter1.inc
  stable/11/lib/clang/include/AArch64GenCallingConv.inc
  stable/11/lib/clang/include/AArch64GenDAGISel.inc
  stable/11/lib/clang/include/AArch64GenDisassemblerTables.inc
  stable/11/lib/clang/include/AArch64GenFastISel.inc
  stable/11/lib/clang/include/AArch64GenInstrInfo.inc
  stable/11/lib/clang/include/AArch64GenMCCodeEmitter.inc
  stable/11/lib/clang/include/AArch64GenMCPseudoLowering.inc
  stable/11/lib/clang/include/AArch64GenRegisterInfo.inc
  stable/11/lib/clang/include/AArch64GenSubtargetInfo.inc
  stable/11/lib/clang/include/ARMGenAsmMatcher.inc
  stable/11/lib/clang/include/ARMGenAsmWriter.inc
  stable/11/lib/clang/include/ARMGenCallingConv.inc
  stable/11/lib/clang/include/ARMGenCodeEmitter.inc
  stable/11/lib/clang/include/ARMGenDAGISel.inc
  stable/11/lib/clang/include/ARMGenDisassemblerTables.inc
  stable/11/lib/clang/include/ARMGenFastISel.inc
  stable/11/lib/clang/include/ARMGenInstrInfo.inc
  stable/11/lib/clang/include/ARMGenMCCodeEmitter.inc
  stable/11/lib/clang/include/ARMGenMCPseudoLowering.inc
  stable/11/lib/clang/include/ARMGenRegisterInfo.inc
  stable/11/lib/clang/include/ARMGenSubtargetInfo.inc
  stable/11/lib/clang/include/AttributesCompatFunc.inc
  stable/11/lib/clang/include/Checkers.inc
  stable/11/lib/clang/include/Makefile
  stable/11/lib/clang/include/Makefile.depend
  stable/11/lib/clang/include/MipsGenAsmMatcher.inc
  stable/11/lib/clang/include/MipsGenAsmWriter.inc
  stable/11/lib/clang/include/MipsGenCallingConv.inc
  stable/11/lib/clang/include/MipsGenCodeEmitter.inc
  stable/11/lib/clang/include/MipsGenDAGISel.inc
  stable/11/lib/clang/include/MipsGenDisassemblerTables.inc
  stable/11/lib/clang/include/MipsGenFastISel.inc
  stable/11/lib/clang/include/MipsGenInstrInfo.inc
  stable/11/lib/clang/include/MipsGenMCCodeEmitter.inc
  stable/11/lib/clang/include/MipsGenMCPseudoLowering.inc
  stable/11/lib/clang/include/MipsGenRegisterInfo.inc
  stable/11/lib/clang/include/MipsGenSubtargetInfo.inc
  stable/11/lib/clang/include/PPCGenAsmMatcher.inc
  stable/11/lib/clang/include/PPCGenAsmWriter.inc
  stable/11/lib/clang/include/PPCGenCallingConv.inc
  stable/11/lib/clang/include/PPCGenCodeEmitter.inc
  stable/11/lib/clang/include/PPCGenDAGISel.inc
  stable/11/lib/clang/include/PPCGenDisassemblerTables.inc
  stable/11/lib/clang/include/PPCGenFastISel.inc
  stable/11/lib/clang/include/PPCGenInstrInfo.inc
  stable/11/lib/clang/include/PPCGenMCCodeEmitter.inc
  stable/11/lib/clang/include/PPCGenRegisterInfo.inc
  stable/11/lib/clang/include/PPCGenSubtargetInfo.inc
  stable/11/lib/clang/include/SparcGenAsmMatcher.inc
  stable/11/lib/clang/include/SparcGenAsmWriter.inc
  stable/11/lib/clang/include/SparcGenCallingConv.inc
  stable/11/lib/clang/include/SparcGenCodeEmitter.inc
  stable/11/lib/clang/include/SparcGenDAGISel.inc
  stable/11/lib/clang/include/SparcGenDisassemblerTables.inc
  stable/11/lib/clang/include/SparcGenInstrInfo.inc
  stable/11/lib/clang/include/SparcGenMCCodeEmitter.inc
  stable/11/lib/clang/include/SparcGenRegisterInfo.inc
  stable/11/lib/clang/include/SparcGenSubtargetInfo.inc
  stable/11/lib/clang/include/X86GenAsmMatcher.inc
  stable/11/lib/clang/include/X86GenAsmWriter.inc
  stable/11/lib/clang/include/X86GenAsmWriter1.inc
  stable/11/lib/clang/include/X86GenCallingConv.inc
  stable/11/lib/clang/include/X86GenDAGISel.inc
  stable/11/lib/clang/include/X86GenDisassemblerTables.inc
  stable/11/lib/clang/include/X86GenFastISel.inc
  stable/11/lib/clang/include/X86GenInstrInfo.inc
  stable/11/lib/clang/include/X86GenRegisterInfo.inc
  stable/11/lib/clang/include/X86GenSubtargetInfo.inc
  stable/11/lib/clang/include/clang/AST/
  stable/11/lib/clang/include/clang/Basic/AttrHasAttributeImpl.inc
  stable/11/lib/clang/include/clang/Basic/AttrList.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticASTKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticAnalysisKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticCommentKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticCommonKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticDriverKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticFrontendKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticGroups.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticIndexName.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticLexKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticParseKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticSemaKinds.inc
  stable/11/lib/clang/include/clang/Basic/DiagnosticSerializationKinds.inc
  stable/11/lib/clang/include/clang/Basic/arm_neon.inc
  stable/11/lib/clang/include/clang/Driver/
  stable/11/lib/clang/include/clang/Parse/
  stable/11/lib/clang/include/clang/Sema/
  stable/11/lib/clang/include/clang/Serialization/
  stable/11/lib/clang/include/llvm/IR/
  stable/11/lib/clang/libclanganalysis/
  stable/11/lib/clang/libclangarcmigrate/
  stable/11/lib/clang/libclangast/
  stable/11/lib/clang/libclangbasic/
  stable/11/lib/clang/libclangcodegen/
  stable/11/lib/clang/libclangdriver/
  stable/11/lib/clang/libclangedit/
  stable/11/lib/clang/libclangformat/
  stable/11/lib/clang/libclangfrontend/
  stable/11/lib/clang/libclangfrontendtool/
  stable/11/lib/clang/libclanglex/
  stable/11/lib/clang/libclangparse/
  stable/11/lib/clang/libclangrewrite/
  stable/11/lib/clang/libclangrewritefrontend/
  stable/11/lib/clang/libclangsema/
  stable/11/lib/clang/libclangserialization/
  stable/11/lib/clang/libclangstaticanalyzercheckers/
  stable/11/lib/clang/libclangstaticanalyzercore/
  stable/11/lib/clang/libclangstaticanalyzerfrontend/
  stable/11/lib/clang/libclangtoolingcore/
  stable/11/lib/clang/liblldbAPI/
  stable/11/lib/clang/liblldbBreakpoint/
  stable/11/lib/clang/liblldbCommands/
  stable/11/lib/clang/liblldbCore/
  stable/11/lib/clang/liblldbDataFormatters/
  stable/11/lib/clang/liblldbExpression/
  stable/11/lib/clang/liblldbHostCommon/
  stable/11/lib/clang/liblldbHostFreeBSD/
  stable/11/lib/clang/liblldbHostPOSIX/
  stable/11/lib/clang/liblldbInitialization/
  stable/11/lib/clang/liblldbInterpreter/
  stable/11/lib/clang/liblldbPluginABISysV_arm/
  stable/11/lib/clang/liblldbPluginABISysV_arm64/
  stable/11/lib/clang/liblldbPluginABISysV_i386/
  stable/11/lib/clang/liblldbPluginABISysV_mips/
  stable/11/lib/clang/liblldbPluginABISysV_mips64/
  stable/11/lib/clang/liblldbPluginABISysV_ppc/
  stable/11/lib/clang/liblldbPluginABISysV_ppc64/
  stable/11/lib/clang/liblldbPluginABISysV_x86_64/
  stable/11/lib/clang/liblldbPluginCXXItaniumABI/
  stable/11/lib/clang/liblldbPluginDisassemblerLLVM/
  stable/11/lib/clang/liblldbPluginDynamicLoaderPosixDYLD/
  stable/11/lib/clang/liblldbPluginDynamicLoaderStatic/
  stable/11/lib/clang/liblldbPluginExpressionParserClang/
  stable/11/lib/clang/liblldbPluginExpressionParserGo/
  stable/11/lib/clang/liblldbPluginInstructionARM/
  stable/11/lib/clang/liblldbPluginInstructionARM64/
  stable/11/lib/clang/liblldbPluginInstructionMIPS/
  stable/11/lib/clang/liblldbPluginInstructionMIPS64/
  stable/11/lib/clang/liblldbPluginInstrumentationRuntimeAddressSanitizer/
  stable/11/lib/clang/liblldbPluginJITLoaderGDB/
  stable/11/lib/clang/liblldbPluginLanguageCPlusPlus/
  stable/11/lib/clang/liblldbPluginLanguageObjC/
  stable/11/lib/clang/liblldbPluginMemoryHistoryASan/
  stable/11/lib/clang/liblldbPluginObjectContainerBSDArchive/
  stable/11/lib/clang/liblldbPluginObjectFileELF/
  stable/11/lib/clang/liblldbPluginObjectFileJIT/
  stable/11/lib/clang/liblldbPluginPlatformFreeBSD/
  stable/11/lib/clang/liblldbPluginPlatformGDB/
  stable/11/lib/clang/liblldbPluginProcessElfCore/
  stable/11/lib/clang/liblldbPluginProcessFreeBSD/
  stable/11/lib/clang/liblldbPluginProcessGDBRemote/
  stable/11/lib/clang/liblldbPluginProcessPOSIX/
  stable/11/lib/clang/liblldbPluginProcessUtility/
  stable/11/lib/clang/liblldbPluginScriptInterpreterNone/
  stable/11/lib/clang/liblldbPluginSymbolFileDWARF/
  stable/11/lib/clang/liblldbPluginSymbolFileSymtab/
  stable/11/lib/clang/liblldbPluginSymbolVendorELF/
  stable/11/lib/clang/liblldbPluginUnwindAssemblyInstEmulation/
  stable/11/lib/clang/liblldbPluginUnwindAssemblyX86/
  stable/11/lib/clang/liblldbSymbol/
  stable/11/lib/clang/liblldbTarget/
  stable/11/lib/clang/liblldbUtility/
  stable/11/lib/clang/libllvmaarch64asmparser/
  stable/11/lib/clang/libllvmaarch64asmprinter/
  stable/11/lib/clang/libllvmaarch64codegen/
  stable/11/lib/clang/libllvmaarch64desc/
  stable/11/lib/clang/libllvmaarch64disassembler/
  stable/11/lib/clang/libllvmaarch64info/
  stable/11/lib/clang/libllvmaarch64utils/
  stable/11/lib/clang/libllvmanalysis/
  stable/11/lib/clang/libllvmarmasmparser/
  stable/11/lib/clang/libllvmarmasmprinter/
  stable/11/lib/clang/libllvmarmcodegen/
  stable/11/lib/clang/libllvmarmdesc/
  stable/11/lib/clang/libllvmarmdisassembler/
  stable/11/lib/clang/libllvmarminfo/
  stable/11/lib/clang/libllvmasmparser/
  stable/11/lib/clang/libllvmasmprinter/
  stable/11/lib/clang/libllvmbitreader/
  stable/11/lib/clang/libllvmbitwriter/
  stable/11/lib/clang/libllvmcodegen/
  stable/11/lib/clang/libllvmcore/
  stable/11/lib/clang/libllvmdebuginfodwarf/
  stable/11/lib/clang/libllvmdebuginfopdb/
  stable/11/lib/clang/libllvmexecutionengine/
  stable/11/lib/clang/libllvminstcombine/
  stable/11/lib/clang/libllvminstrumentation/
  stable/11/lib/clang/libllvminterpreter/
  stable/11/lib/clang/libllvmipo/
  stable/11/lib/clang/libllvmirreader/
  stable/11/lib/clang/libllvmlibdriver/
  stable/11/lib/clang/libllvmlinker/
  stable/11/lib/clang/libllvmlto/
  stable/11/lib/clang/libllvmmc/
  stable/11/lib/clang/libllvmmcdisassembler/
  stable/11/lib/clang/libllvmmcjit/
  stable/11/lib/clang/libllvmmcparser/
  stable/11/lib/clang/libllvmmipsasmparser/
  stable/11/lib/clang/libllvmmipsasmprinter/
  stable/11/lib/clang/libllvmmipscodegen/
  stable/11/lib/clang/libllvmmipsdesc/
  stable/11/lib/clang/libllvmmipsdisassembler/
  stable/11/lib/clang/libllvmmipsinfo/
  stable/11/lib/clang/libllvmmirparser/
  stable/11/lib/clang/libllvmobjcarcopts/
  stable/11/lib/clang/libllvmobject/
  stable/11/lib/clang/libllvmoption/
  stable/11/lib/clang/libllvmorcjit/
  stable/11/lib/clang/libllvmpasses/
  stable/11/lib/clang/libllvmpowerpcasmparser/
  stable/11/lib/clang/libllvmpowerpcasmprinter/
  stable/11/lib/clang/libllvmpowerpccodegen/
  stable/11/lib/clang/libllvmpowerpcdesc/
  stable/11/lib/clang/libllvmpowerpcdisassembler/
  stable/11/lib/clang/libllvmpowerpcinfo/
  stable/11/lib/clang/libllvmprofiledata/
  stable/11/lib/clang/libllvmruntimedyld/
  stable/11/lib/clang/libllvmscalaropts/
  stable/11/lib/clang/libllvmselectiondag/
  stable/11/lib/clang/libllvmsparcasmparser/
  stable/11/lib/clang/libllvmsparcasmprinter/
  stable/11/lib/clang/libllvmsparccodegen/
  stable/11/lib/clang/libllvmsparcdesc/
  stable/11/lib/clang/libllvmsparcdisassembler/
  stable/11/lib/clang/libllvmsparcinfo/
  stable/11/lib/clang/libllvmsupport/
  stable/11/lib/clang/libllvmsymbolize/
  stable/11/lib/clang/libllvmtablegen/
  stable/11/lib/clang/libllvmtarget/
  stable/11/lib/clang/libllvmtransformutils/
  stable/11/lib/clang/libllvmvectorize/
  stable/11/lib/clang/libllvmx86asmparser/
  stable/11/lib/clang/libllvmx86asmprinter/
  stable/11/lib/clang/libllvmx86codegen/
  stable/11/lib/clang/libllvmx86desc/
  stable/11/lib/clang/libllvmx86disassembler/
  stable/11/lib/clang/libllvmx86info/
  stable/11/lib/clang/libllvmx86utils/
  stable/11/lib/clang/lldb.lib.mk
Modified:
  stable/11/Makefile.inc1
  stable/11/ObsoleteFiles.inc
  stable/11/UPDATING
  stable/11/contrib/compiler-rt/LICENSE.TXT
  stable/11/contrib/compiler-rt/include/sanitizer/allocator_interface.h
  stable/11/contrib/compiler-rt/include/sanitizer/common_interface_defs.h
  stable/11/contrib/compiler-rt/include/sanitizer/linux_syscall_hooks.h
  stable/11/contrib/compiler-rt/lib/asan/asan_activation.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_allocator.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_allocator.h
  stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.h
  stable/11/contrib/compiler-rt/lib/asan/asan_flags.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_flags.inc
  stable/11/contrib/compiler-rt/lib/asan/asan_globals.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_init_version.h
  stable/11/contrib/compiler-rt/lib/asan/asan_interceptors.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_interceptors.h
  stable/11/contrib/compiler-rt/lib/asan/asan_interface_internal.h
  stable/11/contrib/compiler-rt/lib/asan/asan_internal.h
  stable/11/contrib/compiler-rt/lib/asan/asan_linux.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_mac.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_malloc_linux.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_malloc_win.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_mapping.h
  stable/11/contrib/compiler-rt/lib/asan/asan_new_delete.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_poisoning.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_posix.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_report.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_report.h
  stable/11/contrib/compiler-rt/lib/asan/asan_rtl.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_stack.h
  stable/11/contrib/compiler-rt/lib/asan/asan_suppressions.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_thread.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_thread.h
  stable/11/contrib/compiler-rt/lib/asan/asan_win.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_win_dll_thunk.cc
  stable/11/contrib/compiler-rt/lib/asan/asan_win_dynamic_runtime_thunk.cc
  stable/11/contrib/compiler-rt/lib/builtins/arm/adddf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/addsf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_cdcmp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_cfcmp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_dcmp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_fcmp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_idivmod.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_ldivmod.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_memcmp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_memcpy.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_memmove.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_memset.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_uidivmod.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/aeabi_uldivmod.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/bswapdi2.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/bswapsi2.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/clzdi2.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/clzsi2.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/comparesf2.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/divdf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/divmodsi4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/divsf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/divsi3.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/eqdf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/eqsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/extendsfdf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/fixdfsivfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/fixsfsivfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/fixunsdfsivfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/fixunssfsivfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/floatsidfvfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/floatsisfvfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/floatunssidfvfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/floatunssisfvfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/gedf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/gesf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/gtdf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/gtsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/ledf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/lesf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/ltdf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/ltsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/modsi3.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/muldf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/mulsf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/nedf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/negdf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/negsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/nesf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/restore_vfp_d8_d15_regs.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/save_vfp_d8_d15_regs.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/subdf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/subsf3vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/switch16.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/switch32.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/switch8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/switchu8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_add_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_add_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_and_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_and_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_max_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_max_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_min_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_min_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_nand_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_nand_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_or_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_or_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_sub_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_sub_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_umax_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_umax_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_umin_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_umin_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_xor_4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_fetch_and_xor_8.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/sync_synchronize.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/truncdfsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/udivmodsi4.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/udivsi3.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/umodsi3.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/unorddf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/arm/unordsf2vfp.S
  stable/11/contrib/compiler-rt/lib/builtins/assembly.h
  stable/11/contrib/compiler-rt/lib/builtins/clear_cache.c
  stable/11/contrib/compiler-rt/lib/builtins/emutls.c
  stable/11/contrib/compiler-rt/lib/builtins/floatdidf.c
  stable/11/contrib/compiler-rt/lib/builtins/floattidf.c
  stable/11/contrib/compiler-rt/lib/builtins/floatundidf.c
  stable/11/contrib/compiler-rt/lib/builtins/floatuntidf.c
  stable/11/contrib/compiler-rt/lib/builtins/gcc_personality_v0.c
  stable/11/contrib/compiler-rt/lib/builtins/i386/ashldi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/ashrdi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/divdi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatdidf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatdisf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatdixf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatundidf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatundisf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/floatundixf.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/lshrdi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/moddi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/muldi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/udivdi3.S
  stable/11/contrib/compiler-rt/lib/builtins/i386/umoddi3.S
  stable/11/contrib/compiler-rt/lib/builtins/int_lib.h
  stable/11/contrib/compiler-rt/lib/builtins/ppc/restFP.S
  stable/11/contrib/compiler-rt/lib/builtins/ppc/saveFP.S
  stable/11/contrib/compiler-rt/lib/builtins/x86_64/floatundidf.S
  stable/11/contrib/compiler-rt/lib/builtins/x86_64/floatundisf.S
  stable/11/contrib/compiler-rt/lib/builtins/x86_64/floatundixf.S
  stable/11/contrib/compiler-rt/lib/cfi/cfi.cc
  stable/11/contrib/compiler-rt/lib/dfsan/dfsan.cc
  stable/11/contrib/compiler-rt/lib/interception/interception_win.cc
  stable/11/contrib/compiler-rt/lib/interception/interception_win.h
  stable/11/contrib/compiler-rt/lib/lsan/lsan.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan.h
  stable/11/contrib/compiler-rt/lib/lsan/lsan_allocator.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_common.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_common.h
  stable/11/contrib/compiler-rt/lib/lsan/lsan_common_linux.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_flags.inc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_interceptors.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_thread.cc
  stable/11/contrib/compiler-rt/lib/lsan/lsan_thread.h
  stable/11/contrib/compiler-rt/lib/msan/msan.cc
  stable/11/contrib/compiler-rt/lib/msan/msan.h
  stable/11/contrib/compiler-rt/lib/msan/msan_interceptors.cc
  stable/11/contrib/compiler-rt/lib/msan/msan_linux.cc
  stable/11/contrib/compiler-rt/lib/msan/msan_report.cc
  stable/11/contrib/compiler-rt/lib/profile/GCDAProfiling.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfData.inc
  stable/11/contrib/compiler-rt/lib/profile/InstrProfiling.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfiling.h
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingBuffer.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingFile.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingInternal.h
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingPlatformDarwin.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingPlatformLinux.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingPlatformOther.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingPort.h
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingUtil.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingUtil.h
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingValue.c
  stable/11/contrib/compiler-rt/lib/profile/InstrProfilingWriter.c
  stable/11/contrib/compiler-rt/lib/profile/WindowsMMap.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_allocator.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_allocator_interface.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_allocator_internal.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_atomic_msvc.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors.inc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common_nolibc.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_common_syscalls.inc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_coverage_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_coverage_mapping_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_deadlock_detector1.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_deadlock_detector_interface.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_flags.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_flags.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_flags.inc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_interface_internal.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_libc.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_libc.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_list.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_mac.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_linux.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_posix.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_posix.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_procmaps.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_common.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_quarantine.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_stacktrace.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_stacktrace_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_internal.h
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_mac.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_win.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_thread_registry.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_unwind_linux_libcdep.cc
  stable/11/contrib/compiler-rt/lib/sanitizer_common/sanitizer_win.cc
  stable/11/contrib/compiler-rt/lib/tsan/dd/dd_interceptors.cc
  stable/11/contrib/compiler-rt/lib/tsan/go/test.c
  stable/11/contrib/compiler-rt/lib/tsan/go/tsan_go.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_defs.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_flags.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_flags.inc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interceptors.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interceptors.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interceptors_mac.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interface.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interface_atomic.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_interface_java.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_libdispatch_mac.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_malloc_mac.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_mman.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_mman.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_mutex.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_mutex.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_new_delete.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_platform.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_platform_linux.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_platform_mac.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_platform_posix.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_report.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_report.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl_mutex.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl_report.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_rtl_thread.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_stat.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_stat.h
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_suppressions.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_sync.cc
  stable/11/contrib/compiler-rt/lib/tsan/rtl/tsan_sync.h
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_diag.cc
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_flags.cc
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_handlers.cc
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_handlers.h
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_handlers_cxx.cc
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_handlers_cxx.h
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_platform.h
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_type_hash.h
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cc
  stable/11/contrib/compiler-rt/lib/ubsan/ubsan_value.cc
  stable/11/contrib/libc++/CREDITS.TXT
  stable/11/contrib/libc++/LICENSE.TXT
  stable/11/contrib/libc++/include/__config
  stable/11/contrib/libc++/include/__functional_base
  stable/11/contrib/libc++/include/__hash_table
  stable/11/contrib/libc++/include/__mutex_base
  stable/11/contrib/libc++/include/__tree
  stable/11/contrib/libc++/include/__tuple
  stable/11/contrib/libc++/include/__undef___deallocate
  stable/11/contrib/libc++/include/__undef_min_max
  stable/11/contrib/libc++/include/algorithm
  stable/11/contrib/libc++/include/array
  stable/11/contrib/libc++/include/atomic
  stable/11/contrib/libc++/include/bitset
  stable/11/contrib/libc++/include/cctype
  stable/11/contrib/libc++/include/cmath
  stable/11/contrib/libc++/include/complex
  stable/11/contrib/libc++/include/cstring
  stable/11/contrib/libc++/include/cwchar
  stable/11/contrib/libc++/include/deque
  stable/11/contrib/libc++/include/exception
  stable/11/contrib/libc++/include/experimental/__config
  stable/11/contrib/libc++/include/experimental/algorithm
  stable/11/contrib/libc++/include/experimental/any
  stable/11/contrib/libc++/include/experimental/dynarray
  stable/11/contrib/libc++/include/experimental/functional
  stable/11/contrib/libc++/include/experimental/optional
  stable/11/contrib/libc++/include/experimental/string_view
  stable/11/contrib/libc++/include/experimental/tuple
  stable/11/contrib/libc++/include/ext/hash_map
  stable/11/contrib/libc++/include/ext/hash_set
  stable/11/contrib/libc++/include/forward_list
  stable/11/contrib/libc++/include/fstream
  stable/11/contrib/libc++/include/functional
  stable/11/contrib/libc++/include/future
  stable/11/contrib/libc++/include/iomanip
  stable/11/contrib/libc++/include/ios
  stable/11/contrib/libc++/include/iosfwd
  stable/11/contrib/libc++/include/istream
  stable/11/contrib/libc++/include/iterator
  stable/11/contrib/libc++/include/list
  stable/11/contrib/libc++/include/locale
  stable/11/contrib/libc++/include/map
  stable/11/contrib/libc++/include/memory
  stable/11/contrib/libc++/include/mutex
  stable/11/contrib/libc++/include/queue
  stable/11/contrib/libc++/include/shared_mutex
  stable/11/contrib/libc++/include/stack
  stable/11/contrib/libc++/include/stdexcept
  stable/11/contrib/libc++/include/streambuf
  stable/11/contrib/libc++/include/string
  stable/11/contrib/libc++/include/thread
  stable/11/contrib/libc++/include/tuple
  stable/11/contrib/libc++/include/type_traits
  stable/11/contrib/libc++/include/unordered_map
  stable/11/contrib/libc++/include/unordered_set
  stable/11/contrib/libc++/include/utility
  stable/11/contrib/libc++/include/vector
  stable/11/contrib/libc++/include/wchar.h
  stable/11/contrib/libc++/src/algorithm.cpp
  stable/11/contrib/libc++/src/bind.cpp
  stable/11/contrib/libc++/src/condition_variable.cpp
  stable/11/contrib/libc++/src/locale.cpp
  stable/11/contrib/libc++/src/memory.cpp
  stable/11/contrib/libc++/src/mutex.cpp
  stable/11/contrib/libc++/src/regex.cpp
  stable/11/contrib/libc++/src/strstream.cpp
  stable/11/contrib/libc++/src/system_error.cpp
  stable/11/contrib/libc++/src/thread.cpp
  stable/11/contrib/llvm/LICENSE.TXT
  stable/11/contrib/llvm/include/llvm-c/Core.h
  stable/11/contrib/llvm/include/llvm-c/Disassembler.h
  stable/11/contrib/llvm/include/llvm-c/ErrorHandling.h
  stable/11/contrib/llvm/include/llvm-c/Linker.h
  stable/11/contrib/llvm/include/llvm-c/OrcBindings.h
  stable/11/contrib/llvm/include/llvm-c/Target.h
  stable/11/contrib/llvm/include/llvm-c/TargetMachine.h
  stable/11/contrib/llvm/include/llvm-c/Transforms/Scalar.h
  stable/11/contrib/llvm/include/llvm-c/Types.h
  stable/11/contrib/llvm/include/llvm-c/lto.h
  stable/11/contrib/llvm/include/llvm/ADT/APFloat.h
  stable/11/contrib/llvm/include/llvm/ADT/APInt.h
  stable/11/contrib/llvm/include/llvm/ADT/ArrayRef.h
  stable/11/contrib/llvm/include/llvm/ADT/BitVector.h
  stable/11/contrib/llvm/include/llvm/ADT/DenseMap.h
  stable/11/contrib/llvm/include/llvm/ADT/DenseMapInfo.h
  stable/11/contrib/llvm/include/llvm/ADT/DenseSet.h
  stable/11/contrib/llvm/include/llvm/ADT/FoldingSet.h
  stable/11/contrib/llvm/include/llvm/ADT/GraphTraits.h
  stable/11/contrib/llvm/include/llvm/ADT/Hashing.h
  stable/11/contrib/llvm/include/llvm/ADT/PointerEmbeddedInt.h
  stable/11/contrib/llvm/include/llvm/ADT/PostOrderIterator.h
  stable/11/contrib/llvm/include/llvm/ADT/SCCIterator.h
  stable/11/contrib/llvm/include/llvm/ADT/STLExtras.h
  stable/11/contrib/llvm/include/llvm/ADT/SetVector.h
  stable/11/contrib/llvm/include/llvm/ADT/SmallBitVector.h
  stable/11/contrib/llvm/include/llvm/ADT/SmallPtrSet.h
  stable/11/contrib/llvm/include/llvm/ADT/SmallSet.h
  stable/11/contrib/llvm/include/llvm/ADT/SmallVector.h
  stable/11/contrib/llvm/include/llvm/ADT/SparseSet.h
  stable/11/contrib/llvm/include/llvm/ADT/Statistic.h
  stable/11/contrib/llvm/include/llvm/ADT/StringExtras.h
  stable/11/contrib/llvm/include/llvm/ADT/StringMap.h
  stable/11/contrib/llvm/include/llvm/ADT/StringRef.h
  stable/11/contrib/llvm/include/llvm/ADT/StringSet.h
  stable/11/contrib/llvm/include/llvm/ADT/TinyPtrVector.h
  stable/11/contrib/llvm/include/llvm/ADT/Triple.h
  stable/11/contrib/llvm/include/llvm/ADT/ilist.h
  stable/11/contrib/llvm/include/llvm/ADT/iterator.h
  stable/11/contrib/llvm/include/llvm/Analysis/AliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/AliasSetTracker.h
  stable/11/contrib/llvm/include/llvm/Analysis/AssumptionCache.h
  stable/11/contrib/llvm/include/llvm/Analysis/BasicAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/BlockFrequencyInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/BlockFrequencyInfoImpl.h
  stable/11/contrib/llvm/include/llvm/Analysis/BranchProbabilityInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/CGSCCPassManager.h
  stable/11/contrib/llvm/include/llvm/Analysis/CallGraph.h
  stable/11/contrib/llvm/include/llvm/Analysis/CallGraphSCCPass.h
  stable/11/contrib/llvm/include/llvm/Analysis/CallPrinter.h
  stable/11/contrib/llvm/include/llvm/Analysis/CodeMetrics.h
  stable/11/contrib/llvm/include/llvm/Analysis/ConstantFolding.h
  stable/11/contrib/llvm/include/llvm/Analysis/DemandedBits.h
  stable/11/contrib/llvm/include/llvm/Analysis/DependenceAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/DominanceFrontier.h
  stable/11/contrib/llvm/include/llvm/Analysis/EHPersonalities.h
  stable/11/contrib/llvm/include/llvm/Analysis/GlobalsModRef.h
  stable/11/contrib/llvm/include/llvm/Analysis/IVUsers.h
  stable/11/contrib/llvm/include/llvm/Analysis/InlineCost.h
  stable/11/contrib/llvm/include/llvm/Analysis/InstructionSimplify.h
  stable/11/contrib/llvm/include/llvm/Analysis/Interval.h
  stable/11/contrib/llvm/include/llvm/Analysis/IteratedDominanceFrontier.h
  stable/11/contrib/llvm/include/llvm/Analysis/LazyCallGraph.h
  stable/11/contrib/llvm/include/llvm/Analysis/LazyValueInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/Loads.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopAccessAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopInfoImpl.h
  stable/11/contrib/llvm/include/llvm/Analysis/LoopPass.h
  stable/11/contrib/llvm/include/llvm/Analysis/MemoryBuiltins.h
  stable/11/contrib/llvm/include/llvm/Analysis/MemoryDependenceAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/MemoryLocation.h
  stable/11/contrib/llvm/include/llvm/Analysis/ObjCARCAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/ObjCARCAnalysisUtils.h
  stable/11/contrib/llvm/include/llvm/Analysis/ObjCARCInstKind.h
  stable/11/contrib/llvm/include/llvm/Analysis/Passes.h
  stable/11/contrib/llvm/include/llvm/Analysis/PostDominators.h
  stable/11/contrib/llvm/include/llvm/Analysis/RegionInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/RegionInfoImpl.h
  stable/11/contrib/llvm/include/llvm/Analysis/ScalarEvolution.h
  stable/11/contrib/llvm/include/llvm/Analysis/ScalarEvolutionAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpander.h
  stable/11/contrib/llvm/include/llvm/Analysis/ScalarEvolutionExpressions.h
  stable/11/contrib/llvm/include/llvm/Analysis/ScopedNoAliasAA.h
  stable/11/contrib/llvm/include/llvm/Analysis/SparsePropagation.h
  stable/11/contrib/llvm/include/llvm/Analysis/TargetLibraryInfo.def
  stable/11/contrib/llvm/include/llvm/Analysis/TargetLibraryInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/TargetTransformInfo.h
  stable/11/contrib/llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
  stable/11/contrib/llvm/include/llvm/Analysis/TypeBasedAliasAnalysis.h
  stable/11/contrib/llvm/include/llvm/Analysis/ValueTracking.h
  stable/11/contrib/llvm/include/llvm/Analysis/VectorUtils.h
  stable/11/contrib/llvm/include/llvm/AsmParser/Parser.h
  stable/11/contrib/llvm/include/llvm/Bitcode/BitCodes.h
  stable/11/contrib/llvm/include/llvm/Bitcode/BitcodeWriterPass.h
  stable/11/contrib/llvm/include/llvm/Bitcode/BitstreamReader.h
  stable/11/contrib/llvm/include/llvm/Bitcode/BitstreamWriter.h
  stable/11/contrib/llvm/include/llvm/Bitcode/LLVMBitCodes.h
  stable/11/contrib/llvm/include/llvm/Bitcode/ReaderWriter.h
  stable/11/contrib/llvm/include/llvm/CodeGen/Analysis.h
  stable/11/contrib/llvm/include/llvm/CodeGen/AsmPrinter.h
  stable/11/contrib/llvm/include/llvm/CodeGen/BasicTTIImpl.h
  stable/11/contrib/llvm/include/llvm/CodeGen/CallingConvLower.h
  stable/11/contrib/llvm/include/llvm/CodeGen/CommandFlags.h
  stable/11/contrib/llvm/include/llvm/CodeGen/DFAPacketizer.h
  stable/11/contrib/llvm/include/llvm/CodeGen/DIE.h
  stable/11/contrib/llvm/include/llvm/CodeGen/DIEValue.def
  stable/11/contrib/llvm/include/llvm/CodeGen/FastISel.h
  stable/11/contrib/llvm/include/llvm/CodeGen/FaultMaps.h
  stable/11/contrib/llvm/include/llvm/CodeGen/FunctionLoweringInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/GCMetadata.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ISDOpcodes.h
  stable/11/contrib/llvm/include/llvm/CodeGen/LiveInterval.h
  stable/11/contrib/llvm/include/llvm/CodeGen/LiveIntervalAnalysis.h
  stable/11/contrib/llvm/include/llvm/CodeGen/LivePhysRegs.h
  stable/11/contrib/llvm/include/llvm/CodeGen/LiveRangeEdit.h
  stable/11/contrib/llvm/include/llvm/CodeGen/LiveVariables.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MIRParser/MIRParser.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MIRYamlMapping.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineBasicBlock.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineBlockFrequencyInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineCombinerPattern.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineDominators.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineFrameInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineFunction.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineFunctionPass.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineInstr.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineInstrBuilder.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineInstrBundle.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineLoopInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineMemOperand.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineModuleInfoImpls.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineOperand.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineRegisterInfo.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineSSAUpdater.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineScheduler.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineTraceMetrics.h
  stable/11/contrib/llvm/include/llvm/CodeGen/MachineValueType.h
  stable/11/contrib/llvm/include/llvm/CodeGen/PBQP/Graph.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ParallelCG.h
  stable/11/contrib/llvm/include/llvm/CodeGen/Passes.h
  stable/11/contrib/llvm/include/llvm/CodeGen/PseudoSourceValue.h
  stable/11/contrib/llvm/include/llvm/CodeGen/RegAllocPBQP.h
  stable/11/contrib/llvm/include/llvm/CodeGen/RegisterPressure.h
  stable/11/contrib/llvm/include/llvm/CodeGen/RegisterScavenging.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ResourcePriorityQueue.h
  stable/11/contrib/llvm/include/llvm/CodeGen/RuntimeLibcalls.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ScheduleDAG.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ScheduleDAGInstrs.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ScheduleHazardRecognizer.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ScoreboardHazardRecognizer.h
  stable/11/contrib/llvm/include/llvm/CodeGen/SelectionDAG.h
  stable/11/contrib/llvm/include/llvm/CodeGen/SelectionDAGISel.h
  stable/11/contrib/llvm/include/llvm/CodeGen/SelectionDAGNodes.h
  stable/11/contrib/llvm/include/llvm/CodeGen/SlotIndexes.h
  stable/11/contrib/llvm/include/llvm/CodeGen/StackMaps.h
  stable/11/contrib/llvm/include/llvm/CodeGen/StackProtector.h
  stable/11/contrib/llvm/include/llvm/CodeGen/TargetLoweringObjectFileImpl.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ValueTypes.h
  stable/11/contrib/llvm/include/llvm/CodeGen/ValueTypes.td
  stable/11/contrib/llvm/include/llvm/CodeGen/WinEHFuncInfo.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/CodeView.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/FieldListRecordBuilder.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/Line.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/ListRecordBuilder.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/MemoryTypeTableBuilder.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeIndex.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeRecord.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeRecordBuilder.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/CodeView/TypeTableBuilder.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DIContext.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFCompileUnit.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFContext.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFDebugAbbrev.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFDebugMacro.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFFormValue.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFTypeUnit.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFUnit.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/DWARF/DWARFUnitIndex.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/ConcreteSymbolEnumerator.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIADataStream.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAEnumLineNumbers.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAEnumSourceFiles.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIAEnumSymbols.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIALineNumber.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIARawSymbol.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIASession.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIASourceFile.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/DIA/DIASupport.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBDataStream.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBEnumChildren.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBLineNumber.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBRawSymbol.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBSession.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/IPDBSourceFile.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDB.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBContext.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBExtras.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymDumper.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbol.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolAnnotation.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolBlock.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolCompiland.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolCompilandDetails.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolCompilandEnv.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolCustom.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolData.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolExe.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolFunc.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolFuncDebugEnd.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolFuncDebugStart.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolLabel.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolPublicSymbol.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolThunk.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeArray.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeBaseClass.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeBuiltin.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeCustom.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeDimension.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeEnum.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeFriend.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeFunctionArg.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeFunctionSig.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeManaged.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypePointer.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeTypedef.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeUDT.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeVTable.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolTypeVTableShape.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolUnknown.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBSymbolUsingNamespace.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/PDB/PDBTypes.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/Symbolize/DIPrinter.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/Symbolize/SymbolizableModule.h
  stable/11/contrib/llvm/include/llvm/DebugInfo/Symbolize/Symbolize.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/ExecutionEngine.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/GenericValue.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/JITEventListener.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/JITSymbolFlags.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/CompileUtils.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/IRCompileLayer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/IndirectionUtils.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/JITSymbol.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/LambdaResolver.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/LazyEmittingLayer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/ObjectTransformLayer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcError.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetServer.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/RPCChannel.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/Orc/RPCUtils.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/RTDyldMemoryManager.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/RuntimeDyld.h
  stable/11/contrib/llvm/include/llvm/ExecutionEngine/RuntimeDyldChecker.h
  stable/11/contrib/llvm/include/llvm/IR/Argument.h
  stable/11/contrib/llvm/include/llvm/IR/Attributes.h
  stable/11/contrib/llvm/include/llvm/IR/Attributes.td
  stable/11/contrib/llvm/include/llvm/IR/AutoUpgrade.h
  stable/11/contrib/llvm/include/llvm/IR/BasicBlock.h
  stable/11/contrib/llvm/include/llvm/IR/CFG.h
  stable/11/contrib/llvm/include/llvm/IR/CallSite.h
  stable/11/contrib/llvm/include/llvm/IR/CallingConv.h
  stable/11/contrib/llvm/include/llvm/IR/Comdat.h
  stable/11/contrib/llvm/include/llvm/IR/Constant.h
  stable/11/contrib/llvm/include/llvm/IR/ConstantRange.h
  stable/11/contrib/llvm/include/llvm/IR/Constants.h
  stable/11/contrib/llvm/include/llvm/IR/DIBuilder.h
  stable/11/contrib/llvm/include/llvm/IR/DataLayout.h
  stable/11/contrib/llvm/include/llvm/IR/DebugInfo.h
  stable/11/contrib/llvm/include/llvm/IR/DebugInfoFlags.def
  stable/11/contrib/llvm/include/llvm/IR/DebugInfoMetadata.h
  stable/11/contrib/llvm/include/llvm/IR/DerivedTypes.h
  stable/11/contrib/llvm/include/llvm/IR/DiagnosticInfo.h
  stable/11/contrib/llvm/include/llvm/IR/Dominators.h
  stable/11/contrib/llvm/include/llvm/IR/Function.h
  stable/11/contrib/llvm/include/llvm/IR/GVMaterializer.h
  stable/11/contrib/llvm/include/llvm/IR/GetElementPtrTypeIterator.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalAlias.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalObject.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalValue.h
  stable/11/contrib/llvm/include/llvm/IR/GlobalVariable.h
  stable/11/contrib/llvm/include/llvm/IR/IRBuilder.h
  stable/11/contrib/llvm/include/llvm/IR/IRPrintingPasses.h
  stable/11/contrib/llvm/include/llvm/IR/InlineAsm.h
  stable/11/contrib/llvm/include/llvm/IR/InstrTypes.h
  stable/11/contrib/llvm/include/llvm/IR/Instruction.h
  stable/11/contrib/llvm/include/llvm/IR/Instructions.h
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicInst.h
  stable/11/contrib/llvm/include/llvm/IR/Intrinsics.h
  stable/11/contrib/llvm/include/llvm/IR/Intrinsics.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsAArch64.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsAMDGPU.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsARM.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsHexagon.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsMips.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsNVVM.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsPowerPC.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsSystemZ.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsWebAssembly.td
  stable/11/contrib/llvm/include/llvm/IR/IntrinsicsX86.td
  stable/11/contrib/llvm/include/llvm/IR/LLVMContext.h
  stable/11/contrib/llvm/include/llvm/IR/LegacyPassManagers.h
  stable/11/contrib/llvm/include/llvm/IR/Mangler.h
  stable/11/contrib/llvm/include/llvm/IR/Metadata.def
  stable/11/contrib/llvm/include/llvm/IR/Metadata.h
  stable/11/contrib/llvm/include/llvm/IR/Module.h
  stable/11/contrib/llvm/include/llvm/IR/ModuleSlotTracker.h
  stable/11/contrib/llvm/include/llvm/IR/Operator.h
  stable/11/contrib/llvm/include/llvm/IR/PassManager.h
  stable/11/contrib/llvm/include/llvm/IR/PassManagerInternal.h
  stable/11/contrib/llvm/include/llvm/IR/PatternMatch.h
  stable/11/contrib/llvm/include/llvm/IR/Statepoint.h
  stable/11/contrib/llvm/include/llvm/IR/SymbolTableListTraits.h
  stable/11/contrib/llvm/include/llvm/IR/TrackingMDRef.h
  stable/11/contrib/llvm/include/llvm/IR/Type.h
  stable/11/contrib/llvm/include/llvm/IR/TypeFinder.h
  stable/11/contrib/llvm/include/llvm/IR/Use.h
  stable/11/contrib/llvm/include/llvm/IR/UseListOrder.h
  stable/11/contrib/llvm/include/llvm/IR/User.h
  stable/11/contrib/llvm/include/llvm/IR/Value.def
  stable/11/contrib/llvm/include/llvm/IR/Value.h
  stable/11/contrib/llvm/include/llvm/IR/ValueMap.h
  stable/11/contrib/llvm/include/llvm/IR/ValueSymbolTable.h
  stable/11/contrib/llvm/include/llvm/IR/Verifier.h
  stable/11/contrib/llvm/include/llvm/IRReader/IRReader.h
  stable/11/contrib/llvm/include/llvm/InitializePasses.h
  stable/11/contrib/llvm/include/llvm/LibDriver/LibDriver.h
  stable/11/contrib/llvm/include/llvm/LineEditor/LineEditor.h
  stable/11/contrib/llvm/include/llvm/LinkAllIR.h
  stable/11/contrib/llvm/include/llvm/LinkAllPasses.h
  stable/11/contrib/llvm/include/llvm/Linker/IRMover.h
  stable/11/contrib/llvm/include/llvm/Linker/Linker.h
  stable/11/contrib/llvm/include/llvm/MC/MCAsmBackend.h
  stable/11/contrib/llvm/include/llvm/MC/MCAsmInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCAsmInfoELF.h
  stable/11/contrib/llvm/include/llvm/MC/MCAssembler.h
  stable/11/contrib/llvm/include/llvm/MC/MCContext.h
  stable/11/contrib/llvm/include/llvm/MC/MCDirectives.h
  stable/11/contrib/llvm/include/llvm/MC/MCDwarf.h
  stable/11/contrib/llvm/include/llvm/MC/MCELFObjectWriter.h
  stable/11/contrib/llvm/include/llvm/MC/MCELFStreamer.h
  stable/11/contrib/llvm/include/llvm/MC/MCExpr.h
  stable/11/contrib/llvm/include/llvm/MC/MCFragment.h
  stable/11/contrib/llvm/include/llvm/MC/MCInstPrinter.h
  stable/11/contrib/llvm/include/llvm/MC/MCLinkerOptimizationHint.h
  stable/11/contrib/llvm/include/llvm/MC/MCMachObjectWriter.h
  stable/11/contrib/llvm/include/llvm/MC/MCObjectFileInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCObjectStreamer.h
  stable/11/contrib/llvm/include/llvm/MC/MCObjectWriter.h
  stable/11/contrib/llvm/include/llvm/MC/MCParser/AsmLexer.h
  stable/11/contrib/llvm/include/llvm/MC/MCParser/MCAsmLexer.h
  stable/11/contrib/llvm/include/llvm/MC/MCRegisterInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCSchedule.h
  stable/11/contrib/llvm/include/llvm/MC/MCSection.h
  stable/11/contrib/llvm/include/llvm/MC/MCSectionCOFF.h
  stable/11/contrib/llvm/include/llvm/MC/MCSectionELF.h
  stable/11/contrib/llvm/include/llvm/MC/MCStreamer.h
  stable/11/contrib/llvm/include/llvm/MC/MCSubtargetInfo.h
  stable/11/contrib/llvm/include/llvm/MC/MCSymbol.h
  stable/11/contrib/llvm/include/llvm/MC/MCSymbolMachO.h
  stable/11/contrib/llvm/include/llvm/MC/MCTargetOptions.h
  stable/11/contrib/llvm/include/llvm/MC/MCWin64EH.h
  stable/11/contrib/llvm/include/llvm/MC/MCWinEH.h
  stable/11/contrib/llvm/include/llvm/MC/SectionKind.h
  stable/11/contrib/llvm/include/llvm/MC/StringTableBuilder.h
  stable/11/contrib/llvm/include/llvm/MC/SubtargetFeature.h
  stable/11/contrib/llvm/include/llvm/Object/Archive.h
  stable/11/contrib/llvm/include/llvm/Object/ArchiveWriter.h
  stable/11/contrib/llvm/include/llvm/Object/Binary.h
  stable/11/contrib/llvm/include/llvm/Object/COFF.h
  stable/11/contrib/llvm/include/llvm/Object/ELF.h
  stable/11/contrib/llvm/include/llvm/Object/ELFObjectFile.h
  stable/11/contrib/llvm/include/llvm/Object/ELFTypes.h
  stable/11/contrib/llvm/include/llvm/Object/Error.h
  stable/11/contrib/llvm/include/llvm/Object/IRObjectFile.h
  stable/11/contrib/llvm/include/llvm/Object/MachO.h
  stable/11/contrib/llvm/include/llvm/Object/MachOUniversal.h
  stable/11/contrib/llvm/include/llvm/Object/ObjectFile.h
  stable/11/contrib/llvm/include/llvm/Object/RelocVisitor.h
  stable/11/contrib/llvm/include/llvm/Object/StackMapParser.h
  stable/11/contrib/llvm/include/llvm/Object/SymbolicFile.h
  stable/11/contrib/llvm/include/llvm/Option/OptParser.td
  stable/11/contrib/llvm/include/llvm/Option/Option.h
  stable/11/contrib/llvm/include/llvm/Pass.h
  stable/11/contrib/llvm/include/llvm/PassAnalysisSupport.h
  stable/11/contrib/llvm/include/llvm/PassRegistry.h
  stable/11/contrib/llvm/include/llvm/PassSupport.h
  stable/11/contrib/llvm/include/llvm/Passes/PassBuilder.h
  stable/11/contrib/llvm/include/llvm/ProfileData/InstrProf.h
  stable/11/contrib/llvm/include/llvm/ProfileData/InstrProfData.inc
  stable/11/contrib/llvm/include/llvm/ProfileData/InstrProfReader.h
  stable/11/contrib/llvm/include/llvm/ProfileData/InstrProfWriter.h
  stable/11/contrib/llvm/include/llvm/ProfileData/SampleProf.h
  stable/11/contrib/llvm/include/llvm/ProfileData/SampleProfReader.h
  stable/11/contrib/llvm/include/llvm/ProfileData/SampleProfWriter.h
  stable/11/contrib/llvm/include/llvm/Support/ARMBuildAttributes.h
  stable/11/contrib/llvm/include/llvm/Support/ARMTargetParser.def
  stable/11/contrib/llvm/include/llvm/Support/AlignOf.h
  stable/11/contrib/llvm/include/llvm/Support/Allocator.h
  stable/11/contrib/llvm/include/llvm/Support/Atomic.h
  stable/11/contrib/llvm/include/llvm/Support/BranchProbability.h
  stable/11/contrib/llvm/include/llvm/Support/COFF.h
  stable/11/contrib/llvm/include/llvm/Support/CodeGen.h
  stable/11/contrib/llvm/include/llvm/Support/CommandLine.h
  stable/11/contrib/llvm/include/llvm/Support/Compiler.h
  stable/11/contrib/llvm/include/llvm/Support/ConvertUTF.h
  stable/11/contrib/llvm/include/llvm/Support/CrashRecoveryContext.h
  stable/11/contrib/llvm/include/llvm/Support/Dwarf.def
  stable/11/contrib/llvm/include/llvm/Support/Dwarf.h
  stable/11/contrib/llvm/include/llvm/Support/ELF.h
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/Hexagon.def
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/Mips.def
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/i386.def
  stable/11/contrib/llvm/include/llvm/Support/ELFRelocs/x86_64.def
  stable/11/contrib/llvm/include/llvm/Support/Endian.h
  stable/11/contrib/llvm/include/llvm/Support/EndianStream.h
  stable/11/contrib/llvm/include/llvm/Support/ErrorHandling.h
  stable/11/contrib/llvm/include/llvm/Support/ErrorOr.h
  stable/11/contrib/llvm/include/llvm/Support/FileSystem.h
  stable/11/contrib/llvm/include/llvm/Support/Format.h
  stable/11/contrib/llvm/include/llvm/Support/GenericDomTree.h
  stable/11/contrib/llvm/include/llvm/Support/Host.h
  stable/11/contrib/llvm/include/llvm/Support/JamCRC.h
  stable/11/contrib/llvm/include/llvm/Support/Locale.h
  stable/11/contrib/llvm/include/llvm/Support/LockFileManager.h
  stable/11/contrib/llvm/include/llvm/Support/MD5.h
  stable/11/contrib/llvm/include/llvm/Support/MachO.h
  stable/11/contrib/llvm/include/llvm/Support/ManagedStatic.h
  stable/11/contrib/llvm/include/llvm/Support/MathExtras.h
  stable/11/contrib/llvm/include/llvm/Support/OnDiskHashTable.h
  stable/11/contrib/llvm/include/llvm/Support/Path.h
  stable/11/contrib/llvm/include/llvm/Support/PointerLikeTypeTraits.h
  stable/11/contrib/llvm/include/llvm/Support/PrettyStackTrace.h
  stable/11/contrib/llvm/include/llvm/Support/Printable.h
  stable/11/contrib/llvm/include/llvm/Support/Process.h
  stable/11/contrib/llvm/include/llvm/Support/Program.h
  stable/11/contrib/llvm/include/llvm/Support/RandomNumberGenerator.h
  stable/11/contrib/llvm/include/llvm/Support/Registry.h
  stable/11/contrib/llvm/include/llvm/Support/ScaledNumber.h
  stable/11/contrib/llvm/include/llvm/Support/Signals.h
  stable/11/contrib/llvm/include/llvm/Support/StreamingMemoryObject.h
  stable/11/contrib/llvm/include/llvm/Support/SwapByteOrder.h
  stable/11/contrib/llvm/include/llvm/Support/TargetParser.h
  stable/11/contrib/llvm/include/llvm/Support/TargetRegistry.h
  stable/11/contrib/llvm/include/llvm/Support/Threading.h
  stable/11/contrib/llvm/include/llvm/Support/Timer.h
  stable/11/contrib/llvm/include/llvm/Support/TrailingObjects.h
  stable/11/contrib/llvm/include/llvm/Support/Unicode.h
  stable/11/contrib/llvm/include/llvm/Support/Valgrind.h
  stable/11/contrib/llvm/include/llvm/Support/YAMLParser.h
  stable/11/contrib/llvm/include/llvm/Support/YAMLTraits.h
  stable/11/contrib/llvm/include/llvm/Support/thread.h
  stable/11/contrib/llvm/include/llvm/Support/type_traits.h
  stable/11/contrib/llvm/include/llvm/TableGen/Record.h
  stable/11/contrib/llvm/include/llvm/TableGen/StringToOffsetTable.h
  stable/11/contrib/llvm/include/llvm/Target/Target.td
  stable/11/contrib/llvm/include/llvm/Target/TargetCallingConv.h
  stable/11/contrib/llvm/include/llvm/Target/TargetCallingConv.td
  stable/11/contrib/llvm/include/llvm/Target/TargetFrameLowering.h
  stable/11/contrib/llvm/include/llvm/Target/TargetInstrInfo.h
  stable/11/contrib/llvm/include/llvm/Target/TargetLowering.h
  stable/11/contrib/llvm/include/llvm/Target/TargetLoweringObjectFile.h
  stable/11/contrib/llvm/include/llvm/Target/TargetMachine.h
  stable/11/contrib/llvm/include/llvm/Target/TargetOpcodes.h
  stable/11/contrib/llvm/include/llvm/Target/TargetOptions.h
  stable/11/contrib/llvm/include/llvm/Target/TargetRecip.h
  stable/11/contrib/llvm/include/llvm/Target/TargetRegisterInfo.h
  stable/11/contrib/llvm/include/llvm/Target/TargetSchedule.td
  stable/11/contrib/llvm/include/llvm/Target/TargetSelectionDAG.td
  stable/11/contrib/llvm/include/llvm/Target/TargetSubtargetInfo.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/ForceFunctionAttrs.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/FunctionImport.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/InferFunctionAttrs.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/InlinerPass.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/PassManagerBuilder.h
  stable/11/contrib/llvm/include/llvm/Transforms/IPO/StripDeadPrototypes.h
  stable/11/contrib/llvm/include/llvm/Transforms/InstCombine/InstCombine.h
  stable/11/contrib/llvm/include/llvm/Transforms/InstCombine/InstCombineWorklist.h
  stable/11/contrib/llvm/include/llvm/Transforms/Instrumentation.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/ADCE.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/EarlyCSE.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/LowerExpectIntrinsic.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/SROA.h
  stable/11/contrib/llvm/include/llvm/Transforms/Scalar/SimplifyCFG.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/BasicBlockUtils.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/BuildLibCalls.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/Cloning.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/CodeExtractor.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/Local.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/LoopUtils.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/LoopVersioning.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/ModuleUtils.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/PromoteMemToReg.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdater.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SSAUpdaterImpl.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SimplifyIndVar.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SimplifyLibCalls.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/SplitModule.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/UnrollLoop.h
  stable/11/contrib/llvm/include/llvm/Transforms/Utils/ValueMapper.h
  stable/11/contrib/llvm/include/llvm/Transforms/Vectorize.h
  stable/11/contrib/llvm/include/llvm/module.modulemap
  stable/11/contrib/llvm/lib/Analysis/AliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/AliasAnalysisEvaluator.cpp
  stable/11/contrib/llvm/lib/Analysis/AliasSetTracker.cpp
  stable/11/contrib/llvm/lib/Analysis/Analysis.cpp
  stable/11/contrib/llvm/lib/Analysis/AssumptionCache.cpp
  stable/11/contrib/llvm/lib/Analysis/BasicAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/BlockFrequencyInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/BlockFrequencyInfoImpl.cpp
  stable/11/contrib/llvm/lib/Analysis/BranchProbabilityInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/CFG.cpp
  stable/11/contrib/llvm/lib/Analysis/CGSCCPassManager.cpp
  stable/11/contrib/llvm/lib/Analysis/CallGraph.cpp
  stable/11/contrib/llvm/lib/Analysis/CallGraphSCCPass.cpp
  stable/11/contrib/llvm/lib/Analysis/CallPrinter.cpp
  stable/11/contrib/llvm/lib/Analysis/CaptureTracking.cpp
  stable/11/contrib/llvm/lib/Analysis/CodeMetrics.cpp
  stable/11/contrib/llvm/lib/Analysis/ConstantFolding.cpp
  stable/11/contrib/llvm/lib/Analysis/CostModel.cpp
  stable/11/contrib/llvm/lib/Analysis/Delinearization.cpp
  stable/11/contrib/llvm/lib/Analysis/DemandedBits.cpp
  stable/11/contrib/llvm/lib/Analysis/DependenceAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/DivergenceAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/DomPrinter.cpp
  stable/11/contrib/llvm/lib/Analysis/DominanceFrontier.cpp
  stable/11/contrib/llvm/lib/Analysis/EHPersonalities.cpp
  stable/11/contrib/llvm/lib/Analysis/GlobalsModRef.cpp
  stable/11/contrib/llvm/lib/Analysis/IVUsers.cpp
  stable/11/contrib/llvm/lib/Analysis/InlineCost.cpp
  stable/11/contrib/llvm/lib/Analysis/InstructionSimplify.cpp
  stable/11/contrib/llvm/lib/Analysis/Interval.cpp
  stable/11/contrib/llvm/lib/Analysis/IntervalPartition.cpp
  stable/11/contrib/llvm/lib/Analysis/IteratedDominanceFrontier.cpp
  stable/11/contrib/llvm/lib/Analysis/LazyCallGraph.cpp
  stable/11/contrib/llvm/lib/Analysis/LazyValueInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/Lint.cpp
  stable/11/contrib/llvm/lib/Analysis/Loads.cpp
  stable/11/contrib/llvm/lib/Analysis/LoopAccessAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/LoopInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/LoopPass.cpp
  stable/11/contrib/llvm/lib/Analysis/MemDepPrinter.cpp
  stable/11/contrib/llvm/lib/Analysis/MemDerefPrinter.cpp
  stable/11/contrib/llvm/lib/Analysis/MemoryBuiltins.cpp
  stable/11/contrib/llvm/lib/Analysis/MemoryDependenceAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/MemoryLocation.cpp
  stable/11/contrib/llvm/lib/Analysis/ObjCARCAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/ObjCARCInstKind.cpp
  stable/11/contrib/llvm/lib/Analysis/PHITransAddr.cpp
  stable/11/contrib/llvm/lib/Analysis/PostDominators.cpp
  stable/11/contrib/llvm/lib/Analysis/RegionInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/RegionPrinter.cpp
  stable/11/contrib/llvm/lib/Analysis/ScalarEvolution.cpp
  stable/11/contrib/llvm/lib/Analysis/ScalarEvolutionAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/ScalarEvolutionExpander.cpp
  stable/11/contrib/llvm/lib/Analysis/ScalarEvolutionNormalization.cpp
  stable/11/contrib/llvm/lib/Analysis/ScopedNoAliasAA.cpp
  stable/11/contrib/llvm/lib/Analysis/SparsePropagation.cpp
  stable/11/contrib/llvm/lib/Analysis/StratifiedSets.h
  stable/11/contrib/llvm/lib/Analysis/TargetLibraryInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/TargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Analysis/Trace.cpp
  stable/11/contrib/llvm/lib/Analysis/TypeBasedAliasAnalysis.cpp
  stable/11/contrib/llvm/lib/Analysis/ValueTracking.cpp
  stable/11/contrib/llvm/lib/Analysis/VectorUtils.cpp
  stable/11/contrib/llvm/lib/AsmParser/LLLexer.cpp
  stable/11/contrib/llvm/lib/AsmParser/LLParser.cpp
  stable/11/contrib/llvm/lib/AsmParser/LLParser.h
  stable/11/contrib/llvm/lib/AsmParser/LLToken.h
  stable/11/contrib/llvm/lib/AsmParser/Parser.cpp
  stable/11/contrib/llvm/lib/Bitcode/Reader/BitReader.cpp
  stable/11/contrib/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
  stable/11/contrib/llvm/lib/Bitcode/Reader/BitstreamReader.cpp
  stable/11/contrib/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
  stable/11/contrib/llvm/lib/Bitcode/Writer/BitcodeWriterPass.cpp
  stable/11/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.cpp
  stable/11/contrib/llvm/lib/Bitcode/Writer/ValueEnumerator.h
  stable/11/contrib/llvm/lib/CodeGen/AggressiveAntiDepBreaker.cpp
  stable/11/contrib/llvm/lib/CodeGen/AggressiveAntiDepBreaker.h
  stable/11/contrib/llvm/lib/CodeGen/Analysis.cpp
  stable/11/contrib/llvm/lib/CodeGen/AntiDepBreaker.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/ARMException.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/AddressPool.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterHandler.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/ByteStreamer.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DIE.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DIEHash.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DbgValueHistoryCalculator.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DbgValueHistoryCalculator.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DebugLocEntry.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCFIException.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfException.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfExpression.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfExpression.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfFile.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfFile.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/EHStreamer.h
  stable/11/contrib/llvm/lib/CodeGen/AsmPrinter/WinException.cpp
  stable/11/contrib/llvm/lib/CodeGen/AtomicExpandPass.cpp
  stable/11/contrib/llvm/lib/CodeGen/BranchFolding.cpp
  stable/11/contrib/llvm/lib/CodeGen/BranchFolding.h
  stable/11/contrib/llvm/lib/CodeGen/CalcSpillWeights.cpp
  stable/11/contrib/llvm/lib/CodeGen/CallingConvLower.cpp
  stable/11/contrib/llvm/lib/CodeGen/CodeGen.cpp
  stable/11/contrib/llvm/lib/CodeGen/CodeGenPrepare.cpp
  stable/11/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.cpp
  stable/11/contrib/llvm/lib/CodeGen/CriticalAntiDepBreaker.h
  stable/11/contrib/llvm/lib/CodeGen/DFAPacketizer.cpp
  stable/11/contrib/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
  stable/11/contrib/llvm/lib/CodeGen/EarlyIfConversion.cpp
  stable/11/contrib/llvm/lib/CodeGen/ExecutionDepsFix.cpp
  stable/11/contrib/llvm/lib/CodeGen/ExpandISelPseudos.cpp
  stable/11/contrib/llvm/lib/CodeGen/ExpandPostRAPseudos.cpp
  stable/11/contrib/llvm/lib/CodeGen/FuncletLayout.cpp
  stable/11/contrib/llvm/lib/CodeGen/GCRootLowering.cpp
  stable/11/contrib/llvm/lib/CodeGen/GlobalMerge.cpp
  stable/11/contrib/llvm/lib/CodeGen/IfConversion.cpp
  stable/11/contrib/llvm/lib/CodeGen/ImplicitNullChecks.cpp
  stable/11/contrib/llvm/lib/CodeGen/InlineSpiller.cpp
  stable/11/contrib/llvm/lib/CodeGen/InterleavedAccessPass.cpp
  stable/11/contrib/llvm/lib/CodeGen/LLVMTargetMachine.cpp
  stable/11/contrib/llvm/lib/CodeGen/LexicalScopes.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveDebugValues.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveDebugVariables.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveDebugVariables.h
  stable/11/contrib/llvm/lib/CodeGen/LiveInterval.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveIntervalAnalysis.cpp
  stable/11/contrib/llvm/lib/CodeGen/LivePhysRegs.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveRangeCalc.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveRangeCalc.h
  stable/11/contrib/llvm/lib/CodeGen/LiveRangeEdit.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveStackAnalysis.cpp
  stable/11/contrib/llvm/lib/CodeGen/LiveVariables.cpp
  stable/11/contrib/llvm/lib/CodeGen/LocalStackSlotAllocation.cpp
  stable/11/contrib/llvm/lib/CodeGen/MIRParser/MILexer.cpp
  stable/11/contrib/llvm/lib/CodeGen/MIRParser/MILexer.h
  stable/11/contrib/llvm/lib/CodeGen/MIRParser/MIParser.cpp
  stable/11/contrib/llvm/lib/CodeGen/MIRParser/MIParser.h
  stable/11/contrib/llvm/lib/CodeGen/MIRParser/MIRParser.cpp
  stable/11/contrib/llvm/lib/CodeGen/MIRPrinter.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineBasicBlock.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineBlockFrequencyInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineBlockPlacement.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineBranchProbabilityInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineCSE.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineCombiner.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineCopyPropagation.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineDominators.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineFunction.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineFunctionPass.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineInstr.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineInstrBundle.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineLICM.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineLoopInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineModuleInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineRegionInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineRegisterInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineSSAUpdater.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineScheduler.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineSink.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineTraceMetrics.cpp
  stable/11/contrib/llvm/lib/CodeGen/MachineVerifier.cpp
  stable/11/contrib/llvm/lib/CodeGen/OptimizePHIs.cpp
  stable/11/contrib/llvm/lib/CodeGen/PHIElimination.cpp
  stable/11/contrib/llvm/lib/CodeGen/ParallelCG.cpp
  stable/11/contrib/llvm/lib/CodeGen/PeepholeOptimizer.cpp
  stable/11/contrib/llvm/lib/CodeGen/PostRASchedulerList.cpp
  stable/11/contrib/llvm/lib/CodeGen/PrologEpilogInserter.cpp
  stable/11/contrib/llvm/lib/CodeGen/PseudoSourceValue.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegAllocBase.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegAllocBase.h
  stable/11/contrib/llvm/lib/CodeGen/RegAllocBasic.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegAllocFast.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegAllocGreedy.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegAllocPBQP.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegisterCoalescer.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegisterPressure.cpp
  stable/11/contrib/llvm/lib/CodeGen/RegisterScavenging.cpp
  stable/11/contrib/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp
  stable/11/contrib/llvm/lib/CodeGen/ScheduleDAGPrinter.cpp
  stable/11/contrib/llvm/lib/CodeGen/ScoreboardHazardRecognizer.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/InstrEmitter.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SDNodeDbgValue.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/StatepointLowering.cpp
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/StatepointLowering.h
  stable/11/contrib/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
  stable/11/contrib/llvm/lib/CodeGen/ShadowStackGCLowering.cpp
  stable/11/contrib/llvm/lib/CodeGen/SjLjEHPrepare.cpp
  stable/11/contrib/llvm/lib/CodeGen/SlotIndexes.cpp
  stable/11/contrib/llvm/lib/CodeGen/SpillPlacement.cpp
  stable/11/contrib/llvm/lib/CodeGen/SpillPlacement.h
  stable/11/contrib/llvm/lib/CodeGen/Spiller.h
  stable/11/contrib/llvm/lib/CodeGen/SplitKit.cpp
  stable/11/contrib/llvm/lib/CodeGen/SplitKit.h
  stable/11/contrib/llvm/lib/CodeGen/StackColoring.cpp
  stable/11/contrib/llvm/lib/CodeGen/StackMapLivenessAnalysis.cpp
  stable/11/contrib/llvm/lib/CodeGen/StackMaps.cpp
  stable/11/contrib/llvm/lib/CodeGen/StackProtector.cpp
  stable/11/contrib/llvm/lib/CodeGen/StackSlotColoring.cpp
  stable/11/contrib/llvm/lib/CodeGen/TailDuplication.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetFrameLoweringImpl.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetInstrInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetLoweringBase.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetRegisterInfo.cpp
  stable/11/contrib/llvm/lib/CodeGen/TargetSchedule.cpp
  stable/11/contrib/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp
  stable/11/contrib/llvm/lib/CodeGen/UnreachableBlockElim.cpp
  stable/11/contrib/llvm/lib/CodeGen/VirtRegMap.cpp
  stable/11/contrib/llvm/lib/CodeGen/WinEHPrepare.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/FieldListRecordBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/ListRecordBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/MemoryTypeTableBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/MethodListRecordBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/TypeRecordBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/CodeView/TypeTableBuilder.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFContext.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFDebugFrame.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFDebugLine.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFDebugMacro.cpp
  stable/11/contrib/llvm/lib/DebugInfo/DWARF/DWARFUnit.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIADataStream.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAEnumDebugStreams.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAEnumLineNumbers.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAEnumSourceFiles.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIAEnumSymbols.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIALineNumber.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIARawSymbol.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIASession.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/DIA/DIASourceFile.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/IPDBSourceFile.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDB.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBContext.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBExtras.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBInterfaceAnchors.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymDumper.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbol.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolAnnotation.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolBlock.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolCompiland.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolCompilandDetails.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolCompilandEnv.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolCustom.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolData.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolExe.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolFunc.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolFuncDebugEnd.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolFuncDebugStart.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolLabel.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolPublicSymbol.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolThunk.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeArray.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeBaseClass.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeBuiltin.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeCustom.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeDimension.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeEnum.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeFriend.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeFunctionArg.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeFunctionSig.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeManaged.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypePointer.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeTypedef.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeUDT.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeVTable.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolTypeVTableShape.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolUnknown.cpp
  stable/11/contrib/llvm/lib/DebugInfo/PDB/PDBSymbolUsingNamespace.cpp
  stable/11/contrib/llvm/lib/DebugInfo/Symbolize/DIPrinter.cpp
  stable/11/contrib/llvm/lib/DebugInfo/Symbolize/SymbolizableObjectFile.cpp
  stable/11/contrib/llvm/lib/DebugInfo/Symbolize/Symbolize.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/ExecutionEngineBindings.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/IntelJITEvents/IntelJITEventListener.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/MCJIT/MCJIT.h
  stable/11/contrib/llvm/lib/ExecutionEngine/OProfileJIT/OProfileWrapper.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/IndirectionUtils.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcCBindings.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcCBindingsStack.h
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcError.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h
  stable/11/contrib/llvm/lib/ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RTDyldMemoryManager.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldCOFF.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldCOFF.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldCheckerImpl.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFX86_64.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOAArch64.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOARM.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOI386.h
  stable/11/contrib/llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOX86_64.h
  stable/11/contrib/llvm/lib/ExecutionEngine/TargetSelect.cpp
  stable/11/contrib/llvm/lib/IR/AsmWriter.cpp
  stable/11/contrib/llvm/lib/IR/AttributeImpl.h
  stable/11/contrib/llvm/lib/IR/Attributes.cpp
  stable/11/contrib/llvm/lib/IR/AutoUpgrade.cpp
  stable/11/contrib/llvm/lib/IR/BasicBlock.cpp
  stable/11/contrib/llvm/lib/IR/Comdat.cpp
  stable/11/contrib/llvm/lib/IR/ConstantFold.cpp
  stable/11/contrib/llvm/lib/IR/ConstantFold.h
  stable/11/contrib/llvm/lib/IR/ConstantRange.cpp
  stable/11/contrib/llvm/lib/IR/Constants.cpp
  stable/11/contrib/llvm/lib/IR/ConstantsContext.h
  stable/11/contrib/llvm/lib/IR/Core.cpp
  stable/11/contrib/llvm/lib/IR/DIBuilder.cpp
  stable/11/contrib/llvm/lib/IR/DataLayout.cpp
  stable/11/contrib/llvm/lib/IR/DebugInfo.cpp
  stable/11/contrib/llvm/lib/IR/DebugInfoMetadata.cpp
  stable/11/contrib/llvm/lib/IR/DebugLoc.cpp
  stable/11/contrib/llvm/lib/IR/DiagnosticInfo.cpp
  stable/11/contrib/llvm/lib/IR/Dominators.cpp
  stable/11/contrib/llvm/lib/IR/Function.cpp
  stable/11/contrib/llvm/lib/IR/GCOV.cpp
  stable/11/contrib/llvm/lib/IR/Globals.cpp
  stable/11/contrib/llvm/lib/IR/IRBuilder.cpp
  stable/11/contrib/llvm/lib/IR/IRPrintingPasses.cpp
  stable/11/contrib/llvm/lib/IR/InlineAsm.cpp
  stable/11/contrib/llvm/lib/IR/Instruction.cpp
  stable/11/contrib/llvm/lib/IR/Instructions.cpp
  stable/11/contrib/llvm/lib/IR/IntrinsicInst.cpp
  stable/11/contrib/llvm/lib/IR/LLVMContext.cpp
  stable/11/contrib/llvm/lib/IR/LLVMContextImpl.cpp
  stable/11/contrib/llvm/lib/IR/LLVMContextImpl.h
  stable/11/contrib/llvm/lib/IR/LegacyPassManager.cpp
  stable/11/contrib/llvm/lib/IR/MDBuilder.cpp
  stable/11/contrib/llvm/lib/IR/Mangler.cpp
  stable/11/contrib/llvm/lib/IR/Metadata.cpp
  stable/11/contrib/llvm/lib/IR/Module.cpp
  stable/11/contrib/llvm/lib/IR/Operator.cpp
  stable/11/contrib/llvm/lib/IR/Pass.cpp
  stable/11/contrib/llvm/lib/IR/PassManager.cpp
  stable/11/contrib/llvm/lib/IR/PassRegistry.cpp
  stable/11/contrib/llvm/lib/IR/Statepoint.cpp
  stable/11/contrib/llvm/lib/IR/Type.cpp
  stable/11/contrib/llvm/lib/IR/TypeFinder.cpp
  stable/11/contrib/llvm/lib/IR/Value.cpp
  stable/11/contrib/llvm/lib/IR/ValueSymbolTable.cpp
  stable/11/contrib/llvm/lib/IR/ValueTypes.cpp
  stable/11/contrib/llvm/lib/IR/Verifier.cpp
  stable/11/contrib/llvm/lib/LTO/LTOCodeGenerator.cpp
  stable/11/contrib/llvm/lib/LTO/LTOModule.cpp
  stable/11/contrib/llvm/lib/LibDriver/LibDriver.cpp
  stable/11/contrib/llvm/lib/LineEditor/LineEditor.cpp
  stable/11/contrib/llvm/lib/Linker/IRMover.cpp
  stable/11/contrib/llvm/lib/Linker/LinkModules.cpp
  stable/11/contrib/llvm/lib/MC/ConstantPools.cpp
  stable/11/contrib/llvm/lib/MC/ELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/MC/MCAsmBackend.cpp
  stable/11/contrib/llvm/lib/MC/MCAsmInfo.cpp
  stable/11/contrib/llvm/lib/MC/MCAsmInfoDarwin.cpp
  stable/11/contrib/llvm/lib/MC/MCAsmInfoELF.cpp
  stable/11/contrib/llvm/lib/MC/MCAsmStreamer.cpp
  stable/11/contrib/llvm/lib/MC/MCAssembler.cpp
  stable/11/contrib/llvm/lib/MC/MCContext.cpp
  stable/11/contrib/llvm/lib/MC/MCDisassembler/Disassembler.cpp
  stable/11/contrib/llvm/lib/MC/MCDisassembler/Disassembler.h
  stable/11/contrib/llvm/lib/MC/MCDisassembler/MCDisassembler.cpp
  stable/11/contrib/llvm/lib/MC/MCDisassembler/MCExternalSymbolizer.cpp
  stable/11/contrib/llvm/lib/MC/MCDisassembler/MCRelocationInfo.cpp
  stable/11/contrib/llvm/lib/MC/MCDwarf.cpp
  stable/11/contrib/llvm/lib/MC/MCELFStreamer.cpp
  stable/11/contrib/llvm/lib/MC/MCExpr.cpp
  stable/11/contrib/llvm/lib/MC/MCFragment.cpp
  stable/11/contrib/llvm/lib/MC/MCInst.cpp
  stable/11/contrib/llvm/lib/MC/MCLabel.cpp
  stable/11/contrib/llvm/lib/MC/MCLinkerOptimizationHint.cpp
  stable/11/contrib/llvm/lib/MC/MCMachOStreamer.cpp
  stable/11/contrib/llvm/lib/MC/MCObjectFileInfo.cpp
  stable/11/contrib/llvm/lib/MC/MCObjectStreamer.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/AsmLexer.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/AsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/COFFAsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/DarwinAsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/ELFAsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/MCAsmLexer.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/MCAsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCParser/MCTargetAsmParser.cpp
  stable/11/contrib/llvm/lib/MC/MCRegisterInfo.cpp
  stable/11/contrib/llvm/lib/MC/MCSection.cpp
  stable/11/contrib/llvm/lib/MC/MCStreamer.cpp
  stable/11/contrib/llvm/lib/MC/MCSymbol.cpp
  stable/11/contrib/llvm/lib/MC/MCValue.cpp
  stable/11/contrib/llvm/lib/MC/MCWin64EH.cpp
  stable/11/contrib/llvm/lib/MC/MCWinEH.cpp
  stable/11/contrib/llvm/lib/MC/MachObjectWriter.cpp
  stable/11/contrib/llvm/lib/MC/StringTableBuilder.cpp
  stable/11/contrib/llvm/lib/MC/SubtargetFeature.cpp
  stable/11/contrib/llvm/lib/MC/WinCOFFObjectWriter.cpp
  stable/11/contrib/llvm/lib/MC/WinCOFFStreamer.cpp
  stable/11/contrib/llvm/lib/Object/Archive.cpp
  stable/11/contrib/llvm/lib/Object/ArchiveWriter.cpp
  stable/11/contrib/llvm/lib/Object/Binary.cpp
  stable/11/contrib/llvm/lib/Object/COFFObjectFile.cpp
  stable/11/contrib/llvm/lib/Object/ELF.cpp
  stable/11/contrib/llvm/lib/Object/ELFObjectFile.cpp
  stable/11/contrib/llvm/lib/Object/Error.cpp
  stable/11/contrib/llvm/lib/Object/IRObjectFile.cpp
  stable/11/contrib/llvm/lib/Object/MachOObjectFile.cpp
  stable/11/contrib/llvm/lib/Object/MachOUniversal.cpp
  stable/11/contrib/llvm/lib/Object/Object.cpp
  stable/11/contrib/llvm/lib/Object/ObjectFile.cpp
  stable/11/contrib/llvm/lib/Object/RecordStreamer.cpp
  stable/11/contrib/llvm/lib/Object/RecordStreamer.h
  stable/11/contrib/llvm/lib/Object/SymbolicFile.cpp
  stable/11/contrib/llvm/lib/Option/OptTable.cpp
  stable/11/contrib/llvm/lib/Option/Option.cpp
  stable/11/contrib/llvm/lib/Passes/PassBuilder.cpp
  stable/11/contrib/llvm/lib/Passes/PassRegistry.def
  stable/11/contrib/llvm/lib/ProfileData/InstrProf.cpp
  stable/11/contrib/llvm/lib/ProfileData/InstrProfReader.cpp
  stable/11/contrib/llvm/lib/ProfileData/InstrProfWriter.cpp
  stable/11/contrib/llvm/lib/ProfileData/SampleProf.cpp
  stable/11/contrib/llvm/lib/ProfileData/SampleProfReader.cpp
  stable/11/contrib/llvm/lib/ProfileData/SampleProfWriter.cpp
  stable/11/contrib/llvm/lib/Support/APFloat.cpp
  stable/11/contrib/llvm/lib/Support/APInt.cpp
  stable/11/contrib/llvm/lib/Support/APSInt.cpp
  stable/11/contrib/llvm/lib/Support/ARMBuildAttrs.cpp
  stable/11/contrib/llvm/lib/Support/Atomic.cpp
  stable/11/contrib/llvm/lib/Support/BranchProbability.cpp
  stable/11/contrib/llvm/lib/Support/CommandLine.cpp
  stable/11/contrib/llvm/lib/Support/ConvertUTFWrapper.cpp
  stable/11/contrib/llvm/lib/Support/CrashRecoveryContext.cpp
  stable/11/contrib/llvm/lib/Support/Dwarf.cpp
  stable/11/contrib/llvm/lib/Support/ErrorHandling.cpp
  stable/11/contrib/llvm/lib/Support/FileUtilities.cpp
  stable/11/contrib/llvm/lib/Support/FoldingSet.cpp
  stable/11/contrib/llvm/lib/Support/Host.cpp
  stable/11/contrib/llvm/lib/Support/IntEqClasses.cpp
  stable/11/contrib/llvm/lib/Support/JamCRC.cpp
  stable/11/contrib/llvm/lib/Support/Locale.cpp
  stable/11/contrib/llvm/lib/Support/LockFileManager.cpp
  stable/11/contrib/llvm/lib/Support/ManagedStatic.cpp
  stable/11/contrib/llvm/lib/Support/MemoryBuffer.cpp
  stable/11/contrib/llvm/lib/Support/Path.cpp
  stable/11/contrib/llvm/lib/Support/PrettyStackTrace.cpp
  stable/11/contrib/llvm/lib/Support/Process.cpp
  stable/11/contrib/llvm/lib/Support/ScaledNumber.cpp
  stable/11/contrib/llvm/lib/Support/Signals.cpp
  stable/11/contrib/llvm/lib/Support/SmallPtrSet.cpp
  stable/11/contrib/llvm/lib/Support/SpecialCaseList.cpp
  stable/11/contrib/llvm/lib/Support/Statistic.cpp
  stable/11/contrib/llvm/lib/Support/StreamingMemoryObject.cpp
  stable/11/contrib/llvm/lib/Support/StringMap.cpp
  stable/11/contrib/llvm/lib/Support/StringRef.cpp
  stable/11/contrib/llvm/lib/Support/TargetParser.cpp
  stable/11/contrib/llvm/lib/Support/TargetRegistry.cpp
  stable/11/contrib/llvm/lib/Support/ThreadPool.cpp
  stable/11/contrib/llvm/lib/Support/Threading.cpp
  stable/11/contrib/llvm/lib/Support/Timer.cpp
  stable/11/contrib/llvm/lib/Support/Triple.cpp
  stable/11/contrib/llvm/lib/Support/Twine.cpp
  stable/11/contrib/llvm/lib/Support/Unix/Memory.inc
  stable/11/contrib/llvm/lib/Support/Unix/Path.inc
  stable/11/contrib/llvm/lib/Support/Unix/Process.inc
  stable/11/contrib/llvm/lib/Support/Unix/Signals.inc
  stable/11/contrib/llvm/lib/Support/Windows/DynamicLibrary.inc
  stable/11/contrib/llvm/lib/Support/Windows/Path.inc
  stable/11/contrib/llvm/lib/Support/Windows/Process.inc
  stable/11/contrib/llvm/lib/Support/Windows/Signals.inc
  stable/11/contrib/llvm/lib/Support/Windows/WindowsSupport.h
  stable/11/contrib/llvm/lib/Support/YAMLParser.cpp
  stable/11/contrib/llvm/lib/Support/YAMLTraits.cpp
  stable/11/contrib/llvm/lib/Support/raw_ostream.cpp
  stable/11/contrib/llvm/lib/TableGen/Record.cpp
  stable/11/contrib/llvm/lib/TableGen/SetTheory.cpp
  stable/11/contrib/llvm/lib/TableGen/TGParser.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64A53Fix835769.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64AddressTypePromotion.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64AdvSIMDScalarPass.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64BranchRelaxation.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64CallingConvention.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64CleanupLocalDynamicTLSPass.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64CollectLOH.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ConditionOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ConditionalCompares.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64DeadRegisterDefinitionsPass.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64FastISel.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64FrameLowering.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64InstrAtomics.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64InstrFormats.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64InstrInfo.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64InstrInfo.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64LoadStoreOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64MachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64PBQPRegAlloc.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64PromoteConstant.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64RegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64RegisterInfo.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedA53.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedA57.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedCyclone.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SchedM1.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64Schedule.td
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64SelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64StorePairSuppress.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64Subtarget.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64Subtarget.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64TargetMachine.h
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/Disassembler/AArch64Disassembler.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/Disassembler/AArch64Disassembler.h
  stable/11/contrib/llvm/lib/Target/AArch64/Disassembler/AArch64ExternalSymbolizer.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/Disassembler/AArch64ExternalSymbolizer.h
  stable/11/contrib/llvm/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/InstPrinter/AArch64InstPrinter.h
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64AddressingModes.h
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64ELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.h
  stable/11/contrib/llvm/lib/Target/AArch64/Utils/AArch64BaseInfo.cpp
  stable/11/contrib/llvm/lib/Target/AArch64/Utils/AArch64BaseInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPU.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPU.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUAlwaysInlinePass.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUAnnotateUniformValues.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUCallingConv.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUFrameLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUISelLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUInstrInfo.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUInstructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUIntrinsicInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUIntrinsicInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUIntrinsics.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUMCInstLower.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUMachineFunction.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUMachineFunction.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUOpenCLImageTypeLoweringPass.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPURegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPURegisterInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDILCFGStructurizer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/AMDKernelCodeT.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/CIInstructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/CaymanInstructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/EvergreenInstructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/InstPrinter/AMDGPUInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/InstPrinter/AMDGPUInstPrinter.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUELFStreamer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUELFStreamer.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUFixupKinds.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCAsmInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCCodeEmitter.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUMCTargetDesc.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/R600MCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Processors.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600ClauseMergePass.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600ControlFlowFinalizer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600Defines.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600EmitClauseMarkers.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600ExpandSpecialInstrs.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600ISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600ISelLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600InstrInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600Instructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600Intrinsics.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600MachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600MachineScheduler.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600MachineScheduler.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600OptimizeVectorRegisters.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600Packetizer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600RegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600RegisterInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/R600Schedule.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIAnnotateControlFlow.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIDefines.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIFixSGPRCopies.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIFoldOperands.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIFrameLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIISelLowering.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInsertWaits.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInstrFormats.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInstrInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInstrInfo.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIInstructions.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIIntrinsics.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SILoadStoreOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SILowerControlFlow.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SILowerI1Copies.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIMachineScheduler.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIMachineScheduler.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIRegisterInfo.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SISchedule.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/SIShrinkInstructions.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/SITypeRewriter.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
  stable/11/contrib/llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h
  stable/11/contrib/llvm/lib/Target/AMDGPU/VIInstrFormats.td
  stable/11/contrib/llvm/lib/Target/AMDGPU/VIInstructions.td
  stable/11/contrib/llvm/lib/Target/ARM/A15SDOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARM.h
  stable/11/contrib/llvm/lib/Target/ARM/ARM.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMAsmPrinter.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMBaseInstrInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMBaseRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMCallingConv.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMCallingConv.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMConstantIslandPass.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMConstantPoolValue.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMExpandPseudoInsts.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMFastISel.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMFrameLowering.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMHazardRecognizer.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMISelLowering.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrFormats.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrInfo.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrThumb.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrThumb2.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMInstrVFP.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMOptimizeBarriersPass.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMSchedule.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMScheduleA8.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMScheduleA9.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMScheduleSwift.td
  stable/11/contrib/llvm/lib/Target/ARM/ARMSelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMSelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMSubtarget.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMTargetMachine.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/ARM/ARMTargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ARMTargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/ARM/InstPrinter/ARMInstPrinter.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackendDarwin.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackendELF.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackendWinCOFF.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMBaseInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMFixupKinds.h
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMachORelocationInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMMachObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/ARM/MLxExpansionPass.cpp
  stable/11/contrib/llvm/lib/Target/ARM/TargetInfo/ARMTargetInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Thumb1FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Thumb1FrameLowering.h
  stable/11/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Thumb1InstrInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/Thumb2ITBlockPass.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/Thumb2InstrInfo.h
  stable/11/contrib/llvm/lib/Target/ARM/Thumb2SizeReduction.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ThumbRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/ARM/ThumbRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/AVR/AVR.h
  stable/11/contrib/llvm/lib/Target/AVR/AVR.td
  stable/11/contrib/llvm/lib/Target/AVR/AVRMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRSelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/AVR/AVRTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/AVR/AVRTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/BPF/BPFAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFFrameLowering.h
  stable/11/contrib/llvm/lib/Target/BPF/BPFISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFISelLowering.h
  stable/11/contrib/llvm/lib/Target/BPF/BPFInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFInstrInfo.h
  stable/11/contrib/llvm/lib/Target/BPF/BPFMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFSubtarget.h
  stable/11/contrib/llvm/lib/Target/BPF/BPFTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/BPF/BPFTargetMachine.h
  stable/11/contrib/llvm/lib/Target/BPF/MCTargetDesc/BPFAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/BPF/MCTargetDesc/BPFELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/BPF/MCTargetDesc/BPFMCAsmInfo.h
  stable/11/contrib/llvm/lib/Target/BPF/MCTargetDesc/BPFMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/BPF/MCTargetDesc/BPFMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/AsmParser/HexagonAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/BitTracker.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/BitTracker.h
  stable/11/contrib/llvm/lib/Target/Hexagon/Disassembler/HexagonDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/Hexagon.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBitSimplify.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBitTracker.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonBitTracker.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonCFGOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonCommonGEP.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonCopyToCombine.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonEarlyIfConv.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonExpandCondsets.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonFixupHwLoops.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonFrameLowering.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonGenExtract.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonGenInsert.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonGenMux.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonGenPredicate.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonHardwareLoops.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonISelLowering.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrAlias.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrFormatsV4.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfoV3.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfoV4.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfoV60.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonInstrInfoVector.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonIntrinsics.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonIntrinsicsV4.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonIntrinsicsV5.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonIntrinsicsV60.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonMachineScheduler.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonNewValueJump.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonOperands.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonOptimizeSZextends.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonPeephole.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonRDF.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonRDFOpt.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonRegisterInfo.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonScheduleV4.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonScheduleV55.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonScheduleV60.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSplitConst32AndConst64.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSplitDouble.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonStoreWidening.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSubtarget.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonSystemInst.td
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonTargetMachine.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonTargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonVLIWPacketizer.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/HexagonVLIWPacketizer.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonBaseInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonFixupKinds.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCAsmInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCChecker.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCChecker.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCDuplexInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCELFStreamer.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInstrInfo.h
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCShuffler.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFCopy.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFCopy.h
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFDeadCode.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFDeadCode.h
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFGraph.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFGraph.h
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFLiveness.cpp
  stable/11/contrib/llvm/lib/Target/Hexagon/RDFLiveness.h
  stable/11/contrib/llvm/lib/Target/MSP430/MCTargetDesc/MSP430MCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430BranchSelector.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430FrameLowering.h
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430ISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430ISelLowering.h
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430InstrInfo.h
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430Subtarget.h
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/MSP430/MSP430TargetMachine.h
  stable/11/contrib/llvm/lib/Target/Mips/AsmParser/MipsAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Mips/InstPrinter/MipsInstPrinter.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsABIFlagsSection.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsABIFlagsSection.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsABIInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsABIInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsAsmBackend.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsBaseInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsFixupKinds.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCExpr.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCExpr.h
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MCTargetDesc/MipsTargetStreamer.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MicroMips32r6InstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMips32r6InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMips64r6InstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMips64r6InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMipsDSPInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMipsDSPInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMipsInstrFPU.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMipsInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MicroMipsInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips.h
  stable/11/contrib/llvm/lib/Target/Mips/Mips.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips16FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips16HardFloat.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips16ISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips16ISelDAGToDAG.h
  stable/11/contrib/llvm/lib/Target/Mips/Mips16ISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips16ISelLowering.h
  stable/11/contrib/llvm/lib/Target/Mips/Mips16InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips16InstrInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/Mips16InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips16RegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/Mips32r6InstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips32r6InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips64InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/Mips64r6InstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsAsmPrinter.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsCCState.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsCallingConv.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsCondMov.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsConstantIslandPass.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsDSPInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsDSPInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsEVAInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsFastISel.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsFrameLowering.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsISelDAGToDAG.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsISelLowering.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsInstrFPU.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsInstrInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsLongBranch.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsMCInstLower.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsMSAInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsMachineFunction.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsMachineFunction.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsOs16.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsRegisterInfo.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEISelDAGToDAG.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEISelLowering.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSEInstrInfo.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsSERegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSchedule.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsScheduleP5600.td
  stable/11/contrib/llvm/lib/Target/Mips/MipsSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsSubtarget.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsTargetMachine.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsTargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/Mips/MipsTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/Mips/MipsTargetStreamer.h
  stable/11/contrib/llvm/lib/Target/NVPTX/MCTargetDesc/NVPTXMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/MCTargetDesc/NVPTXMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTX.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTX.td
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXAsmPrinter.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXFavorNonGenericAddrSpaces.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXFrameLowering.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXGenericToNVVM.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXISelDAGToDAG.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXISelLowering.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXImageOptimizer.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXInstrInfo.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXInstrInfo.td
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXIntrinsics.td
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXLowerAlloca.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXLowerKernelArgs.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXMCExpr.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXMCExpr.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXPeephole.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXSection.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXSubtarget.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXTargetMachine.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXTargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXTargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXTargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXUtilities.cpp
  stable/11/contrib/llvm/lib/Target/NVPTX/NVPTXUtilities.h
  stable/11/contrib/llvm/lib/Target/NVPTX/NVVMReflect.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.h
  stable/11/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/MCTargetDesc/PPCMachObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPC.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPC.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCBoolRetToInt.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCBranchSelector.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCCTRLoops.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCCallingConv.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCEarlyReturn.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCFastISel.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCHazardRecognizers.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCISelLowering.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstr64Bit.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrAltivec.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrFormats.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrInfo.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCInstrVSX.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCLoopPreIncPrep.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCMIPeephole.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCSchedule.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCSchedule440.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleA2.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleE500mc.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleE5500.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleG5.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleP7.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCScheduleP8.td
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCSubtarget.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTLSDynamicCall.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTOCRegDeps.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTargetMachine.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCVSXCopy.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCVSXFMAMutate.cpp
  stable/11/contrib/llvm/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/AsmParser/SparcAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/DelaySlotFiller.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/Disassembler/SparcDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/InstPrinter/SparcInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/MCTargetDesc/SparcMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/Sparc.h
  stable/11/contrib/llvm/lib/Target/Sparc/Sparc.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcFrameLowering.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcISelLowering.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstr64Bit.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstrAliases.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstrFormats.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcInstrInfo.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcMCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcRegisterInfo.td
  stable/11/contrib/llvm/lib/Target/Sparc/SparcSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcSubtarget.h
  stable/11/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/Sparc/SparcTargetMachine.h
  stable/11/contrib/llvm/lib/Target/SystemZ/AsmParser/SystemZAsmParser.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/Disassembler/SystemZDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/README.txt
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZ.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZCallingConv.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZCallingConv.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZCallingConv.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZElimCompare.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZFrameLowering.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZISelLowering.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrBuilder.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrFP.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrFormats.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrInfo.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZInstrInfo.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZLDCleanup.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZLongBranch.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZOperands.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZOperators.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZProcessors.td
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZRegisterInfo.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZSelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZSelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZShortenInst.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZSubtarget.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZSubtarget.h
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/SystemZ/SystemZTargetMachine.h
  stable/11/contrib/llvm/lib/Target/Target.cpp
  stable/11/contrib/llvm/lib/Target/TargetLoweringObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/TargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/TargetMachineC.cpp
  stable/11/contrib/llvm/lib/Target/TargetRecip.cpp
  stable/11/contrib/llvm/lib/Target/TargetSubtargetInfo.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/Disassembler/WebAssemblyDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/InstPrinter/WebAssemblyInstPrinter.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyAsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyTargetStreamer.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyTargetStreamer.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/README.txt
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssembly.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyArgumentMove.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyFastISel.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyFrameLowering.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyISD.def
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrFloat.td
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrInfo.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrInfo.td
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrInteger.td
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyInstrMemory.td
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyLowerBrUnless.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyPeephole.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyRegColoring.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyRegNumbering.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyRegStackify.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyRegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblySelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyStoreResults.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblySubtarget.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyTargetMachine.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyTargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/WebAssembly/WebAssemblyTargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/WebAssembly/known_gcc_test_failures.txt
  stable/11/contrib/llvm/lib/Target/X86/AsmParser/X86AsmInstrumentation.cpp
  stable/11/contrib/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
  stable/11/contrib/llvm/lib/Target/X86/AsmParser/X86AsmParserCommon.h
  stable/11/contrib/llvm/lib/Target/X86/AsmParser/X86Operand.h
  stable/11/contrib/llvm/lib/Target/X86/Disassembler/X86Disassembler.cpp
  stable/11/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.cpp
  stable/11/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoder.h
  stable/11/contrib/llvm/lib/Target/X86/Disassembler/X86DisassemblerDecoderCommon.h
  stable/11/contrib/llvm/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp
  stable/11/contrib/llvm/lib/Target/X86/InstPrinter/X86InstComments.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86FixupKinds.h
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86MachObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/X86/MCTargetDesc/X86WinCOFFObjectWriter.cpp
  stable/11/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.cpp
  stable/11/contrib/llvm/lib/Target/X86/Utils/X86ShuffleDecode.h
  stable/11/contrib/llvm/lib/Target/X86/X86.h
  stable/11/contrib/llvm/lib/Target/X86/X86.td
  stable/11/contrib/llvm/lib/Target/X86/X86AsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86AsmPrinter.h
  stable/11/contrib/llvm/lib/Target/X86/X86CallFrameOptimization.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86CallingConv.td
  stable/11/contrib/llvm/lib/Target/X86/X86ExpandPseudo.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FastISel.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FixupLEAs.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FloatingPoint.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86FrameLowering.h
  stable/11/contrib/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86ISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86ISelLowering.h
  stable/11/contrib/llvm/lib/Target/X86/X86InstrAVX512.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrBuilder.h
  stable/11/contrib/llvm/lib/Target/X86/X86InstrCompiler.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrControl.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrFPStack.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrFormats.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrFragmentsSIMD.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86InstrInfo.h
  stable/11/contrib/llvm/lib/Target/X86/X86InstrInfo.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrMMX.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrMPX.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrSSE.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrSystem.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrVMX.td
  stable/11/contrib/llvm/lib/Target/X86/X86InstrXOP.td
  stable/11/contrib/llvm/lib/Target/X86/X86IntrinsicsInfo.h
  stable/11/contrib/llvm/lib/Target/X86/X86MCInstLower.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86MachineFunctionInfo.h
  stable/11/contrib/llvm/lib/Target/X86/X86OptimizeLEAs.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86PadShortFunction.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86RegisterInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86RegisterInfo.td
  stable/11/contrib/llvm/lib/Target/X86/X86Schedule.td
  stable/11/contrib/llvm/lib/Target/X86/X86ScheduleAtom.td
  stable/11/contrib/llvm/lib/Target/X86/X86SelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86SelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/X86/X86ShuffleDecodeConstantPool.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86ShuffleDecodeConstantPool.h
  stable/11/contrib/llvm/lib/Target/X86/X86Subtarget.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86Subtarget.h
  stable/11/contrib/llvm/lib/Target/X86/X86TargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86TargetMachine.h
  stable/11/contrib/llvm/lib/Target/X86/X86TargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86TargetObjectFile.h
  stable/11/contrib/llvm/lib/Target/X86/X86TargetTransformInfo.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86TargetTransformInfo.h
  stable/11/contrib/llvm/lib/Target/X86/X86VZeroUpper.cpp
  stable/11/contrib/llvm/lib/Target/X86/X86WinEHState.cpp
  stable/11/contrib/llvm/lib/Target/XCore/Disassembler/XCoreDisassembler.cpp
  stable/11/contrib/llvm/lib/Target/XCore/MCTargetDesc/XCoreMCTargetDesc.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreAsmPrinter.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreFrameLowering.h
  stable/11/contrib/llvm/lib/Target/XCore/XCoreFrameToArgsOffsetElim.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreISelDAGToDAG.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreISelLowering.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreISelLowering.h
  stable/11/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreInstrInfo.h
  stable/11/contrib/llvm/lib/Target/XCore/XCoreLowerThreadLocal.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreSelectionDAGInfo.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreSelectionDAGInfo.h
  stable/11/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreTargetMachine.h
  stable/11/contrib/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
  stable/11/contrib/llvm/lib/Target/XCore/XCoreTargetObjectFile.h
  stable/11/contrib/llvm/lib/Transforms/IPO/ArgumentPromotion.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/ConstantMerge.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/CrossDSOCFI.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/ElimAvailExtern.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/ExtractGV.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/ForceFunctionAttrs.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/FunctionAttrs.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/FunctionImport.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/GlobalDCE.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/GlobalOpt.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/IPO.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/InferFunctionAttrs.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/InlineAlways.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/InlineSimple.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/Inliner.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/Internalize.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/LoopExtractor.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/MergeFunctions.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/PartialInlining.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/PruneEH.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/SampleProfile.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/StripDeadPrototypes.cpp
  stable/11/contrib/llvm/lib/Transforms/IPO/StripSymbols.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineAddSub.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineInternal.h
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombinePHI.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineSelect.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp
  stable/11/contrib/llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/BoundsChecking.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/CFGMST.h
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/DataFlowSanitizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/Instrumentation.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/MemorySanitizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/SanitizerCoverage.cpp
  stable/11/contrib/llvm/lib/Transforms/Instrumentation/ThreadSanitizer.cpp
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/BlotMapVector.h
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/DependencyAnalysis.h
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARC.cpp
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARC.h
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARCAPElim.cpp
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARCContract.cpp
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARCExpand.cpp
  stable/11/contrib/llvm/lib/Transforms/ObjCARC/ObjCARCOpts.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/ADCE.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/AlignmentFromAssumptions.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/BDCE.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/ConstantHoisting.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/ConstantProp.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/CorrelatedValuePropagation.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/DCE.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/EarlyCSE.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Float2Int.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/GVN.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/InductiveRangeCheckElimination.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/JumpThreading.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LICM.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoadCombine.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopDeletion.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopDistribute.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopInstSimplify.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopInterchange.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopLoadElimination.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopRerollPass.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopRotation.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopUnrollPass.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LoopUnswitch.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LowerAtomic.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/LowerExpectIntrinsic.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/MergedLoadStoreMotion.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/NaryReassociate.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/PartiallyInlineLibCalls.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/PlaceSafepoints.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Reassociate.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Reg2Mem.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/RewriteStatepointsForGC.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/SCCP.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/SROA.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Scalar.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Scalarizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/SimplifyCFGPass.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/Sink.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/SpeculativeExecution.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/StraightLineStrengthReduce.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/StructurizeCFG.cpp
  stable/11/contrib/llvm/lib/Transforms/Scalar/TailRecursionElimination.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/ASanStackFrameLayout.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/AddDiscriminators.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/BreakCriticalEdges.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/BuildLibCalls.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/CloneFunction.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/CloneModule.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/CodeExtractor.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/GlobalStatus.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/InlineFunction.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/InstructionNamer.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/IntegerDivision.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LCSSA.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/Local.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LoopSimplify.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LoopUnroll.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LoopUnrollRuntime.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LoopUtils.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LoopVersioning.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LowerInvoke.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/LowerSwitch.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/Mem2Reg.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/ModuleUtils.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/PromoteMemoryToRegister.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SimplifyCFG.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SimplifyIndVar.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SimplifyInstructions.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SplitModule.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/SymbolRewriter.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/UnifyFunctionExitNodes.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/Utils.cpp
  stable/11/contrib/llvm/lib/Transforms/Utils/ValueMapper.cpp
  stable/11/contrib/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
  stable/11/contrib/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
  stable/11/contrib/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
  stable/11/contrib/llvm/lib/Transforms/Vectorize/Vectorize.cpp
  stable/11/contrib/llvm/tools/bugpoint/BugDriver.h
  stable/11/contrib/llvm/tools/bugpoint/CrashDebugger.cpp
  stable/11/contrib/llvm/tools/bugpoint/ExecutionDriver.cpp
  stable/11/contrib/llvm/tools/bugpoint/ExtractFunction.cpp
  stable/11/contrib/llvm/tools/bugpoint/Miscompilation.cpp
  stable/11/contrib/llvm/tools/bugpoint/OptimizerDriver.cpp
  stable/11/contrib/llvm/tools/bugpoint/ToolRunner.cpp
  stable/11/contrib/llvm/tools/bugpoint/bugpoint.cpp
  stable/11/contrib/llvm/tools/clang/LICENSE.TXT
  stable/11/contrib/llvm/tools/clang/include/clang-c/Index.h
  stable/11/contrib/llvm/tools/clang/include/clang/ARCMigrate/ARCMTActions.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ASTConsumer.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ASTContext.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ASTImporter.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ASTMutationListener.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ASTTypeTraits.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Attr.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/BaseSubobject.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/BuiltinTypes.def
  stable/11/contrib/llvm/tools/clang/include/clang/AST/CanonicalType.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/CharUnits.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Decl.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclBase.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclCXX.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclFriend.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclObjC.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclOpenMP.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclTemplate.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/DeclarationName.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Expr.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ExprCXX.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ExprObjC.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ExprOpenMP.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/ExternalASTSource.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/GlobalDecl.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/LambdaCapture.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Mangle.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/OpenMPClause.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/OperationKinds.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/PrettyPrinter.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/RecordLayout.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/RecursiveASTVisitor.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Stmt.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/StmtCXX.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/StmtGraphTraits.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/StmtObjC.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/StmtOpenMP.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/TemplateBase.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/TemplateName.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/Type.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/TypeLoc.h
  stable/11/contrib/llvm/tools/clang/include/clang/AST/UnresolvedSet.h
  stable/11/contrib/llvm/tools/clang/include/clang/ASTMatchers/ASTMatchFinder.h
  stable/11/contrib/llvm/tools/clang/include/clang/ASTMatchers/ASTMatchers.h
  stable/11/contrib/llvm/tools/clang/include/clang/ASTMatchers/ASTMatchersInternal.h
  stable/11/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/Dominators.h
  stable/11/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/FormatString.h
  stable/11/contrib/llvm/tools/clang/include/clang/Analysis/Analyses/ThreadSafetyUtil.h
  stable/11/contrib/llvm/tools/clang/include/clang/Analysis/AnalysisContext.h
  stable/11/contrib/llvm/tools/clang/include/clang/Analysis/ProgramPoint.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/AddressSpaces.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Attr.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/AttrDocs.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/AttrKinds.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Builtins.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Builtins.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsAArch64.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsAMDGPU.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsARM.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsHexagon.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsNVPTX.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsPPC.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsSystemZ.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsWebAssembly.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/BuiltinsX86.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DeclNodes.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Diagnostic.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticASTKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticCommonKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticDriverKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticFrontendKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticGroups.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticIDs.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticLexKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticParseKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/DiagnosticSemaKinds.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/FileManager.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/IdentifierTable.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Lambda.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/LangOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/ObjCRuntime.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/OpenCLExtensions.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/OpenMPKinds.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/OpenMPKinds.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Sanitizers.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Sanitizers.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/SourceLocation.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/SourceManager.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/Specifiers.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/StmtNodes.td
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/TargetCXXABI.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/TargetInfo.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/TargetOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/TokenKinds.def
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/TypeTraits.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/VersionTuple.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/VirtualFileSystem.h
  stable/11/contrib/llvm/tools/clang/include/clang/Basic/arm_neon.td
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/BackendUtil.h
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/CGFunctionInfo.h
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/CodeGenABITypes.h
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/ModuleBuilder.h
  stable/11/contrib/llvm/tools/clang/include/clang/CodeGen/ObjectFilePCHContainerOperations.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Action.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/CC1Options.td
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/CLCompatOptions.td
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Compilation.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Driver.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Job.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Multilib.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Options.td
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/SanitizerArgs.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/ToolChain.h
  stable/11/contrib/llvm/tools/clang/include/clang/Driver/Types.def
  stable/11/contrib/llvm/tools/clang/include/clang/Format/Format.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/ASTConsumers.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/ASTUnit.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/CodeGenOptions.def
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/CodeGenOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInstance.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/CompilerInvocation.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/DependencyOutputOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/FrontendAction.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/FrontendActions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/FrontendOptions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/LangStandards.def
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/MultiplexConsumer.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/PCHContainerOperations.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/TextDiagnosticPrinter.h
  stable/11/contrib/llvm/tools/clang/include/clang/Frontend/Utils.h
  stable/11/contrib/llvm/tools/clang/include/clang/Index/USRGeneration.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/DirectoryLookup.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/HeaderMap.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/HeaderSearch.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/Lexer.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/LiteralSupport.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/MacroArgs.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/MacroInfo.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/ModuleMap.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/Preprocessor.h
  stable/11/contrib/llvm/tools/clang/include/clang/Lex/Token.h
  stable/11/contrib/llvm/tools/clang/include/clang/Parse/Parser.h
  stable/11/contrib/llvm/tools/clang/include/clang/Rewrite/Frontend/ASTConsumers.h
  stable/11/contrib/llvm/tools/clang/include/clang/Rewrite/Frontend/FrontendActions.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/AttributeList.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/CodeCompleteConsumer.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/DeclSpec.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/ExternalSemaSource.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Initialization.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Lookup.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/MultiplexExternalSemaSource.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/ObjCMethodList.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Overload.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Ownership.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/ParsedTemplate.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Scope.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/Sema.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/SemaInternal.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/SemaLambda.h
  stable/11/contrib/llvm/tools/clang/include/clang/Sema/TemplateDeduction.h
  stable/11/contrib/llvm/tools/clang/include/clang/Serialization/ASTBitCodes.h
  stable/11/contrib/llvm/tools/clang/include/clang/Serialization/ASTReader.h
  stable/11/contrib/llvm/tools/clang/include/clang/Serialization/ASTWriter.h
  stable/11/contrib/llvm/tools/clang/include/clang/Serialization/Module.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitor.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/PathDiagnostic.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/Checker.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CoreEngine.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Environment.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SValBuilder.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SubEngine.h
  stable/11/contrib/llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymbolManager.h
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/CommonOptionsParser.h
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/Core/Replacement.h
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/Refactoring.h
  stable/11/contrib/llvm/tools/clang/include/clang/Tooling/Tooling.h
  stable/11/contrib/llvm/tools/clang/include/clang/module.modulemap
  stable/11/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMT.cpp
  stable/11/contrib/llvm/tools/clang/lib/ARCMigrate/ARCMTActions.cpp
  stable/11/contrib/llvm/tools/clang/lib/ARCMigrate/ObjCMT.cpp
  stable/11/contrib/llvm/tools/clang/lib/ARCMigrate/TransProperties.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/APValue.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTConsumer.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTContext.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTDiagnostic.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTDumper.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTImporter.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ASTTypeTraits.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/CXXInheritance.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Comment.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/CommentLexer.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/CommentSema.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Decl.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclBase.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclOpenMP.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclPrinter.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclTemplate.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/DeclarationName.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Expr.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ExprCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ExprClassification.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ExprConstant.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ItaniumMangle.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Mangle.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/MicrosoftCXXABI.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/MicrosoftMangle.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/NSAPI.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/NestedNameSpecifier.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/OpenMPClause.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/ParentMap.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/RecordLayout.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/RecordLayoutBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Stmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/StmtCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/StmtOpenMP.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/StmtPrinter.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/StmtProfile.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/TemplateBase.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/TemplateName.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/Type.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/TypeLoc.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/TypePrinter.cpp
  stable/11/contrib/llvm/tools/clang/lib/AST/VTableBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/ASTMatchers/ASTMatchFinder.cpp
  stable/11/contrib/llvm/tools/clang/lib/ASTMatchers/ASTMatchersInternal.cpp
  stable/11/contrib/llvm/tools/clang/lib/ASTMatchers/Dynamic/Marshallers.h
  stable/11/contrib/llvm/tools/clang/lib/ASTMatchers/Dynamic/Registry.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/AnalysisDeclContext.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/BodyFarm.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/BodyFarm.h
  stable/11/contrib/llvm/tools/clang/lib/Analysis/CFG.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/CallGraph.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/Consumed.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/FormatString.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/FormatStringParsing.h
  stable/11/contrib/llvm/tools/clang/lib/Analysis/PrintfFormatString.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/PseudoConstantAnalysis.cpp
  stable/11/contrib/llvm/tools/clang/lib/Analysis/ScanfFormatString.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/Builtins.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/Diagnostic.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/DiagnosticIDs.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/FileManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/IdentifierTable.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/LangOptions.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/Module.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/OpenMPKinds.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/OperatorPrecedence.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/SourceManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/TargetInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/Targets.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/Version.cpp
  stable/11/contrib/llvm/tools/clang/lib/Basic/VirtualFileSystem.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/ABIInfo.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/BackendUtil.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGAtomic.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGBlocks.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGBuilder.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGBuiltin.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCUDANV.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCUDARuntime.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCXXABI.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCall.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGClass.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCleanup.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGCleanup.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGDebugInfo.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGDeclCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGException.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGExpr.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGExprAgg.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGExprCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGExprConstant.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGExprScalar.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGLoopInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGLoopInfo.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGObjCGNU.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGObjCMac.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGObjCRuntime.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGOpenCLRuntime.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntime.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGRecordLayout.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGRecordLayoutBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGStmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGStmtOpenMP.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGVTT.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CGValue.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenABITypes.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenAction.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenFunction.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenModule.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTBAA.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CodeGenTypes.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CoverageMappingGen.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/CoverageMappingGen.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/EHScopeStack.h
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/ItaniumCXXABI.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/MicrosoftCXXABI.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/ModuleBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/ObjectFilePCHContainerOperations.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/CodeGen/TargetInfo.h
  stable/11/contrib/llvm/tools/clang/lib/Driver/Action.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/Compilation.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/CrossWindowsToolChain.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/Driver.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/Job.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/MSVCToolChain.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/SanitizerArgs.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/ToolChain.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/ToolChains.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/ToolChains.h
  stable/11/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
  stable/11/contrib/llvm/tools/clang/lib/Driver/Tools.h
  stable/11/contrib/llvm/tools/clang/lib/Driver/Types.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/ContinuationIndenter.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/ContinuationIndenter.h
  stable/11/contrib/llvm/tools/clang/lib/Format/Encoding.h
  stable/11/contrib/llvm/tools/clang/lib/Format/Format.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/FormatToken.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/FormatToken.h
  stable/11/contrib/llvm/tools/clang/lib/Format/TokenAnnotator.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/TokenAnnotator.h
  stable/11/contrib/llvm/tools/clang/lib/Format/UnwrappedLineFormatter.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/UnwrappedLineParser.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/UnwrappedLineParser.h
  stable/11/contrib/llvm/tools/clang/lib/Format/WhitespaceManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/Format/WhitespaceManager.h
  stable/11/contrib/llvm/tools/clang/lib/Frontend/ASTConsumers.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/ASTMerge.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/ASTUnit.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/CacheTokens.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/ChainedIncludesSource.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/CompilerInstance.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/CompilerInvocation.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/DependencyFile.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/DiagnosticRenderer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/FrontendAction.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/FrontendActions.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/HeaderIncludeGen.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/InitHeaderSearch.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/InitPreprocessor.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/LayoutOverrideSource.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/ModuleDependencyCollector.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/MultiplexConsumer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/PCHContainerOperations.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/PrintPreprocessedOutput.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/Rewrite/FrontendActions.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/Rewrite/HTMLPrint.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/Rewrite/InclusionRewriter.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/Rewrite/RewriteObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/SerializedDiagnosticPrinter.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/TestModuleFileExtension.cpp
  stable/11/contrib/llvm/tools/clang/lib/Frontend/TextDiagnostic.cpp
  stable/11/contrib/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
  stable/11/contrib/llvm/tools/clang/lib/Headers/__clang_cuda_runtime_wrapper.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/__wmmintrin_aes.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/__wmmintrin_pclmul.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/altivec.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/ammintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/arm_acle.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx2intrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512bwintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512cdintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512dqintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512erintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512fintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vlbwintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vldqintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avx512vlintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/avxintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/bmiintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/cpuid.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/cuda_builtin_vars.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/emmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/f16cintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/float.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/fma4intrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/fmaintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/htmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/htmxlintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/ia32intrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/immintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/inttypes.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/mm3dnow.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/mmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/module.modulemap
  stable/11/contrib/llvm/tools/clang/lib/Headers/pkuintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/pmmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/popcntintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/smmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/tbmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/tmmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/unwind.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/x86intrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/xmmintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Headers/xopintrin.h
  stable/11/contrib/llvm/tools/clang/lib/Index/CommentToXML.cpp
  stable/11/contrib/llvm/tools/clang/lib/Index/USRGeneration.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/HeaderMap.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/HeaderSearch.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/Lexer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/LiteralSupport.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/MacroInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/ModuleMap.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/PPCaching.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/PPDirectives.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/PPExpressions.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/PPLexerChange.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/PPMacroExpansion.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/Pragma.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/Preprocessor.cpp
  stable/11/contrib/llvm/tools/clang/lib/Lex/TokenLexer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseAST.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseCXXInlineMethods.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseDeclCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseExpr.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseExprCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseInit.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseObjc.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseOpenMP.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParsePragma.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseStmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseStmtAsm.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseTemplate.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/ParseTentative.cpp
  stable/11/contrib/llvm/tools/clang/lib/Parse/Parser.cpp
  stable/11/contrib/llvm/tools/clang/lib/Rewrite/HTMLRewrite.cpp
  stable/11/contrib/llvm/tools/clang/lib/Rewrite/RewriteRope.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/AnalysisBasedWarnings.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/AttributeList.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/CodeCompleteConsumer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/DeclSpec.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/IdentifierResolver.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/JumpDiagnostics.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/MultiplexExternalSemaSource.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/Scope.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/ScopeInfo.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/Sema.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaAccess.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaAttr.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaCUDA.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaCXXScopeSpec.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaCast.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaChecking.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaCodeComplete.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaCoroutine.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclAttr.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaExceptionSpec.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaExpr.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaExprMember.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaExprObjC.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaInit.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLookup.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaObjCProperty.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaOpenMP.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaOverload.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaPseudoObject.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaStmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaStmtAsm.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaStmtAttr.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaTemplate.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaTemplateDeduction.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiate.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaTemplateVariadic.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/SemaType.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/TreeTransform.h
  stable/11/contrib/llvm/tools/clang/lib/Sema/TypeLocBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/Sema/TypeLocBuilder.h
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTCommon.h
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTReader.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTReaderDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTReaderStmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTWriter.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTWriterDecl.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ASTWriterStmt.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/GeneratePCH.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/GlobalModuleIndex.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/Module.cpp
  stable/11/contrib/llvm/tools/clang/lib/Serialization/ModuleManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/AnalyzerStatsChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundCheckerV2.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/BasicObjCFoundationChecks.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CallAndMessageChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckerDocumentation.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ChrootChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ClangCheckers.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ClangSACheckers.h
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DeadStoresChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DereferenceChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DirectIvarAssignment.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ExprInspectionChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/IvarInvalidationChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MacOSXAPIChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/MallocOverflowSecurityChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NSErrorChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/NullabilityChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PaddingChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/PointerArithChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/SimpleStreamChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/StackAddrEscapeChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/TraversalChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UndefBranchChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/UnreachableCodeChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Checkers/VforkChecker.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporter.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CallEvent.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerContext.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerHelpers.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CheckerRegistry.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExplodedGraph.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/IssueHash.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/MemRegion.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PathDiagnostic.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/PlistDiagnostics.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/ProgramState.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/RegionStore.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SValBuilder.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SVals.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Core/SymbolManager.cpp
  stable/11/contrib/llvm/tools/clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/CommonOptionsParser.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/CompilationDatabase.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/Core/Replacement.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/Refactoring.cpp
  stable/11/contrib/llvm/tools/clang/lib/Tooling/Tooling.cpp
  stable/11/contrib/llvm/tools/clang/tools/clang-format/ClangFormat.cpp
  stable/11/contrib/llvm/tools/clang/tools/driver/cc1_main.cpp
  stable/11/contrib/llvm/tools/clang/tools/driver/cc1as_main.cpp
  stable/11/contrib/llvm/tools/clang/tools/driver/driver.cpp
  stable/11/contrib/llvm/tools/clang/utils/TableGen/ClangAttrEmitter.cpp
  stable/11/contrib/llvm/tools/clang/utils/TableGen/ClangDiagnosticsEmitter.cpp
  stable/11/contrib/llvm/tools/clang/utils/TableGen/NeonEmitter.cpp
  stable/11/contrib/llvm/tools/clang/utils/TableGen/TableGen.cpp
  stable/11/contrib/llvm/tools/llc/llc.cpp
  stable/11/contrib/llvm/tools/lld/COFF/CMakeLists.txt
  stable/11/contrib/llvm/tools/lld/ELF/InputFiles.cpp
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/LLDB.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBCommandReturnObject.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBDefines.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBExpressionOptions.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBFileSpec.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBHostOS.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBInstruction.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBLaunchInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBListener.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBProcess.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBStream.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBStringList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBTarget.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBThread.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBThreadCollection.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/API/SBValue.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointLocation.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointLocationCollection.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointLocationList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointResolver.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointResolverFileLine.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointResolverFileRegex.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointResolverName.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointSite.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/BreakpointSiteList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Breakpoint/WatchpointList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ArchSpec.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Broadcaster.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Communication.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ConstString.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/DataExtractor.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Debugger.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/EmulateInstruction.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Event.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/History.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/IOHandler.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Listener.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Logging.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/MappedHash.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Module.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ModuleList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ModuleSpec.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/RangeMap.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/RegisterValue.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Scalar.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/SearchFilter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Section.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/StreamCallback.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/StreamTee.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ThreadSafeSTLMap.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ThreadSafeValue.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Timer.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/UserSettingsController.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/Value.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObject.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectConstResult.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectConstResultCast.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectConstResultChild.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectConstResultImpl.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectDynamicValue.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Core/ValueObjectSyntheticFilter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/DumpValueObjectOptions.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/FormatCache.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/FormatManager.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/FormattersContainer.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/FormattersHelpers.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/TypeCategory.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/TypeCategoryMap.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/TypeSynthetic.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/ValueObjectPrinter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/DataFormatters/VectorIterator.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/DWARFExpression.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/ExpressionParser.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/ExpressionSourceCode.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/ExpressionVariable.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/FunctionCaller.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/IRDynamicChecks.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/IRExecutionUnit.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/IRInterpreter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/IRMemoryMap.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/LLVMUserExpression.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/UserExpression.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Expression/UtilityFunction.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/Editline.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/File.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/FileSpec.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/FileSystem.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/Host.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/HostInfoBase.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/HostNativeProcessBase.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/HostProcess.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/OptionParser.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/ProcessRunLock.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/common/NativeBreakpointList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/common/NativeProcessProtocol.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/posix/ConnectionFileDescriptorPosix.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/posix/HostInfoPosix.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Host/posix/HostProcessPosix.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Initialization/SystemLifetimeManager.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/Args.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandHistory.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandInterpreter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandObject.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/CommandObjectMultiword.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/OptionGroupValueObjectDisplay.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Interpreter/ScriptInterpreter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/ArmUnwindInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Block.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/ClangASTContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/ClangASTImporter.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/CompactUnwindInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/CompileUnit.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/CompilerDecl.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/CompilerDeclContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/CompilerType.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/DWARFCallFrameInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/FuncUnwinders.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Function.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/GoASTContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/LineEntry.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/ObjectFile.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Symbol.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/SymbolContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/SymbolFile.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/SymbolVendor.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Symtab.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Type.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/TypeSystem.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/UnwindPlan.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/UnwindTable.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Symbol/Variable.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ABI.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/DynamicLoader.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ExecutionContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/InstrumentationRuntime.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/JITLoaderList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Language.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/LanguageRuntime.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Memory.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/MemoryRegionInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/PathMappingList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Platform.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Process.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ProcessLaunchInfo.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/QueueList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/RegisterContext.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/SectionLoadHistory.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/SectionLoadList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/StackFrame.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/StackFrameList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Target.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/TargetList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Thread.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ThreadCollection.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ThreadList.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ThreadPlan.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ThreadPlanPython.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/ThreadPlanStepInstruction.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Target/Unwind.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Utility/Iterable.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Utility/ProcessStructReader.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/Utility/SharedCluster.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-enumerations.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-forward.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-private-enumerations.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-private-interfaces.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-private-types.h
  stable/11/contrib/llvm/tools/lldb/include/lldb/lldb-private.h
  stable/11/contrib/llvm/tools/lldb/source/API/SBAddress.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBBlock.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBBreakpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBBreakpointLocation.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBBroadcaster.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBCommandInterpreter.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBCommandReturnObject.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBDebugger.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBExpressionOptions.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBFileSpec.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBFrame.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBFunction.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBHostOS.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBInstruction.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBInstructionList.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBListener.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBModule.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBProcess.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBStringList.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBSymbol.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBTarget.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBThread.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBValue.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SBWatchpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/SystemInitializerFull.cpp
  stable/11/contrib/llvm/tools/lldb/source/API/liblldb.exports
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/Breakpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointLocation.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointLocationCollection.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointLocationList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointResolver.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointResolverAddress.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointResolverFileLine.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointResolverFileRegex.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointResolverName.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointSite.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/BreakpointSiteList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Breakpoint/WatchpointList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandCompletions.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectApropos.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectArgs.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectBreakpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectBreakpointCommand.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectBugreport.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectCommands.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectDisassemble.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectDisassemble.h
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectExpression.h
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectFrame.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectHelp.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectHelp.h
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectLanguage.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectLanguage.h
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectLog.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectMemory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectMultiword.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectPlatform.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectPlugin.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectProcess.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectQuit.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectRegister.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectSettings.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectSource.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectSyntax.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectTarget.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectType.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectVersion.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectWatchpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/Commands/CommandObjectWatchpointCommand.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Address.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/AddressRange.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/AddressResolverName.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ArchSpec.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Broadcaster.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Communication.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ConnectionSharedMemory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ConstString.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/CxaDemangle.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/DataBufferHeap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/DataBufferMemoryMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/DataEncoder.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/DataExtractor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Debugger.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Disassembler.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/DynamicLoader.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/EmulateInstruction.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Error.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Event.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/FastDemangle.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/FileSpecList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/FormatEntity.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/IOHandler.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Listener.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Log.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Logging.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Mangled.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Module.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ModuleList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Opcode.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/PluginManager.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/RegisterValue.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/RegularExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Scalar.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/SearchFilter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Section.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/StreamCallback.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Timer.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/UserSettingsController.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/Value.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObject.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectConstResult.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectConstResultCast.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectConstResultChild.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectConstResultImpl.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectDynamicValue.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectSyntheticFilter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Core/ValueObjectVariable.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/DumpValueObjectOptions.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/FormatCache.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/FormatManager.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/FormattersHelpers.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/StringPrinter.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/TypeCategory.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/TypeCategoryMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/TypeFormat.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/TypeSummary.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/TypeSynthetic.cpp
  stable/11/contrib/llvm/tools/lldb/source/DataFormatters/ValueObjectPrinter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/DWARFExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/ExpressionSourceCode.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/ExpressionVariable.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/FunctionCaller.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/IRDynamicChecks.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/IRExecutionUnit.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/IRInterpreter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/IRMemoryMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/LLVMUserExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/Materializer.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/REPL.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/UserExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Expression/UtilityFunction.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/Editline.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/File.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/FileSpec.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/Host.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/HostInfoBase.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/HostProcess.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/MonitoringProcessLauncher.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/NativeBreakpointList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/NativeProcessProtocol.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/OptionParser.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/Socket.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/SocketAddress.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/SoftwareBreakpoint.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/TCPSocket.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/common/UDPSocket.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/DomainSocket.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/FileSystem.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/HostInfoPosix.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/HostProcessPosix.cpp
  stable/11/contrib/llvm/tools/lldb/source/Host/posix/HostThreadPosix.cpp
  stable/11/contrib/llvm/tools/lldb/source/Initialization/SystemInitializerCommon.cpp
  stable/11/contrib/llvm/tools/lldb/source/Initialization/SystemLifetimeManager.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/Args.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/CommandHistory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/CommandInterpreter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/CommandObject.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/CommandObjectScript.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/OptionGroupValueObjectDisplay.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/OptionValueArray.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/OptionValueFileSpecLIst.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/OptionValuePathMappings.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/OptionValueProperties.cpp
  stable/11/contrib/llvm/tools/lldb/source/Interpreter/Options.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-hexagon/ABISysV_hexagon.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/Hexagon-DYLD/DynamicLoaderHexagonDYLD.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/Hexagon-DYLD/DynamicLoaderHexagonDYLD.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/Static/DynamicLoaderStatic.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/DynamicLoader/Static/DynamicLoaderStatic.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ASTDumper.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ASTResultSynthesizer.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ASTResultSynthesizer.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionDeclMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionDeclMap.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionHelper.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangFunctionCaller.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangFunctionCaller.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangModulesDeclVendor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangPersistentVariables.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangPersistentVariables.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangUserExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangUserExpression.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangUtilityFunction.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/ClangUtilityFunction.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Go/GoAST.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Go/GoUserExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ExpressionParser/Go/GoUserExpression.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM/EmulateInstructionARM.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM/EmulateInstructionARM.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM/EmulationStateARM.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM/EmulationStateARM.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/InstrumentationRuntime/AddressSanitizer/AddressSanitizerRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/JITLoader/GDB/JITLoaderGDB.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/CxxStringTypes.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxx.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxInitializerList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxUnorderedMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibCxxVector.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibStdcpp.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/CPlusPlus/LibStdcpp.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/CF.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/Cocoa.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/Cocoa.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSArray.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSDictionary.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSError.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSException.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSIndexPath.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/NSSet.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/ObjCLanguage.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Language/ObjC/ObjCLanguage.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/Go/GoLanguageRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCClassDescriptorV2.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCClassDescriptorV2.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCDeclVendor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV1.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptRuntime.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/MemoryHistory/asan/MemoryHistoryASan.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectContainer/BSD-Archive/ObjectContainerBSDArchive.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectContainer/BSD-Archive/ObjectContainerBSDArchive.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ELFHeader.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ObjectFile/JIT/ObjectFileJIT.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/NetBSD/PlatformNetBSD.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/NetBSD/PlatformNetBSD.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/FreeBSDThread.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessFreeBSD.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessFreeBSD.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/RegisterContextPOSIXProcessMonitor_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/RegisterContextPOSIXProcessMonitor_powerpc.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/HistoryThread.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/HistoryThread.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/HistoryUnwind.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/HistoryUnwind.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/InferiorCallPOSIX.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_arm64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLLDB.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_arm.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_arm64.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_arm.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_arm64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_i386.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_mips.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_mips64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_powerpc.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/RegisterInfos_x86_64.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/StopInfoMachException.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/Utility/lldb-mips-linux-register-enums.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/ProcessElfCore.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/ThreadElfCore.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/elf-core/ThreadElfCore.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerCommon.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerCommon.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerPlatform.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerPlatform.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DIERef.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DIERef.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParser.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserGo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDIE.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDIE.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDIECollection.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDIECollection.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDeclContext.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/HashedNameToDIE.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDwo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDwo.h
  stable/11/contrib/llvm/tools/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
  stable/11/contrib/llvm/tools/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ArmUnwindInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Block.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ClangASTContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ClangASTImporter.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ClangExternalASTSourceCommon.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/CompactUnwindInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/CompileUnit.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/CompilerDecl.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/CompilerDeclContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/CompilerType.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/DWARFCallFrameInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/FuncUnwinders.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Function.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/GoASTContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/LineEntry.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/LineTable.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/ObjectFile.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Symbol.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/SymbolContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/SymbolFile.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/SymbolVendor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Symtab.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Type.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/TypeSystem.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/UnwindPlan.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/UnwindTable.cpp
  stable/11/contrib/llvm/tools/lldb/source/Symbol/Variable.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ABI.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ExecutionContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/InstrumentationRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/JITLoader.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/JITLoaderList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Language.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/LanguageRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Memory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/MemoryHistory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ObjCLanguageRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/OperatingSystem.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/PathMappingList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Platform.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Process.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ProcessInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ProcessLaunchInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Queue.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/QueueList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/RegisterContext.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/SectionLoadHistory.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/SectionLoadList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/StackFrame.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/StackID.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/StopInfo.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/SystemRuntime.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Target.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/TargetList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/Thread.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadCollection.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadList.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlan.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanCallUserExpression.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanShouldStopHere.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanStepInstruction.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanStepOverRange.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanStepRange.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/ThreadPlanStepThrough.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/UnixSignals.cpp
  stable/11/contrib/llvm/tools/lldb/source/Target/UnwindAssembly.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/ConvertEnum.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/JSON.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/ModuleCache.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/SharingPtr.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/StringExtractor.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/StringExtractorGDBRemote.cpp
  stable/11/contrib/llvm/tools/lldb/source/Utility/StringExtractorGDBRemote.h
  stable/11/contrib/llvm/tools/lldb/source/Utility/TaskPool.cpp
  stable/11/contrib/llvm/tools/lldb/tools/compact-unwind/compact-unwind-dumper.c
  stable/11/contrib/llvm/tools/lldb/tools/driver/Driver.cpp
  stable/11/contrib/llvm/tools/lldb/tools/driver/Driver.h
  stable/11/contrib/llvm/tools/lldb/tools/driver/Platform.cpp
  stable/11/contrib/llvm/tools/lldb/tools/driver/Platform.h
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdBreak.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdData.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdData.h
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdThread.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdThread.h
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmdCmdVar.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmnLLDBDebugSessionInfo.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MICmnLLDBDebuggerHandleEvents.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/MIUtilFileStd.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-mi/Platform.h
  stable/11/contrib/llvm/tools/lldb/tools/lldb-server/lldb-gdbserver.cpp
  stable/11/contrib/llvm/tools/lldb/tools/lldb-server/lldb-server.cpp
  stable/11/contrib/llvm/tools/lli/ChildTarget/ChildTarget.cpp
  stable/11/contrib/llvm/tools/lli/OrcLazyJIT.cpp
  stable/11/contrib/llvm/tools/lli/OrcLazyJIT.h
  stable/11/contrib/llvm/tools/lli/RemoteJITUtils.h
  stable/11/contrib/llvm/tools/lli/lli.cpp
  stable/11/contrib/llvm/tools/llvm-ar/llvm-ar.cpp
  stable/11/contrib/llvm/tools/llvm-as/llvm-as.cpp
  stable/11/contrib/llvm/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
  stable/11/contrib/llvm/tools/llvm-cov/CodeCoverage.cpp
  stable/11/contrib/llvm/tools/llvm-cov/CoverageFilters.h
  stable/11/contrib/llvm/tools/llvm-cov/CoverageReport.cpp
  stable/11/contrib/llvm/tools/llvm-cov/CoverageReport.h
  stable/11/contrib/llvm/tools/llvm-cov/CoverageSummaryInfo.h
  stable/11/contrib/llvm/tools/llvm-cov/CoverageViewOptions.h
  stable/11/contrib/llvm/tools/llvm-cov/RenderingSupport.h
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageView.cpp
  stable/11/contrib/llvm/tools/llvm-cov/SourceCoverageView.h
  stable/11/contrib/llvm/tools/llvm-cov/TestingSupport.cpp
  stable/11/contrib/llvm/tools/llvm-cov/gcov.cpp
  stable/11/contrib/llvm/tools/llvm-cov/llvm-cov.cpp
  stable/11/contrib/llvm/tools/llvm-cxxdump/Error.cpp
  stable/11/contrib/llvm/tools/llvm-cxxdump/llvm-cxxdump.cpp
  stable/11/contrib/llvm/tools/llvm-diff/DiffConsumer.h
  stable/11/contrib/llvm/tools/llvm-diff/DiffLog.cpp
  stable/11/contrib/llvm/tools/llvm-diff/DifferenceEngine.cpp
  stable/11/contrib/llvm/tools/llvm-diff/DifferenceEngine.h
  stable/11/contrib/llvm/tools/llvm-diff/llvm-diff.cpp
  stable/11/contrib/llvm/tools/llvm-dis/llvm-dis.cpp
  stable/11/contrib/llvm/tools/llvm-dwarfdump/llvm-dwarfdump.cpp
  stable/11/contrib/llvm/tools/llvm-extract/llvm-extract.cpp
  stable/11/contrib/llvm/tools/llvm-link/llvm-link.cpp
  stable/11/contrib/llvm/tools/llvm-lto/llvm-lto.cpp
  stable/11/contrib/llvm/tools/llvm-mc/Disassembler.cpp
  stable/11/contrib/llvm/tools/llvm-mc/llvm-mc.cpp
  stable/11/contrib/llvm/tools/llvm-nm/llvm-nm.cpp
  stable/11/contrib/llvm/tools/llvm-objdump/COFFDump.cpp
  stable/11/contrib/llvm/tools/llvm-objdump/MachODump.cpp
  stable/11/contrib/llvm/tools/llvm-objdump/llvm-objdump.cpp
  stable/11/contrib/llvm/tools/llvm-objdump/llvm-objdump.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/BuiltinDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/BuiltinDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/ClassDefinitionDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/ClassDefinitionDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/CompilandDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/CompilandDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/EnumDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/EnumDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/ExternalSymbolDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/ExternalSymbolDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/FunctionDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/FunctionDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/LinePrinter.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/LinePrinter.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/TypeDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/TypeDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/TypedefDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/TypedefDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/VariableDumper.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/VariableDumper.h
  stable/11/contrib/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
  stable/11/contrib/llvm/tools/llvm-pdbdump/llvm-pdbdump.h
  stable/11/contrib/llvm/tools/llvm-profdata/llvm-profdata.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ARMAttributeParser.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ARMAttributeParser.h
  stable/11/contrib/llvm/tools/llvm-readobj/ARMEHABIPrinter.h
  stable/11/contrib/llvm/tools/llvm-readobj/ARMWinEHPrinter.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ARMWinEHPrinter.h
  stable/11/contrib/llvm/tools/llvm-readobj/COFFDumper.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ELFDumper.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/Error.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/MachODumper.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ObjDumper.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/ObjDumper.h
  stable/11/contrib/llvm/tools/llvm-readobj/Win64EHDumper.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/Win64EHDumper.h
  stable/11/contrib/llvm/tools/llvm-readobj/llvm-readobj.cpp
  stable/11/contrib/llvm/tools/llvm-readobj/llvm-readobj.h
  stable/11/contrib/llvm/tools/llvm-rtdyld/llvm-rtdyld.cpp
  stable/11/contrib/llvm/tools/llvm-stress/llvm-stress.cpp
  stable/11/contrib/llvm/tools/llvm-symbolizer/llvm-symbolizer.cpp
  stable/11/contrib/llvm/tools/opt/AnalysisWrappers.cpp
  stable/11/contrib/llvm/tools/opt/BreakpointPrinter.cpp
  stable/11/contrib/llvm/tools/opt/NewPMDriver.cpp
  stable/11/contrib/llvm/tools/opt/NewPMDriver.h
  stable/11/contrib/llvm/tools/opt/opt.cpp
  stable/11/contrib/llvm/utils/TableGen/AsmMatcherEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/AsmWriterEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/AsmWriterInst.cpp
  stable/11/contrib/llvm/utils/TableGen/AsmWriterInst.h
  stable/11/contrib/llvm/utils/TableGen/Attributes.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeEmitterGen.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenDAGPatterns.h
  stable/11/contrib/llvm/utils/TableGen/CodeGenInstruction.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenInstruction.h
  stable/11/contrib/llvm/utils/TableGen/CodeGenIntrinsics.h
  stable/11/contrib/llvm/utils/TableGen/CodeGenMapTable.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenRegisters.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenRegisters.h
  stable/11/contrib/llvm/utils/TableGen/CodeGenSchedule.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenSchedule.h
  stable/11/contrib/llvm/utils/TableGen/CodeGenTarget.cpp
  stable/11/contrib/llvm/utils/TableGen/CodeGenTarget.h
  stable/11/contrib/llvm/utils/TableGen/DAGISelMatcher.cpp
  stable/11/contrib/llvm/utils/TableGen/DAGISelMatcher.h
  stable/11/contrib/llvm/utils/TableGen/DAGISelMatcherEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/DAGISelMatcherGen.cpp
  stable/11/contrib/llvm/utils/TableGen/DAGISelMatcherOpt.cpp
  stable/11/contrib/llvm/utils/TableGen/DFAPacketizerEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/DisassemblerEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/FastISelEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/InstrInfoEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/IntrinsicEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/RegisterInfoEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/SequenceToOffsetTable.h
  stable/11/contrib/llvm/utils/TableGen/SubtargetEmitter.cpp
  stable/11/contrib/llvm/utils/TableGen/TableGen.cpp
  stable/11/contrib/llvm/utils/TableGen/TableGenBackends.h
  stable/11/contrib/llvm/utils/TableGen/X86DisassemblerTables.cpp
  stable/11/contrib/llvm/utils/TableGen/X86RecognizableInstr.cpp
  stable/11/contrib/llvm/utils/TableGen/X86RecognizableInstr.h
  stable/11/etc/mtree/BSD.debug.dist
  stable/11/etc/mtree/BSD.usr.dist
  stable/11/lib/clang/Makefile
  stable/11/lib/clang/clang.build.mk
  stable/11/lib/clang/freebsd_cc_version.h
  stable/11/lib/clang/headers/Makefile
  stable/11/lib/clang/include/clang/Basic/Version.inc
  stable/11/lib/clang/include/clang/Config/config.h
  stable/11/lib/clang/include/llvm/Config/AsmParsers.def
  stable/11/lib/clang/include/llvm/Config/AsmPrinters.def
  stable/11/lib/clang/include/llvm/Config/Disassemblers.def
  stable/11/lib/clang/include/llvm/Config/Targets.def
  stable/11/lib/clang/include/llvm/Config/config.h
  stable/11/lib/clang/include/llvm/Config/llvm-config.h
  stable/11/lib/clang/include/llvm/Support/DataTypes.h
  stable/11/lib/clang/liblldb/Makefile
  stable/11/lib/clang/libllvmminimal/Makefile
  stable/11/lib/libc++/Makefile
  stable/11/lib/libclang_rt/Makefile
  stable/11/lib/libclang_rt/Makefile.inc
  stable/11/lib/libclang_rt/asan-preinit/Makefile
  stable/11/lib/libclang_rt/asan/Makefile
  stable/11/lib/libclang_rt/asan_cxx/Makefile
  stable/11/lib/libclang_rt/asan_dynamic/Makefile
  stable/11/lib/libclang_rt/include/Makefile
  stable/11/lib/libclang_rt/profile/Makefile
  stable/11/lib/libclang_rt/safestack/Makefile
  stable/11/lib/libclang_rt/ubsan_standalone/Makefile
  stable/11/lib/libclang_rt/ubsan_standalone_cxx/Makefile
  stable/11/lib/libcompiler_rt/Makefile
  stable/11/release/packages/clang.ucl
  stable/11/share/mk/local.gendirdeps.mk
  stable/11/share/mk/src.opts.mk
  stable/11/sys/sys/param.h
  stable/11/targets/pseudo/clang/Makefile.depend
  stable/11/tools/build/mk/OptionalObsoleteFiles.inc
  stable/11/usr.bin/clang/Makefile
  stable/11/usr.bin/clang/bugpoint/Makefile
  stable/11/usr.bin/clang/clang-format/Makefile
  stable/11/usr.bin/clang/clang-tblgen/Makefile
  stable/11/usr.bin/clang/clang.prog.mk
  stable/11/usr.bin/clang/clang/Makefile
  stable/11/usr.bin/clang/llc/Makefile
  stable/11/usr.bin/clang/lld/Makefile
  stable/11/usr.bin/clang/lldb/Makefile
  stable/11/usr.bin/clang/lli/Makefile
  stable/11/usr.bin/clang/llvm-ar/Makefile
  stable/11/usr.bin/clang/llvm-as/Makefile
  stable/11/usr.bin/clang/llvm-bcanalyzer/Makefile
  stable/11/usr.bin/clang/llvm-cov/Makefile
  stable/11/usr.bin/clang/llvm-cxxdump/Makefile
  stable/11/usr.bin/clang/llvm-diff/Makefile
  stable/11/usr.bin/clang/llvm-dis/Makefile
  stable/11/usr.bin/clang/llvm-dwarfdump/Makefile
  stable/11/usr.bin/clang/llvm-extract/Makefile
  stable/11/usr.bin/clang/llvm-link/Makefile
  stable/11/usr.bin/clang/llvm-lto/Makefile
  stable/11/usr.bin/clang/llvm-mc/Makefile
  stable/11/usr.bin/clang/llvm-nm/Makefile
  stable/11/usr.bin/clang/llvm-objdump/Makefile
  stable/11/usr.bin/clang/llvm-pdbdump/Makefile
  stable/11/usr.bin/clang/llvm-profdata/Makefile
  stable/11/usr.bin/clang/llvm-rtdyld/Makefile
  stable/11/usr.bin/clang/llvm-symbolizer/Makefile
  stable/11/usr.bin/clang/llvm-tblgen/Makefile
  stable/11/usr.bin/clang/opt/Makefile
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/Makefile.inc1
==============================================================================
--- stable/11/Makefile.inc1	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/Makefile.inc1	Mon Dec 26 20:36:37 2016	(r310618)
@@ -1636,13 +1636,12 @@ _gensnmptree=	usr.sbin/bsnmpd/gensnmptre
 # the bootstrap compiler, or as the part of the normal build.
 .if ${MK_CLANG_BOOTSTRAP} != "no" || ${MK_CLANG} != "no"
 _clang_tblgen= \
-	lib/clang/libllvmsupport \
-	lib/clang/libllvmtablegen \
+	lib/clang/libllvmminimal \
 	usr.bin/clang/llvm-tblgen \
 	usr.bin/clang/clang-tblgen
 
-${_bt}-usr.bin/clang/clang-tblgen: ${_bt}-lib/clang/libllvmtablegen ${_bt}-lib/clang/libllvmsupport
-${_bt}-usr.bin/clang/llvm-tblgen: ${_bt}-lib/clang/libllvmtablegen ${_bt}-lib/clang/libllvmsupport
+${_bt}-usr.bin/clang/clang-tblgen: ${_bt}-lib/clang/libllvmminimal
+${_bt}-usr.bin/clang/llvm-tblgen: ${_bt}-lib/clang/libllvmminimal
 .endif
 
 # Default to building the GPL DTC, but build the BSDL one if users explicitly

Modified: stable/11/ObsoleteFiles.inc
==============================================================================
--- stable/11/ObsoleteFiles.inc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/ObsoleteFiles.inc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -38,6 +38,207 @@
 #   xargs -n1 | sort | uniq -d;
 # done
 
+# 20161217: new clang import which bumps version from 3.9.0 to 3.9.1.
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/allocator_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/asan_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/common_interface_defs.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/coverage_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/dfsan_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/esan_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/linux_syscall_hooks.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/lsan_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/msan_interface.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/sanitizer/tsan_interface_atomic.h
+OLD_DIRS+=usr/lib/clang/3.9.0/include/sanitizer
+OLD_FILES+=usr/lib/clang/3.9.0/include/__clang_cuda_cmath.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__clang_cuda_intrinsics.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__clang_cuda_math_forward_declares.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__clang_cuda_runtime_wrapper.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__stddef_max_align_t.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__wmmintrin_aes.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/__wmmintrin_pclmul.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/adxintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/altivec.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/ammintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/arm_acle.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/arm_neon.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx2intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512bwintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512cdintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512dqintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512erintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512fintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512ifmaintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512ifmavlintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512pfintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vbmiintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vbmivlintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vlbwintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vlcdintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vldqintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avx512vlintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/avxintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/bmi2intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/bmiintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/clflushoptintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/cpuid.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/cuda_builtin_vars.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/emmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/f16cintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/fma4intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/fmaintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/fxsrintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/htmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/htmxlintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/ia32intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/immintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/lzcntintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/mm3dnow.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/mm_malloc.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/mmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/module.modulemap
+OLD_FILES+=usr/lib/clang/3.9.0/include/mwaitxintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/nmmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/opencl-c.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/pkuintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/pmmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/popcntintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/prfchwintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/rdseedintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/rtmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/s390intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/shaintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/smmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/tbmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/tmmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/vadefs.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/vecintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/wmmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/x86intrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xmmintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xopintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xsavecintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xsaveintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xsaveoptintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xsavesintrin.h
+OLD_FILES+=usr/lib/clang/3.9.0/include/xtestintrin.h
+OLD_DIRS+=usr/lib/clang/3.9.0/include
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-i386.so
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-preinit-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-preinit-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan-x86_64.so
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan_cxx-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.asan_cxx-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.profile-arm.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.profile-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.profile-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.safestack-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.safestack-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.stats-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.stats-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.stats_client-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.stats_client-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.ubsan_standalone-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.ubsan_standalone-x86_64.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.ubsan_standalone_cxx-i386.a
+OLD_FILES+=usr/lib/clang/3.9.0/lib/freebsd/libclang_rt.ubsan_standalone_cxx-x86_64.a
+OLD_DIRS+=usr/lib/clang/3.9.0/lib/freebsd
+OLD_DIRS+=usr/lib/clang/3.9.0/lib
+OLD_DIRS+=usr/lib/clang/3.9.0
+# 20161124: new clang import which bumps version from 3.8.0 to 3.9.0.
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/allocator_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/asan_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/common_interface_defs.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/coverage_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/dfsan_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/linux_syscall_hooks.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/lsan_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/msan_interface.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/sanitizer/tsan_interface_atomic.h
+OLD_DIRS+=usr/lib/clang/3.8.0/include/sanitizer
+OLD_FILES+=usr/lib/clang/3.8.0/include/__clang_cuda_runtime_wrapper.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/__stddef_max_align_t.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/__wmmintrin_aes.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/__wmmintrin_pclmul.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/adxintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/altivec.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/ammintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/arm_acle.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/arm_neon.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx2intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512bwintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512cdintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512dqintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512erintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512fintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512vlbwintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512vldqintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avx512vlintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/avxintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/bmi2intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/bmiintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/cpuid.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/cuda_builtin_vars.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/emmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/f16cintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/fma4intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/fmaintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/fxsrintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/htmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/htmxlintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/ia32intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/immintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/lzcntintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/mm3dnow.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/mm_malloc.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/mmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/module.modulemap
+OLD_FILES+=usr/lib/clang/3.8.0/include/nmmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/pkuintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/pmmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/popcntintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/prfchwintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/rdseedintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/rtmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/s390intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/shaintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/smmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/tbmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/tmmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/vadefs.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/vecintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/wmmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/x86intrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xmmintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xopintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xsavecintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xsaveintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xsaveoptintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xsavesintrin.h
+OLD_FILES+=usr/lib/clang/3.8.0/include/xtestintrin.h
+OLD_DIRS+=usr/lib/clang/3.8.0/include
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-i386.so
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-preinit-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-preinit-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan-x86_64.so
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan_cxx-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.asan_cxx-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.profile-arm.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.profile-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.profile-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.safestack-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.safestack-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.ubsan_standalone-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.ubsan_standalone-x86_64.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.ubsan_standalone_cxx-i386.a
+OLD_FILES+=usr/lib/clang/3.8.0/lib/freebsd/libclang_rt.ubsan_standalone_cxx-x86_64.a
+OLD_DIRS+=usr/lib/clang/3.8.0/lib/freebsd
+OLD_DIRS+=usr/lib/clang/3.8.0/lib
+OLD_DIRS+=usr/lib/clang/3.8.0
 # 20161121: Hyper-V manuals only apply to amd64 and i386.
 .if ${TARGET_ARCH} != "amd64" && ${TARGET_ARCH} != "i386"
 OLD_FILES+=usr/share/man/man4/hv_kvp.4.gz

Modified: stable/11/UPDATING
==============================================================================
--- stable/11/UPDATING	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/UPDATING	Mon Dec 26 20:36:37 2016	(r310618)
@@ -16,6 +16,21 @@ from older versions of FreeBSD, try WITH
 the tip of head, and then rebuild without this option. The bootstrap process
 from older version of current across the gcc/clang cutover is a bit fragile.
 
+20161217:
+	Clang, llvm, lldb, compiler-rt and libc++ have been upgraded to 3.9.1.
+	Please see the 20141231 entry below for information about prerequisites
+	and upgrading, if you are not already using clang 3.5.0 or higher.
+
+20161124:
+	Clang, llvm, lldb, compiler-rt and libc++ have been upgraded to 3.9.0.
+	Please see the 20141231 entry below for information about prerequisites
+	and upgrading, if you are not already using clang 3.5.0 or higher.
+
+20161119:
+	The layout of the pmap structure has changed for powerpc to put the pmap
+	statistics at the front for all CPU variations.  libkvm(3) and all tools
+	that link against it need to be recompiled.
+
 20161030:
 	isl(4) and cyapa(4) drivers now require a new driver,
 	chromebook_platform(4), to work properly on Chromebook-class hardware.

Modified: stable/11/contrib/compiler-rt/LICENSE.TXT
==============================================================================
--- stable/11/contrib/compiler-rt/LICENSE.TXT	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/LICENSE.TXT	Mon Dec 26 20:36:37 2016	(r310618)
@@ -14,7 +14,7 @@ Full text of the relevant licenses is in
 University of Illinois/NCSA
 Open Source License
 
-Copyright (c) 2009-2015 by the contributors listed in CREDITS.TXT
+Copyright (c) 2009-2016 by the contributors listed in CREDITS.TXT
 
 All rights reserved.
 

Modified: stable/11/contrib/compiler-rt/include/sanitizer/allocator_interface.h
==============================================================================
--- stable/11/contrib/compiler-rt/include/sanitizer/allocator_interface.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/include/sanitizer/allocator_interface.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -59,6 +59,23 @@ extern "C" {
        deallocation of "ptr". */
   void __sanitizer_malloc_hook(const volatile void *ptr, size_t size);
   void __sanitizer_free_hook(const volatile void *ptr);
+
+  /* Installs a pair of hooks for malloc/free.
+     Several (currently, 5) hook pairs may be installed, they are executed
+     in the order they were installed and after calling
+     __sanitizer_malloc_hook/__sanitizer_free_hook.
+     Unlike __sanitizer_malloc_hook/__sanitizer_free_hook these hooks can be
+     chained and do not rely on weak symbols working on the platform, but
+     require __sanitizer_install_malloc_and_free_hooks to be called at startup
+     and thus will not be called on malloc/free very early in the process.
+     Returns the number of hooks currently installed or 0 on failure.
+     Not thread-safe, should be called in the main thread before starting
+     other threads.
+  */
+  int __sanitizer_install_malloc_and_free_hooks(
+      void (*malloc_hook)(const volatile void *, size_t),
+      void (*free_hook)(const volatile void *));
+
 #ifdef __cplusplus
 }  // extern "C"
 #endif

Modified: stable/11/contrib/compiler-rt/include/sanitizer/common_interface_defs.h
==============================================================================
--- stable/11/contrib/compiler-rt/include/sanitizer/common_interface_defs.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/include/sanitizer/common_interface_defs.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -41,6 +41,9 @@ extern "C" {
 
   // Tell the tools to write their reports to "path.<pid>" instead of stderr.
   void __sanitizer_set_report_path(const char *path);
+  // Tell the tools to write their reports to the provided file descriptor
+  // (casted to void *).
+  void __sanitizer_set_report_fd(void *fd);
 
   // Notify the tools that the sandbox is going to be turned on. The reserved
   // parameter will be used in the future to hold a structure with functions
@@ -128,8 +131,45 @@ extern "C" {
                                     const void *s2, size_t n, int result);
   void __sanitizer_weak_hook_strncmp(void *called_pc, const char *s1,
                                     const char *s2, size_t n, int result);
+  void __sanitizer_weak_hook_strncasecmp(void *called_pc, const char *s1,
+                                         const char *s2, size_t n, int result);
   void __sanitizer_weak_hook_strcmp(void *called_pc, const char *s1,
                                     const char *s2, int result);
+  void __sanitizer_weak_hook_strcasecmp(void *called_pc, const char *s1,
+                                        const char *s2, int result);
+  void __sanitizer_weak_hook_strstr(void *called_pc, const char *s1,
+                                    const char *s2, char *result);
+  void __sanitizer_weak_hook_strcasestr(void *called_pc, const char *s1,
+                                        const char *s2, char *result);
+  void __sanitizer_weak_hook_memmem(void *called_pc,
+                                    const void *s1, size_t len1,
+                                    const void *s2, size_t len2, void *result);
+
+  // Prints stack traces for all live heap allocations ordered by total
+  // allocation size until `top_percent` of total live heap is shown.
+  // `top_percent` should be between 1 and 100.
+  // Experimental feature currently available only with asan on Linux/x86_64.
+  void __sanitizer_print_memory_profile(size_t top_percent);
+
+  // Fiber annotation interface.
+  // Before switching to a different stack, one must call
+  // __sanitizer_start_switch_fiber with a pointer to the bottom of the
+  // destination stack and its size. When code starts running on the new stack,
+  // it must call __sanitizer_finish_switch_fiber to finalize the switch.
+  // The start_switch function takes a void** to store the current fake stack if
+  // there is one (it is needed when detect_stack_use_after_return is enabled).
+  // When restoring a stack, this pointer must be given to the finish_switch
+  // function. In most cases, this void* can be stored on the stack just before
+  // switching.  When leaving a fiber definitely, null must be passed as first
+  // argument to the start_switch function so that the fake stack is destroyed.
+  // If you do not want support for stack use-after-return detection, you can
+  // always pass null to these two functions.
+  // Note that the fake stack mechanism is disabled during fiber switch, so if a
+  // signal callback runs during the switch, it will not benefit from the stack
+  // use-after-return detection.
+  void __sanitizer_start_switch_fiber(void **fake_stack_save,
+                                      const void *bottom, size_t size);
+  void __sanitizer_finish_switch_fiber(void *fake_stack_save);
 #ifdef __cplusplus
 }  // extern "C"
 #endif

Copied: stable/11/contrib/compiler-rt/include/sanitizer/esan_interface.h (from r309124, head/contrib/compiler-rt/include/sanitizer/esan_interface.h)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/11/contrib/compiler-rt/include/sanitizer/esan_interface.h	Mon Dec 26 20:36:37 2016	(r310618, copy of r309124, head/contrib/compiler-rt/include/sanitizer/esan_interface.h)
@@ -0,0 +1,50 @@
+//===-- sanitizer/esan_interface.h ------------------------------*- C++ -*-===//
+//
+//                     The LLVM Compiler Infrastructure
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file is a part of EfficiencySanitizer, a family of performance tuners.
+//
+// Public interface header.
+//===----------------------------------------------------------------------===//
+#ifndef SANITIZER_ESAN_INTERFACE_H
+#define SANITIZER_ESAN_INTERFACE_H
+
+#include <sanitizer/common_interface_defs.h>
+
+// We declare our interface routines as weak to allow the user to avoid
+// ifdefs and instead use this pattern to allow building the same sources
+// with and without our runtime library:
+//     if (__esan_report)
+//       __esan_report();
+#ifdef _MSC_VER
+/* selectany is as close to weak as we'll get. */
+#define COMPILER_RT_WEAK __declspec(selectany)
+#elif __GNUC__
+#define COMPILER_RT_WEAK __attribute__((weak))
+#else
+#define COMPILER_RT_WEAK
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+// This function can be called mid-run (or at the end of a run for
+// a server process that doesn't shut down normally) to request that
+// data for that point in the run be reported from the tool.
+void COMPILER_RT_WEAK __esan_report();
+
+// This function returns the number of samples that the esan tool has collected
+// to this point.  This is useful for testing.
+unsigned int COMPILER_RT_WEAK __esan_get_sample_count();
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // SANITIZER_ESAN_INTERFACE_H

Modified: stable/11/contrib/compiler-rt/include/sanitizer/linux_syscall_hooks.h
==============================================================================
--- stable/11/contrib/compiler-rt/include/sanitizer/linux_syscall_hooks.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/include/sanitizer/linux_syscall_hooks.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -1835,6 +1835,17 @@
   __sanitizer_syscall_pre_impl_vfork()
 #define __sanitizer_syscall_post_vfork(res) \
   __sanitizer_syscall_post_impl_vfork(res)
+#define __sanitizer_syscall_pre_sigaction(signum, act, oldact)                 \
+  __sanitizer_syscall_pre_impl_sigaction((long)signum, (long)act, (long)oldact)
+#define __sanitizer_syscall_post_sigaction(res, signum, act, oldact)           \
+  __sanitizer_syscall_post_impl_sigaction(res, (long)signum, (long)act,        \
+                                          (long)oldact)
+#define __sanitizer_syscall_pre_rt_sigaction(signum, act, oldact, sz)          \
+  __sanitizer_syscall_pre_impl_rt_sigaction((long)signum, (long)act,           \
+                                            (long)oldact, (long)sz)
+#define __sanitizer_syscall_post_rt_sigaction(res, signum, act, oldact, sz)    \
+  __sanitizer_syscall_post_impl_rt_sigaction(res, (long)signum, (long)act,     \
+                                             (long)oldact, (long)sz)
 
 // And now a few syscalls we don't handle yet.
 #define __sanitizer_syscall_pre_afs_syscall(...)
@@ -1889,7 +1900,6 @@
 #define __sanitizer_syscall_pre_query_module(...)
 #define __sanitizer_syscall_pre_readahead(...)
 #define __sanitizer_syscall_pre_readdir(...)
-#define __sanitizer_syscall_pre_rt_sigaction(...)
 #define __sanitizer_syscall_pre_rt_sigreturn(...)
 #define __sanitizer_syscall_pre_rt_sigsuspend(...)
 #define __sanitizer_syscall_pre_security(...)
@@ -1903,7 +1913,6 @@
 #define __sanitizer_syscall_pre_setreuid32(...)
 #define __sanitizer_syscall_pre_set_thread_area(...)
 #define __sanitizer_syscall_pre_setuid32(...)
-#define __sanitizer_syscall_pre_sigaction(...)
 #define __sanitizer_syscall_pre_sigaltstack(...)
 #define __sanitizer_syscall_pre_sigreturn(...)
 #define __sanitizer_syscall_pre_sigsuspend(...)
@@ -1971,7 +1980,6 @@
 #define __sanitizer_syscall_post_query_module(res, ...)
 #define __sanitizer_syscall_post_readahead(res, ...)
 #define __sanitizer_syscall_post_readdir(res, ...)
-#define __sanitizer_syscall_post_rt_sigaction(res, ...)
 #define __sanitizer_syscall_post_rt_sigreturn(res, ...)
 #define __sanitizer_syscall_post_rt_sigsuspend(res, ...)
 #define __sanitizer_syscall_post_security(res, ...)
@@ -1985,7 +1993,6 @@
 #define __sanitizer_syscall_post_setreuid32(res, ...)
 #define __sanitizer_syscall_post_set_thread_area(res, ...)
 #define __sanitizer_syscall_post_setuid32(res, ...)
-#define __sanitizer_syscall_post_sigaction(res, ...)
 #define __sanitizer_syscall_post_sigaltstack(res, ...)
 #define __sanitizer_syscall_post_sigreturn(res, ...)
 #define __sanitizer_syscall_post_sigsuspend(res, ...)
@@ -3062,7 +3069,13 @@ void __sanitizer_syscall_pre_impl_fork()
 void __sanitizer_syscall_post_impl_fork(long res);
 void __sanitizer_syscall_pre_impl_vfork();
 void __sanitizer_syscall_post_impl_vfork(long res);
-
+void __sanitizer_syscall_pre_impl_sigaction(long signum, long act, long oldact);
+void __sanitizer_syscall_post_impl_sigaction(long res, long signum, long act,
+                                             long oldact);
+void __sanitizer_syscall_pre_impl_rt_sigaction(long signum, long act,
+                                               long oldact, long sz);
+void __sanitizer_syscall_post_impl_rt_sigaction(long res, long signum, long act,
+                                                long oldact, long sz);
 #ifdef __cplusplus
 }  // extern "C"
 #endif

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_activation.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_activation.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_activation.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -47,6 +47,7 @@ static struct AsanDeactivatedFlags {
     FlagParser parser;
     RegisterActivationFlags(&parser, &f, &cf);
 
+    cf.SetDefaults();
     // Copy the current activation flags.
     allocator_options.CopyTo(&f, &cf);
     cf.malloc_context_size = malloc_context_size;
@@ -61,7 +62,7 @@ static struct AsanDeactivatedFlags {
       parser.ParseString(env);
     }
 
-    SetVerbosity(cf.verbosity);
+    InitializeCommonFlags(&cf);
 
     if (Verbosity()) ReportUnrecognizedFlags();
 

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_allocator.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_allocator.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_allocator.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -223,7 +223,7 @@ void AllocatorOptions::CopyTo(Flags *f, 
 
 struct Allocator {
   static const uptr kMaxAllowedMallocSize =
-      FIRST_32_SECOND_64(3UL << 30, 1UL << 40);
+      FIRST_32_SECOND_64(3UL << 30, 1ULL << 40);
   static const uptr kMaxThreadLocalQuarantine =
       FIRST_32_SECOND_64(1 << 18, 1 << 20);
 
@@ -457,29 +457,28 @@ struct Allocator {
     return res;
   }
 
-  void AtomicallySetQuarantineFlag(AsanChunk *m, void *ptr,
+  // Set quarantine flag if chunk is allocated, issue ASan error report on
+  // available and quarantined chunks. Return true on success, false otherwise.
+  bool AtomicallySetQuarantineFlagIfAllocated(AsanChunk *m, void *ptr,
                                    BufferedStackTrace *stack) {
     u8 old_chunk_state = CHUNK_ALLOCATED;
     // Flip the chunk_state atomically to avoid race on double-free.
-    if (!atomic_compare_exchange_strong((atomic_uint8_t*)m, &old_chunk_state,
-                                        CHUNK_QUARANTINE, memory_order_acquire))
+    if (!atomic_compare_exchange_strong((atomic_uint8_t *)m, &old_chunk_state,
+                                        CHUNK_QUARANTINE,
+                                        memory_order_acquire)) {
       ReportInvalidFree(ptr, old_chunk_state, stack);
+      // It's not safe to push a chunk in quarantine on invalid free.
+      return false;
+    }
     CHECK_EQ(CHUNK_ALLOCATED, old_chunk_state);
+    return true;
   }
 
   // Expects the chunk to already be marked as quarantined by using
-  // AtomicallySetQuarantineFlag.
+  // AtomicallySetQuarantineFlagIfAllocated.
   void QuarantineChunk(AsanChunk *m, void *ptr, BufferedStackTrace *stack,
                        AllocType alloc_type) {
     CHECK_EQ(m->chunk_state, CHUNK_QUARANTINE);
-
-    if (m->alloc_type != alloc_type) {
-      if (atomic_load(&alloc_dealloc_mismatch, memory_order_acquire)) {
-        ReportAllocTypeMismatch((uptr)ptr, stack, (AllocType)m->alloc_type,
-                                (AllocType)alloc_type);
-      }
-    }
-
     CHECK_GE(m->alloc_tid, 0);
     if (SANITIZER_WORDSIZE == 64)  // On 32-bits this resides in user area.
       CHECK_EQ(m->free_tid, kInvalidTid);
@@ -516,13 +515,24 @@ struct Allocator {
 
     uptr chunk_beg = p - kChunkHeaderSize;
     AsanChunk *m = reinterpret_cast<AsanChunk *>(chunk_beg);
+
+    ASAN_FREE_HOOK(ptr);
+    // Must mark the chunk as quarantined before any changes to its metadata.
+    // Do not quarantine given chunk if we failed to set CHUNK_QUARANTINE flag.
+    if (!AtomicallySetQuarantineFlagIfAllocated(m, ptr, stack)) return;
+
+    if (m->alloc_type != alloc_type) {
+      if (atomic_load(&alloc_dealloc_mismatch, memory_order_acquire)) {
+        ReportAllocTypeMismatch((uptr)ptr, stack, (AllocType)m->alloc_type,
+                                (AllocType)alloc_type);
+      }
+    }
+
     if (delete_size && flags()->new_delete_type_mismatch &&
         delete_size != m->UsedSize()) {
-      ReportNewDeleteSizeMismatch(p, delete_size, stack);
+      ReportNewDeleteSizeMismatch(p, m->UsedSize(), delete_size, stack);
     }
-    ASAN_FREE_HOOK(ptr);
-    // Must mark the chunk as quarantined before any changes to its metadata.
-    AtomicallySetQuarantineFlag(m, ptr, stack);
+
     QuarantineChunk(m, ptr, stack, alloc_type);
   }
 
@@ -655,6 +665,9 @@ static AsanAllocator &get_allocator() {
 bool AsanChunkView::IsValid() {
   return chunk_ && chunk_->chunk_state != CHUNK_AVAILABLE;
 }
+bool AsanChunkView::IsAllocated() {
+  return chunk_ && chunk_->chunk_state == CHUNK_ALLOCATED;
+}
 uptr AsanChunkView::Beg() { return chunk_->Beg(); }
 uptr AsanChunkView::End() { return Beg() + UsedSize(); }
 uptr AsanChunkView::UsedSize() { return chunk_->UsedSize(); }
@@ -668,12 +681,15 @@ static StackTrace GetStackTraceFromId(u3
   return res;
 }
 
+u32 AsanChunkView::GetAllocStackId() { return chunk_->alloc_context_id; }
+u32 AsanChunkView::GetFreeStackId() { return chunk_->free_context_id; }
+
 StackTrace AsanChunkView::GetAllocStack() {
-  return GetStackTraceFromId(chunk_->alloc_context_id);
+  return GetStackTraceFromId(GetAllocStackId());
 }
 
 StackTrace AsanChunkView::GetFreeStack() {
-  return GetStackTraceFromId(chunk_->free_context_id);
+  return GetStackTraceFromId(GetFreeStackId());
 }
 
 void InitializeAllocator(const AllocatorOptions &options) {
@@ -754,7 +770,7 @@ int asan_posix_memalign(void **memptr, u
   return 0;
 }
 
-uptr asan_malloc_usable_size(void *ptr, uptr pc, uptr bp) {
+uptr asan_malloc_usable_size(const void *ptr, uptr pc, uptr bp) {
   if (!ptr) return 0;
   uptr usable_size = instance.AllocationSize(reinterpret_cast<uptr>(ptr));
   if (flags()->check_malloc_usable_size && (usable_size == 0)) {

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_allocator.h
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_allocator.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_allocator.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -49,14 +49,17 @@ void GetAllocatorOptions(AllocatorOption
 class AsanChunkView {
  public:
   explicit AsanChunkView(AsanChunk *chunk) : chunk_(chunk) {}
-  bool IsValid();   // Checks if AsanChunkView points to a valid allocated
-                    // or quarantined chunk.
-  uptr Beg();       // First byte of user memory.
-  uptr End();       // Last byte of user memory.
-  uptr UsedSize();  // Size requested by the user.
+  bool IsValid();        // Checks if AsanChunkView points to a valid allocated
+                         // or quarantined chunk.
+  bool IsAllocated();    // Checks if the memory is currently allocated.
+  uptr Beg();            // First byte of user memory.
+  uptr End();            // Last byte of user memory.
+  uptr UsedSize();       // Size requested by the user.
   uptr AllocTid();
   uptr FreeTid();
   bool Eq(const AsanChunkView &c) const { return chunk_ == c.chunk_; }
+  u32 GetAllocStackId();
+  u32 GetFreeStackId();
   StackTrace GetAllocStack();
   StackTrace GetFreeStack();
   bool AddrIsInside(uptr addr, uptr access_size, sptr *offset) {
@@ -171,7 +174,7 @@ void *asan_pvalloc(uptr size, BufferedSt
 
 int asan_posix_memalign(void **memptr, uptr alignment, uptr size,
                         BufferedStackTrace *stack);
-uptr asan_malloc_usable_size(void *ptr, uptr pc, uptr bp);
+uptr asan_malloc_usable_size(const void *ptr, uptr pc, uptr bp);
 
 uptr asan_mz_size(const void *ptr);
 void asan_mz_force_lock();

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -31,7 +31,7 @@ ALWAYS_INLINE void SetShadow(uptr ptr, u
   CHECK_EQ(SHADOW_SCALE, 3);  // This code expects SHADOW_SCALE=3.
   u64 *shadow = reinterpret_cast<u64*>(MemToShadow(ptr));
   if (class_id <= 6) {
-    for (uptr i = 0; i < (1U << class_id); i++) {
+    for (uptr i = 0; i < (((uptr)1) << class_id); i++) {
       shadow[i] = magic;
       // Make sure this does not become memset.
       SanitizerBreakOptimization(nullptr);
@@ -121,7 +121,7 @@ uptr FakeStack::AddrIsInFakeStack(uptr p
   uptr class_id = (ptr - beg) >> stack_size_log;
   uptr base = beg + (class_id << stack_size_log);
   CHECK_LE(base, ptr);
-  CHECK_LT(ptr, base + (1UL << stack_size_log));
+  CHECK_LT(ptr, base + (((uptr)1) << stack_size_log));
   uptr pos = (ptr - base) >> (kMinStackFrameSizeLog + class_id);
   uptr res = base + pos * BytesInSizeClass(class_id);
   *frame_end = res + BytesInSizeClass(class_id);

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.h
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_fake_stack.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -69,12 +69,12 @@ class FakeStack {
 
   // stack_size_log is at least 15 (stack_size >= 32K).
   static uptr SizeRequiredForFlags(uptr stack_size_log) {
-    return 1UL << (stack_size_log + 1 - kMinStackFrameSizeLog);
+    return ((uptr)1) << (stack_size_log + 1 - kMinStackFrameSizeLog);
   }
 
   // Each size class occupies stack_size bytes.
   static uptr SizeRequiredForFrames(uptr stack_size_log) {
-    return (1ULL << stack_size_log) * kNumberOfSizeClasses;
+    return (((uptr)1) << stack_size_log) * kNumberOfSizeClasses;
   }
 
   // Number of bytes requires for the whole object.
@@ -91,12 +91,12 @@ class FakeStack {
   // and so on.
   static uptr FlagsOffset(uptr stack_size_log, uptr class_id) {
     uptr t = kNumberOfSizeClasses - 1 - class_id;
-    const uptr all_ones = (1 << (kNumberOfSizeClasses - 1)) - 1;
+    const uptr all_ones = (((uptr)1) << (kNumberOfSizeClasses - 1)) - 1;
     return ((all_ones >> t) << t) << (stack_size_log - 15);
   }
 
   static uptr NumberOfFrames(uptr stack_size_log, uptr class_id) {
-    return 1UL << (stack_size_log - kMinStackFrameSizeLog - class_id);
+    return ((uptr)1) << (stack_size_log - kMinStackFrameSizeLog - class_id);
   }
 
   // Divide n by the numbe of frames in size class.
@@ -114,7 +114,8 @@ class FakeStack {
   u8 *GetFrame(uptr stack_size_log, uptr class_id, uptr pos) {
     return reinterpret_cast<u8 *>(this) + kFlagsOffset +
            SizeRequiredForFlags(stack_size_log) +
-           (1 << stack_size_log) * class_id + BytesInSizeClass(class_id) * pos;
+           (((uptr)1) << stack_size_log) * class_id +
+           BytesInSizeClass(class_id) * pos;
   }
 
   // Allocate the fake frame.
@@ -137,7 +138,7 @@ class FakeStack {
 
   // Number of bytes in a fake frame of this size class.
   static uptr BytesInSizeClass(uptr class_id) {
-    return 1UL << (class_id + kMinStackFrameSizeLog);
+    return ((uptr)1) << (class_id + kMinStackFrameSizeLog);
   }
 
   // The fake frame is guaranteed to have a right redzone.
@@ -159,7 +160,7 @@ class FakeStack {
   static const uptr kFlagsOffset = 4096;  // This is were the flags begin.
   // Must match the number of uses of DEFINE_STACK_MALLOC_FREE_WITH_CLASS_ID
   COMPILER_CHECK(kNumberOfSizeClasses == 11);
-  static const uptr kMaxStackMallocSize = 1 << kMaxStackFrameSizeLog;
+  static const uptr kMaxStackMallocSize = ((uptr)1) << kMaxStackFrameSizeLog;
 
   uptr hint_position_[kNumberOfSizeClasses];
   uptr stack_size_log_;

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_flags.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_flags.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_flags.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -116,7 +116,7 @@ void InitializeFlags() {
   ubsan_parser.ParseString(GetEnv("UBSAN_OPTIONS"));
 #endif
 
-  SetVerbosity(common_flags()->verbosity);
+  InitializeCommonFlags();
 
   // TODO(eugenis): dump all flags at verbosity>=2?
   if (Verbosity()) ReportUnrecognizedFlags();
@@ -159,6 +159,14 @@ void InitializeFlags() {
         (ASAN_LOW_MEMORY) ? 1UL << 6 : 1UL << 8;
     f->quarantine_size_mb = kDefaultQuarantineSizeMb;
   }
+  if (!f->replace_str && common_flags()->intercept_strlen) {
+    Report("WARNING: strlen interceptor is enabled even though replace_str=0. "
+           "Use intercept_strlen=0 to disable it.");
+  }
+  if (!f->replace_str && common_flags()->intercept_strchr) {
+    Report("WARNING: strchr* interceptors are enabled even though "
+           "replace_str=0. Use intercept_strchr=0 to disable them.");
+  }
 }
 
 }  // namespace __asan

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_flags.inc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_flags.inc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_flags.inc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -43,7 +43,7 @@ ASAN_FLAG(
     "If set, uses custom wrappers and replacements for libc string functions "
     "to find more errors.")
 ASAN_FLAG(bool, replace_intrin, true,
-          "If set, uses custom wrappers for memset/memcpy/memmove intinsics.")
+          "If set, uses custom wrappers for memset/memcpy/memmove intrinsics.")
 ASAN_FLAG(bool, detect_stack_use_after_return, false,
           "Enables stack-use-after-return checking at run-time.")
 ASAN_FLAG(int, min_uar_stack_size_log, 16, // We can't do smaller anyway.
@@ -77,6 +77,8 @@ ASAN_FLAG(bool, print_stats, false,
           "Print various statistics after printing an error message or if "
           "atexit=1.")
 ASAN_FLAG(bool, print_legend, true, "Print the legend for the shadow bytes.")
+ASAN_FLAG(bool, print_scariness, false,
+          "Print the scariness score. Experimental.")
 ASAN_FLAG(bool, atexit, false,
           "If set, prints ASan exit stats even after program terminates "
           "successfully.")
@@ -104,7 +106,7 @@ ASAN_FLAG(bool, alloc_dealloc_mismatch,
           "Report errors on malloc/delete, new/free, new/delete[], etc.")
 
 ASAN_FLAG(bool, new_delete_type_mismatch, true,
-          "Report errors on mismatch betwen size of new and delete.")
+          "Report errors on mismatch between size of new and delete.")
 ASAN_FLAG(
     bool, strict_init_order, false,
     "If true, assume that dynamic initializers can never access globals from "
@@ -135,3 +137,5 @@ ASAN_FLAG(const char *, suppressions, ""
 ASAN_FLAG(bool, halt_on_error, true,
           "Crash the program after printing the first error report "
           "(WARNING: USE AT YOUR OWN RISK!)")
+ASAN_FLAG(bool, use_odr_indicator, false,
+          "Use special ODR indicator symbol for ODR violation detection")

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_globals.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_globals.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_globals.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -135,6 +135,70 @@ bool GetInfoForAddressIfGlobal(uptr addr
   return false;
 }
 
+enum GlobalSymbolState {
+  UNREGISTERED = 0,
+  REGISTERED = 1
+};
+
+// Check ODR violation for given global G via special ODR indicator. We use
+// this method in case compiler instruments global variables through their
+// local aliases.
+static void CheckODRViolationViaIndicator(const Global *g) {
+  u8 *odr_indicator = reinterpret_cast<u8 *>(g->odr_indicator);
+  if (*odr_indicator == UNREGISTERED) {
+    *odr_indicator = REGISTERED;
+    return;
+  }
+  // If *odr_indicator is DEFINED, some module have already registered
+  // externally visible symbol with the same name. This is an ODR violation.
+  for (ListOfGlobals *l = list_of_all_globals; l; l = l->next) {
+    if (g->odr_indicator == l->g->odr_indicator &&
+        (flags()->detect_odr_violation >= 2 || g->size != l->g->size) &&
+        !IsODRViolationSuppressed(g->name))
+      ReportODRViolation(g, FindRegistrationSite(g),
+                         l->g, FindRegistrationSite(l->g));
+  }
+}
+
+// Check ODR violation for given global G by checking if it's already poisoned.
+// We use this method in case compiler doesn't use private aliases for global
+// variables.
+static void CheckODRViolationViaPoisoning(const Global *g) {
+  if (__asan_region_is_poisoned(g->beg, g->size_with_redzone)) {
+    // This check may not be enough: if the first global is much larger
+    // the entire redzone of the second global may be within the first global.
+    for (ListOfGlobals *l = list_of_all_globals; l; l = l->next) {
+      if (g->beg == l->g->beg &&
+          (flags()->detect_odr_violation >= 2 || g->size != l->g->size) &&
+          !IsODRViolationSuppressed(g->name))
+        ReportODRViolation(g, FindRegistrationSite(g),
+                           l->g, FindRegistrationSite(l->g));
+    }
+  }
+}
+
+// Clang provides two different ways for global variables protection:
+// it can poison the global itself or its private alias. In former
+// case we may poison same symbol multiple times, that can help us to
+// cheaply detect ODR violation: if we try to poison an already poisoned
+// global, we have ODR violation error.
+// In latter case, we poison each symbol exactly once, so we use special
+// indicator symbol to perform similar check.
+// In either case, compiler provides a special odr_indicator field to Global
+// structure, that can contain two kinds of values:
+//   1) Non-zero value. In this case, odr_indicator is an address of
+//      corresponding indicator variable for given global.
+//   2) Zero. This means that we don't use private aliases for global variables
+//      and can freely check ODR violation with the first method.
+//
+// This routine chooses between two different methods of ODR violation
+// detection.
+static inline bool UseODRIndicator(const Global *g) {
+  // Use ODR indicator method iff use_odr_indicator flag is set and
+  // indicator symbol address is not 0.
+  return flags()->use_odr_indicator && g->odr_indicator > 0;
+}
+
 // Register a global variable.
 // This function may be called more than once for every global
 // so we store the globals in a map.
@@ -144,22 +208,24 @@ static void RegisterGlobal(const Global 
     ReportGlobal(*g, "Added");
   CHECK(flags()->report_globals);
   CHECK(AddrIsInMem(g->beg));
-  CHECK(AddrIsAlignedByGranularity(g->beg));
+  if (!AddrIsAlignedByGranularity(g->beg)) {
+    Report("The following global variable is not properly aligned.\n");
+    Report("This may happen if another global with the same name\n");
+    Report("resides in another non-instrumented module.\n");
+    Report("Or the global comes from a C file built w/o -fno-common.\n");
+    Report("In either case this is likely an ODR violation bug,\n");
+    Report("but AddressSanitizer can not provide more details.\n");
+    ReportODRViolation(g, FindRegistrationSite(g), g, FindRegistrationSite(g));
+    CHECK(AddrIsAlignedByGranularity(g->beg));
+  }
   CHECK(AddrIsAlignedByGranularity(g->size_with_redzone));
   if (flags()->detect_odr_violation) {
     // Try detecting ODR (One Definition Rule) violation, i.e. the situation
     // where two globals with the same name are defined in different modules.
-    if (__asan_region_is_poisoned(g->beg, g->size_with_redzone)) {
-      // This check may not be enough: if the first global is much larger
-      // the entire redzone of the second global may be within the first global.
-      for (ListOfGlobals *l = list_of_all_globals; l; l = l->next) {
-        if (g->beg == l->g->beg &&
-            (flags()->detect_odr_violation >= 2 || g->size != l->g->size) &&
-            !IsODRViolationSuppressed(g->name))
-          ReportODRViolation(g, FindRegistrationSite(g),
-                             l->g, FindRegistrationSite(l->g));
-      }
-    }
+    if (UseODRIndicator(g))
+      CheckODRViolationViaIndicator(g);
+    else
+      CheckODRViolationViaPoisoning(g);
   }
   if (CanPoisonMemory())
     PoisonRedZones(*g);
@@ -190,6 +256,12 @@ static void UnregisterGlobal(const Globa
   // We unpoison the shadow memory for the global but we do not remove it from
   // the list because that would require O(n^2) time with the current list
   // implementation. It might not be worth doing anyway.
+
+  // Release ODR indicator.
+  if (UseODRIndicator(g)) {
+    u8 *odr_indicator = reinterpret_cast<u8 *>(g->odr_indicator);
+    *odr_indicator = UNREGISTERED;
+  }
 }
 
 void StopInitOrderChecking() {
@@ -212,6 +284,25 @@ void StopInitOrderChecking() {
 // ---------------------- Interface ---------------- {{{1
 using namespace __asan;  // NOLINT
 
+
+// Apply __asan_register_globals to all globals found in the same loaded
+// executable or shared library as `flag'. The flag tracks whether globals have
+// already been registered or not for this image.
+void __asan_register_image_globals(uptr *flag) {
+  if (*flag)
+    return;
+  AsanApplyToGlobals(__asan_register_globals, flag);
+  *flag = 1;
+}
+
+// This mirrors __asan_register_image_globals.
+void __asan_unregister_image_globals(uptr *flag) {
+  if (!*flag)
+    return;
+  AsanApplyToGlobals(__asan_unregister_globals, flag);
+  *flag = 0;
+}
+
 // Register an array of globals.
 void __asan_register_globals(__asan_global *globals, uptr n) {
   if (!flags()->report_globals) return;

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_init_version.h
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_init_version.h	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_init_version.h	Mon Dec 26 20:36:37 2016	(r310618)
@@ -19,16 +19,20 @@ extern "C" {
   // Every time the ASan ABI changes we also change the version number in the
   // __asan_init function name.  Objects built with incompatible ASan ABI
   // versions will not link with run-time.
+  //
   // Changes between ABI versions:
   // v1=>v2: added 'module_name' to __asan_global
   // v2=>v3: stack frame description (created by the compiler)
-  //         contains the function PC as the 3-rd field (see
-  //         DescribeAddressIfStack).
-  // v3=>v4: added '__asan_global_source_location' to __asan_global.
+  //         contains the function PC as the 3rd field (see
+  //         DescribeAddressIfStack)
+  // v3=>v4: added '__asan_global_source_location' to __asan_global
   // v4=>v5: changed the semantics and format of __asan_stack_malloc_ and
-  //         __asan_stack_free_ functions.
+  //         __asan_stack_free_ functions
   // v5=>v6: changed the name of the version check symbol
-  #define __asan_version_mismatch_check __asan_version_mismatch_check_v6
+  // v6=>v7: added 'odr_indicator' to __asan_global
+  // v7=>v8: added '__asan_(un)register_image_globals' functions for dead
+  //         stripping support on Mach-O platforms
+  #define __asan_version_mismatch_check __asan_version_mismatch_check_v8
 }
 
 #endif  // ASAN_INIT_VERSION_H

Modified: stable/11/contrib/compiler-rt/lib/asan/asan_interceptors.cc
==============================================================================
--- stable/11/contrib/compiler-rt/lib/asan/asan_interceptors.cc	Mon Dec 26 19:33:40 2016	(r310617)
+++ stable/11/contrib/compiler-rt/lib/asan/asan_interceptors.cc	Mon Dec 26 20:36:37 2016	(r310618)
@@ -21,6 +21,7 @@
 #include "asan_stack.h"
 #include "asan_stats.h"
 #include "asan_suppressions.h"
+#include "lsan/lsan_common.h"
 #include "sanitizer_common/sanitizer_libc.h"
 
 #if SANITIZER_POSIX
@@ -110,7 +111,7 @@ static inline bool RangesOverlap(const c
 } while (0)
 
 static inline uptr MaybeRealStrnlen(const char *s, uptr maxlen) {
-#if ASAN_INTERCEPT_STRNLEN
+#if SANITIZER_INTERCEPT_STRNLEN
   if (REAL(strnlen)) {
     return REAL(strnlen)(s, maxlen);
   }
@@ -143,6 +144,8 @@ DECLARE_REAL_AND_INTERCEPTOR(void, free,
   (void) ctx;                                                                  \
 
 #define COMMON_INTERCEPT_FUNCTION(name) ASAN_INTERCEPT_FUNC(name)
+#define COMMON_INTERCEPT_FUNCTION_VER(name, ver)                          \
+  ASAN_INTERCEPT_FUNC_VER(name, ver)
 #define COMMON_INTERCEPTOR_WRITE_RANGE(ctx, ptr, size) \
   ASAN_WRITE_RANGE(ctx, ptr, size)
 #define COMMON_INTERCEPTOR_READ_RANGE(ctx, ptr, size) \
@@ -195,6 +198,10 @@ DECLARE_REAL_AND_INTERCEPTOR(void, free,
   } else {                                                                     \
     *begin = *end = 0;                                                         \
   }
+// Asan needs custom handling of these:
+#undef SANITIZER_INTERCEPT_MEMSET
+#undef SANITIZER_INTERCEPT_MEMMOVE
+#undef SANITIZER_INTERCEPT_MEMCPY
 #include "sanitizer_common/sanitizer_common_interceptors.inc"
 
 // Syscall interceptors don't have contexts, we don't support suppressions
@@ -218,6 +225,7 @@ struct ThreadStartParam {
   atomic_uintptr_t is_registered;
 };
 

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Mon Dec 26 22:13:45 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3729FC9178F;
 Mon, 26 Dec 2016 22:13:45 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E3F161A54;
 Mon, 26 Dec 2016 22:13:44 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBQMDiVE036337;
 Mon, 26 Dec 2016 22:13:44 GMT (envelope-from gonzo@FreeBSD.org)
Received: (from gonzo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBQMDh9c036331;
 Mon, 26 Dec 2016 22:13:43 GMT (envelope-from gonzo@FreeBSD.org)
Message-Id: <201612262213.uBQMDh9c036331@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: gonzo set sender to
 gonzo@FreeBSD.org using -f
From: Oleksandr Tymoshenko <gonzo@FreeBSD.org>
Date: Mon, 26 Dec 2016 22:13:43 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310621 - in head/sys: conf dev/ichiic
 modules/i2c/controllers/ichiic
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Dec 2016 22:13:45 -0000

Author: gonzo
Date: Mon Dec 26 22:13:43 2016
New Revision: 310621
URL: https://svnweb.freebsd.org/changeset/base/310621

Log:
  [ig4] Add ACPI platform support for ig4 driver
  
  Add ACPI part for ig4 driver to make it work on Intel BayTrail SoC where
  ig4 device is available only through ACPI
  
  Reviewed by:	avg
  MFC after:	1 week
  Differential Revision:	https://reviews.freebsd.org/D8742

Added:
  head/sys/dev/ichiic/ig4_acpi.c   (contents, props changed)
Modified:
  head/sys/conf/files
  head/sys/dev/ichiic/ig4_iic.c
  head/sys/dev/ichiic/ig4_pci.c
  head/sys/dev/ichiic/ig4_var.h
  head/sys/modules/i2c/controllers/ichiic/Makefile

Modified: head/sys/conf/files
==============================================================================
--- head/sys/conf/files	Mon Dec 26 21:27:21 2016	(r310620)
+++ head/sys/conf/files	Mon Dec 26 22:13:43 2016	(r310621)
@@ -1730,6 +1730,7 @@ dev/hptiop/hptiop.c		optional hptiop scb
 dev/hwpmc/hwpmc_logging.c	optional hwpmc
 dev/hwpmc/hwpmc_mod.c		optional hwpmc
 dev/hwpmc/hwpmc_soft.c		optional hwpmc
+dev/ichiic/ig4_acpi.c		optional ig4 acpi iicbus
 dev/ichiic/ig4_iic.c		optional ig4 iicbus
 dev/ichiic/ig4_pci.c		optional ig4 pci iicbus
 dev/ichsmb/ichsmb.c		optional ichsmb

Added: head/sys/dev/ichiic/ig4_acpi.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sys/dev/ichiic/ig4_acpi.c	Mon Dec 26 22:13:43 2016	(r310621)
@@ -0,0 +1,166 @@
+/*-
+ * Copyright (c) 2016 Oleksandr Tymoshenko <gonzo@FreeBSD.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
+
+#include "opt_acpi.h"
+
+#include <sys/param.h>
+#include <sys/bus.h>
+#include <sys/kernel.h>
+#include <sys/module.h>
+#include <sys/proc.h>
+#include <sys/rman.h>
+
+#include <machine/bus.h>
+#include <machine/resource.h>
+
+#include <contrib/dev/acpica/include/acpi.h>
+#include <contrib/dev/acpica/include/accommon.h>
+
+#include <dev/acpica/acpivar.h>
+#include <dev/iicbus/iiconf.h>
+
+#include <dev/ichiic/ig4_reg.h>
+#include <dev/ichiic/ig4_var.h>
+
+static int	ig4iic_acpi_probe(device_t dev);
+static int	ig4iic_acpi_attach(device_t dev);
+static int	ig4iic_acpi_detach(device_t dev);
+
+static char *ig4iic_ids[] = {
+	"INT33C2",
+	"INT33C3",
+	"INT3432",
+	"INT3433",
+	"80860F41",
+	"808622C1",
+	"AMDI0510",
+	"APMC0D0F",
+	NULL
+};
+
+static int
+ig4iic_acpi_probe(device_t dev)
+{
+
+	if (acpi_disabled("ig4iic") ||
+	    ACPI_ID_PROBE(device_get_parent(dev), dev, ig4iic_ids) == NULL)
+	return (ENXIO);
+
+	device_set_desc(dev, "Designware I2C Controller");
+	return (0);
+}
+
+static int
+ig4iic_acpi_attach(device_t dev)
+{
+	ig4iic_softc_t	*sc;
+	int error;
+
+	sc = device_get_softc(dev);
+
+	sc->dev = dev;
+	sc->regs_rid = 0;
+	sc->regs_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY,
+					  &sc->regs_rid, RF_ACTIVE);
+	if (sc->regs_res == NULL) {
+		device_printf(dev, "unable to map registers\n");
+		ig4iic_acpi_detach(dev);
+		return (ENXIO);
+	}
+	sc->intr_rid = 0;
+	sc->intr_res = bus_alloc_resource_any(dev, SYS_RES_IRQ,
+					  &sc->intr_rid, RF_SHAREABLE | RF_ACTIVE);
+	if (sc->intr_res == NULL) {
+		device_printf(dev, "unable to map interrupt\n");
+		ig4iic_acpi_detach(dev);
+		return (ENXIO);
+	}
+	sc->platform_attached = 1;
+
+	error = ig4iic_attach(sc);
+	if (error)
+		ig4iic_acpi_detach(dev);
+
+	return (error);
+}
+
+static int
+ig4iic_acpi_detach(device_t dev)
+{
+	ig4iic_softc_t *sc = device_get_softc(dev);
+	int error;
+
+	if (sc->platform_attached) {
+		error = ig4iic_detach(sc);
+		if (error)
+			return (error);
+		sc->platform_attached = 0;
+	}
+
+	if (sc->intr_res) {
+		bus_release_resource(dev, SYS_RES_IRQ,
+				     sc->intr_rid, sc->intr_res);
+		sc->intr_res = NULL;
+	}
+	if (sc->regs_res) {
+		bus_release_resource(dev, SYS_RES_MEMORY,
+				     sc->regs_rid, sc->regs_res);
+		sc->regs_res = NULL;
+	}
+
+	return (0);
+}
+
+static device_method_t ig4iic_acpi_methods[] = {
+	/* Device interface */
+	DEVMETHOD(device_probe, ig4iic_acpi_probe),
+	DEVMETHOD(device_attach, ig4iic_acpi_attach),
+	DEVMETHOD(device_detach, ig4iic_acpi_detach),
+
+	/* iicbus interface */
+	DEVMETHOD(iicbus_transfer, ig4iic_transfer),
+	DEVMETHOD(iicbus_reset, ig4iic_reset),
+	DEVMETHOD(iicbus_callback, iicbus_null_callback),
+
+	DEVMETHOD_END
+};
+
+static driver_t ig4iic_acpi_driver = {
+	"ig4iic_acpi",
+	ig4iic_acpi_methods,
+	sizeof(struct ig4iic_softc),
+};
+
+static devclass_t ig4iic_acpi_devclass;
+DRIVER_MODULE(ig4iic_acpi, acpi, ig4iic_acpi_driver, ig4iic_acpi_devclass, 0, 0);
+
+MODULE_DEPEND(ig4iic_acpi, acpi, 1, 1, 1);
+MODULE_DEPEND(ig4iic_acpi, pci, 1, 1, 1);
+MODULE_DEPEND(ig4iic_acpi, iicbus, IICBUS_MINVER, IICBUS_PREFVER, IICBUS_MAXVER);
+MODULE_VERSION(ig4iic_acpi, 1);

Modified: head/sys/dev/ichiic/ig4_iic.c
==============================================================================
--- head/sys/dev/ichiic/ig4_iic.c	Mon Dec 26 21:27:21 2016	(r310620)
+++ head/sys/dev/ichiic/ig4_iic.c	Mon Dec 26 22:13:43 2016	(r310621)
@@ -522,6 +522,9 @@ ig4iic_attach(ig4iic_softc_t *sc)
 	int error;
 	uint32_t v;
 
+	mtx_init(&sc->io_lock, "IG4 I/O lock", NULL, MTX_DEF);
+	sx_init(&sc->call_lock, "IG4 call lock");
+
 	v = reg_read(sc, IG4_REG_COMP_TYPE);
 	v = reg_read(sc, IG4_REG_COMP_PARAM1);
 	v = reg_read(sc, IG4_REG_GENERAL);
@@ -664,6 +667,10 @@ ig4iic_detach(ig4iic_softc_t *sc)
 
 	mtx_unlock(&sc->io_lock);
 	sx_xunlock(&sc->call_lock);
+
+	mtx_destroy(&sc->io_lock);
+	sx_destroy(&sc->call_lock);
+
 	return (0);
 }
 
@@ -731,4 +738,5 @@ ig4iic_dump(ig4iic_softc_t *sc)
 }
 #undef REGDUMP
 
-DRIVER_MODULE(iicbus, ig4iic, iicbus_driver, iicbus_devclass, NULL, NULL);
+DRIVER_MODULE(iicbus, ig4iic_acpi, iicbus_driver, iicbus_devclass, NULL, NULL);
+DRIVER_MODULE(iicbus, ig4iic_pci, iicbus_driver, iicbus_devclass, NULL, NULL);

Modified: head/sys/dev/ichiic/ig4_pci.c
==============================================================================
--- head/sys/dev/ichiic/ig4_pci.c	Mon Dec 26 21:27:21 2016	(r310620)
+++ head/sys/dev/ichiic/ig4_pci.c	Mon Dec 26 22:13:43 2016	(r310621)
@@ -115,11 +115,6 @@ ig4iic_pci_attach(device_t dev)
 	ig4iic_softc_t *sc = device_get_softc(dev);
 	int error;
 
-	bzero(sc, sizeof(*sc));
-
-	mtx_init(&sc->io_lock, "IG4 I/O lock", NULL, MTX_DEF);
-	sx_init(&sc->call_lock, "IG4 call lock");
-
 	sc->dev = dev;
 	sc->regs_rid = PCIR_BAR(0);
 	sc->regs_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY,
@@ -140,7 +135,7 @@ ig4iic_pci_attach(device_t dev)
 		ig4iic_pci_detach(dev);
 		return (ENXIO);
 	}
-	sc->pci_attached = 1;
+	sc->platform_attached = 1;
 
 	error = ig4iic_attach(sc);
 	if (error)
@@ -155,11 +150,11 @@ ig4iic_pci_detach(device_t dev)
 	ig4iic_softc_t *sc = device_get_softc(dev);
 	int error;
 
-	if (sc->pci_attached) {
+	if (sc->platform_attached) {
 		error = ig4iic_detach(sc);
 		if (error)
 			return (error);
-		sc->pci_attached = 0;
+		sc->platform_attached = 0;
 	}
 
 	if (sc->intr_res) {
@@ -174,10 +169,6 @@ ig4iic_pci_detach(device_t dev)
 				     sc->regs_rid, sc->regs_res);
 		sc->regs_res = NULL;
 	}
-	if (mtx_initialized(&sc->io_lock)) {
-		mtx_destroy(&sc->io_lock);
-		sx_destroy(&sc->call_lock);
-	}
 
 	return (0);
 }
@@ -196,15 +187,15 @@ static device_method_t ig4iic_pci_method
 };
 
 static driver_t ig4iic_pci_driver = {
-	"ig4iic",
+	"ig4iic_pci",
 	ig4iic_pci_methods,
 	sizeof(struct ig4iic_softc)
 };
 
 static devclass_t ig4iic_pci_devclass;
 
-DRIVER_MODULE_ORDERED(ig4iic, pci, ig4iic_pci_driver, ig4iic_pci_devclass, 0, 0,
+DRIVER_MODULE_ORDERED(ig4iic_pci, pci, ig4iic_pci_driver, ig4iic_pci_devclass, 0, 0,
     SI_ORDER_ANY);
-MODULE_DEPEND(ig4iic, pci, 1, 1, 1);
-MODULE_DEPEND(ig4iic, iicbus, IICBUS_MINVER, IICBUS_PREFVER, IICBUS_MAXVER);
-MODULE_VERSION(ig4iic, 1);
+MODULE_DEPEND(ig4iic_pci, pci, 1, 1, 1);
+MODULE_DEPEND(ig4iic_pci, iicbus, IICBUS_MINVER, IICBUS_PREFVER, IICBUS_MAXVER);
+MODULE_VERSION(ig4iic_pci, 1);

Modified: head/sys/dev/ichiic/ig4_var.h
==============================================================================
--- head/sys/dev/ichiic/ig4_var.h	Mon Dec 26 21:27:21 2016	(r310620)
+++ head/sys/dev/ichiic/ig4_var.h	Mon Dec 26 22:13:43 2016	(r310621)
@@ -65,7 +65,7 @@ struct ig4iic_softc {
 	char		rbuf[IG4_RBUFSIZE];
 	int		error;
 	uint8_t		last_slave;
-	int		pci_attached : 1;
+	int		platform_attached : 1;
 	int		use_10bit : 1;
 	int		slave_valid : 1;
 	int		read_started : 1;

Modified: head/sys/modules/i2c/controllers/ichiic/Makefile
==============================================================================
--- head/sys/modules/i2c/controllers/ichiic/Makefile	Mon Dec 26 21:27:21 2016	(r310620)
+++ head/sys/modules/i2c/controllers/ichiic/Makefile	Mon Dec 26 22:13:43 2016	(r310621)
@@ -2,7 +2,12 @@
 
 .PATH:		${.CURDIR}/../../../../dev/ichiic
 KMOD		= ig4
-SRCS		= device_if.h bus_if.h iicbus_if.h pci_if.h smbus_if.h \
-		  ig4_iic.c ig4_pci.c ig4_reg.h ig4_var.h
+SRCS		= acpi_if.h device_if.h bus_if.h iicbus_if.h pci_if.h \
+		  smbus_if.h ${ig4_acpi} ig4_iic.c ig4_pci.c ig4_reg.h \
+		  ig4_var.h opt_acpi.h
+
+.if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386"
+ig4_acpi=	ig4_acpi.c
+.endif
 
 .include <bsd.kmod.mk>

From owner-svn-src-all@freebsd.org  Tue Dec 27 00:51:57 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 46EC5C90CED;
 Tue, 27 Dec 2016 00:51:57 +0000 (UTC) (envelope-from mm@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id EB31015A1;
 Tue, 27 Dec 2016 00:51:56 +0000 (UTC) (envelope-from mm@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR0puxu099921;
 Tue, 27 Dec 2016 00:51:56 GMT (envelope-from mm@FreeBSD.org)
Received: (from mm@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR0psiH099168;
 Tue, 27 Dec 2016 00:51:54 GMT (envelope-from mm@FreeBSD.org)
Message-Id: <201612270051.uBR0psiH099168@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mm set sender to mm@FreeBSD.org
 using -f
From: Martin Matuska <mm@FreeBSD.org>
Date: Tue, 27 Dec 2016 00:51:54 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-vendor@freebsd.org
Subject: svn commit: r310622 - in vendor/libarchive/dist: . cpio/test
 libarchive libarchive/test tar
X-SVN-Group: vendor
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 00:51:57 -0000

Author: mm
Date: Tue Dec 27 00:51:53 2016
New Revision: 310622
URL: https://svnweb.freebsd.org/changeset/base/310622

Log:
  Update vendor/libarchive to git to 42a3408ac7df1e69bea9ea12b72e14f59f7400c0
  
  Vendor bugfixes:
  
  PR 844: Coverity bug fixes in tests
  PR 846: Spelling fixes
  PR 850: Fix issues with reading certain jar files
  PR 826: OpenSSL 1.1 support
  PR 830, 831, 833: Spelling fixes
  OSS-Fuzz 227, 230, 239: Fix possible memory leak in archive_read_free()
  OSS-Fuzz 237: Fix heap buffer overflow when reading invalid ar archives
  OSS-Fuzz 286: Bugfix in archive_strncat_l()

Added:
  vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c   (contents, props changed)
  vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu
Modified:
  vendor/libarchive/dist/Makefile.am
  vendor/libarchive/dist/cpio/test/test_owner_parse.c
  vendor/libarchive/dist/libarchive/archive_read.c
  vendor/libarchive/dist/libarchive/archive_read_disk_posix.c
  vendor/libarchive/dist/libarchive/archive_read_disk_windows.c
  vendor/libarchive/dist/libarchive/archive_read_support_filter_xz.c
  vendor/libarchive/dist/libarchive/archive_read_support_format_7zip.c
  vendor/libarchive/dist/libarchive/archive_read_support_format_cpio.c
  vendor/libarchive/dist/libarchive/archive_read_support_format_zip.c
  vendor/libarchive/dist/libarchive/archive_string.c
  vendor/libarchive/dist/libarchive/archive_write_set_format_iso9660.c
  vendor/libarchive/dist/libarchive/test/CMakeLists.txt
  vendor/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c
  vendor/libarchive/dist/libarchive/test/test_write_disk_appledouble.c
  vendor/libarchive/dist/libarchive/test/test_write_format_xar_empty.c
  vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty.c
  vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty_zip64.c
  vendor/libarchive/dist/tar/read.c
  vendor/libarchive/dist/tar/write.c

Modified: vendor/libarchive/dist/Makefile.am
==============================================================================
--- vendor/libarchive/dist/Makefile.am	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/Makefile.am	Tue Dec 27 00:51:53 2016	(r310622)
@@ -483,6 +483,7 @@ libarchive_test_SOURCES= \
 	libarchive/test/test_read_format_zip_encryption_header.c \
 	libarchive/test/test_read_format_zip_filename.c \
 	libarchive/test/test_read_format_zip_high_compression.c \
+	libarchive/test/test_read_format_zip_jar.c \
 	libarchive/test/test_read_format_zip_mac_metadata.c \
 	libarchive/test/test_read_format_zip_malformed.c \
 	libarchive/test/test_read_format_zip_msdos.c \
@@ -801,6 +802,7 @@ libarchive_test_EXTRA_DIST=\
 	libarchive/test/test_read_format_zip_filename_utf8_ru2.zip.uu \
 	libarchive/test/test_read_format_zip_high_compression.zip.uu \
 	libarchive/test/test_read_format_zip_length_at_end.zip.uu \
+	libarchive/test/test_read_format_zip_jar.jar.uu \
 	libarchive/test/test_read_format_zip_mac_metadata.zip.uu \
 	libarchive/test/test_read_format_zip_malformed1.zip.uu \
 	libarchive/test/test_read_format_zip_msdos.zip.uu \

Modified: vendor/libarchive/dist/cpio/test/test_owner_parse.c
==============================================================================
--- vendor/libarchive/dist/cpio/test/test_owner_parse.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/cpio/test/test_owner_parse.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -38,7 +38,7 @@ static const int root_gids[] = { 0, 1 };
  * its primary group membership depends on how the user set up
  * their /etc/passwd. Likely values are 513 (None), 545 (Users),
  * or 544 (Administrators). Just check for one of those...
- * TODO: Handle non-English localizations...e.g. French 'Administrateur'
+ * TODO: Handle non-English localizations... e.g. French 'Administrateur'
  *       Use CreateWellKnownSID() and LookupAccountName()?
  */
 #define ROOT "Administrator"

Modified: vendor/libarchive/dist/libarchive/archive_read.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -764,7 +764,7 @@ archive_read_header_position(struct arch
  * we cannot say whether there are encrypted entries, then
  * ARCHIVE_READ_FORMAT_ENCRYPTION_DONT_KNOW is returned.
  * In general, this function will return values below zero when the
- * reader is uncertain or totally uncapable of encryption support.
+ * reader is uncertain or totally incapable of encryption support.
  * When this function returns 0 you can be sure that the reader
  * supports encryption detection but no encrypted entries have
  * been found yet.

Modified: vendor/libarchive/dist/libarchive/archive_read_disk_posix.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_disk_posix.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_disk_posix.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -1026,7 +1026,7 @@ next_entry(struct archive_read_disk *a, 
 
 	/* Save the times to be restored. This must be in before
 	 * calling archive_read_disk_descend() or any chance of it,
-	 * especially, invokng a callback. */
+	 * especially, invoking a callback. */
 	t->restore_time.mtime = archive_entry_mtime(entry);
 	t->restore_time.mtime_nsec = archive_entry_mtime_nsec(entry);
 	t->restore_time.atime = archive_entry_atime(entry);

Modified: vendor/libarchive/dist/libarchive/archive_read_disk_windows.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_disk_windows.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_disk_windows.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -862,7 +862,7 @@ next_entry(struct archive_read_disk *a, 
 
 	/* Save the times to be restored. This must be in before
 	 * calling archive_read_disk_descend() or any chance of it,
-	 * especially, invokng a callback. */
+	 * especially, invoking a callback. */
 	t->restore_time.lastWriteTime = st->ftLastWriteTime;
 	t->restore_time.lastAccessTime = st->ftLastAccessTime;
 	t->restore_time.filetype = archive_entry_filetype(entry);

Modified: vendor/libarchive/dist/libarchive/archive_read_support_filter_xz.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_support_filter_xz.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_support_filter_xz.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -293,7 +293,7 @@ lzma_bidder_bid(struct archive_read_filt
 	/* Second through fifth bytes are dictionary size, stored in
 	 * little-endian order. The minimum dictionary size is
 	 * 1 << 12(4KiB) which the lzma of LZMA SDK uses with option
-	 * -d12 and the maxinam dictionary size is 1 << 27(128MiB)
+	 * -d12 and the maximum dictionary size is 1 << 27(128MiB)
 	 * which the one uses with option -d27.
 	 * NOTE: A comment of LZMA SDK source code says this dictionary
 	 * range is from 1 << 12 to 1 << 30. */
@@ -584,9 +584,7 @@ lzip_init(struct archive_read_filter *se
 		return (ARCHIVE_FATAL);
 	}
 	ret = lzma_raw_decoder(&(state->stream), filters);
-#if LZMA_VERSION < 50010000
 	free(filters[0].options);
-#endif
 	if (ret != LZMA_OK) {
 		set_error(self, ret);
 		return (ARCHIVE_FATAL);

Modified: vendor/libarchive/dist/libarchive/archive_read_support_format_7zip.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_support_format_7zip.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_support_format_7zip.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -263,22 +263,22 @@ struct _7zip {
 	/*
 	 * Decompressor controllers.
 	 */
-	/* Decording LZMA1 and LZMA2 data. */
+	/* Decoding LZMA1 and LZMA2 data. */
 #ifdef HAVE_LZMA_H
 	lzma_stream		 lzstream;
 	int			 lzstream_valid;
 #endif
-	/* Decording bzip2 data. */
+	/* Decoding bzip2 data. */
 #if defined(HAVE_BZLIB_H) && defined(BZ_CONFIG_ERROR)
 	bz_stream		 bzstream;
 	int			 bzstream_valid;
 #endif
-	/* Decording deflate data. */
+	/* Decoding deflate data. */
 #ifdef HAVE_ZLIB_H
 	z_stream		 stream;
 	int			 stream_valid;
 #endif
-	/* Decording PPMd data. */
+	/* Decoding PPMd data. */
 	int			 ppmd7_stat;
 	CPpmd7			 ppmd7_context;
 	CPpmd7z_RangeDec	 range_dec;
@@ -1056,10 +1056,7 @@ init_decompression(struct archive_read *
 #endif
 	{
 		lzma_options_delta delta_opt;
-		lzma_filter filters[LZMA_FILTERS_MAX];
-#if LZMA_VERSION < 50010000
-		lzma_filter *ff;
-#endif
+		lzma_filter filters[LZMA_FILTERS_MAX], *ff;
 		int fi = 0;
 
 		if (zip->lzstream_valid) {
@@ -1144,9 +1141,7 @@ init_decompression(struct archive_read *
 		else
 			filters[fi].id = LZMA_FILTER_LZMA1;
 		filters[fi].options = NULL;
-#if LZMA_VERSION < 50010000
 		ff = &filters[fi];
-#endif
 		r = lzma_properties_decode(&filters[fi], NULL,
 		    coder1->properties, (size_t)coder1->propertiesSize);
 		if (r != LZMA_OK) {
@@ -1158,9 +1153,7 @@ init_decompression(struct archive_read *
 		filters[fi].id = LZMA_VLI_UNKNOWN;
 		filters[fi].options = NULL;
 		r = lzma_raw_decoder(&(zip->lzstream), filters);
-#if LZMA_VERSION < 50010000
 		free(ff->options);
-#endif
 		if (r != LZMA_OK) {
 			set_error(a, r);
 			return (ARCHIVE_FAILED);

Modified: vendor/libarchive/dist/libarchive/archive_read_support_format_cpio.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_support_format_cpio.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_support_format_cpio.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -326,7 +326,7 @@ archive_read_format_cpio_options(struct 
 
 	cpio = (struct cpio *)(a->format->data);
 	if (strcmp(key, "compat-2x")  == 0) {
-		/* Handle filnames as libarchive 2.x */
+		/* Handle filenames as libarchive 2.x */
 		cpio->init_default_conversion = (val != NULL)?1:0;
 		return (ARCHIVE_OK);
 	} else if (strcmp(key, "hdrcharset")  == 0) {

Modified: vendor/libarchive/dist/libarchive/archive_read_support_format_zip.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_read_support_format_zip.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_read_support_format_zip.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -864,29 +864,33 @@ zip_read_local_file_header(struct archiv
 		zip_entry->mode |= AE_IFREG;
 	}
 
-	if ((zip_entry->mode & AE_IFMT) == 0) {
-		/* Especially in streaming mode, we can end up
-		   here without having seen proper mode information.
-		   Guess from the filename. */
+	/* If the mode is totally empty, set some sane default. */
+	if (zip_entry->mode == 0) {
+		zip_entry->mode |= 0664;
+	}
+
+	/* Make sure that entries with a trailing '/' are marked as directories
+	 * even if the External File Attributes contains bogus values.  If this
+	 * is not a directory and there is no type, assume regularfile. */
+	if ((zip_entry->mode & AE_IFMT) != AE_IFDIR) {
+		int has_slash;
+
 		wp = archive_entry_pathname_w(entry);
 		if (wp != NULL) {
 			len = wcslen(wp);
-			if (len > 0 && wp[len - 1] == L'/')
-				zip_entry->mode |= AE_IFDIR;
-			else
-				zip_entry->mode |= AE_IFREG;
+			has_slash = len > 0 && wp[len - 1] == L'/';
 		} else {
 			cp = archive_entry_pathname(entry);
 			len = (cp != NULL)?strlen(cp):0;
-			if (len > 0 && cp[len - 1] == '/')
-				zip_entry->mode |= AE_IFDIR;
-			else
-				zip_entry->mode |= AE_IFREG;
-		}
-		if (zip_entry->mode == AE_IFDIR) {
-			zip_entry->mode |= 0775;
-		} else if (zip_entry->mode == AE_IFREG) {
-			zip_entry->mode |= 0664;
+			has_slash = len > 0 && cp[len - 1] == '/';
+		}
+		/* Correct file type as needed. */
+		if (has_slash) {
+			zip_entry->mode &= ~AE_IFMT;
+			zip_entry->mode |= AE_IFDIR;
+			zip_entry->mode |= 0111;
+		} else if ((zip_entry->mode & AE_IFMT) == 0) {
+			zip_entry->mode |= AE_IFREG;
 		}
 	}
 

Modified: vendor/libarchive/dist/libarchive/archive_string.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_string.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_string.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -1827,7 +1827,7 @@ archive_string_conversion_set_opt(struct
 	 * A filename in UTF-8 was made with libarchive 2.x in a wrong
 	 * assumption that wchar_t was Unicode.
 	 * This option enables simulating the assumption in order to read
-	 * that filname correctly.
+	 * that filename correctly.
 	 */
 	case SCONV_SET_OPT_UTF8_LIBARCHIVE2X:
 #if (defined(_WIN32) && !defined(__CYGWIN__)) \
@@ -1939,12 +1939,19 @@ archive_strncat_l(struct archive_string 
     struct archive_string_conv *sc)
 {
 	const void *s;
-	size_t length;
+	size_t length = 0;
 	int i, r = 0, r2;
 
+	if (_p != NULL && n > 0) {
+		if (sc != NULL && (sc->flag & SCONV_FROM_UTF16))
+			length = utf16nbytes(_p, n);
+		else
+			length = mbsnbytes(_p, n);
+	}
+
 	/* We must allocate memory even if there is no data for conversion
 	 * or copy. This simulates archive_string_append behavior. */
-	if (_p == NULL || n == 0) {
+	if (length == 0) {
 		int tn = 1;
 		if (sc != NULL && (sc->flag & SCONV_TO_UTF16))
 			tn = 2;
@@ -1960,16 +1967,11 @@ archive_strncat_l(struct archive_string 
 	 * If sc is NULL, we just make a copy.
 	 */
 	if (sc == NULL) {
-		length = mbsnbytes(_p, n);
 		if (archive_string_append(as, _p, length) == NULL)
 			return (-1);/* No memory */
 		return (0);
 	}
 
-	if (sc->flag & SCONV_FROM_UTF16)
-		length = utf16nbytes(_p, n);
-	else
-		length = mbsnbytes(_p, n);
 	s = _p;
 	i = 0;
 	if (sc->nconverter > 1) {

Modified: vendor/libarchive/dist/libarchive/archive_write_set_format_iso9660.c
==============================================================================
--- vendor/libarchive/dist/libarchive/archive_write_set_format_iso9660.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/archive_write_set_format_iso9660.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -680,7 +680,7 @@ struct iso9660 {
 	/* The creation time of ISO image. */
 	time_t			 birth_time;
 	/* A file stream of a temporary file, which file contents
-	 * save to until ISO iamge can be created. */
+	 * save to until ISO image can be created. */
 	int			 temp_fd;
 
 	struct isofile		*cur_file;
@@ -1995,7 +1995,7 @@ iso9660_close(struct archive_write *a)
 	 * Write an ISO 9660 image.
 	 */
 
-	/* Switc to start using wbuff as file buffer. */
+	/* Switch to start using wbuff as file buffer. */
 	iso9660->wbuff_remaining = wb_buffmax();
 	iso9660->wbuff_type = WB_TO_STREAM;
 	iso9660->wbuff_offset = 0;
@@ -4558,7 +4558,7 @@ write_file_descriptors(struct archive_wr
 		file->cur_content = &(file->content);
 		do {
 			blocks += file->cur_content->blocks;
-			/* Next fragument */
+			/* Next fragment */
 			file->cur_content = file->cur_content->next;
 		} while (file->cur_content != NULL);
 	}
@@ -4748,7 +4748,7 @@ isofile_gen_utility_names(struct archive
 		}
 
 		/*
-		 * Converte a filename to UTF-16BE.
+		 * Convert a filename to UTF-16BE.
 		 */
 		if (0 > archive_entry_pathname_l(file->entry, &u16, &u16len,
 		    iso9660->sconv_to_utf16be)) {
@@ -5512,7 +5512,7 @@ isoent_setup_file_location(struct iso966
 			file->cur_content->location = location;
 			location += file->cur_content->blocks;
 			total_block += file->cur_content->blocks;
-			/* Next fragument */
+			/* Next fragment */
 			file->cur_content = file->cur_content->next;
 		} while (file->cur_content != NULL);
 	}
@@ -6164,7 +6164,7 @@ isoent_gen_iso9660_identifier(struct arc
 		np->id_len = l = ext_off + np->ext_len;
 
 		/* Make an offset of the number which is used to be set
-		 * hexadecimal number to avoid duplicate identififier. */
+		 * hexadecimal number to avoid duplicate identifier. */
 		if (iso9660->opt.iso_level == 1) {
 			if (ext_off >= 5)
 				noff = 5;
@@ -6742,7 +6742,7 @@ isoent_rr_move(struct archive_write *a)
 	int r;
 
 	pt = &(iso9660->primary.pathtbl[MAX_DEPTH-1]);
-	/* Theare aren't level 8 directories reaching a deepr level. */
+	/* There aren't level 8 directories reaching a deeper level. */
 	if (pt->cnt == 0)
 		return (ARCHIVE_OK);
 
@@ -6813,7 +6813,7 @@ _compare_path_table(const void *v1, cons
 	if (cmp != 0)
 		return (cmp);
 
-	/* Compare indetifier */
+	/* Compare identifier */
 	s1 = p1->identifier;
 	s2 = p2->identifier;
 	l = p1->ext_off;
@@ -6855,7 +6855,7 @@ _compare_path_table_joliet(const void *v
 	if (cmp != 0)
 		return (cmp);
 
-	/* Compare indetifier */
+	/* Compare identifier */
 	s1 = (const unsigned char *)p1->identifier;
 	s2 = (const unsigned char *)p2->identifier;
 	l = p1->ext_off;

Modified: vendor/libarchive/dist/libarchive/test/CMakeLists.txt
==============================================================================
--- vendor/libarchive/dist/libarchive/test/CMakeLists.txt	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/CMakeLists.txt	Tue Dec 27 00:51:53 2016	(r310622)
@@ -169,6 +169,7 @@ IF(ENABLE_TEST)
     test_read_format_zip_encryption_partially.c
     test_read_format_zip_filename.c
     test_read_format_zip_high_compression.c
+    test_read_format_zip_jar.c
     test_read_format_zip_mac_metadata.c
     test_read_format_zip_malformed.c
     test_read_format_zip_msdos.c

Modified: vendor/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c
==============================================================================
--- vendor/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/test_read_disk_directory_traversals.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -500,8 +500,8 @@ test_basic(void)
 
 	/*
 	 * We should be on the initial directory where we performed
-	 * archive_read_disk_new() after we perfome archive_read_free()
-	 *  even if we broke off the directory traversals.
+	 * archive_read_disk_new() after we perform archive_read_free()
+	 * even if we broke off the directory traversals.
 	 */
 
 	/* Save current working directory. */
@@ -1565,11 +1565,11 @@ DEFINE_TEST(test_read_disk_directory_tra
 {
 	/* Basic test. */
 	test_basic();
-	/* Test hybird mode; follow symlink initially, then not. */
+	/* Test hybrid mode; follow symlink initially, then not. */
 	test_symlink_hybrid();
-	/* Test logcal mode; follow all symlinks. */
+	/* Test logical mode; follow all symlinks. */
 	test_symlink_logical();
-	/* Test logcal mode; prevent loop in symlinks. */ 
+	/* Test logical mode; prevent loop in symlinks. */
 	test_symlink_logical_loop();
 	/* Test to restore atime. */
 	test_restore_atime();

Added: vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -0,0 +1,59 @@
+/*-
+ * Copyright (c) 2016 Peter Wu
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+#include "test.h"
+__FBSDID("$FreeBSD$");
+
+/*
+ * Issue 822: jar files have an empty External File Attributes field which
+ * is misinterpreted as regular file type due to OS MS-DOS.
+ */
+
+DEFINE_TEST(test_read_format_zip_jar)
+{
+	const char *refname = "test_read_format_zip_jar.jar";
+	char *p;
+	size_t s;
+	struct archive *a;
+	struct archive_entry *ae;
+	char data[16];
+
+	extract_reference_file(refname);
+	p = slurpfile(&s, refname);
+
+	assert((a = archive_read_new()) != NULL);
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_support_format_zip_seekable(a));
+	assertEqualIntA(a, ARCHIVE_OK, read_open_memory_seek(a, p, s, 1));
+
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
+	assertEqualString("somedir/", archive_entry_pathname(ae));
+	assertEqualInt(AE_IFDIR | 0775, archive_entry_mode(ae));
+	assertEqualInt(0, archive_entry_size(ae));
+	assertEqualIntA(a, 0, archive_read_data(a, data, 16));
+
+	assertEqualIntA(a, ARCHIVE_EOF, archive_read_next_header(a, &ae));
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_close(a));
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_free(a));
+	free(p);
+}

Added: vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu	Tue Dec 27 00:51:53 2016	(r310622)
@@ -0,0 +1,6 @@
+begin 640 test_read_format_zip_jar.jar
+M4$L#! H   @  $AQETD                (  0 <V]M961I<B_^R@  4$L!
+M @H "@  "   2'&720                @ !                    '-O
+@;65D:7(O_LH  %!+!08      0 ! #H    J        
+ 
+end

Modified: vendor/libarchive/dist/libarchive/test/test_write_disk_appledouble.c
==============================================================================
--- vendor/libarchive/dist/libarchive/test/test_write_disk_appledouble.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/test_write_disk_appledouble.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -144,7 +144,7 @@ DEFINE_TEST(test_write_disk_appledouble)
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
-	/* Extract ._file3 which will be merged into file3 as medtadata. */
+	/* Extract ._file3 which will be merged into file3 as metadata. */
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./._file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
@@ -203,7 +203,7 @@ DEFINE_TEST(test_write_disk_appledouble)
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
-	/* Extract ._file3 which will be merged into file3 as medtadata. */
+	/* Extract ._file3 which will be merged into file3 as metadata. */
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./._file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));

Modified: vendor/libarchive/dist/libarchive/test/test_write_format_xar_empty.c
==============================================================================
--- vendor/libarchive/dist/libarchive/test/test_write_format_xar_empty.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/test_write_format_xar_empty.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -115,6 +115,6 @@ DEFINE_TEST(test_write_format_xar_empty)
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Xar archive. */
+	/* Verify the correct format for an empty Xar archive. */
 	assertEqualInt(used, 0);
 }

Modified: vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty.c
==============================================================================
--- vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -49,7 +49,7 @@ DEFINE_TEST(test_write_format_zip_empty)
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Zip archive. */
+	/* Verify the correct format for an empty Zip archive. */
 	assertEqualInt(used, 22);
 	assertEqualMem(buff,
 	    "PK\005\006\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",

Modified: vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty_zip64.c
==============================================================================
--- vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty_zip64.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/libarchive/test/test_write_format_zip_empty_zip64.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -51,7 +51,7 @@ DEFINE_TEST(test_write_format_zip_empty_
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Zip archive with Zip64 extensions forced. */
+	/* Verify the correct format for an empty Zip archive with Zip64 extensions forced. */
 	assertEqualInt(used, 98);
 	assertEqualMem(buff,
 	    "PK\006\006" /* Zip64 end-of-central-directory record */

Modified: vendor/libarchive/dist/tar/read.c
==============================================================================
--- vendor/libarchive/dist/tar/read.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/tar/read.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -188,18 +188,17 @@ read_archive(struct bsdtar *bsdtar, char
 
 	reader_options = getenv(ENV_READER_OPTIONS);
 	if (reader_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(reader_options) + 1;
 		char *p;
 		/* Set default read options. */
-		p = (char *)malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(reader_options) + 1);
-		if (p == NULL)
+		if ((p = malloc(module_len + opt_len)) == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or  modules which are not added to
 		 *  the archive read object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, reader_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p + module_len, reader_options, opt_len);
 		r = archive_read_set_options(a, p);
 		free(p);
 		if (r == ARCHIVE_FATAL)

Modified: vendor/libarchive/dist/tar/write.c
==============================================================================
--- vendor/libarchive/dist/tar/write.c	Mon Dec 26 22:13:43 2016	(r310621)
+++ vendor/libarchive/dist/tar/write.c	Tue Dec 27 00:51:53 2016	(r310622)
@@ -145,18 +145,17 @@ set_writer_options(struct bsdtar *bsdtar
 
 	writer_options = getenv(ENV_WRITER_OPTIONS);
 	if (writer_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(writer_options) + 1;
 		char *p;
 		/* Set default write options. */
-		p = malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(writer_options) + 1);
-		if (p == NULL)
+		if ((p = malloc(module_len + opt_len)) == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or filters which are not added to
 		 * the archive write object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, writer_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p, writer_options, opt_len);
 		r = archive_write_set_options(a, p);
 		free(p);
 		if (r < ARCHIVE_WARN)
@@ -178,18 +177,18 @@ set_reader_options(struct bsdtar *bsdtar
 
 	reader_options = getenv(ENV_READER_OPTIONS);
 	if (reader_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(reader_options) + 1;
 		char *p;
 		/* Set default write options. */
-		p = malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(reader_options) + 1);
+		if ((p = malloc(module_len + opt_len)) == NULL)
 		if (p == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or filters which are not added to
 		 * the archive write object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, reader_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p, reader_options, opt_len);
 		r = archive_read_set_options(a, p);
 		free(p);
 		if (r < ARCHIVE_WARN)

From owner-svn-src-all@freebsd.org  Tue Dec 27 01:10:31 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E3930C91267;
 Tue, 27 Dec 2016 01:10:31 +0000 (UTC) (envelope-from mm@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 921C31CC2;
 Tue, 27 Dec 2016 01:10:31 +0000 (UTC) (envelope-from mm@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR1AUk9005241;
 Tue, 27 Dec 2016 01:10:30 GMT (envelope-from mm@FreeBSD.org)
Received: (from mm@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR1AS3a005222;
 Tue, 27 Dec 2016 01:10:28 GMT (envelope-from mm@FreeBSD.org)
Message-Id: <201612270110.uBR1AS3a005222@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mm set sender to mm@FreeBSD.org
 using -f
From: Martin Matuska <mm@FreeBSD.org>
Date: Tue, 27 Dec 2016 01:10:28 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310623 - in head: contrib/libarchive/cpio/test
 contrib/libarchive/libarchive contrib/libarchive/libarchive/test
 contrib/libarchive/tar lib/libarchive/tests
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 01:10:32 -0000

Author: mm
Date: Tue Dec 27 01:10:28 2016
New Revision: 310623
URL: https://svnweb.freebsd.org/changeset/base/310623

Log:
  MFV r310622:
  
  Sync libarchive with vendor.
  
  Vendor bugfixes (relevant to FreeBSD):
  PR 846: Spelling fixes
  PR 850: Fix issues with reading certain jar files
  OSS-Fuzz 286: Bugfix in archive_strncat_l()

Added:
  head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.c
     - copied unchanged from r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c
  head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.jar.uu
     - copied unchanged from r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu
Modified:
  head/contrib/libarchive/cpio/test/test_owner_parse.c
  head/contrib/libarchive/libarchive/archive_read.c
  head/contrib/libarchive/libarchive/archive_read_disk_posix.c
  head/contrib/libarchive/libarchive/archive_read_support_filter_xz.c
  head/contrib/libarchive/libarchive/archive_read_support_format_7zip.c
  head/contrib/libarchive/libarchive/archive_read_support_format_cpio.c
  head/contrib/libarchive/libarchive/archive_read_support_format_zip.c
  head/contrib/libarchive/libarchive/archive_string.c
  head/contrib/libarchive/libarchive/archive_write_set_format_iso9660.c
  head/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
  head/contrib/libarchive/libarchive/test/test_write_disk_appledouble.c
  head/contrib/libarchive/libarchive/test/test_write_format_xar_empty.c
  head/contrib/libarchive/libarchive/test/test_write_format_zip_empty.c
  head/contrib/libarchive/libarchive/test/test_write_format_zip_empty_zip64.c
  head/contrib/libarchive/tar/read.c
  head/contrib/libarchive/tar/write.c
  head/lib/libarchive/tests/Makefile
Directory Properties:
  head/contrib/libarchive/   (props changed)

Modified: head/contrib/libarchive/cpio/test/test_owner_parse.c
==============================================================================
--- head/contrib/libarchive/cpio/test/test_owner_parse.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/cpio/test/test_owner_parse.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -38,7 +38,7 @@ static const int root_gids[] = { 0, 1 };
  * its primary group membership depends on how the user set up
  * their /etc/passwd. Likely values are 513 (None), 545 (Users),
  * or 544 (Administrators). Just check for one of those...
- * TODO: Handle non-English localizations...e.g. French 'Administrateur'
+ * TODO: Handle non-English localizations... e.g. French 'Administrateur'
  *       Use CreateWellKnownSID() and LookupAccountName()?
  */
 #define ROOT "Administrator"

Modified: head/contrib/libarchive/libarchive/archive_read.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -764,7 +764,7 @@ archive_read_header_position(struct arch
  * we cannot say whether there are encrypted entries, then
  * ARCHIVE_READ_FORMAT_ENCRYPTION_DONT_KNOW is returned.
  * In general, this function will return values below zero when the
- * reader is uncertain or totally uncapable of encryption support.
+ * reader is uncertain or totally incapable of encryption support.
  * When this function returns 0 you can be sure that the reader
  * supports encryption detection but no encrypted entries have
  * been found yet.

Modified: head/contrib/libarchive/libarchive/archive_read_disk_posix.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read_disk_posix.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read_disk_posix.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -1026,7 +1026,7 @@ next_entry(struct archive_read_disk *a, 
 
 	/* Save the times to be restored. This must be in before
 	 * calling archive_read_disk_descend() or any chance of it,
-	 * especially, invokng a callback. */
+	 * especially, invoking a callback. */
 	t->restore_time.mtime = archive_entry_mtime(entry);
 	t->restore_time.mtime_nsec = archive_entry_mtime_nsec(entry);
 	t->restore_time.atime = archive_entry_atime(entry);

Modified: head/contrib/libarchive/libarchive/archive_read_support_filter_xz.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read_support_filter_xz.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read_support_filter_xz.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -293,7 +293,7 @@ lzma_bidder_bid(struct archive_read_filt
 	/* Second through fifth bytes are dictionary size, stored in
 	 * little-endian order. The minimum dictionary size is
 	 * 1 << 12(4KiB) which the lzma of LZMA SDK uses with option
-	 * -d12 and the maxinam dictionary size is 1 << 27(128MiB)
+	 * -d12 and the maximum dictionary size is 1 << 27(128MiB)
 	 * which the one uses with option -d27.
 	 * NOTE: A comment of LZMA SDK source code says this dictionary
 	 * range is from 1 << 12 to 1 << 30. */
@@ -584,9 +584,7 @@ lzip_init(struct archive_read_filter *se
 		return (ARCHIVE_FATAL);
 	}
 	ret = lzma_raw_decoder(&(state->stream), filters);
-#if LZMA_VERSION < 50010000
 	free(filters[0].options);
-#endif
 	if (ret != LZMA_OK) {
 		set_error(self, ret);
 		return (ARCHIVE_FATAL);

Modified: head/contrib/libarchive/libarchive/archive_read_support_format_7zip.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read_support_format_7zip.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read_support_format_7zip.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -263,22 +263,22 @@ struct _7zip {
 	/*
 	 * Decompressor controllers.
 	 */
-	/* Decording LZMA1 and LZMA2 data. */
+	/* Decoding LZMA1 and LZMA2 data. */
 #ifdef HAVE_LZMA_H
 	lzma_stream		 lzstream;
 	int			 lzstream_valid;
 #endif
-	/* Decording bzip2 data. */
+	/* Decoding bzip2 data. */
 #if defined(HAVE_BZLIB_H) && defined(BZ_CONFIG_ERROR)
 	bz_stream		 bzstream;
 	int			 bzstream_valid;
 #endif
-	/* Decording deflate data. */
+	/* Decoding deflate data. */
 #ifdef HAVE_ZLIB_H
 	z_stream		 stream;
 	int			 stream_valid;
 #endif
-	/* Decording PPMd data. */
+	/* Decoding PPMd data. */
 	int			 ppmd7_stat;
 	CPpmd7			 ppmd7_context;
 	CPpmd7z_RangeDec	 range_dec;
@@ -1056,10 +1056,7 @@ init_decompression(struct archive_read *
 #endif
 	{
 		lzma_options_delta delta_opt;
-		lzma_filter filters[LZMA_FILTERS_MAX];
-#if LZMA_VERSION < 50010000
-		lzma_filter *ff;
-#endif
+		lzma_filter filters[LZMA_FILTERS_MAX], *ff;
 		int fi = 0;
 
 		if (zip->lzstream_valid) {
@@ -1144,9 +1141,7 @@ init_decompression(struct archive_read *
 		else
 			filters[fi].id = LZMA_FILTER_LZMA1;
 		filters[fi].options = NULL;
-#if LZMA_VERSION < 50010000
 		ff = &filters[fi];
-#endif
 		r = lzma_properties_decode(&filters[fi], NULL,
 		    coder1->properties, (size_t)coder1->propertiesSize);
 		if (r != LZMA_OK) {
@@ -1158,9 +1153,7 @@ init_decompression(struct archive_read *
 		filters[fi].id = LZMA_VLI_UNKNOWN;
 		filters[fi].options = NULL;
 		r = lzma_raw_decoder(&(zip->lzstream), filters);
-#if LZMA_VERSION < 50010000
 		free(ff->options);
-#endif
 		if (r != LZMA_OK) {
 			set_error(a, r);
 			return (ARCHIVE_FAILED);

Modified: head/contrib/libarchive/libarchive/archive_read_support_format_cpio.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read_support_format_cpio.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read_support_format_cpio.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -326,7 +326,7 @@ archive_read_format_cpio_options(struct 
 
 	cpio = (struct cpio *)(a->format->data);
 	if (strcmp(key, "compat-2x")  == 0) {
-		/* Handle filnames as libarchive 2.x */
+		/* Handle filenames as libarchive 2.x */
 		cpio->init_default_conversion = (val != NULL)?1:0;
 		return (ARCHIVE_OK);
 	} else if (strcmp(key, "hdrcharset")  == 0) {

Modified: head/contrib/libarchive/libarchive/archive_read_support_format_zip.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_read_support_format_zip.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_read_support_format_zip.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -864,29 +864,33 @@ zip_read_local_file_header(struct archiv
 		zip_entry->mode |= AE_IFREG;
 	}
 
-	if ((zip_entry->mode & AE_IFMT) == 0) {
-		/* Especially in streaming mode, we can end up
-		   here without having seen proper mode information.
-		   Guess from the filename. */
+	/* If the mode is totally empty, set some sane default. */
+	if (zip_entry->mode == 0) {
+		zip_entry->mode |= 0664;
+	}
+
+	/* Make sure that entries with a trailing '/' are marked as directories
+	 * even if the External File Attributes contains bogus values.  If this
+	 * is not a directory and there is no type, assume regularfile. */
+	if ((zip_entry->mode & AE_IFMT) != AE_IFDIR) {
+		int has_slash;
+
 		wp = archive_entry_pathname_w(entry);
 		if (wp != NULL) {
 			len = wcslen(wp);
-			if (len > 0 && wp[len - 1] == L'/')
-				zip_entry->mode |= AE_IFDIR;
-			else
-				zip_entry->mode |= AE_IFREG;
+			has_slash = len > 0 && wp[len - 1] == L'/';
 		} else {
 			cp = archive_entry_pathname(entry);
 			len = (cp != NULL)?strlen(cp):0;
-			if (len > 0 && cp[len - 1] == '/')
-				zip_entry->mode |= AE_IFDIR;
-			else
-				zip_entry->mode |= AE_IFREG;
-		}
-		if (zip_entry->mode == AE_IFDIR) {
-			zip_entry->mode |= 0775;
-		} else if (zip_entry->mode == AE_IFREG) {
-			zip_entry->mode |= 0664;
+			has_slash = len > 0 && cp[len - 1] == '/';
+		}
+		/* Correct file type as needed. */
+		if (has_slash) {
+			zip_entry->mode &= ~AE_IFMT;
+			zip_entry->mode |= AE_IFDIR;
+			zip_entry->mode |= 0111;
+		} else if ((zip_entry->mode & AE_IFMT) == 0) {
+			zip_entry->mode |= AE_IFREG;
 		}
 	}
 

Modified: head/contrib/libarchive/libarchive/archive_string.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_string.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_string.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -1827,7 +1827,7 @@ archive_string_conversion_set_opt(struct
 	 * A filename in UTF-8 was made with libarchive 2.x in a wrong
 	 * assumption that wchar_t was Unicode.
 	 * This option enables simulating the assumption in order to read
-	 * that filname correctly.
+	 * that filename correctly.
 	 */
 	case SCONV_SET_OPT_UTF8_LIBARCHIVE2X:
 #if (defined(_WIN32) && !defined(__CYGWIN__)) \
@@ -1939,12 +1939,19 @@ archive_strncat_l(struct archive_string 
     struct archive_string_conv *sc)
 {
 	const void *s;
-	size_t length;
+	size_t length = 0;
 	int i, r = 0, r2;
 
+	if (_p != NULL && n > 0) {
+		if (sc != NULL && (sc->flag & SCONV_FROM_UTF16))
+			length = utf16nbytes(_p, n);
+		else
+			length = mbsnbytes(_p, n);
+	}
+
 	/* We must allocate memory even if there is no data for conversion
 	 * or copy. This simulates archive_string_append behavior. */
-	if (_p == NULL || n == 0) {
+	if (length == 0) {
 		int tn = 1;
 		if (sc != NULL && (sc->flag & SCONV_TO_UTF16))
 			tn = 2;
@@ -1960,16 +1967,11 @@ archive_strncat_l(struct archive_string 
 	 * If sc is NULL, we just make a copy.
 	 */
 	if (sc == NULL) {
-		length = mbsnbytes(_p, n);
 		if (archive_string_append(as, _p, length) == NULL)
 			return (-1);/* No memory */
 		return (0);
 	}
 
-	if (sc->flag & SCONV_FROM_UTF16)
-		length = utf16nbytes(_p, n);
-	else
-		length = mbsnbytes(_p, n);
 	s = _p;
 	i = 0;
 	if (sc->nconverter > 1) {

Modified: head/contrib/libarchive/libarchive/archive_write_set_format_iso9660.c
==============================================================================
--- head/contrib/libarchive/libarchive/archive_write_set_format_iso9660.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/archive_write_set_format_iso9660.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -680,7 +680,7 @@ struct iso9660 {
 	/* The creation time of ISO image. */
 	time_t			 birth_time;
 	/* A file stream of a temporary file, which file contents
-	 * save to until ISO iamge can be created. */
+	 * save to until ISO image can be created. */
 	int			 temp_fd;
 
 	struct isofile		*cur_file;
@@ -1995,7 +1995,7 @@ iso9660_close(struct archive_write *a)
 	 * Write an ISO 9660 image.
 	 */
 
-	/* Switc to start using wbuff as file buffer. */
+	/* Switch to start using wbuff as file buffer. */
 	iso9660->wbuff_remaining = wb_buffmax();
 	iso9660->wbuff_type = WB_TO_STREAM;
 	iso9660->wbuff_offset = 0;
@@ -4558,7 +4558,7 @@ write_file_descriptors(struct archive_wr
 		file->cur_content = &(file->content);
 		do {
 			blocks += file->cur_content->blocks;
-			/* Next fragument */
+			/* Next fragment */
 			file->cur_content = file->cur_content->next;
 		} while (file->cur_content != NULL);
 	}
@@ -4748,7 +4748,7 @@ isofile_gen_utility_names(struct archive
 		}
 
 		/*
-		 * Converte a filename to UTF-16BE.
+		 * Convert a filename to UTF-16BE.
 		 */
 		if (0 > archive_entry_pathname_l(file->entry, &u16, &u16len,
 		    iso9660->sconv_to_utf16be)) {
@@ -5512,7 +5512,7 @@ isoent_setup_file_location(struct iso966
 			file->cur_content->location = location;
 			location += file->cur_content->blocks;
 			total_block += file->cur_content->blocks;
-			/* Next fragument */
+			/* Next fragment */
 			file->cur_content = file->cur_content->next;
 		} while (file->cur_content != NULL);
 	}
@@ -6164,7 +6164,7 @@ isoent_gen_iso9660_identifier(struct arc
 		np->id_len = l = ext_off + np->ext_len;
 
 		/* Make an offset of the number which is used to be set
-		 * hexadecimal number to avoid duplicate identififier. */
+		 * hexadecimal number to avoid duplicate identifier. */
 		if (iso9660->opt.iso_level == 1) {
 			if (ext_off >= 5)
 				noff = 5;
@@ -6742,7 +6742,7 @@ isoent_rr_move(struct archive_write *a)
 	int r;
 
 	pt = &(iso9660->primary.pathtbl[MAX_DEPTH-1]);
-	/* Theare aren't level 8 directories reaching a deepr level. */
+	/* There aren't level 8 directories reaching a deeper level. */
 	if (pt->cnt == 0)
 		return (ARCHIVE_OK);
 
@@ -6813,7 +6813,7 @@ _compare_path_table(const void *v1, cons
 	if (cmp != 0)
 		return (cmp);
 
-	/* Compare indetifier */
+	/* Compare identifier */
 	s1 = p1->identifier;
 	s2 = p2->identifier;
 	l = p1->ext_off;
@@ -6855,7 +6855,7 @@ _compare_path_table_joliet(const void *v
 	if (cmp != 0)
 		return (cmp);
 
-	/* Compare indetifier */
+	/* Compare identifier */
 	s1 = (const unsigned char *)p1->identifier;
 	s2 = (const unsigned char *)p2->identifier;
 	l = p1->ext_off;

Modified: head/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c
==============================================================================
--- head/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/test/test_read_disk_directory_traversals.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -500,8 +500,8 @@ test_basic(void)
 
 	/*
 	 * We should be on the initial directory where we performed
-	 * archive_read_disk_new() after we perfome archive_read_free()
-	 *  even if we broke off the directory traversals.
+	 * archive_read_disk_new() after we perform archive_read_free()
+	 * even if we broke off the directory traversals.
 	 */
 
 	/* Save current working directory. */
@@ -1565,11 +1565,11 @@ DEFINE_TEST(test_read_disk_directory_tra
 {
 	/* Basic test. */
 	test_basic();
-	/* Test hybird mode; follow symlink initially, then not. */
+	/* Test hybrid mode; follow symlink initially, then not. */
 	test_symlink_hybrid();
-	/* Test logcal mode; follow all symlinks. */
+	/* Test logical mode; follow all symlinks. */
 	test_symlink_logical();
-	/* Test logcal mode; prevent loop in symlinks. */ 
+	/* Test logical mode; prevent loop in symlinks. */
 	test_symlink_logical_loop();
 	/* Test to restore atime. */
 	test_restore_atime();

Copied: head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.c (from r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.c	Tue Dec 27 01:10:28 2016	(r310623, copy of r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.c)
@@ -0,0 +1,59 @@
+/*-
+ * Copyright (c) 2016 Peter Wu
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+#include "test.h"
+__FBSDID("$FreeBSD$");
+
+/*
+ * Issue 822: jar files have an empty External File Attributes field which
+ * is misinterpreted as regular file type due to OS MS-DOS.
+ */
+
+DEFINE_TEST(test_read_format_zip_jar)
+{
+	const char *refname = "test_read_format_zip_jar.jar";
+	char *p;
+	size_t s;
+	struct archive *a;
+	struct archive_entry *ae;
+	char data[16];
+
+	extract_reference_file(refname);
+	p = slurpfile(&s, refname);
+
+	assert((a = archive_read_new()) != NULL);
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_support_format_zip_seekable(a));
+	assertEqualIntA(a, ARCHIVE_OK, read_open_memory_seek(a, p, s, 1));
+
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
+	assertEqualString("somedir/", archive_entry_pathname(ae));
+	assertEqualInt(AE_IFDIR | 0775, archive_entry_mode(ae));
+	assertEqualInt(0, archive_entry_size(ae));
+	assertEqualIntA(a, 0, archive_read_data(a, data, 16));
+
+	assertEqualIntA(a, ARCHIVE_EOF, archive_read_next_header(a, &ae));
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_close(a));
+	assertEqualIntA(a, ARCHIVE_OK, archive_read_free(a));
+	free(p);
+}

Copied: head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.jar.uu (from r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/contrib/libarchive/libarchive/test/test_read_format_zip_jar.jar.uu	Tue Dec 27 01:10:28 2016	(r310623, copy of r310622, vendor/libarchive/dist/libarchive/test/test_read_format_zip_jar.jar.uu)
@@ -0,0 +1,6 @@
+begin 640 test_read_format_zip_jar.jar
+M4$L#! H   @  $AQETD                (  0 <V]M961I<B_^R@  4$L!
+M @H "@  "   2'&720                @ !                    '-O
+@;65D:7(O_LH  %!+!08      0 ! #H    J        
+ 
+end

Modified: head/contrib/libarchive/libarchive/test/test_write_disk_appledouble.c
==============================================================================
--- head/contrib/libarchive/libarchive/test/test_write_disk_appledouble.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/test/test_write_disk_appledouble.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -144,7 +144,7 @@ DEFINE_TEST(test_write_disk_appledouble)
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
-	/* Extract ._file3 which will be merged into file3 as medtadata. */
+	/* Extract ._file3 which will be merged into file3 as metadata. */
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./._file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
@@ -203,7 +203,7 @@ DEFINE_TEST(test_write_disk_appledouble)
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));
-	/* Extract ._file3 which will be merged into file3 as medtadata. */
+	/* Extract ._file3 which will be merged into file3 as metadata. */
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_next_header(a, &ae));
 	assertEqualString("./._file3", archive_entry_pathname(ae));
 	assertEqualIntA(a, ARCHIVE_OK, archive_read_extract2(a, ae, ad));

Modified: head/contrib/libarchive/libarchive/test/test_write_format_xar_empty.c
==============================================================================
--- head/contrib/libarchive/libarchive/test/test_write_format_xar_empty.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/test/test_write_format_xar_empty.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -115,6 +115,6 @@ DEFINE_TEST(test_write_format_xar_empty)
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Xar archive. */
+	/* Verify the correct format for an empty Xar archive. */
 	assertEqualInt(used, 0);
 }

Modified: head/contrib/libarchive/libarchive/test/test_write_format_zip_empty.c
==============================================================================
--- head/contrib/libarchive/libarchive/test/test_write_format_zip_empty.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/test/test_write_format_zip_empty.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -49,7 +49,7 @@ DEFINE_TEST(test_write_format_zip_empty)
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Zip archive. */
+	/* Verify the correct format for an empty Zip archive. */
 	assertEqualInt(used, 22);
 	assertEqualMem(buff,
 	    "PK\005\006\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",

Modified: head/contrib/libarchive/libarchive/test/test_write_format_zip_empty_zip64.c
==============================================================================
--- head/contrib/libarchive/libarchive/test/test_write_format_zip_empty_zip64.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/libarchive/test/test_write_format_zip_empty_zip64.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -51,7 +51,7 @@ DEFINE_TEST(test_write_format_zip_empty_
 	assertEqualIntA(a, ARCHIVE_OK, archive_write_close(a));
 	assertEqualInt(ARCHIVE_OK, archive_write_free(a));
 
-	/* Verify the correct format for an empy Zip archive with Zip64 extensions forced. */
+	/* Verify the correct format for an empty Zip archive with Zip64 extensions forced. */
 	assertEqualInt(used, 98);
 	assertEqualMem(buff,
 	    "PK\006\006" /* Zip64 end-of-central-directory record */

Modified: head/contrib/libarchive/tar/read.c
==============================================================================
--- head/contrib/libarchive/tar/read.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/tar/read.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -188,18 +188,17 @@ read_archive(struct bsdtar *bsdtar, char
 
 	reader_options = getenv(ENV_READER_OPTIONS);
 	if (reader_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(reader_options) + 1;
 		char *p;
 		/* Set default read options. */
-		p = (char *)malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(reader_options) + 1);
-		if (p == NULL)
+		if ((p = malloc(module_len + opt_len)) == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or  modules which are not added to
 		 *  the archive read object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, reader_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p + module_len, reader_options, opt_len);
 		r = archive_read_set_options(a, p);
 		free(p);
 		if (r == ARCHIVE_FATAL)

Modified: head/contrib/libarchive/tar/write.c
==============================================================================
--- head/contrib/libarchive/tar/write.c	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/contrib/libarchive/tar/write.c	Tue Dec 27 01:10:28 2016	(r310623)
@@ -145,18 +145,17 @@ set_writer_options(struct bsdtar *bsdtar
 
 	writer_options = getenv(ENV_WRITER_OPTIONS);
 	if (writer_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(writer_options) + 1;
 		char *p;
 		/* Set default write options. */
-		p = malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(writer_options) + 1);
-		if (p == NULL)
+		if ((p = malloc(module_len + opt_len)) == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or filters which are not added to
 		 * the archive write object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, writer_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p, writer_options, opt_len);
 		r = archive_write_set_options(a, p);
 		free(p);
 		if (r < ARCHIVE_WARN)
@@ -178,18 +177,18 @@ set_reader_options(struct bsdtar *bsdtar
 
 	reader_options = getenv(ENV_READER_OPTIONS);
 	if (reader_options != NULL) {
+		size_t module_len = sizeof(IGNORE_WRONG_MODULE_NAME) - 1;
+		size_t opt_len = strlen(reader_options) + 1;
 		char *p;
 		/* Set default write options. */
-		p = malloc(sizeof(IGNORE_WRONG_MODULE_NAME)
-		    + strlen(reader_options) + 1);
+		if ((p = malloc(module_len + opt_len)) == NULL)
 		if (p == NULL)
 			lafe_errc(1, errno, "Out of memory");
 		/* Prepend magic code to ignore options for
 		 * a format or filters which are not added to
 		 * the archive write object. */
-		strncpy(p, IGNORE_WRONG_MODULE_NAME,
-		    sizeof(IGNORE_WRONG_MODULE_NAME) -1);
-		strcpy(p + sizeof(IGNORE_WRONG_MODULE_NAME) -1, reader_options);
+		memcpy(p, IGNORE_WRONG_MODULE_NAME, module_len);
+		memcpy(p, reader_options, opt_len);
 		r = archive_read_set_options(a, p);
 		free(p);
 		if (r < ARCHIVE_WARN)

Modified: head/lib/libarchive/tests/Makefile
==============================================================================
--- head/lib/libarchive/tests/Makefile	Tue Dec 27 00:51:53 2016	(r310622)
+++ head/lib/libarchive/tests/Makefile	Tue Dec 27 01:10:28 2016	(r310623)
@@ -182,6 +182,7 @@ TESTS_SRCS= \
 	test_read_format_zip_encryption_partially.c	\
 	test_read_format_zip_filename.c		\
 	test_read_format_zip_high_compression.c	\
+	test_read_format_zip_jar.c		\
 	test_read_format_zip_mac_metadata.c	\
 	test_read_format_zip_malformed.c	\
 	test_read_format_zip_msdos.c		\
@@ -521,6 +522,7 @@ ${PACKAGE}FILES+=	test_read_format_zip_f
 ${PACKAGE}FILES+=	test_read_format_zip_filename_utf8_ru.zip.uu
 ${PACKAGE}FILES+=	test_read_format_zip_filename_utf8_ru2.zip.uu
 ${PACKAGE}FILES+=	test_read_format_zip_high_compression.zip.uu
+${PACKAGE}FILES+=	test_read_format_zip_jar.jar.uu
 ${PACKAGE}FILES+=	test_read_format_zip_length_at_end.zip.uu
 ${PACKAGE}FILES+=	test_read_format_zip_mac_metadata.zip.uu
 ${PACKAGE}FILES+=	test_read_format_zip_malformed1.zip.uu

From owner-svn-src-all@freebsd.org  Tue Dec 27 06:10:30 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 27D1CC92161;
 Tue, 27 Dec 2016 06:10:30 +0000 (UTC)
 (envelope-from adrian@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id DC5871245;
 Tue, 27 Dec 2016 06:10:29 +0000 (UTC)
 (envelope-from adrian@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR6ATpI025715;
 Tue, 27 Dec 2016 06:10:29 GMT (envelope-from adrian@FreeBSD.org)
Received: (from adrian@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR6ASrp025710;
 Tue, 27 Dec 2016 06:10:28 GMT (envelope-from adrian@FreeBSD.org)
Message-Id: <201612270610.uBR6ASrp025710@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: adrian set sender to
 adrian@FreeBSD.org using -f
From: Adrian Chadd <adrian@FreeBSD.org>
Date: Tue, 27 Dec 2016 06:10:28 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310624 - head/sys/net80211
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 06:10:30 -0000

Author: adrian
Date: Tue Dec 27 06:10:28 2016
New Revision: 310624
URL: https://svnweb.freebsd.org/changeset/base/310624

Log:
  [net80211] turn the default TX key configuration (for WEP) into a vap callback.
  
  The ath10k firmware supports hardware WEP offload, and in native wifi mode
  (or 802.3 ethernet mode, for that matter) the WEP key isn't actually included
  in the TX payload from net80211.  Instead, a separate firmware command is issued
  that sets the default TX key to be the specified key.
  
  However, net80211 doesn't at all inform the driver layer that this is
  occuring - it just "expects" to be inserting WEP header information
  when doing WEP TX, even with hardware encryption.
  
  So, to better support the newer world order, turn the default TX key assignment
  into a VAP method that can be overridden by the driver and ensure its wrapped
  in a crypto begin/end set.  That way it should be correctly atomic from the
  point of view of keychanges (as long as the driver does the right thing.)
  
  It'd be nice if we passed through to the key_set call a flag that says
  "also make this the default key" - that's captured here by calling the
  deftxkey method after the key_set method.  Maybe I can do that later.
  
  Note: this is a net80211 ABI change, and will require a kernel+modules
  recompile.  Happy Holidays, etc.
  
  Tested:
  
  * ath10k driver port
  * rtwn_usb, WEP station

Modified:
  head/sys/net80211/ieee80211.c
  head/sys/net80211/ieee80211_crypto.c
  head/sys/net80211/ieee80211_crypto.h
  head/sys/net80211/ieee80211_ioctl.c
  head/sys/net80211/ieee80211_var.h

Modified: head/sys/net80211/ieee80211.c
==============================================================================
--- head/sys/net80211/ieee80211.c	Tue Dec 27 01:10:28 2016	(r310623)
+++ head/sys/net80211/ieee80211.c	Tue Dec 27 06:10:28 2016	(r310624)
@@ -433,6 +433,22 @@ default_reset(struct ieee80211vap *vap, 
 }
 
 /*
+ * Default for updating the VAP default TX key index.
+ *
+ * Drivers that support TX offload as well as hardware encryption offload
+ * may need to be informed of key index changes separate from the key
+ * update.
+ */
+static void
+default_update_deftxkey(struct ieee80211vap *vap, ieee80211_keyix kid)
+{
+
+	/* XXX assert validity */
+	/* XXX assert we're in a key update block */
+	vap->iv_def_txkey = kid;
+}
+
+/*
  * Add underlying device errors to vap errors.
  */
 static uint64_t
@@ -561,6 +577,12 @@ ieee80211_vap_setup(struct ieee80211com 
 	 */
 	vap->iv_reset = default_reset;
 
+	/*
+	 * Install a default crypto key update method, the driver
+	 * can override this.
+	 */
+	vap->iv_update_deftxkey = default_update_deftxkey;
+
 	ieee80211_sysctl_vattach(vap);
 	ieee80211_crypto_vattach(vap);
 	ieee80211_node_vattach(vap);

Modified: head/sys/net80211/ieee80211_crypto.c
==============================================================================
--- head/sys/net80211/ieee80211_crypto.c	Tue Dec 27 01:10:28 2016	(r310623)
+++ head/sys/net80211/ieee80211_crypto.c	Tue Dec 27 06:10:28 2016	(r310624)
@@ -787,3 +787,18 @@ ieee80211_crypto_reload_keys(struct ieee
 	 */
 	ieee80211_iterate_nodes(&ic->ic_sta, load_ucastkey, NULL);
 }
+
+/*
+ * Set the default key index for WEP, or KEYIX_NONE for no default TX key.
+ *
+ * This should be done as part of a key update block (iv_key_update_begin /
+ * iv_key_update_end.)
+ */
+void
+ieee80211_crypto_set_deftxkey(struct ieee80211vap *vap, ieee80211_keyix kid)
+{
+
+	/* XXX TODO: assert we're in a key update block */
+
+	vap->iv_update_deftxkey(vap, kid);
+}

Modified: head/sys/net80211/ieee80211_crypto.h
==============================================================================
--- head/sys/net80211/ieee80211_crypto.h	Tue Dec 27 01:10:28 2016	(r310623)
+++ head/sys/net80211/ieee80211_crypto.h	Tue Dec 27 06:10:28 2016	(r310624)
@@ -171,6 +171,8 @@ int	ieee80211_crypto_delkey(struct ieee8
 int	ieee80211_crypto_setkey(struct ieee80211vap *, struct ieee80211_key *);
 void	ieee80211_crypto_delglobalkeys(struct ieee80211vap *);
 void	ieee80211_crypto_reload_keys(struct ieee80211com *);
+void	ieee80211_crypto_set_deftxkey(struct ieee80211vap *,
+	    ieee80211_keyix kid);
 
 /*
  * Template for a supported cipher.  Ciphers register with the

Modified: head/sys/net80211/ieee80211_ioctl.c
==============================================================================
--- head/sys/net80211/ieee80211_ioctl.c	Tue Dec 27 01:10:28 2016	(r310623)
+++ head/sys/net80211/ieee80211_ioctl.c	Tue Dec 27 06:10:28 2016	(r310624)
@@ -855,6 +855,8 @@ ieee80211_ioctl_get80211(struct ieee8021
 		 * Tx power limit is the min of max regulatory
 		 * power, any user-set limit, and the max the
 		 * radio can do.
+		 *
+		 * TODO: methodize this
 		 */
 		ireq->i_val = 2*ic->ic_curchan->ic_maxregpower;
 		if (ireq->i_val > ic->ic_txpowlimit)
@@ -1013,6 +1015,7 @@ ieee80211_ioctl_get80211(struct ieee8021
 			ireq->i_val |= 2;
 		break;
 	case IEEE80211_IOC_AMPDU_LIMIT:
+		/* XXX TODO: make this a per-node thing; and leave this as global */
 		if (vap->iv_opmode == IEEE80211_M_HOSTAP)
 			ireq->i_val = vap->iv_ampdu_rxmax;
 		else if (vap->iv_state == IEEE80211_S_RUN || vap->iv_state == IEEE80211_S_SLEEP)
@@ -1026,6 +1029,7 @@ ieee80211_ioctl_get80211(struct ieee8021
 			ireq->i_val = vap->iv_ampdu_limit;
 		break;
 	case IEEE80211_IOC_AMPDU_DENSITY:
+		/* XXX TODO: make this a per-node thing; and leave this as global */
 		if (vap->iv_opmode == IEEE80211_M_STA &&
 		    (vap->iv_state == IEEE80211_S_RUN || vap->iv_state == IEEE80211_S_SLEEP))
 			/*
@@ -1204,7 +1208,15 @@ ieee80211_ioctl_setkey(struct ieee80211v
 		if (!ieee80211_crypto_setkey(vap, wk))
 			error = EIO;
 		else if ((ik.ik_flags & IEEE80211_KEY_DEFAULT))
-			vap->iv_def_txkey = kid;
+			/*
+			 * Inform the driver that this is the default
+			 * transmit key.  Now, ideally we'd just set
+			 * a flag in the key update that would
+			 * say "yes, we're the default key", but
+			 * that currently isn't the way the ioctl ->
+			 * key interface works.
+			 */
+			ieee80211_crypto_set_deftxkey(vap, kid);
 	} else
 		error = ENXIO;
 	ieee80211_key_update_end(vap);
@@ -2687,7 +2699,17 @@ ieee80211_ioctl_set80211(struct ieee8021
 		if (kid >= IEEE80211_WEP_NKID &&
 		    (uint16_t) kid != IEEE80211_KEYIX_NONE)
 			return EINVAL;
-		vap->iv_def_txkey = kid;
+		/*
+		 * Firmware devices may need to be told about an explicit
+		 * key index here, versus just inferring it from the
+		 * key set / change.  Since we may also need to pause
+		 * things like transmit before the key is updated,
+		 * give the driver a chance to flush things by tying
+		 * into key update begin/end.
+		 */
+		ieee80211_key_update_begin(vap);
+		ieee80211_crypto_set_deftxkey(vap, kid);
+		ieee80211_key_update_end(vap);
 		break;
 	case IEEE80211_IOC_AUTHMODE:
 		switch (ireq->i_val) {
@@ -3094,6 +3116,7 @@ ieee80211_ioctl_set80211(struct ieee8021
 			error = ERESTART;
 		break;
 	case IEEE80211_IOC_AMPDU_LIMIT:
+		/* XXX TODO: figure out ampdu_limit versus ampdu_rxmax */
 		if (!(IEEE80211_HTCAP_MAXRXAMPDU_8K <= ireq->i_val &&
 		      ireq->i_val <= IEEE80211_HTCAP_MAXRXAMPDU_64K))
 			return EINVAL;

Modified: head/sys/net80211/ieee80211_var.h
==============================================================================
--- head/sys/net80211/ieee80211_var.h	Tue Dec 27 01:10:28 2016	(r310623)
+++ head/sys/net80211/ieee80211_var.h	Tue Dec 27 06:10:28 2016	(r310624)
@@ -470,6 +470,8 @@ struct ieee80211vap {
 	struct ieee80211_appie	*iv_appie_wpa;
 	uint8_t			*iv_wpa_ie;
 	uint8_t			*iv_rsn_ie;
+
+	/* Key management */
 	uint16_t		iv_max_keyix;	/* max h/w key index */
 	ieee80211_keyix		iv_def_txkey;	/* default/group tx key index */
 	struct ieee80211_key	iv_nw_keys[IEEE80211_WEP_NKID];
@@ -482,6 +484,8 @@ struct ieee80211vap {
 				    const struct ieee80211_key *);
 	void			(*iv_key_update_begin)(struct ieee80211vap *);
 	void			(*iv_key_update_end)(struct ieee80211vap *);
+	void			(*iv_update_deftxkey)(struct ieee80211vap *,
+				    ieee80211_keyix deftxkey);
 
 	const struct ieee80211_authenticator *iv_auth; /* authenticator glue */
 	void			*iv_ec;		/* private auth state */
@@ -536,6 +540,7 @@ struct ieee80211vap {
 	/* 802.3 output method for raw frame xmit */
 	int			(*iv_output)(struct ifnet *, struct mbuf *,
 				    const struct sockaddr *, struct route *);
+
 	uint64_t		iv_spare[6];
 };
 MALLOC_DECLARE(M_80211_VAP);

From owner-svn-src-all@freebsd.org  Tue Dec 27 08:19:46 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 95E58C93A86;
 Tue, 27 Dec 2016 08:19:46 +0000 (UTC)
 (envelope-from hiren@strugglingcoder.info)
Received: from mail.strugglingcoder.info (strugglingcoder.info
 [104.236.146.68])
 by mx1.freebsd.org (Postfix) with ESMTP id 880B91610;
 Tue, 27 Dec 2016 08:19:46 +0000 (UTC)
 (envelope-from hiren@strugglingcoder.info)
Received: from localhost (unknown [10.1.1.3])
 (Authenticated sender: hiren@strugglingcoder.info)
 by mail.strugglingcoder.info (Postfix) with ESMTPA id 5DEAF17985;
 Tue, 27 Dec 2016 00:19:40 -0800 (PST)
Date: Tue, 27 Dec 2016 00:19:40 -0800
From: hiren panchasara <hiren@strugglingcoder.info>
To: Michael Tuexen <tuexen@FreeBSD.org>
Cc: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: Re: svn commit: r310547 - head/sys/netinet
Message-ID: <20161227081940.GL82166@strugglingcoder.info>
References: <201612251737.uBPHbIhd027939@repo.freebsd.org>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
 protocol="application/pgp-signature"; boundary="DMotDPdpQlD4ewOK"
Content-Disposition: inline
In-Reply-To: <201612251737.uBPHbIhd027939@repo.freebsd.org>
User-Agent: Mutt/1.5.23 (2014-03-12)
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 08:19:46 -0000


--DMotDPdpQlD4ewOK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On 12/25/16 at 05:37P, Michael Tuexen wrote:
> Author: tuexen
> Date: Sun Dec 25 17:37:18 2016
> New Revision: 310547
> URL: https://svnweb.freebsd.org/changeset/base/310547
>=20
> Log:
>   Remove a KASSERT which is not always true.
>  =20
>   In case of the empty queue tp->snd_holes and tcp_sackhole_insert()
>   failing due to memory shortage, tp->snd_holes will be empty.
>   This problem was hit when stress tests where performed by pho.
>  =20
>   PR:		215513
>   Reported by:	pho
>   Tested by:	pho
>   Sponsored by:	Netflix, Inc.
>=20
> Modified:
>   head/sys/netinet/tcp_sack.c

Thanks for the fix, Michael. Can you please MFC this?

Cheers,
Hiren

--DMotDPdpQlD4ewOK
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQF8BAABCgBmBQJYYiQXXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRBNEUyMEZBMUQ4Nzg4RjNGMTdFNjZGMDI4
QjkyNTBFMTU2M0VERkU1AAoJEIuSUOFWPt/l23YH/0cjn7o0/yLDsEMdLKyN7MRr
sxE4g74dafR9ZnfvQAKClJp145fjN0its4oQUEJGbnOvlV9BMTSy48d4M+gsF/zr
pVa9//tQYBvpc+zkyt00wP+r+SXq2w9xd9sq/eTLagFAz8bW54XGacm6xCqkKIcs
0SuijW7eCeRiTSJ2HJxy6BeVQi+r/UgMaNe1onObSqgEn8aOB+1j1AaMisYDbAUP
bVQX6ipUaInNgpoh0ktmnzehRdI8MPA6l7Kz8fk/PXl5mWeZxOunP4K0rEDPpNt/
jMMjf3EQx4TdNo29PEkKCXlEIfzpi/2j9k6zg3SzC3KtW7D/dy3mdwNGi5cIUm8=
=twQt
-----END PGP SIGNATURE-----

--DMotDPdpQlD4ewOK--

From owner-svn-src-all@freebsd.org  Tue Dec 27 08:31:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4432AC93F67;
 Tue, 27 Dec 2016 08:31:42 +0000 (UTC)
 (envelope-from julian@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E71761D54;
 Tue, 27 Dec 2016 08:31:41 +0000 (UTC)
 (envelope-from julian@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR8VfkQ081602;
 Tue, 27 Dec 2016 08:31:41 GMT (envelope-from julian@FreeBSD.org)
Received: (from julian@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR8VfdH081599;
 Tue, 27 Dec 2016 08:31:41 GMT (envelope-from julian@FreeBSD.org)
Message-Id: <201612270831.uBR8VfdH081599@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: julian set sender to
 julian@FreeBSD.org using -f
From: Julian Elischer <julian@FreeBSD.org>
Date: Tue, 27 Dec 2016 08:31:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310625 - in stable/11: share/man/man4 sys/netgraph
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 08:31:42 -0000

Author: julian
Date: Tue Dec 27 08:31:40 2016
New Revision: 310625
URL: https://svnweb.freebsd.org/changeset/base/310625

Log:
  MFH: r309408
  
  Changes to allow the patching of packets with an offset (and other changes.. see man page)
  
  PR:	206185
  Submitted by:	Dmitry Vagin <daemon-hammer@ya.ru>
  MFC after:	 1 week
  Relnotes:	yes (also ng_checksum node)

Modified:
  stable/11/share/man/man4/ng_patch.4
  stable/11/sys/netgraph/ng_patch.c
  stable/11/sys/netgraph/ng_patch.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/share/man/man4/ng_patch.4
==============================================================================
--- stable/11/share/man/man4/ng_patch.4	Tue Dec 27 06:10:28 2016	(r310624)
+++ stable/11/share/man/man4/ng_patch.4	Tue Dec 27 08:31:40 2016	(r310625)
@@ -1,5 +1,6 @@
 .\" Copyright (c) 2010 Maxim Ignatenko <gelraen.ua@gmail.com>
 .\" Copyright (c) 2010 Vadim Goncharov <vadimnuclight@tpu.ru>
+.\" Copyright (c) 2015 Dmitry Vagin <daemon.hammer@ya.ru>
 .\" All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
@@ -25,7 +26,7 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd March 5, 2012
+.Dd November 17, 2015
 .Dt NG_PATCH 4
 .Os
 .Sh NAME
@@ -47,33 +48,52 @@ A negation operation is the one exceptio
 and second operand (the
 .Va value )
 is not used.
-There may be several modification operations, they are all applied
-to a packet sequentially in order they were specified by user.
-Data payload of packet is viewed as array of bytes, with zero offset
-corresponding to the very first byte of packet headers, and
+If there is more than one modification operation, they are applied
+to packets sequentially in the order they were specified by the user.
+The data payload of a packet is viewed as an array of bytes, with a zero offset
+corresponding to the very first byte of packet headers, and the
 .Va length
 bytes beginning from
 .Va offset
-are taken as a single integer in network byte order.
+as a single integer in network byte order. An additional offset can be optionally 
+requested at configuration time to account for packet type.
 .Sh HOOKS
 This node type has two hooks:
 .Bl -tag -width ".Va out"
 .It Va in
 Packets received on this hook are modified according to rules specified
-in config and then forwarded to
+in the configuration and then forwarded to the
 .Ar out
-hook, if it exists and connected.
+hook, if it exists.
 Otherwise they are reflected back to the
 .Ar in
 hook.
 .It Va out
-Packets received on this hook are forwarded to
+Packets received on this hook are forwarded to the
 .Ar in
 hook without any changes.
 .El
 .Sh CONTROL MESSAGES
 This node type supports the generic control messages, plus the following:
 .Bl -tag -width foo
+.It Dv NGM_PATCH_SETDLT Pq Ic setdlt
+Sets the data link type on the
+.Va in
+hook (to help calculate relative offset). Currently, supported types are
+.Cm DLT_RAW
+(raw IP datagrams , no offset applied, the default) and
+.Cm DLT_EN10MB
+(Ethernet). DLT_ definitions can be found in
+.In net/bpf.h .
+If you want to work on the link layer header you must use no additional offset by specifying
+.Cm DLT_RAW .
+If
+.Cm EN10MB 
+is specified, then the optional additional offset will take into account the Ethernet header and a QinQ header if present.
+.It Dv NGM_PATCH_GETDLT Pq Ic getdlt
+This control message returns the data link type of the
+.Va in
+hook.
 .It Dv NGM_PATCH_SETCONFIG Pq Ic setconfig
 This command sets the sequence of modify operations
 that will be applied to incoming data on a hook.
@@ -82,10 +102,10 @@ The following
 must be supplied as an argument:
 .Bd -literal -offset 4n
 struct ng_patch_op {
-	uint64_t	value;
 	uint32_t	offset;
 	uint16_t	length; /* 1,2,4 or 8 bytes */
 	uint16_t	mode;
+	uint64_t	value;
 };
 /* Patching modes */
 #define NG_PATCH_MODE_SET	1
@@ -103,6 +123,7 @@ struct ng_patch_op {
 struct ng_patch_config {
 	uint32_t	count;
 	uint32_t	csum_flags;
+	uint32_t	relative_offset;
 	struct ng_patch_op ops[];
 };
 .Ed
@@ -116,14 +137,14 @@ The
 .Nm
 node does not do any checksum correction by itself.
 .It Dv NGM_PATCH_GETCONFIG Pq Ic getconfig
-This control message obtains current set of modify operations,
-returned as
+This control message returns the current set of modify operations,
+in the form of a
 .Vt "struct ng_patch_config" .
 .It Dv NGM_PATCH_GET_STATS Pq Ic getstats
-Returns node statistics as a
+Returns the node's statistics as a
 .Vt "struct ng_patch_stats" .
 .It Dv NGM_PATCH_CLR_STATS Pq Ic clrstats
-Clear node statistics.
+Clears the node's statistics.
 .It Dv NGM_PATCH_GETCLR_STATS Pq Ic getclrstats
 This command is identical to
 .Dv NGM_PATCH_GET_STATS ,
@@ -134,19 +155,20 @@ This node shuts down upon receipt of a
 .Dv NGM_SHUTDOWN
 control message, or when all hooks have been disconnected.
 .Sh EXAMPLES
-The
+This
 .Nm
-node allows to modify TTL and TOS/DSCP fields in IP packets.
-Suppose you have two adjacent simplex links to remote network
+node was designed to modify TTL and TOS/DSCP fields in IP packets.
+As an example,
+suppose you have two adjacent simplex links to a remote network
 (e.g.\& satellite), so that the packets expiring in between
 will generate unwanted ICMP-replies which have to go forth, not back.
 Thus you need to raise TTL of every packet entering link by 2
 to ensure the TTL will not reach zero there.
-So you setup
+To achieve this you can set an
 .Xr ipfw 8
-rule with
+rule to use the
 .Cm netgraph
-action to inject packets going to other end of simplex link by the
+action to inject packets which are going to the simplex link into the patch node, by using the
 following
 .Xr ngctl 8
 script:
@@ -160,11 +182,11 @@ SEQ
 /sbin/ipfw add 150 netgraph 200 ip from any to simplex.remote.net
 .Ed
 .Pp
-Here
+Here the
 .Dq Li ttl_add
 node of type
 .Nm
-configured to add (mode
+is configured to add (mode
 .Dv NG_PATCH_MODE_ADD )
 a
 .Va value
@@ -218,13 +240,15 @@ The
 node type was implemented in
 .Fx 8.1 .
 .Sh AUTHORS
-.An Maxim Ignatenko Aq Mt gelraen.ua@gmail.com
+.An "Maxim Ignatenko" Aq gelraen.ua@gmail.com .
+.Pp
+Relative offset code by
+.An "DMitry Vagin"
 .Pp
-.An -nosplit
 This manual page was written by
-.An Vadim Goncharov Aq Mt vadimnuclight@tpu.ru .
+.An "Vadim Goncharov" Aq vadimnuclight@tpu.ru .
 .Sh BUGS
-Node blindly tries to apply every patching operation to each packet
+The node blindly tries to apply every patching operation to each packet
 (except those which offset if greater than length of the packet),
 so be sure that you supply only the right packets to it (e.g. changing
 bytes in the ARP packets meant to be in IP header could corrupt
@@ -232,6 +256,6 @@ them and make your machine unreachable f
 .Pp
 .Em !!! WARNING !!!
 .Pp
-Output path of the IP stack assumes correct fields and lengths in the
-packets - changing them by mistake to incorrect values can cause
+The output path of the IP stack assumes correct fields and lengths in the
+packets - changing them by to incorrect values can cause
 unpredictable results including kernel panics.

Modified: stable/11/sys/netgraph/ng_patch.c
==============================================================================
--- stable/11/sys/netgraph/ng_patch.c	Tue Dec 27 06:10:28 2016	(r310624)
+++ stable/11/sys/netgraph/ng_patch.c	Tue Dec 27 08:31:40 2016	(r310625)
@@ -1,5 +1,6 @@
 /*-
- * Copyright (c) 2010  Maxim Ignatenko <gelraen.ua@gmail.com>
+ * Copyright (c) 2010 Maxim Ignatenko <gelraen.ua@gmail.com>
+ * Copyright (c) 2015 Dmitry Vagin <daemon.hammer@ya.ru>
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -34,11 +35,28 @@ __FBSDID("$FreeBSD$");
 #include <sys/endian.h>
 #include <sys/malloc.h>
 #include <sys/mbuf.h>
+
+#include <net/bpf.h>
+#include <net/ethernet.h>
+
 #include <netgraph/ng_message.h>
 #include <netgraph/ng_parse.h>
-#include <netgraph/ng_patch.h>
 #include <netgraph/netgraph.h>
 
+#include <netgraph/ng_patch.h>
+
+/* private data */
+struct ng_patch_priv {
+	hook_p		in;
+	hook_p		out;
+	uint8_t		dlt;	/* DLT_XXX from bpf.h */
+	struct ng_patch_stats stats;
+	struct ng_patch_config *conf;
+};
+
+typedef struct ng_patch_priv *priv_p;
+
+/* Netgraph methods */
 static ng_constructor_t	ng_patch_constructor;
 static ng_rcvmsg_t	ng_patch_rcvmsg;
 static ng_shutdown_t	ng_patch_shutdown;
@@ -46,6 +64,8 @@ static ng_newhook_t	ng_patch_newhook;
 static ng_rcvdata_t	ng_patch_rcvdata;
 static ng_disconnect_t	ng_patch_disconnect;
 
+#define ERROUT(x) { error = (x); goto done; }
+
 static int
 ng_patch_config_getlen(const struct ng_parse_type *type,
     const u_char *start, const u_char *buf)
@@ -59,7 +79,7 @@ ng_patch_config_getlen(const struct ng_p
 }
 
 static const struct ng_parse_struct_field ng_patch_op_type_fields[]
-	= NG_PATCH_OP_TYPE_INFO;
+	= NG_PATCH_OP_TYPE;
 static const struct ng_parse_type ng_patch_op_type = {
 	&ng_parse_struct_type,
 	&ng_patch_op_type_fields
@@ -75,14 +95,14 @@ static const struct ng_parse_type ng_pat
 };
 
 static const struct ng_parse_struct_field ng_patch_config_type_fields[]
-	= NG_PATCH_CONFIG_TYPE_INFO;
+	= NG_PATCH_CONFIG_TYPE;
 static const struct ng_parse_type ng_patch_config_type = {
 	&ng_parse_struct_type,
 	&ng_patch_config_type_fields
 };
 
 static const struct ng_parse_struct_field ng_patch_stats_fields[]
-	= NG_PATCH_STATS_TYPE_INFO;
+	= NG_PATCH_STATS_TYPE;
 static const struct ng_parse_type ng_patch_stats_type = {
 	&ng_parse_struct_type,
 	&ng_patch_stats_fields
@@ -91,6 +111,20 @@ static const struct ng_parse_type ng_pat
 static const struct ng_cmdlist ng_patch_cmdlist[] = {
 	{
 		NGM_PATCH_COOKIE,
+		NGM_PATCH_GETDLT,
+		"getdlt",
+		NULL,
+		&ng_parse_uint8_type
+	},
+	{
+		NGM_PATCH_COOKIE,
+		NGM_PATCH_SETDLT,
+		"setdlt",
+		&ng_parse_uint8_type,
+		NULL
+	},
+	{
+		NGM_PATCH_COOKIE,
 		NGM_PATCH_GETCONFIG,
 		"getconfig",
 		NULL,
@@ -141,38 +175,16 @@ static struct ng_type typestruct = {
 
 NETGRAPH_INIT(patch, &typestruct);
 
-union patch_val {
-	uint8_t		v1;
-	uint16_t	v2;
-	uint32_t	v4;
-	uint64_t	v8;
-};
-
-/* private data */
-struct ng_patch_priv {
-	hook_p		in;
-	hook_p		out;
-	struct ng_patch_config *config;
-	union patch_val *val;
-	struct ng_patch_stats stats;
-};
-typedef struct ng_patch_priv *priv_p;
-
-#define	NG_PATCH_CONF_SIZE(count)	(sizeof(struct ng_patch_config) + \
-		(count) * sizeof(struct ng_patch_op))
-
-static void do_patch(priv_p conf, struct mbuf *m);
-
 static int
 ng_patch_constructor(node_p node)
 {
 	priv_p privdata;
 
 	privdata = malloc(sizeof(*privdata), M_NETGRAPH, M_WAITOK | M_ZERO);
+	privdata->dlt = DLT_RAW;
+
 	NG_NODE_SET_PRIVATE(node, privdata);
-	privdata->in = NULL;
-	privdata->out = NULL;
-	privdata->config = NULL;
+
 	return (0);
 }
 
@@ -188,7 +200,8 @@ ng_patch_newhook(node_p node, hook_p hoo
 		privp->out = hook;
 	} else
 		return (EINVAL);
-	return(0);
+
+	return (0);
 }
 
 static int
@@ -196,308 +209,341 @@ ng_patch_rcvmsg(node_p node, item_p item
 {
 	const priv_p privp = NG_NODE_PRIVATE(node);
 	struct ng_patch_config *conf, *newconf;
-	union patch_val *newval;
 	struct ng_mesg *msg;
-	struct ng_mesg *resp;
-	int i, clear, error;
+	struct ng_mesg *resp = NULL;
+	int i, error = 0;
 
-	clear = error = 0;
-	resp = NULL;
 	NGI_GET_MSG(item, msg);
-	switch (msg->header.typecookie) {
-	case NGM_PATCH_COOKIE:
-		switch (msg->header.cmd) {
+
+	if  (msg->header.typecookie != NGM_PATCH_COOKIE)
+		ERROUT(EINVAL);
+
+	switch (msg->header.cmd)
+	{
 		case NGM_PATCH_GETCONFIG:
-			if (privp->config == NULL)
-				break;
+			if (privp->conf == NULL)
+				ERROUT(0);
+
 			NG_MKRESPONSE(resp, msg,
-			    NG_PATCH_CONF_SIZE(privp->config->count),
-			    M_WAITOK);
-			bcopy(privp->config, resp->data,
-			    NG_PATCH_CONF_SIZE(privp->config->count));
-			break;
-		case NGM_PATCH_SETCONFIG:
-		    {
-			if (msg->header.arglen <
-			    sizeof(struct ng_patch_config)) {
-				error = EINVAL;
-				break;
-			}
+			    NG_PATCH_CONF_SIZE(privp->conf->count), M_WAITOK);
 
-			conf = (struct ng_patch_config *)msg->data;
-			if (msg->header.arglen <
-			    NG_PATCH_CONF_SIZE(conf->count)) {
-				error = EINVAL;
-				break;
-			}
+			if (resp == NULL)
+				ERROUT(ENOMEM);
 
-			for(i = 0; i < conf->count; i++) {
-				switch(conf->ops[i].length) {
-				case 1:
-				case 2:
-				case 4:
-				case 8:
-					break;
-				default:
-					error = EINVAL;
-					break;
+			bcopy(privp->conf, resp->data,
+			    NG_PATCH_CONF_SIZE(privp->conf->count));
+
+			conf = (struct ng_patch_config *) resp->data;
+
+			for (i = 0; i < conf->count; i++) {
+				switch (conf->ops[i].length)
+				{
+					case 1:
+						conf->ops[i].val.v8 = conf->ops[i].val.v1;
+						break;
+					case 2:
+						conf->ops[i].val.v8 = conf->ops[i].val.v2;
+						break;
+					case 4:
+						conf->ops[i].val.v8 = conf->ops[i].val.v4;
+						break;
+					case 8:
+						break;
 				}
-				if (error != 0)
-					break;
 			}
 
-			conf->csum_flags &= CSUM_IP | CSUM_TCP | CSUM_UDP |
-			    CSUM_SCTP;
+			break;
+
+		case NGM_PATCH_SETCONFIG:
+			conf = (struct ng_patch_config *) msg->data;
 
-			if (error == 0) {
-				newconf = malloc(
-				    NG_PATCH_CONF_SIZE(conf->count),
-				    M_NETGRAPH, M_WAITOK);
-				newval = malloc(conf->count *
-				    sizeof(union patch_val), M_NETGRAPH,
-				    M_WAITOK);
-				for(i = 0; i < conf->count; i++) {
-					switch (conf->ops[i].length) {
+			if (msg->header.arglen < sizeof(struct ng_patch_config) ||
+			    msg->header.arglen < NG_PATCH_CONF_SIZE(conf->count))
+				ERROUT(EINVAL);
+
+			for (i = 0; i < conf->count; i++) {
+				switch (conf->ops[i].length)
+				{
 					case 1:
-						newval[i].v1 =
-						    conf->ops[i].value;
+						conf->ops[i].val.v1 = (uint8_t) conf->ops[i].val.v8;
 						break;
 					case 2:
-						newval[i].v2 =
-						    conf->ops[i].value;
+						conf->ops[i].val.v2 = (uint16_t) conf->ops[i].val.v8;
 						break;
 					case 4:
-						newval[i].v4 =
-						    conf->ops[i].value;
+						conf->ops[i].val.v4 = (uint32_t) conf->ops[i].val.v8;
 						break;
 					case 8:
-						newval[i].v8 =
-						    conf->ops[i].value;
 						break;
-					}
+					default:
+						ERROUT(EINVAL);
 				}
-				bcopy(conf, newconf,
-				    NG_PATCH_CONF_SIZE(conf->count));
-				if (privp->val != NULL)
-					free(privp->val, M_NETGRAPH);
-				privp->val = newval;
-				if (privp->config != NULL)
-					free(privp->config, M_NETGRAPH);
-				privp->config = newconf;
 			}
+
+			conf->csum_flags &= NG_PATCH_CSUM_IPV4|NG_PATCH_CSUM_IPV6;
+			conf->relative_offset = !!conf->relative_offset;
+
+			newconf = malloc(NG_PATCH_CONF_SIZE(conf->count), M_NETGRAPH, M_WAITOK | M_ZERO);
+
+			bcopy(conf, newconf, NG_PATCH_CONF_SIZE(conf->count));
+
+			if (privp->conf)
+				free(privp->conf, M_NETGRAPH);
+
+			privp->conf = newconf;
+
 			break;
-		    }
-		case NGM_PATCH_GETCLR_STATS:
-			clear = 1;
-			/* FALLTHROUGH */
+
 		case NGM_PATCH_GET_STATS:
-			NG_MKRESPONSE(resp, msg, sizeof(struct ng_patch_stats),
-			    M_WAITOK);
-			bcopy(&(privp->stats), resp->data,
-			    sizeof(struct ng_patch_stats));
-			if (clear == 0)
-				break;
-			/* else FALLTHROUGH */
 		case NGM_PATCH_CLR_STATS:
-			bzero(&(privp->stats), sizeof(struct ng_patch_stats));
+		case NGM_PATCH_GETCLR_STATS:
+			if (msg->header.cmd != NGM_PATCH_CLR_STATS) {
+				NG_MKRESPONSE(resp, msg, sizeof(struct ng_patch_stats), M_WAITOK);
+
+				if (resp == NULL)
+					ERROUT(ENOMEM);
+
+				bcopy(&(privp->stats), resp->data, sizeof(struct ng_patch_stats));
+			}
+
+			if (msg->header.cmd != NGM_PATCH_GET_STATS)
+				bzero(&(privp->stats), sizeof(struct ng_patch_stats));
+
 			break;
-		default:
-			error = EINVAL;
+
+		case NGM_PATCH_GETDLT:
+			NG_MKRESPONSE(resp, msg, sizeof(uint8_t), M_WAITOK);
+
+			if (resp == NULL)
+				ERROUT(ENOMEM);
+
+			*((uint8_t *) resp->data) = privp->dlt;
+
 			break;
-		}
-		break;
-	default:
-		error = EINVAL;
-		break;
+
+		case NGM_PATCH_SETDLT:
+			if (msg->header.arglen != sizeof(uint8_t))
+				ERROUT(EINVAL);
+
+			switch (*(uint8_t *) msg->data)
+			{
+				case DLT_EN10MB:
+				case DLT_RAW:
+					privp->dlt = *(uint8_t *) msg->data;
+					break;
+
+				default:
+					ERROUT(EINVAL);
+			}
+
+			break;
+
+		default:
+			ERROUT(EINVAL);
 	}
 
+done:
 	NG_RESPOND_MSG(error, node, item, resp);
 	NG_FREE_MSG(msg);
-	return(error);
+
+	return (error);
 }
 
 static void
-do_patch(priv_p privp, struct mbuf *m)
+do_patch(priv_p privp, struct mbuf *m, int global_offset)
 {
-	struct ng_patch_config *conf;
-	uint64_t buf;
-	int i, patched;
+	int i, offset, patched = 0;
+	union ng_patch_op_val val;
+
+	for (i = 0; i < privp->conf->count; i++) {
+		offset = global_offset + privp->conf->ops[i].offset;
 
-	conf = privp->config;
-	patched = 0;
-	for(i = 0; i < conf->count; i++) {
-		if (conf->ops[i].offset + conf->ops[i].length >
-		    m->m_pkthdr.len)
+		if (offset + privp->conf->ops[i].length > m->m_pkthdr.len)
 			continue;
 
 		/* for "=" operation we don't need to copy data from mbuf */
-		if (conf->ops[i].mode != NG_PATCH_MODE_SET) {
-			m_copydata(m, conf->ops[i].offset,
-			    conf->ops[i].length, (caddr_t)&buf);
-		}
+		if (privp->conf->ops[i].mode != NG_PATCH_MODE_SET)
+			m_copydata(m, offset, privp->conf->ops[i].length, (caddr_t) &val);
 
-		switch (conf->ops[i].length) {
-		case 1:
-			switch (conf->ops[i].mode) {
-			case NG_PATCH_MODE_SET:
-				*((uint8_t *)&buf) = privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_ADD:
-				*((uint8_t *)&buf) += privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_SUB:
-				*((uint8_t *)&buf) -= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_MUL:
-				*((uint8_t *)&buf) *= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_DIV:
-				*((uint8_t *)&buf) /= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_NEG:
-				*((int8_t *)&buf) = - *((int8_t *)&buf);
-				break;
-			case NG_PATCH_MODE_AND:
-				*((uint8_t *)&buf) &= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_OR:
-				*((uint8_t *)&buf) |= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_XOR:
-				*((uint8_t *)&buf) ^= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_SHL:
-				*((uint8_t *)&buf) <<= privp->val[i].v1;
-				break;
-			case NG_PATCH_MODE_SHR:
-				*((uint8_t *)&buf) >>= privp->val[i].v1;
-				break;
-			}
-			break;
-		case 2:
-			*((int16_t *)&buf) =  ntohs(*((int16_t *)&buf));
-			switch (conf->ops[i].mode) {
-			case NG_PATCH_MODE_SET:
-				*((uint16_t *)&buf) = privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_ADD:
-				*((uint16_t *)&buf) += privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_SUB:
-				*((uint16_t *)&buf) -= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_MUL:
-				*((uint16_t *)&buf) *= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_DIV:
-				*((uint16_t *)&buf) /= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_NEG:
-				*((int16_t *)&buf) = - *((int16_t *)&buf);
-				break;
-			case NG_PATCH_MODE_AND:
-				*((uint16_t *)&buf) &= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_OR:
-				*((uint16_t *)&buf) |= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_XOR:
-				*((uint16_t *)&buf) ^= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_SHL:
-				*((uint16_t *)&buf) <<= privp->val[i].v2;
-				break;
-			case NG_PATCH_MODE_SHR:
-				*((uint16_t *)&buf) >>= privp->val[i].v2;
-				break;
-			}
-			*((int16_t *)&buf) =  htons(*((int16_t *)&buf));
-			break;
-		case 4:
-			*((int32_t *)&buf) =  ntohl(*((int32_t *)&buf));
-			switch (conf->ops[i].mode) {
-			case NG_PATCH_MODE_SET:
-				*((uint32_t *)&buf) = privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_ADD:
-				*((uint32_t *)&buf) += privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_SUB:
-				*((uint32_t *)&buf) -= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_MUL:
-				*((uint32_t *)&buf) *= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_DIV:
-				*((uint32_t *)&buf) /= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_NEG:
-				*((int32_t *)&buf) = - *((int32_t *)&buf);
-				break;
-			case NG_PATCH_MODE_AND:
-				*((uint32_t *)&buf) &= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_OR:
-				*((uint32_t *)&buf) |= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_XOR:
-				*((uint32_t *)&buf) ^= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_SHL:
-				*((uint32_t *)&buf) <<= privp->val[i].v4;
-				break;
-			case NG_PATCH_MODE_SHR:
-				*((uint32_t *)&buf) >>= privp->val[i].v4;
-				break;
-			}
-			*((int32_t *)&buf) =  htonl(*((int32_t *)&buf));
-			break;
-		case 8:
-			*((int64_t *)&buf) =  be64toh(*((int64_t *)&buf));
-			switch (conf->ops[i].mode) {
-			case NG_PATCH_MODE_SET:
-				*((uint64_t *)&buf) = privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_ADD:
-				*((uint64_t *)&buf) += privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_SUB:
-				*((uint64_t *)&buf) -= privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_MUL:
-				*((uint64_t *)&buf) *= privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_DIV:
-				*((uint64_t *)&buf) /= privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_NEG:
-				*((int64_t *)&buf) = - *((int64_t *)&buf);
-				break;
-			case NG_PATCH_MODE_AND:
-				*((uint64_t *)&buf) &= privp->val[i].v8;
-				break;
-			case NG_PATCH_MODE_OR:
-				*((uint64_t *)&buf) |= privp->val[i].v8;
+		switch (privp->conf->ops[i].length)
+		{
+			case 1:
+				switch (privp->conf->ops[i].mode)
+				{
+					case NG_PATCH_MODE_SET:
+						val.v1 = privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_ADD:
+						val.v1 += privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_SUB:
+						val.v1 -= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_MUL:
+						val.v1 *= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_DIV:
+						val.v1 /= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_NEG:
+						*((int8_t *) &val) = - *((int8_t *) &val);
+						break;
+					case NG_PATCH_MODE_AND:
+						val.v1 &= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_OR:
+						val.v1 |= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_XOR:
+						val.v1 ^= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_SHL:
+						val.v1 <<= privp->conf->ops[i].val.v1;
+						break;
+					case NG_PATCH_MODE_SHR:
+						val.v1 >>= privp->conf->ops[i].val.v1;
+						break;
+				}
 				break;
-			case NG_PATCH_MODE_XOR:
-				*((uint64_t *)&buf) ^= privp->val[i].v8;
+
+			case 2:
+				val.v2 = ntohs(val.v2);
+
+				switch (privp->conf->ops[i].mode)
+				{
+					case NG_PATCH_MODE_SET:
+						val.v2 = privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_ADD:
+						val.v2 += privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_SUB:
+						val.v2 -= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_MUL:
+						val.v2 *= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_DIV:
+						val.v2 /= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_NEG:
+						*((int16_t *) &val) = - *((int16_t *) &val);
+						break;
+					case NG_PATCH_MODE_AND:
+						val.v2 &= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_OR:
+						val.v2 |= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_XOR:
+						val.v2 ^= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_SHL:
+						val.v2 <<= privp->conf->ops[i].val.v2;
+						break;
+					case NG_PATCH_MODE_SHR:
+						val.v2 >>= privp->conf->ops[i].val.v2;
+						break;
+				}
+
+				val.v2 = htons(val.v2);
+
 				break;
-			case NG_PATCH_MODE_SHL:
-				*((uint64_t *)&buf) <<= privp->val[i].v8;
+
+			case 4:
+				val.v4 = ntohl(val.v4);
+
+				switch (privp->conf->ops[i].mode)
+				{
+					case NG_PATCH_MODE_SET:
+						val.v4 = privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_ADD:
+						val.v4 += privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_SUB:
+						val.v4 -= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_MUL:
+						val.v4 *= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_DIV:
+						val.v4 /= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_NEG:
+						*((int32_t *) &val) = - *((int32_t *) &val);
+						break;
+					case NG_PATCH_MODE_AND:
+						val.v4 &= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_OR:
+						val.v4 |= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_XOR:
+						val.v4 ^= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_SHL:
+						val.v4 <<= privp->conf->ops[i].val.v4;
+						break;
+					case NG_PATCH_MODE_SHR:
+						val.v4 >>= privp->conf->ops[i].val.v4;
+						break;
+				}
+
+				val.v4 = htonl(val.v4);
+
 				break;
-			case NG_PATCH_MODE_SHR:
-				*((uint64_t *)&buf) >>= privp->val[i].v8;
+
+			case 8:
+				val.v8 = be64toh(val.v8);
+
+				switch (privp->conf->ops[i].mode)
+				{
+					case NG_PATCH_MODE_SET:
+						val.v8 = privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_ADD:
+						val.v8 += privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_SUB:
+						val.v8 -= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_MUL:
+						val.v8 *= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_DIV:
+						val.v8 /= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_NEG:
+						*((int64_t *) &val) = - *((int64_t *) &val);
+						break;
+					case NG_PATCH_MODE_AND:
+						val.v8 &= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_OR:
+						val.v8 |= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_XOR:
+						val.v8 ^= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_SHL:
+						val.v8 <<= privp->conf->ops[i].val.v8;
+						break;
+					case NG_PATCH_MODE_SHR:
+						val.v8 >>= privp->conf->ops[i].val.v8;
+						break;
+				}
+
+				val.v8 = htobe64(val.v8);
+
 				break;
-			}
-			*((int64_t *)&buf) =  htobe64(*((int64_t *)&buf));
-			break;
 		}
 
-		m_copyback(m, conf->ops[i].offset, conf->ops[i].length,
-		    (caddr_t)&buf);
+		m_copyback(m, offset, privp->conf->ops[i].length, (caddr_t) &val);
 		patched = 1;
 	}
-	if (patched > 0)
+
+	if (patched)
 		privp->stats.patched++;
 }
 
@@ -506,41 +552,107 @@ ng_patch_rcvdata(hook_p hook, item_p ite
 {
 	const priv_p priv = NG_NODE_PRIVATE(NG_HOOK_NODE(hook));
 	struct mbuf *m;
-	hook_p target;
-	int error;
+	hook_p out;
+	int pullup_len = 0;
+	int error = 0;
 
 	priv->stats.received++;
+
 	NGI_GET_M(item, m);
-	if (priv->config != NULL && hook == priv->in &&
-	    (m->m_flags & M_PKTHDR) != 0) {
-		m = m_unshare(m,M_NOWAIT);
-		if (m == NULL) {
-			priv->stats.dropped++;
-			NG_FREE_ITEM(item);
-			return (ENOMEM);
+
+#define	PULLUP_CHECK(mbuf, length) do {					\
+	pullup_len += length;						\
+	if (((mbuf)->m_pkthdr.len < pullup_len) ||			\
+	    (pullup_len > MHLEN)) {					\
+		error = EINVAL;						\
+		goto bypass;						\
+	}								\
+	if ((mbuf)->m_len < pullup_len &&				\
+	    (((mbuf) = m_pullup((mbuf), pullup_len)) == NULL)) {	\
+		error = ENOBUFS;					\
+		goto drop;						\
+	}								\
+} while (0)
+
+	if (priv->conf && hook == priv->in &&
+	    m && (m->m_flags & M_PKTHDR)) {
+
+		m = m_unshare(m, M_NOWAIT);
+
+		if (m == NULL)
+			ERROUT(ENOMEM);
+
+		if (priv->conf->relative_offset) {
+			struct ether_header *eh;
+			struct ng_patch_vlan_header *vh;
+			uint16_t etype;
+
+			switch (priv->dlt)
+			{
+				case DLT_EN10MB:
+					PULLUP_CHECK(m, sizeof(struct ether_header));
+					eh = mtod(m, struct ether_header *);
+					etype = ntohs(eh->ether_type);
+
+					for (;;) {	/* QinQ support */
+						switch (etype)
+						{
+							case 0x8100:
+							case 0x88A8:
+							case 0x9100:
+								PULLUP_CHECK(m, sizeof(struct ng_patch_vlan_header));
+								vh = (struct ng_patch_vlan_header *) mtodo(m,
+								    pullup_len - sizeof(struct ng_patch_vlan_header));
+								etype = ntohs(vh->etype);
+								break;
+

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Tue Dec 27 08:32:55 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D43C1C9106E;
 Tue, 27 Dec 2016 08:32:55 +0000 (UTC)
 (envelope-from julian@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 95ED11101;
 Tue, 27 Dec 2016 08:32:55 +0000 (UTC)
 (envelope-from julian@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR8WsxE085390;
 Tue, 27 Dec 2016 08:32:54 GMT (envelope-from julian@FreeBSD.org)
Received: (from julian@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR8Wskx085389;
 Tue, 27 Dec 2016 08:32:54 GMT (envelope-from julian@FreeBSD.org)
Message-Id: <201612270832.uBR8Wskx085389@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: julian set sender to
 julian@FreeBSD.org using -f
From: Julian Elischer <julian@FreeBSD.org>
Date: Tue, 27 Dec 2016 08:32:54 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310626 - stable/11/share/man/man4
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 08:32:55 -0000

Author: julian
Date: Tue Dec 27 08:32:54 2016
New Revision: 310626
URL: https://svnweb.freebsd.org/changeset/base/310626

Log:
  MFH: r309407
  
  A little light wordsmithing only.
  
  Sponsored by:	FreeBSD

Modified:
  stable/11/share/man/man4/ng_checksum.4
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/share/man/man4/ng_checksum.4
==============================================================================
--- stable/11/share/man/man4/ng_checksum.4	Tue Dec 27 08:31:40 2016	(r310625)
+++ stable/11/share/man/man4/ng_checksum.4	Tue Dec 27 08:32:54 2016	(r310626)
@@ -29,26 +29,26 @@
 .Os
 .Sh NAME
 .Nm ng_checksum
-.Nd IP checksum node type
+.Nd reconstructing IP checksums node type
 .Sh SYNOPSIS
 .In netgraph/ng_checksum.h
 .Sh DESCRIPTION
 The
 .Nm checksum
-node can calculate and prepare for calculation in hardware
-IPv4 header, TCP, UDP checksum.
+node can calculate, or prepare for calculation in hardware,
+IPv4 header, TCP and UDP checksums.
 .Sh HOOKS
 This node type has two hooks:
 .Bl -tag -width ".Va out"
 .It Va in
 Packets received on this hook are processed according to settings specified
-in config and then forwarded to
+in config and then forwarded to the
 .Ar out
-hook, if it exists and connected. Otherwise they are reflected back to the
+hook, if it exists and is connected. Otherwise they are reflected back to the
 .Ar in
 hook.
 .It Va out
-Packets received on this hook are forwarded to
+Packets received on this hook are forwarded to the
 .Ar in
 hook without any changes.
 .El
@@ -56,13 +56,13 @@ hook without any changes.
 This node type supports the generic control messages, plus the following:
 .Bl -tag -width foo
 .It Dv NGM_CHECKSUM_SETDLT Pq Ic setdlt
-Sets data link type on the
+Sets the data link type on the
 .Va in
 hook. Currently, supported types are
 .Cm DLT_RAW
 (raw IP datagrams) and
 .Cm DLT_EN10MB
-(Ethernet). DLT_ definitions can be found in
+(Ethernet). DLT_ definitions can be found in the
 .In net/bpf.h
 header. Currently used values are
 .Cm DLT_EN10MB
@@ -70,11 +70,11 @@ header. Currently used values are
 .Cm DLT_RAW
 = 12.
 .It Dv NGM_CHECKSUM_GETDLT Pq Ic getdlt
-This control message obtains data link type on the
+This control message obtains the data link type on the
 .Va in
 hook.
 .It Dv NGM_CHECKSUM_SETCONFIG Pq Ic setconfig
-Sets node configuration. The following
+Sets the node configuration. The following
 .Vt "struct ng_checksum_config"
 must be supplied as an argument:
 .Bd -literal -offset 4n
@@ -87,23 +87,24 @@ struct ng_checksum_config {
 The
 .Va csum_flags
 can be set to any combination of CSUM_IP, CSUM_TCP, CSUM_UDP, CSUM_TCP_IPV6 and CSUM_UDP_IPV6
-(other values are ignored) for instructing node need calculate the corresponding checksum.
+(other values are ignored) for instructing the node to calculate the corresponding checksum.
 .Pp
 The
 .Va csum_offload
-can be set to any combination of CSUM_IP, CSUM_TCP, CSUM_UDP, CSUM_TCP_IPV6 and CSUM_UDP_IPV6
-(other values are ignored) for instructing node what checksum can calculate in hardware.
+value can be set to any combination of CSUM_IP, CSUM_TCP, CSUM_UDP, CSUM_TCP_IPV6 and CSUM_UDP_IPV6
+(other values are ignored) for instructing the node what checksums should be requested from the hardware.
 .Pp
-Also processed any combination of CSUM_IP, CSUM_TCP, CSUM_UDP, CSUM_TCP_IPV6 and CSUM_UDP_IPV6 sets before on mbuf.
+The node also takes into account any combination of
+CSUM_IP, CSUM_TCP, CSUM_UDP, CSUM_TCP_IPV6 and CSUM_UDP_IPV6 already
+flagged on the mbuf.
 .It Dv NGM_CHECKSUM_GETCONFIG Pq Ic getconfig
-This control message obtains current node configuration,
-returned as
+This control message obtains the current node configuration returned as a
 .Vt "struct ng_checksum_config" .
 .It Dv NGM_CHECKSUM_GET_STATS Pq Ic getstats
 Returns node statistics as a
 .Vt "struct ng_checksum_stats" .
 .It Dv NGM_CHECKSUM_CLR_STATS Pq Ic clrstats
-Clear node statistics.
+Clear the node statistics.
 .It Dv NGM_CHECKSUM_GETCLR_STATS Pq Ic getclrstats
 This command is identical to
 .Dv NGM_CHECKSUM_GET_STATS ,
@@ -118,14 +119,15 @@ control message, or when all hooks have 
 script:
 .Bd -literal -offset 4n
 /usr/sbin/ngctl -f- <<-SEQ
-	msg checksum-1: "setdlt 1"
-	ngctl msg checksum-1: "setconfig { csum_flags=0 csum_offload=6 }"
+	msg checksum-1: setdlt 1
+	msg checksum-1: setconfig { csum_flags=0 csum_offload=6 }
+SEQ
 .Ed
 .Pp
-Set data link type to
+Set the data link type to
 .Cm DLT_EN10MB
-(Ethernet), not set additional checksum flags, set hardware
-can calculate CSUM_IP_UDP|CSUM_IP_TCP.
+(Ethernet), do not set additional checksum flags
+and request that the hardware calculate CSUM_IP_UDP|CSUM_IP_TCP.
 .Sh SEE ALSO
 .Xr netgraph 4 ,
 .Xr ng_patch 4 ,

From owner-svn-src-all@freebsd.org  Tue Dec 27 08:51:28 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77997C9189C;
 Tue, 27 Dec 2016 08:51:28 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 39F3219B0;
 Tue, 27 Dec 2016 08:51:28 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBR8pRer089577;
 Tue, 27 Dec 2016 08:51:27 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBR8pRIc089574;
 Tue, 27 Dec 2016 08:51:27 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612270851.uBR8pRIc089574@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Tue, 27 Dec 2016 08:51:27 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310627 - head/sys/dev/sfxge
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 08:51:28 -0000

Author: arybchik
Date: Tue Dec 27 08:51:26 2016
New Revision: 310627
URL: https://svnweb.freebsd.org/changeset/base/310627

Log:
  sfxge(4): do not limit driver RSS table to RSS channels max
  
  Specification of entire RSS table in the driver allows to spread traffic
  more equally across CPUs/RSS channels if number of RSS channels is not
  power of 2.
  
  Reviewed by:    philip
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days
  Differential Revision: https://reviews.freebsd.org/D8910

Modified:
  head/sys/dev/sfxge/sfxge.h
  head/sys/dev/sfxge/sfxge_rx.c
  head/sys/dev/sfxge/sfxge_tx.c

Modified: head/sys/dev/sfxge/sfxge.h
==============================================================================
--- head/sys/dev/sfxge/sfxge.h	Tue Dec 27 08:32:54 2016	(r310626)
+++ head/sys/dev/sfxge/sfxge.h	Tue Dec 27 08:51:26 2016	(r310627)
@@ -301,7 +301,7 @@ struct sfxge_softc {
 	unsigned int			max_rss_channels;
 	uma_zone_t			rxq_cache;
 	struct sfxge_rxq		*rxq[SFXGE_RX_SCALE_MAX];
-	unsigned int			rx_indir_table[SFXGE_RX_SCALE_MAX];
+	unsigned int			rx_indir_table[EFX_RSS_TBL_SIZE];
 
 	struct sfxge_txq		*txq[SFXGE_TXQ_NTYPES + SFXGE_RX_SCALE_MAX];
 

Modified: head/sys/dev/sfxge/sfxge_rx.c
==============================================================================
--- head/sys/dev/sfxge/sfxge_rx.c	Tue Dec 27 08:32:54 2016	(r310626)
+++ head/sys/dev/sfxge/sfxge_rx.c	Tue Dec 27 08:51:26 2016	(r310627)
@@ -1128,7 +1128,7 @@ sfxge_rx_start(struct sfxge_softc *sc)
 	/*
 	 * Set up the scale table.  Enable all hash types and hash insertion.
 	 */
-	for (index = 0; index < SFXGE_RX_SCALE_MAX; index++)
+	for (index = 0; index < nitems(sc->rx_indir_table); index++)
 #ifdef RSS
 		sc->rx_indir_table[index] =
 			rss_get_indirection_to_bucket(index) % sc->rxq_count;
@@ -1136,7 +1136,7 @@ sfxge_rx_start(struct sfxge_softc *sc)
 		sc->rx_indir_table[index] = index % sc->rxq_count;
 #endif
 	if ((rc = efx_rx_scale_tbl_set(sc->enp, sc->rx_indir_table,
-				       SFXGE_RX_SCALE_MAX)) != 0)
+				       nitems(sc->rx_indir_table))) != 0)
 		goto fail;
 	(void)efx_rx_scale_mode_set(sc->enp, EFX_RX_HASHALG_TOEPLITZ,
 	    (1 << EFX_RX_HASH_IPV4) | (1 << EFX_RX_HASH_TCPIPV4) |

Modified: head/sys/dev/sfxge/sfxge_tx.c
==============================================================================
--- head/sys/dev/sfxge/sfxge_tx.c	Tue Dec 27 08:32:54 2016	(r310626)
+++ head/sys/dev/sfxge/sfxge_tx.c	Tue Dec 27 08:51:26 2016	(r310627)
@@ -838,8 +838,9 @@ sfxge_if_transmit(struct ifnet *ifp, str
 		/* check if flowid is set */
 		if (M_HASHTYPE_GET(m) != M_HASHTYPE_NONE) {
 			uint32_t hash = m->m_pkthdr.flowid;
+			uint32_t idx = hash % nitems(sc->rx_indir_table);
 
-			index = sc->rx_indir_table[hash % SFXGE_RX_SCALE_MAX];
+			index = sc->rx_indir_table[idx];
 		}
 #endif
 #if SFXGE_TX_PARSE_EARLY

From owner-svn-src-all@freebsd.org  Tue Dec 27 10:17:58 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5A071C8FEBE;
 Tue, 27 Dec 2016 10:17:58 +0000 (UTC) (envelope-from avg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 34A8D1AC1;
 Tue, 27 Dec 2016 10:17:58 +0000 (UTC) (envelope-from avg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRAHvsv026774;
 Tue, 27 Dec 2016 10:17:57 GMT (envelope-from avg@FreeBSD.org)
Received: (from avg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRAHv1N026771;
 Tue, 27 Dec 2016 10:17:57 GMT (envelope-from avg@FreeBSD.org)
Message-Id: <201612271017.uBRAHv1N026771@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org
 using -f
From: Andriy Gapon <avg@FreeBSD.org>
Date: Tue, 27 Dec 2016 10:17:57 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310630 - in head: include lib/libkvm
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 10:17:58 -0000

Author: avg
Date: Tue Dec 27 10:17:56 2016
New Revision: 310630
URL: https://svnweb.freebsd.org/changeset/base/310630

Log:
  libkvm: support access to vmm guest memory, allow writes to fwmem and vmm
  
  This change consists of two parts:
  - allow libkvm to recognize /dev/vmm/* character devices as devices that
    provide access to the physical memory of a system (similarly to /dev/fwmem*)
  - allow libkvm to recognize that /dev/vmm/* and /dev/fwmem* devices provide
    access to the physical memory of live remote systems and, thus, the memory
    is writable
  
  As a result, it should be possible to run commands like
  $ kgdb -w /path/to/kernel /dev/fwmem0.0
  $ kgdb /path/to/kernel /dev/vmm/guest
  
  Reviewed by:	kib, jhb
  MFC after:	2 weeks
  Relnotes:	yes
  Sponsored by:	Panzura
  Differential Revision: https://reviews.freebsd.org/D8679

Modified:
  head/include/paths.h
  head/lib/libkvm/kvm.c
  head/lib/libkvm/kvm_private.h

Modified: head/include/paths.h
==============================================================================
--- head/include/paths.h	Tue Dec 27 09:40:07 2016	(r310629)
+++ head/include/paths.h	Tue Dec 27 10:17:56 2016	(r310630)
@@ -99,6 +99,7 @@
 #define	_PATH_VARDB	"/var/db/"
 #define	_PATH_VARRUN	"/var/run/"
 #define	_PATH_VARTMP	"/var/tmp/"
+#define	_PATH_DEVVMM	"/dev/vmm/"
 #define	_PATH_YP	"/var/yp/"
 #define	_PATH_UUCPLOCK	"/var/spool/lock/"
 

Modified: head/lib/libkvm/kvm.c
==============================================================================
--- head/lib/libkvm/kvm.c	Tue Dec 27 09:40:07 2016	(r310629)
+++ head/lib/libkvm/kvm.c	Tue Dec 27 10:17:56 2016	(r310630)
@@ -167,8 +167,10 @@ _kvm_open(kvm_t *kd, const char *uf, con
 			return (kd);
 		}
 	}
+
 	/*
-	 * This is a crash dump.
+	 * This is either a crash dump or a remote live system with its physical
+	 * memory fully accessible via a special device.
 	 * Open the namelist fd and determine the architecture.
 	 */
 	if ((kd->nlfd = open(uf, O_RDONLY | O_CLOEXEC, 0)) < 0) {
@@ -177,8 +179,11 @@ _kvm_open(kvm_t *kd, const char *uf, con
 	}
 	if (_kvm_read_kernel_ehdr(kd) < 0)
 		goto failed;
-	if (strncmp(mf, _PATH_FWMEM, strlen(_PATH_FWMEM)) == 0)
+	if (strncmp(mf, _PATH_FWMEM, strlen(_PATH_FWMEM)) == 0 ||
+	    strncmp(mf, _PATH_DEVVMM, strlen(_PATH_DEVVMM)) == 0) {
 		kd->rawdump = 1;
+		kd->writable = 1;
+	}
 	SET_FOREACH(parch, kvm_arch) {
 		if ((*parch)->ka_probe(kd)) {
 			kd->arch = *parch;
@@ -405,6 +410,15 @@ ssize_t
 kvm_write(kvm_t *kd, u_long kva, const void *buf, size_t len)
 {
 	int cc;
+	ssize_t cw;
+	off_t pa;
+	const char *cp;
+
+	if (!ISALIVE(kd) && !kd->writable) {
+		_kvm_err(kd, kd->program,
+		    "kvm_write not implemented for dead kernels");
+		return (-1);
+	}
 
 	if (ISALIVE(kd)) {
 		/*
@@ -422,12 +436,38 @@ kvm_write(kvm_t *kd, u_long kva, const v
 		} else if ((size_t)cc < len)
 			_kvm_err(kd, kd->program, "short write");
 		return (cc);
-	} else {
-		_kvm_err(kd, kd->program,
-		    "kvm_write not implemented for dead kernels");
-		return (-1);
 	}
-	/* NOTREACHED */
+
+	cp = buf;
+	while (len > 0) {
+		cc = kd->arch->ka_kvatop(kd, kva, &pa);
+		if (cc == 0)
+			return (-1);
+		if (cc > (ssize_t)len)
+			cc = len;
+		errno = 0;
+		if (lseek(kd->pmfd, pa, 0) == -1 && errno != 0) {
+			_kvm_syserr(kd, 0, _PATH_MEM);
+			break;
+		}
+		cw = write(kd->pmfd, cp, cc);
+		if (cw < 0) {
+			_kvm_syserr(kd, kd->program, "kvm_write");
+			break;
+		}
+		/*
+		 * If ka_kvatop returns a bogus value or our core file is
+		 * truncated, we might wind up seeking beyond the end of the
+		 * core file in which case the read will return 0 (EOF).
+		 */
+		if (cw == 0)
+			break;
+		cp += cw;
+		kva += cw;
+		len -= cw;
+	}
+
+	return (cp - (char *)buf);
 }
 
 int

Modified: head/lib/libkvm/kvm_private.h
==============================================================================
--- head/lib/libkvm/kvm_private.h	Tue Dec 27 09:40:07 2016	(r310629)
+++ head/lib/libkvm/kvm_private.h	Tue Dec 27 10:17:56 2016	(r310630)
@@ -78,6 +78,7 @@ struct __kvm {
 	 */
 	struct vmstate *vmst;
 	int	rawdump;	/* raw dump format */
+	int	writable;	/* physical memory is writable */
 
 	int		vnet_initialized;	/* vnet fields set up */
 	kvaddr_t	vnet_start;	/* start of kernel's vnet region */

From owner-svn-src-all@freebsd.org  Tue Dec 27 10:26:59 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8FB34C932B2;
 Tue, 27 Dec 2016 10:26:59 +0000 (UTC) (envelope-from avg@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 46945130B;
 Tue, 27 Dec 2016 10:26:59 +0000 (UTC) (envelope-from avg@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRAQwxi031013;
 Tue, 27 Dec 2016 10:26:58 GMT (envelope-from avg@FreeBSD.org)
Received: (from avg@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRAQw7F031012;
 Tue, 27 Dec 2016 10:26:58 GMT (envelope-from avg@FreeBSD.org)
Message-Id: <201612271026.uBRAQw7F031012@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org
 using -f
From: Andriy Gapon <avg@FreeBSD.org>
Date: Tue, 27 Dec 2016 10:26:58 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310631 - stable/11/usr.sbin/smbmsg
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 10:26:59 -0000

Author: avg
Date: Tue Dec 27 10:26:58 2016
New Revision: 310631
URL: https://svnweb.freebsd.org/changeset/base/310631

Log:
  MFC r308528: smbmsg: use a more convenient way of accessing data read
  from a slave

Modified:
  stable/11/usr.sbin/smbmsg/smbmsg.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/usr.sbin/smbmsg/smbmsg.c
==============================================================================
--- stable/11/usr.sbin/smbmsg/smbmsg.c	Tue Dec 27 10:17:56 2016	(r310630)
+++ stable/11/usr.sbin/smbmsg/smbmsg.c	Tue Dec 27 10:26:58 2016	(r310631)
@@ -61,7 +61,7 @@ static int wflag;		/* word IO */
 
 static unsigned char ibuf[SMB_MAXBLOCKSIZE];
 static unsigned char obuf[SMB_MAXBLOCKSIZE];
-static unsigned short oword, iword;
+static unsigned short oword;
 
 /*
  * The I2C specs say that all addresses below 16 and above or equal
@@ -135,6 +135,8 @@ do_io(void)
 
 	c.slave = slave;
 	c.cmd = cflag;
+	c.rcount = 0;
+	c.wcount = 0;
 
 	if (fmt == NULL && iflag > 0)
 		fmt = wflag? wordfmt: bytefmt;
@@ -163,11 +165,9 @@ do_io(void)
 	}
 	if (iflag == 1 && oflag == -1) {
 		/* command + 1 byte input: read byte op. */
-		c.rbuf = ibuf;
-		c.rcount = iflag;
 		if (ioctl(fd, SMB_READB, &c) == -1)
 			return (-1);
-		printf(fmt, (int)(unsigned char)ibuf[0]);
+		printf(fmt, (unsigned char)c.rdata.byte);
 		putchar('\n');
 		return (0);
 	} else if (iflag == -1 && oflag == 1) {
@@ -176,11 +176,9 @@ do_io(void)
 		return (ioctl(fd, SMB_WRITEB, &c));
 	} else if (wflag && iflag == 2 && oflag == -1) {
 		/* command + 2 bytes input: read word op. */
-		c.rbuf = (char*) &iword;
-		c.rcount = iflag;
 		if (ioctl(fd, SMB_READW, &c) == -1)
 			return (-1);
-		printf(fmt, (int)(unsigned short)iword);
+		printf(fmt, (unsigned short)c.rdata.word);
 		putchar('\n');
 		return (0);
 	} else if (wflag && iflag == -1 && oflag == 2) {
@@ -193,11 +191,9 @@ do_io(void)
 		 * "process call" op.
 		 */
 		c.wdata.word = oword;
-		c.rbuf = (char*) &iword;
-		c.rcount = iflag;
 		if (ioctl(fd, SMB_PCALL, &c) == -1)
 			return (-1);
-		printf(fmt, (int)(unsigned short)iword);
+		printf(fmt, (unsigned short)c.rdata.word);
 		putchar('\n');
 		return (0);
 	} else if (iflag > 1 && oflag == -1) {
@@ -206,7 +202,7 @@ do_io(void)
 		c.rcount = iflag;
 		if (ioctl(fd, SMB_BREAD, &c) == -1)
 			return (-1);
-		for (i = 0; i < iflag; i++) {
+		for (i = 0; i < c.rcount; i++) {
 			if (i != 0)
 				putchar(' ');
 			printf(fmt, ibuf[i]);

From owner-svn-src-all@freebsd.org  Tue Dec 27 10:56:18 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id BF4D4C93DD2;
 Tue, 27 Dec 2016 10:56:18 +0000 (UTC)
 (envelope-from tuexen@freebsd.org)
Received: from drew.franken.de (mail-n.franken.de [193.175.24.27])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client CN "*.franken.de",
 Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id 89501159F;
 Tue, 27 Dec 2016 10:56:17 +0000 (UTC)
 (envelope-from tuexen@freebsd.org)
Received: from [192.168.1.121] (p4FE316D7.dip0.t-ipconnect.de [79.227.22.215])
 (Authenticated sender: macmic)
 by mail-n.franken.de (Postfix) with ESMTPSA id 82F9A721E282E;
 Tue, 27 Dec 2016 11:56:13 +0100 (CET)
Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0 (Mac OS X Mail 10.2 \(3259\))
Subject: Re: svn commit: r310547 - head/sys/netinet
From: Michael Tuexen <tuexen@freebsd.org>
In-Reply-To: <20161227081940.GL82166@strugglingcoder.info>
Date: Tue, 27 Dec 2016 11:56:13 +0100
Cc: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Content-Transfer-Encoding: quoted-printable
Message-Id: <693D4C85-526B-426C-9685-1D463E3C3903@freebsd.org>
References: <201612251737.uBPHbIhd027939@repo.freebsd.org>
 <20161227081940.GL82166@strugglingcoder.info>
To: hiren panchasara <hiren@strugglingcoder.info>
X-Mailer: Apple Mail (2.3259)
X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00
 autolearn=disabled version=3.4.1
X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail-n.franken.de
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 10:56:18 -0000

> On 27 Dec 2016, at 09:19, hiren panchasara =
<hiren@strugglingcoder.info> wrote:
>=20
> On 12/25/16 at 05:37P, Michael Tuexen wrote:
>> Author: tuexen
>> Date: Sun Dec 25 17:37:18 2016
>> New Revision: 310547
>> URL: https://svnweb.freebsd.org/changeset/base/310547
>>=20
>> Log:
>>  Remove a KASSERT which is not always true.
>>=20
>>  In case of the empty queue tp->snd_holes and tcp_sackhole_insert()
>>  failing due to memory shortage, tp->snd_holes will be empty.
>>  This problem was hit when stress tests where performed by pho.
>>=20
>>  PR:		215513
>>  Reported by:	pho
>>  Tested by:	pho
>>  Sponsored by:	Netflix, Inc.
>>=20
>> Modified:
>>  head/sys/netinet/tcp_sack.c
>=20
> Thanks for the fix, Michael. Can you please MFC this?
Sure. Will do it after 3 days or so. Missed that.

Best regards
Michael
>=20
> Cheers,
> Hiren


From owner-svn-src-all@freebsd.org  Tue Dec 27 14:08:50 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33612C8A5DE
 for <svn-src-all@mailman.ysv.freebsd.org>;
 Tue, 27 Dec 2016 14:08:50 +0000 (UTC)
 (envelope-from shawn.webb@hardenedbsd.org)
Received: from mail-qk0-x232.google.com (mail-qk0-x232.google.com
 [IPv6:2607:f8b0:400d:c09::232])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id DDF091A16
 for <svn-src-all@freebsd.org>; Tue, 27 Dec 2016 14:08:49 +0000 (UTC)
 (envelope-from shawn.webb@hardenedbsd.org)
Received: by mail-qk0-x232.google.com with SMTP id t184so220587892qkd.0
 for <svn-src-all@freebsd.org>; Tue, 27 Dec 2016 06:08:49 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=hardenedbsd-org.20150623.gappssmtp.com; s=20150623;
 h=date:from:to:cc:subject:message-id:references:mime-version
 :content-disposition:in-reply-to:user-agent;
 bh=R6UiMYzSMRT9KL6vQAeLB04Inq58HJ+E8cqoRKtE+hQ=;
 b=e4uHXHpqYLJdnmqGg2SY7WHOay1KzNsaZddYpBJYvBZ6m/lUDKV2p9eY38ZsJNwio+
 GI4FoMbXIgYdCVZJNLqvJ1droLWjzkdd7Puyb1KuCUE36YrLWXpUVT2zv0QUnV2xHGs/
 3fSz+i7Ow+x5edcG9wM0WBi0HsWs0mnjt9p9Tso0zyaZ7/CbOPgfuu3Dk/4aXwPIOtGD
 qYZY/nTRdst1n+mR00+NOtmwEYVctezleTnNlPW60awToIl6JAYdPFbik/sL2lt41nfS
 m5JfdgDN7OR6wIgxVV46OZlYaeYxeuELmwx0oW1QC44ysn6zw4XlAj+VZ4gOcIJ/UJCw
 qFSg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:date:from:to:cc:subject:message-id:references
 :mime-version:content-disposition:in-reply-to:user-agent;
 bh=R6UiMYzSMRT9KL6vQAeLB04Inq58HJ+E8cqoRKtE+hQ=;
 b=mri9RfZXcyBp5x2YhhAhoVKMFPxYXu1B16rRdlKengUimbOrPatFEeCgHkxXJKMVqF
 sQGxazGfseCkfhGaA5/fKgrb92dgNZ9YHKInMkc0LqINxOvDatBecN8PriijKzyQ0vhs
 Jd3CCvQAAP96PQ8scp3XBCImJdJCzVDsUADj3QHVOba+FFqkMDd6NH1MOn5PCD3fzdHl
 bI7zaG/kzC+d+CQrOi/xU6v2QEj6ZjoNvr9KnMnIiXD3/2CeDEoiplSPLGCGn5ZIX3+a
 dkUdhO8kJQMkFLInyNS/xXCdHhyL8PFx7HQ2VkPLTBmUXvzJArC4ueYw8chLvq6TxnNB
 XfQA==
X-Gm-Message-State: AIkVDXJe1YKAyW4F69D1HBwScIJGiqI0FQj+dca3ycFFtzxPISK/LGTTI/hK1btOScQAAtkP
X-Received: by 10.55.198.129 with SMTP id s1mr33800972qkl.268.1482847729009;
 Tue, 27 Dec 2016 06:08:49 -0800 (PST)
Received: from mutt-hardenedbsd ([63.88.83.66])
 by smtp.gmail.com with ESMTPSA id s65sm28640599qtd.2.2016.12.27.06.08.47
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Tue, 27 Dec 2016 06:08:47 -0800 (PST)
Date: Tue, 27 Dec 2016 09:08:46 -0500
From: Shawn Webb <shawn.webb@hardenedbsd.org>
To: Adrian Chadd <adrian@FreeBSD.org>
Cc: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: Re: svn commit: r310624 - head/sys/net80211
Message-ID: <20161227140846.xu4f6lmsgqytuhne@mutt-hardenedbsd>
References: <201612270610.uBR6ASrp025710@repo.freebsd.org>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha256;
 protocol="application/pgp-signature"; boundary="dxse5plh6235ywib"
Content-Disposition: inline
In-Reply-To: <201612270610.uBR6ASrp025710@repo.freebsd.org>
X-Operating-System: FreeBSD mutt-hardenedbsd 12.0-CURRENT-HBSD FreeBSD
 12.0-CURRENT-HBSD 
X-PGP-Key: http://pgp.mit.edu/pks/lookup?op=vindex&search=0x6A84658F52456EEE
User-Agent: NeoMutt/20161126 (1.7.1)
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 14:08:50 -0000


--dxse5plh6235ywib
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Tue, Dec 27, 2016 at 06:10:28AM +0000, Adrian Chadd wrote:
> Author: adrian
> Date: Tue Dec 27 06:10:28 2016
> New Revision: 310624
> URL: https://svnweb.freebsd.org/changeset/base/310624
>=20
> Log:
>   [net80211] turn the default TX key configuration (for WEP) into a vap c=
allback.
>  =20
>   The ath10k firmware supports hardware WEP offload, and in native wifi m=
ode
>   (or 802.3 ethernet mode, for that matter) the WEP key isn't actually in=
cluded
>   in the TX payload from net80211.  Instead, a separate firmware command =
is issued
>   that sets the default TX key to be the specified key.
>  =20
>   However, net80211 doesn't at all inform the driver layer that this is
>   occuring - it just "expects" to be inserting WEP header information
>   when doing WEP TX, even with hardware encryption.
>  =20
>   So, to better support the newer world order, turn the default TX key as=
signment
>   into a VAP method that can be overridden by the driver and ensure its w=
rapped
>   in a crypto begin/end set.  That way it should be correctly atomic from=
 the
>   point of view of keychanges (as long as the driver does the right thing=
=2E)
>  =20
>   It'd be nice if we passed through to the key_set call a flag that says
>   "also make this the default key" - that's captured here by calling the
>   deftxkey method after the key_set method.  Maybe I can do that later.
>  =20
>   Note: this is a net80211 ABI change, and will require a kernel+modules
>   recompile.  Happy Holidays, etc.

Hey Adrian,

Thank you very much for your hard work on the wireless stack. Since this
introduces an ABI change, should __FreeBSD_version be bumped?

Thanks,

--=20
Shawn Webb
Cofounder and Security Engineer
HardenedBSD

GPG Key ID:          0x6A84658F52456EEE
GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89  3D9E 6A84 658F 5245 6EEE

--dxse5plh6235ywib
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEKrq2ve9q9Ia+iT2eaoRlj1JFbu4FAlhidewACgkQaoRlj1JF
bu5t5g//cfiAvi9JeNZ37WoRx80fonwDtUHSN+vKLrzeQBFl1yBlpD5S0CWi0nAD
RbFUIWmJ/Rn9aMt9BrPWAK/TTipZVed6XT+xCBodNf8kQatQTD45CdAy+5OAUK8L
txpmE8Fyh2FkOvw4p5WtkHyuYzfocZVGqP4NnJXlhQg0N38EigZTVRZkRub5j3FU
xRJvz49Qn1U7YUJqoWWFLf9CHFMI2jHi65CUMNAcNA05tTw0Rng6l/vkulWThOyw
7B2cMdixfrGH64EdShgjh0uvbYrr8hAh4mHt1rXpHNejQVctU/gJRdpOEDcD8olN
jYae0H2SWWECuYPu2u7fGj/K6lUPfktuIG9okqJLBDjv+m4QgK8HVZjtie7Ehj9v
E1gQ+eeHWNfLbV2d8x+ezATZWd2Wl9CmLqgP/4VsvnBfV0iuURlv1c1mE0YEJOhO
LodNbRx39r4N5m0kbEBk12Yk2O0dvsHnduMssJYHbU4+0kndHcOPTVhVySwC6U8H
p+/vDTaGRwhbgZ6VAfQoMOkvyk60ud5ciEt89JXKMGtZlPxh6xVrG8JgRKvvZwnR
050wAggl2zo9yYceYnvOaEl+94/IdXiMo1Do2ViLj8BtBViRnjZ5tBjrUp8BPtQ+
2mUQkNAVu/3vljkf5aBzo8PkNJjnoRSgGg5bsiGtxO/O1WOSaMg=
=gumU
-----END PGP SIGNATURE-----

--dxse5plh6235ywib--

From owner-svn-src-all@freebsd.org  Tue Dec 27 17:13:33 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48686C926F9;
 Tue, 27 Dec 2016 17:13:33 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id F37281DF8;
 Tue, 27 Dec 2016 17:13:32 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRHDWPk098800;
 Tue, 27 Dec 2016 17:13:32 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRHDWac098798;
 Tue, 27 Dec 2016 17:13:32 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612271713.uBRHDWac098798@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 17:13:32 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310633 - head/usr.sbin/ctld
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 17:13:33 -0000

Author: mav
Date: Tue Dec 27 17:13:31 2016
New Revision: 310633
URL: https://svnweb.freebsd.org/changeset/base/310633

Log:
  Add MAX_LUNS overflow safety checks.
  
  While this MAX_LUNS limitation is too synthetic and should be removed,
  it is better to enforce it while it is here.
  
  MFC after:	2 weeks

Modified:
  head/usr.sbin/ctld/parse.y
  head/usr.sbin/ctld/uclparse.c

Modified: head/usr.sbin/ctld/parse.y
==============================================================================
--- head/usr.sbin/ctld/parse.y	Tue Dec 27 11:31:17 2016	(r310632)
+++ head/usr.sbin/ctld/parse.y	Tue Dec 27 17:13:31 2016	(r310633)
@@ -821,6 +821,11 @@ lun_number:	STR
 			free($1);
 			return (1);
 		}
+		if (tmp >= MAX_LUNS) {
+			yyerror("LU number is too big");
+			free($1);
+			return (1);
+		}
 
 		ret = asprintf(&name, "%s,lun,%ju", target->t_name, tmp);
 		if (ret <= 0)
@@ -845,6 +850,11 @@ target_lun_ref:	LUN STR STR
 			return (1);
 		}
 		free($2);
+		if (tmp >= MAX_LUNS) {
+			yyerror("LU number is too big");
+			free($3);
+			return (1);
+		}
 
 		lun = lun_find(conf, $3);
 		free($3);

Modified: head/usr.sbin/ctld/uclparse.c
==============================================================================
--- head/usr.sbin/ctld/uclparse.c	Tue Dec 27 11:31:17 2016	(r310632)
+++ head/usr.sbin/ctld/uclparse.c	Tue Dec 27 17:13:31 2016	(r310633)
@@ -183,18 +183,25 @@ static int
 uclparse_target_lun(struct target *target, const ucl_object_t *obj)
 {
 	struct lun *lun;
+	uint64_t tmp;
 
 	if (obj->type == UCL_INT) {
 		char *name;
 
-		asprintf(&name, "%s,lun,%ju", target->t_name,
-		    ucl_object_toint(obj));
+		tmp = ucl_object_toint(obj);
+		if (tmp >= MAX_LUNS) {
+			log_warnx("LU number %ju in target \"%s\" is too big",
+			    tmp, target->t_name);
+			return (1);
+		}
+
+		asprintf(&name, "%s,lun,%ju", target->t_name, tmp);
 		lun = lun_new(conf, name);
 		if (lun == NULL)
 			return (1);
 
 		lun_set_scsiname(lun, name);
-		target->t_luns[ucl_object_toint(obj)] = lun;
+		target->t_luns[tmp] = lun;
 		return (0);
 	}
 
@@ -207,6 +214,12 @@ uclparse_target_lun(struct target *targe
 			    "\"number\" integer property", target->t_name);
 			return (1);
 		}
+		tmp = ucl_object_toint(num);
+		if (tmp >= MAX_LUNS) {
+			log_warnx("LU number %ju in target \"%s\" is too big",
+			    tmp, target->t_name);
+			return (1);
+		}
 
 		if (name == NULL || name->type != UCL_STRING) {
 			log_warnx("lun section in target \"%s\" is missing "
@@ -218,7 +231,7 @@ uclparse_target_lun(struct target *targe
 		if (lun == NULL)
 			return (1);
 
-		target->t_luns[ucl_object_toint(num)] = lun;
+		target->t_luns[tmp] = lun;
 	}
 
 	return (0);

From owner-svn-src-all@freebsd.org  Tue Dec 27 17:31:08 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id B0DB8C92B90;
 Tue, 27 Dec 2016 17:31:08 +0000 (UTC)
 (envelope-from emaste@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 671C0179E;
 Tue, 27 Dec 2016 17:31:08 +0000 (UTC)
 (envelope-from emaste@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRHV7BO004205;
 Tue, 27 Dec 2016 17:31:07 GMT (envelope-from emaste@FreeBSD.org)
Received: (from emaste@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRHV7Ul004204;
 Tue, 27 Dec 2016 17:31:07 GMT (envelope-from emaste@FreeBSD.org)
Message-Id: <201612271731.uBRHV7Ul004204@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: emaste set sender to
 emaste@FreeBSD.org using -f
From: Ed Maste <emaste@FreeBSD.org>
Date: Tue, 27 Dec 2016 17:31:07 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310634 - head/contrib/elftoolchain/elfcopy
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 17:31:08 -0000

Author: emaste
Date: Tue Dec 27 17:31:07 2016
New Revision: 310634
URL: https://svnweb.freebsd.org/changeset/base/310634

Log:
  elfcopy: fix PE object section name corruption and crash
  
  Fixed a bug that the PE object section names are generated incorrectly
  using the section name table found in the original input ELF object
  instead of the intermediate ELF object.
  
  Ticket:		#541
  
  Do not try to copy section content from a NULL d_buf when creating
  uninitialized data COFF section for PE object.
  
  Ticket:		#540
  
  Obtained from:	ELF Tool Chain r3507, r3508
  MFC after:	1 week

Modified:
  head/contrib/elftoolchain/elfcopy/pe.c

Modified: head/contrib/elftoolchain/elfcopy/pe.c
==============================================================================
--- head/contrib/elftoolchain/elfcopy/pe.c	Tue Dec 27 17:13:31 2016	(r310633)
+++ head/contrib/elftoolchain/elfcopy/pe.c	Tue Dec 27 17:31:07 2016	(r310634)
@@ -70,7 +70,7 @@ create_pe(struct elfcopy *ecp, int ifd, 
 		errx(EXIT_FAILURE, "gelf_getehdr() failed: %s",
 		    elf_errmsg(-1));
 
-	if (elf_getshstrndx(ecp->ein, &indx) == 0)
+	if (elf_getshstrndx(e, &indx) == 0)
 		errx(EXIT_FAILURE, "elf_getshstrndx() failed: %s",
 		    elf_errmsg(-1));
 
@@ -124,7 +124,7 @@ create_pe(struct elfcopy *ecp, int ifd, 
 			(void) elf_errno();
 			continue;
 		}
-		if ((name = elf_strptr(ecp->ein, indx, sh.sh_name)) ==
+		if ((name = elf_strptr(e, indx, sh.sh_name)) ==
 		    NULL) {
 			warnx("elf_strptr() failed: %s", elf_errmsg(-1));
 			(void) elf_errno();
@@ -210,12 +210,14 @@ create_pe(struct elfcopy *ecp, int ifd, 
 		}
 		pb->pb_align = 1;
 		pb->pb_off = 0;
-		pb->pb_size = roundup(sh.sh_size, poh.oh_filealign);
-		if ((pb->pb_buf = calloc(1, pb->pb_size)) == NULL) {
-			warn("calloc failed");
-			continue;
+		if (sh.sh_type != SHT_NOBITS) {
+			pb->pb_size = roundup(sh.sh_size, poh.oh_filealign);
+			if ((pb->pb_buf = calloc(1, pb->pb_size)) == NULL) {
+				warn("calloc failed");
+				continue;
+			}
+			memcpy(pb->pb_buf, d->d_buf, sh.sh_size);
 		}
-		memcpy(pb->pb_buf, d->d_buf, sh.sh_size);
 	}
 	elferr = elf_errno();
 	if (elferr != 0)

From owner-svn-src-all@freebsd.org  Tue Dec 27 18:23:18 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 76612C9334C;
 Tue, 27 Dec 2016 18:23:18 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 3714E1993;
 Tue, 27 Dec 2016 18:23:18 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRINHfO028634;
 Tue, 27 Dec 2016 18:23:17 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRINHwn028630;
 Tue, 27 Dec 2016 18:23:17 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612271823.uBRINHwn028630@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 18:23:17 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310635 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 18:23:18 -0000

Author: mav
Date: Tue Dec 27 18:23:16 2016
New Revision: 310635
URL: https://svnweb.freebsd.org/changeset/base/310635

Log:
  Decouple limits on number of LUNs per port and LUs per CTL.
  
  Those two values are not directly related, so make them independent.
  This does not change any limits immediately, but makes number of LUNs
  per port controllable via tunable/sysctl kern.cam.ctl.lun_map_size.
  After this change increasing CTL_MAX_LUNS should be pretty cheap,
  and even making it tunable should be easy.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c
  head/sys/cam/ctl/ctl_frontend.c
  head/sys/cam/ctl/ctl_frontend.h
  head/sys/cam/ctl/ctl_io.h

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Tue Dec 27 17:31:07 2016	(r310634)
+++ head/sys/cam/ctl/ctl.c	Tue Dec 27 18:23:16 2016	(r310635)
@@ -407,6 +407,9 @@ SYSCTL_INT(_kern_cam_ctl, OID_AUTO, work
 static int ctl_debug = CTL_DEBUG_NONE;
 SYSCTL_INT(_kern_cam_ctl, OID_AUTO, debug, CTLFLAG_RWTUN,
     &ctl_debug, 0, "Enabled debug flags");
+static int ctl_lun_map_size = 1024;
+SYSCTL_INT(_kern_cam_ctl, OID_AUTO, lun_map_size, CTLFLAG_RWTUN,
+    &ctl_lun_map_size, 0, "Size of per-port LUN map (max LUN + 1)");
 
 /*
  * Supported pages (0x00), Serial number (0x80), Device ID (0x83),
@@ -826,7 +829,7 @@ ctl_isc_announce_port(struct ctl_port *p
 		return;
 	i = sizeof(msg->port) + strlen(port->port_name) + 1;
 	if (port->lun_map)
-		i += sizeof(uint32_t) * CTL_MAX_LUNS;
+		i += port->lun_map_size * sizeof(uint32_t);
 	if (port->port_devid)
 		i += port->port_devid->len;
 	if (port->target_devid)
@@ -846,7 +849,7 @@ ctl_isc_announce_port(struct ctl_port *p
 	    "%d:%s", softc->ha_id, port->port_name) + 1;
 	i += msg->port.name_len;
 	if (port->lun_map) {
-		msg->port.lun_map_len = sizeof(uint32_t) * CTL_MAX_LUNS;
+		msg->port.lun_map_len = port->lun_map_size * sizeof(uint32_t);
 		memcpy(&msg->port.data[i], port->lun_map,
 		    msg->port.lun_map_len);
 		i += msg->port.lun_map_len;
@@ -1155,19 +1158,25 @@ ctl_isc_port_sync(struct ctl_softc *soft
 	    M_CTL);
 	i += msg->port.name_len;
 	if (msg->port.lun_map_len != 0) {
-		if (port->lun_map == NULL)
-			port->lun_map = malloc(sizeof(uint32_t) * CTL_MAX_LUNS,
+		if (port->lun_map == NULL ||
+		    port->lun_map_size * sizeof(uint32_t) <
+		    msg->port.lun_map_len) {
+			port->lun_map_size = 0;
+			free(port->lun_map, M_CTL);
+			port->lun_map = malloc(msg->port.lun_map_len,
 			    M_CTL, M_WAITOK);
-		memcpy(port->lun_map, &msg->port.data[i],
-		    sizeof(uint32_t) * CTL_MAX_LUNS);
+		}
+		memcpy(port->lun_map, &msg->port.data[i], msg->port.lun_map_len);
+		port->lun_map_size = msg->port.lun_map_len / sizeof(uint32_t);
 		i += msg->port.lun_map_len;
 	} else {
+		port->lun_map_size = 0;
 		free(port->lun_map, M_CTL);
 		port->lun_map = NULL;
 	}
 	if (msg->port.port_devid_len != 0) {
 		if (port->port_devid == NULL ||
-		    port->port_devid->len != msg->port.port_devid_len) {
+		    port->port_devid->len < msg->port.port_devid_len) {
 			free(port->port_devid, M_CTL);
 			port->port_devid = malloc(sizeof(struct ctl_devid) +
 			    msg->port.port_devid_len, M_CTL, M_WAITOK);
@@ -1182,7 +1191,7 @@ ctl_isc_port_sync(struct ctl_softc *soft
 	}
 	if (msg->port.target_devid_len != 0) {
 		if (port->target_devid == NULL ||
-		    port->target_devid->len != msg->port.target_devid_len) {
+		    port->target_devid->len < msg->port.target_devid_len) {
 			free(port->target_devid, M_CTL);
 			port->target_devid = malloc(sizeof(struct ctl_devid) +
 			    msg->port.target_devid_len, M_CTL, M_WAITOK);
@@ -1197,7 +1206,7 @@ ctl_isc_port_sync(struct ctl_softc *soft
 	}
 	if (msg->port.init_devid_len != 0) {
 		if (port->init_devid == NULL ||
-		    port->init_devid->len != msg->port.init_devid_len) {
+		    port->init_devid->len < msg->port.init_devid_len) {
 			free(port->init_devid, M_CTL);
 			port->init_devid = malloc(sizeof(struct ctl_devid) +
 			    msg->port.init_devid_len, M_CTL, M_WAITOK);
@@ -3295,7 +3304,7 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 
 			if (port->lun_map != NULL) {
 				sbuf_printf(sb, "\t<lun_map>on</lun_map>\n");
-				for (j = 0; j < CTL_MAX_LUNS; j++) {
+				for (j = 0; j < port->lun_map_size; j++) {
 					plun = ctl_lun_map_from_port(port, j);
 					if (plun == UINT32_MAX)
 						continue;
@@ -3375,7 +3384,7 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 			}
 		}
 		mtx_unlock(&softc->ctl_lock); // XXX: port_enable sleeps
-		if (lm->plun < CTL_MAX_LUNS) {
+		if (lm->plun != UINT32_MAX) {
 			if (lm->lun == UINT32_MAX)
 				retval = ctl_lun_map_unset(port, lm->plun);
 			else if (lm->lun < CTL_MAX_LUNS &&
@@ -3383,13 +3392,12 @@ ctl_ioctl(struct cdev *dev, u_long cmd, 
 				retval = ctl_lun_map_set(port, lm->plun, lm->lun);
 			else
 				return (ENXIO);
-		} else if (lm->plun == UINT32_MAX) {
+		} else {
 			if (lm->lun == UINT32_MAX)
 				retval = ctl_lun_map_deinit(port);
 			else
 				retval = ctl_lun_map_init(port);
-		} else
-			return (ENXIO);
+		}
 		if (port->status & CTL_PORT_STATUS_ONLINE)
 			ctl_isc_announce_port(port);
 		break;
@@ -3442,15 +3450,20 @@ ctl_lun_map_init(struct ctl_port *port)
 {
 	struct ctl_softc *softc = port->ctl_softc;
 	struct ctl_lun *lun;
+	int size = ctl_lun_map_size;
 	uint32_t i;
 
-	if (port->lun_map == NULL)
-		port->lun_map = malloc(sizeof(uint32_t) * CTL_MAX_LUNS,
+	if (port->lun_map == NULL || port->lun_map_size < size) {
+		port->lun_map_size = 0;
+		free(port->lun_map, M_CTL);
+		port->lun_map = malloc(size * sizeof(uint32_t),
 		    M_CTL, M_NOWAIT);
+	}
 	if (port->lun_map == NULL)
 		return (ENOMEM);
-	for (i = 0; i < CTL_MAX_LUNS; i++)
+	for (i = 0; i < size; i++)
 		port->lun_map[i] = UINT32_MAX;
+	port->lun_map_size = size;
 	if (port->status & CTL_PORT_STATUS_ONLINE) {
 		if (port->lun_disable != NULL) {
 			STAILQ_FOREACH(lun, &softc->lun_list, links)
@@ -3469,6 +3482,7 @@ ctl_lun_map_deinit(struct ctl_port *port
 
 	if (port->lun_map == NULL)
 		return (0);
+	port->lun_map_size = 0;
 	free(port->lun_map, M_CTL);
 	port->lun_map = NULL;
 	if (port->status & CTL_PORT_STATUS_ONLINE) {
@@ -3492,6 +3506,8 @@ ctl_lun_map_set(struct ctl_port *port, u
 		if (status != 0)
 			return (status);
 	}
+	if (plun >= port->lun_map_size)
+		return (EINVAL);
 	old = port->lun_map[plun];
 	port->lun_map[plun] = glun;
 	if ((port->status & CTL_PORT_STATUS_ONLINE) && old == UINT32_MAX) {
@@ -3507,7 +3523,7 @@ ctl_lun_map_unset(struct ctl_port *port,
 {
 	uint32_t old;
 
-	if (port->lun_map == NULL)
+	if (port->lun_map == NULL || plun >= port->lun_map_size)
 		return (0);
 	old = port->lun_map[plun];
 	port->lun_map[plun] = UINT32_MAX;
@@ -3525,8 +3541,10 @@ ctl_lun_map_from_port(struct ctl_port *p
 
 	if (port == NULL)
 		return (UINT32_MAX);
-	if (port->lun_map == NULL || lun_id == UINT32_MAX)
+	if (port->lun_map == NULL)
 		return (lun_id);
+	if (lun_id > port->lun_map_size)
+		return (UINT32_MAX);
 	return (port->lun_map[lun_id]);
 }
 
@@ -3539,7 +3557,7 @@ ctl_lun_map_to_port(struct ctl_port *por
 		return (UINT32_MAX);
 	if (port->lun_map == NULL)
 		return (lun_id);
-	for (i = 0; i < CTL_MAX_LUNS; i++) {
+	for (i = 0; i < port->lun_map_size; i++) {
 		if (port->lun_map[i] == lun_id)
 			return (i);
 	}
@@ -9048,9 +9066,8 @@ ctl_report_luns(struct ctl_scsiio *ctsio
 	struct scsi_report_luns_data *lun_data;
 	struct ctl_lun *lun, *request_lun;
 	struct ctl_port *port;
-	int num_luns, retval;
+	int num_filled, num_luns, num_port_luns, retval;
 	uint32_t alloc_len, lun_datalen;
-	int num_filled;
 	uint32_t initidx, targ_lun_id, lun_id;
 
 	retval = CTL_RETVAL_COMPLETE;
@@ -9060,9 +9077,10 @@ ctl_report_luns(struct ctl_scsiio *ctsio
 
 	CTL_DEBUG_PRINT(("ctl_report_luns\n"));
 
-	mtx_lock(&softc->ctl_lock);
 	num_luns = 0;
-	for (targ_lun_id = 0; targ_lun_id < CTL_MAX_LUNS; targ_lun_id++) {
+	num_port_luns = port->lun_map ? port->lun_map_size : CTL_MAX_LUNS;
+	mtx_lock(&softc->ctl_lock);
+	for (targ_lun_id = 0; targ_lun_id < num_port_luns; targ_lun_id++) {
 		if (ctl_lun_map_from_port(port, targ_lun_id) != UINT32_MAX)
 			num_luns++;
 	}
@@ -9121,7 +9139,9 @@ ctl_report_luns(struct ctl_scsiio *ctsio
 	initidx = ctl_get_initindex(&ctsio->io_hdr.nexus);
 
 	mtx_lock(&softc->ctl_lock);
-	for (targ_lun_id = 0, num_filled = 0; targ_lun_id < CTL_MAX_LUNS && num_filled < num_luns; targ_lun_id++) {
+	for (targ_lun_id = 0, num_filled = 0;
+	    targ_lun_id < num_port_luns && num_filled < num_luns;
+	    targ_lun_id++) {
 		lun_id = ctl_lun_map_from_port(port, targ_lun_id);
 		if (lun_id == UINT32_MAX)
 			continue;

Modified: head/sys/cam/ctl/ctl_frontend.c
==============================================================================
--- head/sys/cam/ctl/ctl_frontend.c	Tue Dec 27 17:31:07 2016	(r310634)
+++ head/sys/cam/ctl/ctl_frontend.c	Tue Dec 27 18:23:16 2016	(r310635)
@@ -315,7 +315,7 @@ ctl_port_online(struct ctl_port *port)
 
 	if (port->lun_enable != NULL) {
 		if (port->lun_map) {
-			for (l = 0; l < CTL_MAX_LUNS; l++) {
+			for (l = 0; l < port->lun_map_size; l++) {
 				if (ctl_lun_map_from_port(port, l) ==
 				    UINT32_MAX)
 					continue;
@@ -359,7 +359,7 @@ ctl_port_offline(struct ctl_port *port)
 		port->port_offline(port->onoff_arg);
 	if (port->lun_disable != NULL) {
 		if (port->lun_map) {
-			for (l = 0; l < CTL_MAX_LUNS; l++) {
+			for (l = 0; l < port->lun_map_size; l++) {
 				if (ctl_lun_map_from_port(port, l) ==
 				    UINT32_MAX)
 					continue;

Modified: head/sys/cam/ctl/ctl_frontend.h
==============================================================================
--- head/sys/cam/ctl/ctl_frontend.h	Tue Dec 27 17:31:07 2016	(r310634)
+++ head/sys/cam/ctl/ctl_frontend.h	Tue Dec 27 18:23:16 2016	(r310635)
@@ -225,6 +225,7 @@ struct ctl_port {
 	void		*onoff_arg;		/* passed to CTL */
 	lun_func_t	lun_enable;		/* passed to CTL */
 	lun_func_t	lun_disable;		/* passed to CTL */
+	int		lun_map_size;		/* passed to CTL */
 	uint32_t	*lun_map;		/* passed to CTL */
 	void		*targ_lun_arg;		/* passed to CTL */
 	void		(*fe_datamove)(union ctl_io *io); /* passed to CTL */

Modified: head/sys/cam/ctl/ctl_io.h
==============================================================================
--- head/sys/cam/ctl/ctl_io.h	Tue Dec 27 17:31:07 2016	(r310634)
+++ head/sys/cam/ctl/ctl_io.h	Tue Dec 27 18:23:16 2016	(r310635)
@@ -365,7 +365,7 @@ struct ctl_taskio {
 /*
  * HA link messages.
  */
-#define	CTL_HA_VERSION		1
+#define	CTL_HA_VERSION		2
 
 /*
  * Used for CTL_MSG_LOGIN.

From owner-svn-src-all@freebsd.org  Tue Dec 27 18:48:20 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 57BDBC938B3;
 Tue, 27 Dec 2016 18:48:20 +0000 (UTC)
 (envelope-from adrian.chadd@gmail.com)
Received: from mail-wm0-x243.google.com (mail-wm0-x243.google.com
 [IPv6:2a00:1450:400c:c09::243])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id D76DC1499;
 Tue, 27 Dec 2016 18:48:19 +0000 (UTC)
 (envelope-from adrian.chadd@gmail.com)
Received: by mail-wm0-x243.google.com with SMTP id u144so58389530wmu.0;
 Tue, 27 Dec 2016 10:48:19 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=mime-version:sender:in-reply-to:references:from:date:message-id
 :subject:to:cc;
 bh=QUyXkiY0/KZFjcDxEubcDuTUwDblAVofste+4KOtob0=;
 b=NKMaZLoc/G/qRCqugx1ZSR6aL5+Acyw1gHI94c9BR1G0uDXIkzrOxN+pvx8Mcccde2
 svR1qjMU+0xCTRi+qqtrtfhlBK0QksVApLf/9M3Y2SoA3E380+PI8nH4LlHhN+yfBxQj
 UtcJkcgxl5+Fl2f3Y1o2rv52b67XVoL8dpJMH4rQRUIwAH5avqkhZPDCu+gBd6bbA0I8
 p0MfxiJ/3rrjbgJxL2EheTIirgZ+1JHe7cGqpgvtQxxVSwUFLoLj9K3NK+ZvXvQfTT8m
 EciPs7bQQoVxnXTOJ/fUgydUi77yZyowiXAtIrctWoTSmzQP3NRXF2xjUDBHiL+G152/
 m/uA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:mime-version:sender:in-reply-to:references:from
 :date:message-id:subject:to:cc;
 bh=QUyXkiY0/KZFjcDxEubcDuTUwDblAVofste+4KOtob0=;
 b=s2yzd5f4NdqC4OC4RHUax4oFGzIllGCJrA4w6oTui2O/qsqS4pExmAdd3DZv/KR6i8
 eNRUd+AMIq0Y6CzcqGyxiEk11o6/7CJnMMHv4WjTZuQnCLfi2lmy1QVBHqz6oBCPlhAx
 pDXYrS5EdTLkwqSS3FVOSHDzBFeq8yyefgjyTQWH3MHjea5iG0XwDUlFLB6Ms8afZI13
 YWUlzPqjq5bIUNQsaFQejUmiyl2+DjLHrruQOaIjPwKvswB0HxM0gpB/rK40WDInebNN
 FeNICRjqmKnlKbrSREGAFBN+ilVuONC0SxAyhWSVx7EXrRVPfUuHu2tYSIs99JMq0KPb
 Lq4w==
X-Gm-Message-State: AIkVDXKs9tr5yj/gWz0m05BqQAopi6eXVDBMWG2V51+kv+oXrCo3cP6wFp3S5RTg1LIhGlYZq6LewtzRbWATqQ==
X-Received: by 10.28.165.82 with SMTP id o79mr17941688wme.129.1482864498188;
 Tue, 27 Dec 2016 10:48:18 -0800 (PST)
MIME-Version: 1.0
Sender: adrian.chadd@gmail.com
Received: by 10.194.44.1 with HTTP; Tue, 27 Dec 2016 10:48:17 -0800 (PST)
In-Reply-To: <20161227140846.xu4f6lmsgqytuhne@mutt-hardenedbsd>
References: <201612270610.uBR6ASrp025710@repo.freebsd.org>
 <20161227140846.xu4f6lmsgqytuhne@mutt-hardenedbsd>
From: Adrian Chadd <adrian@freebsd.org>
Date: Tue, 27 Dec 2016 10:48:17 -0800
X-Google-Sender-Auth: 6EkElqfV0HDqV_T4p5xhjrefq5A
Message-ID: <CAJ-VmomnYNtO59EArEh1Ac4iq8fEn-nwer=HLM+7XBeAjkpM+Q@mail.gmail.com>
Subject: Re: svn commit: r310624 - head/sys/net80211
To: Shawn Webb <shawn.webb@hardenedbsd.org>
Cc: "src-committers@freebsd.org" <src-committers@freebsd.org>, 
 "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>, 
 "svn-src-head@freebsd.org" <svn-src-head@freebsd.org>
Content-Type: text/plain; charset=UTF-8
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 18:48:20 -0000

Hi,

As it's a kernel change in a frequently changing subsystem in -HEAD,
I'm opting not to bump it until I get the 11ac bits "done" enough.
Otherwise there'd be a lot of churn. I did bump it for the userland
facing ABI though as that did have a pretty big impact.

Anyone using binary-only wifi kernel modules on FreeBSD should know better. :)

I promise to bump it once 11ac is "done" enough to use, so there is a
good reference point.

Thanks,


-adrian


On 27 December 2016 at 06:08, Shawn Webb <shawn.webb@hardenedbsd.org> wrote:
> On Tue, Dec 27, 2016 at 06:10:28AM +0000, Adrian Chadd wrote:
>> Author: adrian
>> Date: Tue Dec 27 06:10:28 2016
>> New Revision: 310624
>> URL: https://svnweb.freebsd.org/changeset/base/310624
>>
>> Log:
>>   [net80211] turn the default TX key configuration (for WEP) into a vap callback.
>>
>>   The ath10k firmware supports hardware WEP offload, and in native wifi mode
>>   (or 802.3 ethernet mode, for that matter) the WEP key isn't actually included
>>   in the TX payload from net80211.  Instead, a separate firmware command is issued
>>   that sets the default TX key to be the specified key.
>>
>>   However, net80211 doesn't at all inform the driver layer that this is
>>   occuring - it just "expects" to be inserting WEP header information
>>   when doing WEP TX, even with hardware encryption.
>>
>>   So, to better support the newer world order, turn the default TX key assignment
>>   into a VAP method that can be overridden by the driver and ensure its wrapped
>>   in a crypto begin/end set.  That way it should be correctly atomic from the
>>   point of view of keychanges (as long as the driver does the right thing.)
>>
>>   It'd be nice if we passed through to the key_set call a flag that says
>>   "also make this the default key" - that's captured here by calling the
>>   deftxkey method after the key_set method.  Maybe I can do that later.
>>
>>   Note: this is a net80211 ABI change, and will require a kernel+modules
>>   recompile.  Happy Holidays, etc.
>
> Hey Adrian,
>
> Thank you very much for your hard work on the wireless stack. Since this
> introduces an ABI change, should __FreeBSD_version be bumped?
>
> Thanks,
>
> --
> Shawn Webb
> Cofounder and Security Engineer
> HardenedBSD
>
> GPG Key ID:          0x6A84658F52456EEE
> GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89  3D9E 6A84 658F 5245 6EEE

From owner-svn-src-all@freebsd.org  Tue Dec 27 18:50:11 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D5CFBC939EC
 for <svn-src-all@mailman.ysv.freebsd.org>;
 Tue, 27 Dec 2016 18:50:11 +0000 (UTC)
 (envelope-from shawn.webb@hardenedbsd.org)
Received: from mail-qk0-x22f.google.com (mail-qk0-x22f.google.com
 [IPv6:2607:f8b0:400d:c09::22f])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id 89FCE17A5
 for <svn-src-all@freebsd.org>; Tue, 27 Dec 2016 18:50:11 +0000 (UTC)
 (envelope-from shawn.webb@hardenedbsd.org)
Received: by mail-qk0-x22f.google.com with SMTP id u25so216330664qki.2
 for <svn-src-all@freebsd.org>; Tue, 27 Dec 2016 10:50:11 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=hardenedbsd-org.20150623.gappssmtp.com; s=20150623;
 h=date:from:to:cc:subject:message-id:references:mime-version
 :content-disposition:in-reply-to:user-agent;
 bh=UlPp1hdCfOpF7u0wdvwTVYa7saALUaFByXAVw8UKF2o=;
 b=KBojRPYcgYwbbOR7Z9Jp/3GRJlVipN1cE+O5ZOGuSK/EifvLVpIVB3p5XAoV1XMhLB
 fZTo6VhNzqmGn/TUZkelSeQx8CL9qVSl6guMmw1ngka4kINpfs3OzpXw3iueygy58nuv
 PWN/y5EzvBLds60mghfxet5gSYrLTwOMAHKkWp4Nnlu0Tsx4q6z7EbUN0mlDWZFPEeyK
 o19kN6zTi4mGk2Y2SHowfDdWoTgx4FSssKJd2wAQqyYnEskTr+jxsMP9W7CoyI6hFbGT
 y0moz3K7/lQgcRU2A92a1C5T8PxYVrfr1NXN/Kh7qrdeTlgNEfWxaX8mhbz6/DTA1Wrf
 rnGw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:date:from:to:cc:subject:message-id:references
 :mime-version:content-disposition:in-reply-to:user-agent;
 bh=UlPp1hdCfOpF7u0wdvwTVYa7saALUaFByXAVw8UKF2o=;
 b=f1M30Y9+hS1CDJGPURHqFEkzSd641lcaDBRfbuI4ni2UKw4MI9Ixg8xV/Y0sZobMRz
 Gx/qsJ8CWb7MBeWo/3JWMzp6M1Ut+HfcI9WRcjg8GX5ysfXZK5SMuyJlLUdac7ynP3V9
 JQsd2M69cTyxe1x1eT1JRQ85WurYVt/NYasB0ia/yZIapM8y2EjAGjIektUMaaWFTBCg
 PKWApucmpNCeIqxT8gqJLkRm2SFtrr8Y1UWcHHcsUqZAoWIUGS7ETvPk5jGA8k9GnHdv
 dCTvbhZOGro/Wif9NCWNpRd6qDfyoFcL/RZk9XAj5yAjkkk3Fifpdwq/mVYt0TXy2GnA
 2QPw==
X-Gm-Message-State: AIkVDXLmq4J4j1GEY6uyQov4xdr2dDo8Ym2ZQAiOIpJ3sigu0B3p9j8O0E+IRfIiuHntr491
X-Received: by 10.55.44.193 with SMTP id s184mr35029490qkh.278.1482864610591; 
 Tue, 27 Dec 2016 10:50:10 -0800 (PST)
Received: from mutt-hardenedbsd ([63.88.83.66])
 by smtp.gmail.com with ESMTPSA id w34sm29059222qtw.10.2016.12.27.10.50.09
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Tue, 27 Dec 2016 10:50:09 -0800 (PST)
Date: Tue, 27 Dec 2016 13:50:08 -0500
From: Shawn Webb <shawn.webb@hardenedbsd.org>
To: Adrian Chadd <adrian@freebsd.org>
Cc: "src-committers@freebsd.org" <src-committers@freebsd.org>,
 "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>,
 "svn-src-head@freebsd.org" <svn-src-head@freebsd.org>
Subject: Re: svn commit: r310624 - head/sys/net80211
Message-ID: <20161227185008.ugrmmnwfdpin4mcf@mutt-hardenedbsd>
References: <201612270610.uBR6ASrp025710@repo.freebsd.org>
 <20161227140846.xu4f6lmsgqytuhne@mutt-hardenedbsd>
 <CAJ-VmomnYNtO59EArEh1Ac4iq8fEn-nwer=HLM+7XBeAjkpM+Q@mail.gmail.com>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha256;
 protocol="application/pgp-signature"; boundary="yvkoprcmqyatt6gk"
Content-Disposition: inline
In-Reply-To: <CAJ-VmomnYNtO59EArEh1Ac4iq8fEn-nwer=HLM+7XBeAjkpM+Q@mail.gmail.com>
X-Operating-System: FreeBSD mutt-hardenedbsd 12.0-CURRENT-HBSD FreeBSD
 12.0-CURRENT-HBSD 
X-PGP-Key: http://pgp.mit.edu/pks/lookup?op=vindex&search=0x6A84658F52456EEE
User-Agent: NeoMutt/20161126 (1.7.1)
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 18:50:11 -0000


--yvkoprcmqyatt6gk
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Sounds good. Thanks for the explanation!

On Tue, Dec 27, 2016 at 10:48:17AM -0800, Adrian Chadd wrote:
> Hi,
>=20
> As it's a kernel change in a frequently changing subsystem in -HEAD,
> I'm opting not to bump it until I get the 11ac bits "done" enough.
> Otherwise there'd be a lot of churn. I did bump it for the userland
> facing ABI though as that did have a pretty big impact.
>=20
> Anyone using binary-only wifi kernel modules on FreeBSD should know bette=
r. :)
>=20
> I promise to bump it once 11ac is "done" enough to use, so there is a
> good reference point.
>=20
> Thanks,
>=20
>=20
> -adrian
>=20
>=20
> On 27 December 2016 at 06:08, Shawn Webb <shawn.webb@hardenedbsd.org> wro=
te:
> > On Tue, Dec 27, 2016 at 06:10:28AM +0000, Adrian Chadd wrote:
> >> Author: adrian
> >> Date: Tue Dec 27 06:10:28 2016
> >> New Revision: 310624
> >> URL: https://svnweb.freebsd.org/changeset/base/310624
> >>
> >> Log:
> >>   [net80211] turn the default TX key configuration (for WEP) into a va=
p callback.
> >>
> >>   The ath10k firmware supports hardware WEP offload, and in native wif=
i mode
> >>   (or 802.3 ethernet mode, for that matter) the WEP key isn't actually=
 included
> >>   in the TX payload from net80211.  Instead, a separate firmware comma=
nd is issued
> >>   that sets the default TX key to be the specified key.
> >>
> >>   However, net80211 doesn't at all inform the driver layer that this is
> >>   occuring - it just "expects" to be inserting WEP header information
> >>   when doing WEP TX, even with hardware encryption.
> >>
> >>   So, to better support the newer world order, turn the default TX key=
 assignment
> >>   into a VAP method that can be overridden by the driver and ensure it=
s wrapped
> >>   in a crypto begin/end set.  That way it should be correctly atomic f=
rom the
> >>   point of view of keychanges (as long as the driver does the right th=
ing.)
> >>
> >>   It'd be nice if we passed through to the key_set call a flag that sa=
ys
> >>   "also make this the default key" - that's captured here by calling t=
he
> >>   deftxkey method after the key_set method.  Maybe I can do that later.
> >>
> >>   Note: this is a net80211 ABI change, and will require a kernel+modul=
es
> >>   recompile.  Happy Holidays, etc.
> >
> > Hey Adrian,
> >
> > Thank you very much for your hard work on the wireless stack. Since this
> > introduces an ABI change, should __FreeBSD_version be bumped?
> >
> > Thanks,
> >
> > --
> > Shawn Webb
> > Cofounder and Security Engineer
> > HardenedBSD
> >
> > GPG Key ID:          0x6A84658F52456EEE
> > GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89  3D9E 6A84 658F 5245 6EEE

--=20
Shawn Webb
Cofounder and Security Engineer
HardenedBSD

GPG Key ID:          0x6A84658F52456EEE
GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89  3D9E 6A84 658F 5245 6EEE

--yvkoprcmqyatt6gk
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEKrq2ve9q9Ia+iT2eaoRlj1JFbu4FAlhit94ACgkQaoRlj1JF
bu6imQ/6AoeWLdRHHTj07nDHEE33ER+fpZHlyD2EaMCeh4q1rHo5sqgDRFhVJMdA
vVXpQrFUZ6DWwqGoN3s7ATXQqrgYv0iKHO03JtpQTe7bSckel/wYf9mJ/evgOG9o
ZMeU4cR5t1Dc9Yybff7AwtTaUskcJm5IV0iCL3iUmoS8qE7JJxzexHxYaUwdHY6x
2SNeinDie4P5yJBBMYzjhD52MCHrmS6DspCkXV+aW6u4MHjL299clI5Txs9HxNxS
lIFolrBZjjMUx+t2sZ/Ig7XcFFApCbroDpDbM3bHAK8lrCUfDG6u55i1WpYc75UB
ZM1SvNk0GhpHnPCzIbUE+96ATVGH7ygerXC9fnvHz8BY1GX6eKSRQZFrix8F8Gvp
vXP7La32axyPfsNu8nTpkXOK9jPn7PtU1VvJcI8iHrmYSqNCa+YXrAo/nkRrppvM
1dVMdASbGQLvHuGCU0U1Ra+UsDjiEa3aeo4+7RELdfwwQtq71yHB0jxP0lsLO69v
EkGgOzvx4Cz0d3TCxVVn+/TAVw8l2FcgVB6idjBe2RxpKnukTugZ/babfZF76hff
s+4OsQmC2u2d2/S9pIyu5gCyYtJBElmcHE/6p6zeMecOZqDFeMHnjCrcvYhchc21
wthqyvMlVXKp332+od45teTDvQGGGjYr6+i+z/PFIJFFIZbuj2Y=
=/aNR
-----END PGP SIGNATURE-----

--yvkoprcmqyatt6gk--

From owner-svn-src-all@freebsd.org  Tue Dec 27 19:08:09 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A141AC93024;
 Tue, 27 Dec 2016 19:08:09 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 684AE1454;
 Tue, 27 Dec 2016 19:08:09 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRJ88YY046231;
 Tue, 27 Dec 2016 19:08:08 GMT (envelope-from gonzo@FreeBSD.org)
Received: (from gonzo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRJ88DE046230;
 Tue, 27 Dec 2016 19:08:08 GMT (envelope-from gonzo@FreeBSD.org)
Message-Id: <201612271908.uBRJ88DE046230@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: gonzo set sender to
 gonzo@FreeBSD.org using -f
From: Oleksandr Tymoshenko <gonzo@FreeBSD.org>
Date: Tue, 27 Dec 2016 19:08:08 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310636 - head/sys/arm/broadcom/bcm2835
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 19:08:09 -0000

Author: gonzo
Date: Tue Dec 27 19:08:08 2016
New Revision: 310636
URL: https://svnweb.freebsd.org/changeset/base/310636

Log:
  [rpi] Fix bcm2835_audio locking and samples starvation
  
  Rework general approach to locking and working with audio worker thread:
  
  - Use flags to signal requested worker action
  - Fix submitted buffer calculations to avoid samples starvation
  - Protect buffer pointers with locks to fix race condition between callback
    and audio worker thread
  - Remove unnecessary vchi_service_use
  - Do not use lock to serialize VCHI requests since only one thread issues them now
  - Fix unloading signaling per hselasky@ suggestion
  - Add output to detect inconsistent callback data caused by possible firmware bug
    https://github.com/raspberrypi/firmware/issues/696
  - Add stats/debug sysctls to troubleshoot possible bugs
  
  PR:		213687, 205979, 215194
  MFC after:	1 week

Modified:
  head/sys/arm/broadcom/bcm2835/bcm2835_audio.c

Modified: head/sys/arm/broadcom/bcm2835/bcm2835_audio.c
==============================================================================
--- head/sys/arm/broadcom/bcm2835/bcm2835_audio.c	Tue Dec 27 18:23:16 2016	(r310635)
+++ head/sys/arm/broadcom/bcm2835/bcm2835_audio.c	Tue Dec 27 19:08:08 2016	(r310636)
@@ -40,13 +40,33 @@
 
 SND_DECLARE_FILE("$FreeBSD$");
 
+/* Audio destination */
 #define	DEST_AUTO		0
 #define	DEST_HEADPHONES		1
 #define	DEST_HDMI		2
 
+/* Playback state */
+#define	PLAYBACK_IDLE		0
+#define	PLAYBACK_PLAYING	1
+#define	PLAYBACK_STOPPING	2
+
+/* Worker thread state */
+#define	WORKER_RUNNING		0
+#define	WORKER_STOPPING		1
+#define	WORKER_STOPPED		2
+
+/*
+ * Worker thread flags, set to 1 in flags_pending
+ * when driver requests one or another operation
+ * from worker. Cleared to 0 once worker performs
+ * the operations.
+ */
+#define	AUDIO_PARAMS		(1 << 0)
+#define	AUDIO_PLAY		(1 << 1)
+#define	AUDIO_STOP		(1 << 2)
+
 #define	VCHIQ_AUDIO_PACKET_SIZE	4000
-#define	VCHIQ_AUDIO_BUFFER_SIZE	128000
-#define	VCHIQ_AUDIO_PREBUFFER	10 /* Number of pre-buffered audio messages */
+#define	VCHIQ_AUDIO_BUFFER_SIZE	10*VCHIQ_AUDIO_PACKET_SIZE
 
 #define	VCHIQ_AUDIO_MAX_VOLUME	
 /* volume in terms of 0.01dB */
@@ -77,22 +97,25 @@ static struct pcmchan_caps bcm2835_audio
 
 struct bcm2835_audio_info;
 
-#define	PLAYBACK_IDLE		0
-#define	PLAYBACK_STARTING	1
-#define	PLAYBACK_PLAYING	2
-#define	PLAYBACK_STOPPING	3
-
 struct bcm2835_audio_chinfo {
 	struct bcm2835_audio_info *parent;
 	struct pcm_channel *channel;
 	struct snd_dbuf *buffer;
 	uint32_t fmt, spd, blksz;
 
-	uint32_t complete_pos;
-	uint32_t free_buffer;
-	uint32_t buffered_ptr;
+	/* Pointer to first unsubmitted sample */
+	uint32_t unsubmittedptr;
+	/*
+	 * Number of bytes in "submitted but not played"
+	 * pseudo-buffer
+	 */
+	int available_space;
 	int playback_state;
-	int prebuffered;
+	uint64_t callbacks;
+	uint64_t submitted_samples;
+	uint64_t retrieved_samples;
+	uint64_t underruns;
+	int starved;
 };
 
 struct bcm2835_audio_info {
@@ -100,32 +123,25 @@ struct bcm2835_audio_info {
 	unsigned int bufsz;
     	struct bcm2835_audio_chinfo pch;
 	uint32_t dest, volume;
-	struct mtx *lock;
 	struct intr_config_hook intr_hook;
 
 	/* VCHI data */
-	struct sx vchi_lock;
-
 	VCHI_INSTANCE_T vchi_instance;
 	VCHI_CONNECTION_T *vchi_connection;
 	VCHI_SERVICE_HANDLE_T vchi_handle;
 
-	struct sx worker_lock;
+	struct mtx lock;
 	struct cv worker_cv;
 
-	bool parameters_update_pending;
-	bool controls_update_pending;
+	uint32_t flags_pending;
 
-	/* Unloadign module */
-	int unloading;
+	/* Worker thread state */
+	int worker_state;
 };
 
-#define bcm2835_audio_lock(_ess) snd_mtxlock((_ess)->lock)
-#define bcm2835_audio_unlock(_ess) snd_mtxunlock((_ess)->lock)
-#define bcm2835_audio_lock_assert(_ess) snd_mtxassert((_ess)->lock)
-
-#define VCHIQ_VCHI_LOCK(sc)		sx_xlock(&(sc)->vchi_lock)
-#define VCHIQ_VCHI_UNLOCK(sc)		sx_xunlock(&(sc)->vchi_lock)
+#define BCM2835_AUDIO_LOCK(sc)		mtx_lock(&(sc)->lock)
+#define BCM2835_AUDIO_LOCKED(sc)	mtx_assert(&(sc)->lock, MA_OWNED)
+#define BCM2835_AUDIO_UNLOCK(sc)	mtx_unlock(&(sc)->lock)
 
 static const char *
 dest_description(uint32_t dest)
@@ -149,6 +165,36 @@ dest_description(uint32_t dest)
 }
 
 static void
+bcm2835_worker_update_params(struct bcm2835_audio_info *sc)
+{
+
+	BCM2835_AUDIO_LOCKED(sc);
+
+	sc->flags_pending |= AUDIO_PARAMS;
+	cv_signal(&sc->worker_cv);
+}
+
+static void
+bcm2835_worker_play_start(struct bcm2835_audio_info *sc)
+{
+	BCM2835_AUDIO_LOCK(sc);
+	sc->flags_pending &= ~(AUDIO_STOP);
+	sc->flags_pending |= AUDIO_PLAY;
+	cv_signal(&sc->worker_cv);
+	BCM2835_AUDIO_UNLOCK(sc);
+}
+
+static void
+bcm2835_worker_play_stop(struct bcm2835_audio_info *sc)
+{
+	BCM2835_AUDIO_LOCK(sc);
+	sc->flags_pending &= ~(AUDIO_PLAY);
+	sc->flags_pending |= AUDIO_STOP;
+	cv_signal(&sc->worker_cv);
+	BCM2835_AUDIO_UNLOCK(sc);
+}
+
+static void
 bcm2835_audio_callback(void *param, const VCHI_CALLBACK_REASON_T reason, void *msg_handle)
 {
 	struct bcm2835_audio_info *sc = (struct bcm2835_audio_info *)param;
@@ -163,7 +209,7 @@ bcm2835_audio_callback(void *param, cons
 	    &m, sizeof m, &msg_len, VCHI_FLAGS_NONE);
 	if (m.type == VC_AUDIO_MSG_TYPE_RESULT) {
 		if (m.u.result.success) {
-			device_printf(sc->dev, 
+			device_printf(sc->dev,
 			    "msg type %08x failed\n",
 			    m.type);
 		}
@@ -172,13 +218,35 @@ bcm2835_audio_callback(void *param, cons
 
 		int count = m.u.complete.count & 0xffff;
 		int perr = (m.u.complete.count & (1U << 30)) != 0;
-
-		ch->complete_pos = (ch->complete_pos + count) % sndbuf_getsize(ch->buffer);
-		ch->free_buffer += count;
-		chn_intr(sc->pch.channel);
-
-		if (perr || ch->free_buffer >= VCHIQ_AUDIO_PACKET_SIZE)
-			cv_signal(&sc->worker_cv);
+		ch->callbacks++;
+		if (perr)
+			ch->underruns++;
+
+		BCM2835_AUDIO_LOCK(sc);
+		if (ch->playback_state != PLAYBACK_IDLE) {
+			/* Prevent LOR */
+			BCM2835_AUDIO_UNLOCK(sc);
+			chn_intr(sc->pch.channel);
+			BCM2835_AUDIO_LOCK(sc);
+		}
+		/* We should check again, state might have changed */
+		if (ch->playback_state != PLAYBACK_IDLE) {
+			if (!perr) {
+				if ((ch->available_space + count)> VCHIQ_AUDIO_BUFFER_SIZE) {
+					device_printf(sc->dev, "inconsistent data in callback:\n");
+					device_printf(sc->dev, "available_space == %d, count = %d, perr=%d\n",
+					    ch->available_space, count, perr);
+					device_printf(sc->dev,
+					    "retrieved_samples = %lld, submitted_samples = %lld\n",
+					    ch->retrieved_samples, ch->submitted_samples);
+				}
+				ch->available_space += count;
+				ch->retrieved_samples += count;
+			}
+			if (perr || (ch->available_space >= VCHIQ_AUDIO_PACKET_SIZE))
+				cv_signal(&sc->worker_cv);
+		}
+		BCM2835_AUDIO_UNLOCK(sc);
 	} else
 		printf("%s: unknown m.type: %d\n", __func__, m.type);
 }
@@ -218,10 +286,7 @@ bcm2835_audio_init(struct bcm2835_audio_
 	status = vchi_service_open(sc->vchi_instance, &params,
 	    &sc->vchi_handle);
 
-	if (status == 0)
-		/* Finished with the service for now */
-		vchi_service_release(sc->vchi_handle);
-	else
+	if (status != 0)
 		sc->vchi_handle = VCHIQ_SERVICE_HANDLE_INVALID;
 }
 
@@ -231,10 +296,10 @@ bcm2835_audio_release(struct bcm2835_aud
 	int success;
 
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
 		success = vchi_service_close(sc->vchi_handle);
 		if (success != 0)
 			printf("vchi_service_close failed: %d\n", success);
+		vchi_service_release(sc->vchi_handle);
 		sc->vchi_handle = VCHIQ_SERVICE_HANDLE_INVALID;
 	}
 
@@ -244,12 +309,9 @@ bcm2835_audio_release(struct bcm2835_aud
 static void
 bcm2835_audio_reset_channel(struct bcm2835_audio_chinfo *ch)
 {
-	ch->free_buffer = VCHIQ_AUDIO_BUFFER_SIZE;
-	ch->playback_state = 0;
-	ch->buffered_ptr = 0;
-	ch->complete_pos = 0;
-	ch->prebuffered = 0;
 
+	ch->available_space = VCHIQ_AUDIO_BUFFER_SIZE;
+	ch->unsubmittedptr = 0;
 	sndbuf_reset(ch->buffer);
 }
 
@@ -260,21 +322,14 @@ bcm2835_audio_start(struct bcm2835_audio
 	int ret;
 	struct bcm2835_audio_info *sc = ch->parent;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
-
 		m.type = VC_AUDIO_MSG_TYPE_START;
 		ret = vchi_msg_queue(sc->vchi_handle,
 		    &m, sizeof m, VCHI_FLAGS_BLOCK_UNTIL_QUEUED, NULL);
 
 		if (ret != 0)
 			printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
-
-		vchi_service_release(sc->vchi_handle);
 	}
-	VCHIQ_VCHI_UNLOCK(sc);
-
 }
 
 static void
@@ -284,10 +339,7 @@ bcm2835_audio_stop(struct bcm2835_audio_
 	int ret;
 	struct bcm2835_audio_info *sc = ch->parent;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
-
 		m.type = VC_AUDIO_MSG_TYPE_STOP;
 		m.u.stop.draining = 0;
 
@@ -296,10 +348,7 @@ bcm2835_audio_stop(struct bcm2835_audio_
 
 		if (ret != 0)
 			printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
-
-		vchi_service_release(sc->vchi_handle);
 	}
-	VCHIQ_VCHI_UNLOCK(sc);
 }
 
 static void
@@ -308,20 +357,14 @@ bcm2835_audio_open(struct bcm2835_audio_
 	VC_AUDIO_MSG_T m;
 	int ret;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
-
 		m.type = VC_AUDIO_MSG_TYPE_OPEN;
 		ret = vchi_msg_queue(sc->vchi_handle,
 		    &m, sizeof m, VCHI_FLAGS_BLOCK_UNTIL_QUEUED, NULL);
 
 		if (ret != 0)
 			printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
-
-		vchi_service_release(sc->vchi_handle);
 	}
-	VCHIQ_VCHI_UNLOCK(sc);
 }
 
 static void
@@ -330,10 +373,7 @@ bcm2835_audio_update_controls(struct bcm
 	VC_AUDIO_MSG_T m;
 	int ret, db;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
-
 		m.type = VC_AUDIO_MSG_TYPE_CONTROL;
 		m.u.control.dest = dest;
 		if (volume > 99)
@@ -346,10 +386,7 @@ bcm2835_audio_update_controls(struct bcm
 
 		if (ret != 0)
 			printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
-
-		vchi_service_release(sc->vchi_handle);
 	}
-	VCHIQ_VCHI_UNLOCK(sc);
 }
 
 static void
@@ -358,10 +395,7 @@ bcm2835_audio_update_params(struct bcm28
 	VC_AUDIO_MSG_T m;
 	int ret;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle != VCHIQ_SERVICE_HANDLE_INVALID) {
-		vchi_service_use(sc->vchi_handle);
-
 		m.type = VC_AUDIO_MSG_TYPE_CONFIG;
 		m.u.config.channels = AFMT_CHANNEL(fmt);
 		m.u.config.samplerate = speed;
@@ -372,76 +406,48 @@ bcm2835_audio_update_params(struct bcm28
 
 		if (ret != 0)
 			printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
-
-		vchi_service_release(sc->vchi_handle);
 	}
-	VCHIQ_VCHI_UNLOCK(sc);
 }
 
-static __inline uint32_t
-vchiq_unbuffered_bytes(struct bcm2835_audio_chinfo *ch)
+static bool
+bcm2835_audio_buffer_should_sleep(struct bcm2835_audio_chinfo *ch)
 {
-	uint32_t size, ready, readyptr, readyend;
-
-	size = sndbuf_getsize(ch->buffer);
-	readyptr = sndbuf_getreadyptr(ch->buffer);
-	ready = sndbuf_getready(ch->buffer);
+	
+	if (ch->playback_state != PLAYBACK_PLAYING)
+		return (true);
 
-	readyend = readyptr + ready;
-	/* Normal case */
-	if (ch->buffered_ptr >= readyptr) {
-		if (readyend > ch->buffered_ptr)
-			return readyend - ch->buffered_ptr;
-		else
-			return 0;
+	/* Not enough data */
+	if (sndbuf_getready(ch->buffer) < VCHIQ_AUDIO_PACKET_SIZE) {
+		printf("starve\n");
+		ch->starved++;
+		return (true);
 	}
-	else { /* buffered_ptr overflow */
-		if (readyend > ch->buffered_ptr + size)
-			return readyend - ch->buffered_ptr - size;
-		else
-			return 0;
+
+	/* Not enough free space */
+	if (ch->available_space < VCHIQ_AUDIO_PACKET_SIZE) {
+		return (true);
 	}
+
+	return (false);
 }
 
 static void
-bcm2835_audio_write_samples(struct bcm2835_audio_chinfo *ch)
+bcm2835_audio_write_samples(struct bcm2835_audio_chinfo *ch, void *buf, uint32_t count)
 {
 	struct bcm2835_audio_info *sc = ch->parent;
 	VC_AUDIO_MSG_T m;
-	void *buf;
-	uint32_t count, size;
 	int ret;
 
-	VCHIQ_VCHI_LOCK(sc);
 	if (sc->vchi_handle == VCHIQ_SERVICE_HANDLE_INVALID) {
-		VCHIQ_VCHI_UNLOCK(sc);
 		return;
 	}
 
-	vchi_service_use(sc->vchi_handle);
-
-	size = sndbuf_getsize(ch->buffer);
-	count = vchiq_unbuffered_bytes(ch);
-	buf = (uint8_t*)sndbuf_getbuf(ch->buffer) + ch->buffered_ptr;
-
-	if (ch->buffered_ptr + count > size)
-		count = size - ch->buffered_ptr;
-
-	if (count < VCHIQ_AUDIO_PACKET_SIZE)
-		goto done;
-
-	count = min(count, ch->free_buffer);
-	count -= count % VCHIQ_AUDIO_PACKET_SIZE;
-
 	m.type = VC_AUDIO_MSG_TYPE_WRITE;
 	m.u.write.count = count;
 	m.u.write.max_packet = VCHIQ_AUDIO_PACKET_SIZE;
 	m.u.write.callback = NULL;
 	m.u.write.cookie = ch;
-	if (buf)
-		m.u.write.silence = 0;
-	else
-		m.u.write.silence = 1;
+	m.u.write.silence = 0;
 
 	ret = vchi_msg_queue(sc->vchi_handle,
 	    &m, sizeof m, VCHI_FLAGS_BLOCK_UNTIL_QUEUED, NULL);
@@ -449,25 +455,16 @@ bcm2835_audio_write_samples(struct bcm28
 	if (ret != 0)
 		printf("%s: vchi_msg_queue failed (err %d)\n", __func__, ret);
 
-	if (buf) {
-		while (count > 0) {
-			int bytes = MIN((int)m.u.write.max_packet, (int)count);
-			ch->free_buffer -= bytes;
-			ch->buffered_ptr += bytes;
-			ch->buffered_ptr = ch->buffered_ptr % size;
-			ret = vchi_msg_queue(sc->vchi_handle,
-			    buf, bytes, VCHI_FLAGS_BLOCK_UNTIL_QUEUED, NULL);
-			if (ret != 0)
-				printf("%s: vchi_msg_queue failed: %d\n",
-				    __func__, ret);
-			buf = (char *)buf + bytes;
-			count -= bytes;
-		}
+	while (count > 0) {
+		int bytes = MIN((int)m.u.write.max_packet, (int)count);
+		ret = vchi_msg_queue(sc->vchi_handle,
+		    buf, bytes, VCHI_FLAGS_BLOCK_UNTIL_QUEUED, NULL);
+		if (ret != 0)
+			printf("%s: vchi_msg_queue failed: %d\n",
+			    __func__, ret);
+		buf = (char *)buf + bytes;
+		count -= bytes;
 	}
-done:
-
-	vchi_service_release(sc->vchi_handle);
-	VCHIQ_VCHI_UNLOCK(sc);
 }
 
 static void
@@ -477,70 +474,98 @@ bcm2835_audio_worker(void *data)
 	struct bcm2835_audio_chinfo *ch = &sc->pch;
 	uint32_t speed, format;
 	uint32_t volume, dest;
-	bool parameters_changed, controls_changed;
+	uint32_t flags;
+	uint32_t count, size, readyptr;
+	uint8_t *buf;
 
-	sx_slock(&sc->worker_lock);
-	while(1) {
+	ch->playback_state = PLAYBACK_IDLE;
 
-		if (sc->unloading)
+	while (1) {
+		if (sc->worker_state != WORKER_RUNNING)
 			break;
 
-		parameters_changed = false;
-		controls_changed = false;
-		bcm2835_audio_lock(sc);
-		if (sc->parameters_update_pending) {
-			/* TODO: update parameters */
+		BCM2835_AUDIO_LOCK(sc);
+		/*
+		 * wait until there are flags set or buffer is ready
+		 * to consume more samples
+		 */
+		while ((sc->flags_pending == 0) &&
+		    bcm2835_audio_buffer_should_sleep(ch)) {
+			cv_wait_sig(&sc->worker_cv, &sc->lock);
+		}
+		flags = sc->flags_pending;
+		/* Clear pending flags */
+		sc->flags_pending = 0;
+		BCM2835_AUDIO_UNLOCK(sc);
+
+		/* Requested to change parameters */
+		if (flags & AUDIO_PARAMS) {
+			BCM2835_AUDIO_LOCK(sc);
 			speed = ch->spd;
 			format = ch->fmt;
-			sc->parameters_update_pending = false;
-			parameters_changed = true;
-		}
-
-		if (sc->controls_update_pending) {
 			volume = sc->volume;
 			dest = sc->dest;
-			sc->controls_update_pending = false;
-			controls_changed = true;
+			BCM2835_AUDIO_UNLOCK(sc);
+			if (ch->playback_state == PLAYBACK_IDLE)
+				bcm2835_audio_update_params(sc, format, speed);
+			bcm2835_audio_update_controls(sc, volume, dest);
 		}
 
-		bcm2835_audio_unlock(sc);
-
-		if (parameters_changed) {
-			bcm2835_audio_update_params(sc, format, speed);
+		/* Requested to stop playback */
+		if ((flags & AUDIO_STOP) &&
+		    (ch->playback_state == PLAYBACK_PLAYING)) {
+			bcm2835_audio_stop(ch);
+			BCM2835_AUDIO_LOCK(sc);
+			bcm2835_audio_reset_channel(&sc->pch);
+			ch->playback_state = PLAYBACK_IDLE;
+			BCM2835_AUDIO_UNLOCK(sc);
+			continue;
 		}
 
-		if (controls_changed) {
-			bcm2835_audio_update_controls(sc, volume, dest);
+		/* Requested to start playback */
+		if ((flags & AUDIO_PLAY) &&
+		    (ch->playback_state == PLAYBACK_IDLE)) {
+			BCM2835_AUDIO_LOCK(sc);
+			ch->playback_state = PLAYBACK_PLAYING;
+			BCM2835_AUDIO_UNLOCK(sc);
+			bcm2835_audio_start(ch);
 		}
 
-		if (ch->playback_state == PLAYBACK_IDLE) {
-			cv_wait_sig(&sc->worker_cv, &sc->worker_lock);
+		if (ch->playback_state == PLAYBACK_IDLE)
 			continue;
-		}
 
-		if (ch->playback_state == PLAYBACK_STOPPING) {
-			bcm2835_audio_stop(ch);
-			bcm2835_audio_reset_channel(&sc->pch);
-			ch->playback_state = PLAYBACK_IDLE;
+		if (sndbuf_getready(ch->buffer) == 0)
 			continue;
-		}
 
-		if (ch->free_buffer < vchiq_unbuffered_bytes(ch)) {
-			cv_timedwait_sig(&sc->worker_cv, &sc->worker_lock, 10);
+		count = sndbuf_getready(ch->buffer);
+		size = sndbuf_getsize(ch->buffer);
+		readyptr = sndbuf_getreadyptr(ch->buffer);
+
+		BCM2835_AUDIO_LOCK(sc);
+		if (readyptr + count > size)
+			count = size - readyptr;
+		count = min(count, ch->available_space);
+		count -= (count % VCHIQ_AUDIO_PACKET_SIZE);
+		BCM2835_AUDIO_UNLOCK(sc);
+
+		if (count < VCHIQ_AUDIO_PACKET_SIZE)
 			continue;
-		}
 
-		bcm2835_audio_write_samples(ch);
+		buf = (uint8_t*)sndbuf_getbuf(ch->buffer) + readyptr;
 
-		if (ch->playback_state == PLAYBACK_STARTING) {
-			ch->prebuffered++;
-			if (ch->prebuffered == VCHIQ_AUDIO_PREBUFFER) {
-				bcm2835_audio_start(ch);
-				ch->playback_state = PLAYBACK_PLAYING;
-			}
-		}
+		bcm2835_audio_write_samples(ch, buf, count);
+		BCM2835_AUDIO_LOCK(sc);
+		ch->unsubmittedptr = (ch->unsubmittedptr + count) % sndbuf_getsize(ch->buffer);
+		ch->available_space -= count;
+		ch->submitted_samples += count;
+		KASSERT(ch->available_space >= 0, ("ch->available_space == %d\n", ch->available_space));
+		BCM2835_AUDIO_UNLOCK(sc);
 	}
-	sx_sunlock(&sc->worker_lock);
+
+	BCM2835_AUDIO_LOCK(sc);
+	sc->worker_state = WORKER_STOPPED;
+	cv_signal(&sc->worker_cv);
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	kproc_exit(0);
 }
@@ -550,6 +575,7 @@ bcm2835_audio_create_worker(struct bcm28
 {
 	struct proc *newp;
 
+	sc->worker_state = WORKER_RUNNING;
 	if (kproc_create(bcm2835_audio_worker, (void*)sc, &newp, 0, 0,
 	    "bcm2835_audio_worker") != 0) {
 		printf("failed to create bcm2835_audio_worker\n");
@@ -585,8 +611,9 @@ bcmchan_init(kobj_t obj, void *devinfo, 
 		return NULL;
 	}
 
-	sc->parameters_update_pending = true;
-	cv_signal(&sc->worker_cv);
+	BCM2835_AUDIO_LOCK(sc);
+	bcm2835_worker_update_params(sc);
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	return ch;
 }
@@ -610,12 +637,10 @@ bcmchan_setformat(kobj_t obj, void *data
 	struct bcm2835_audio_chinfo *ch = data;
 	struct bcm2835_audio_info *sc = ch->parent;
 
-	bcm2835_audio_lock(sc);
+	BCM2835_AUDIO_LOCK(sc);
 	ch->fmt = format;
-	sc->parameters_update_pending = true;
-	bcm2835_audio_unlock(sc);
-
-	cv_signal(&sc->worker_cv);
+	bcm2835_worker_update_params(sc);
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	return 0;
 }
@@ -626,12 +651,10 @@ bcmchan_setspeed(kobj_t obj, void *data,
 	struct bcm2835_audio_chinfo *ch = data;
 	struct bcm2835_audio_info *sc = ch->parent;
 
-	bcm2835_audio_lock(sc);
+	BCM2835_AUDIO_LOCK(sc);
 	ch->spd = speed;
-	sc->parameters_update_pending = true;
-	bcm2835_audio_unlock(sc);
-
-	cv_signal(&sc->worker_cv);
+	bcm2835_worker_update_params(sc);
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	return ch->spd;
 }
@@ -653,25 +676,18 @@ bcmchan_trigger(kobj_t obj, void *data, 
 	if (!PCMTRIG_COMMON(go))
 		return (0);
 
-
 	switch (go) {
 	case PCMTRIG_START:
-		bcm2835_audio_lock(sc);
-		bcm2835_audio_reset_channel(ch);
-		ch->playback_state = PLAYBACK_STARTING;
-		bcm2835_audio_unlock(sc);
 		/* kickstart data flow */
 		chn_intr(sc->pch.channel);
-		/* wakeup worker thread */
-		cv_signal(&sc->worker_cv);
+		ch->submitted_samples = 0;
+		ch->retrieved_samples = 0;
+		bcm2835_worker_play_start(sc);
 		break;
 
 	case PCMTRIG_STOP:
 	case PCMTRIG_ABORT:
-		bcm2835_audio_lock(sc);
-		ch->playback_state = PLAYBACK_STOPPING;
-		bcm2835_audio_unlock(sc);
-		cv_signal(&sc->worker_cv);
+		bcm2835_worker_play_stop(sc);
 		break;
 
 	default:
@@ -687,11 +703,9 @@ bcmchan_getptr(kobj_t obj, void *data)
 	struct bcm2835_audio_info *sc = ch->parent;
 	uint32_t ret;
 
-	bcm2835_audio_lock(sc);
-
-	ret = ch->complete_pos - (ch->complete_pos % VCHIQ_AUDIO_PACKET_SIZE);
-
-	bcm2835_audio_unlock(sc);
+	BCM2835_AUDIO_LOCK(sc);
+	ret = ch->unsubmittedptr;
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	return ret;
 }
@@ -734,11 +748,11 @@ bcmmix_set(struct snd_mixer *m, unsigned
 
 	switch (dev) {
 	case SOUND_MIXER_VOLUME:
-		bcm2835_audio_lock(sc);
+		BCM2835_AUDIO_LOCK(sc);
 		sc->volume = left;
-		sc->controls_update_pending = true;
-		bcm2835_audio_unlock(sc);
-		cv_signal(&sc->worker_cv);
+		bcm2835_worker_update_params(sc);
+		BCM2835_AUDIO_UNLOCK(sc);
+
 		break;
 
 	default:
@@ -771,13 +785,13 @@ sysctl_bcm2835_audio_dest(SYSCTL_HANDLER
 	if ((val < 0) || (val > 2))
 		return (EINVAL);
 
-	bcm2835_audio_lock(sc);
+	BCM2835_AUDIO_LOCK(sc);
 	sc->dest = val;
-	sc->controls_update_pending = true;
-	bcm2835_audio_unlock(sc);
+	bcm2835_worker_update_params(sc);
+	BCM2835_AUDIO_UNLOCK(sc);
 
-	cv_signal(&sc->worker_cv);
-	device_printf(sc->dev, "destination set to %s\n", dest_description(val));
+	if (bootverbose)
+		device_printf(sc->dev, "destination set to %s\n", dest_description(val));
 
 	return (0);
 }
@@ -799,6 +813,24 @@ vchi_audio_sysctl_init(struct bcm2835_au
 	    CTLFLAG_RW | CTLTYPE_UINT, sc, sizeof(*sc),
 	    sysctl_bcm2835_audio_dest, "IU", "audio destination, "
 	    "0 - auto, 1 - headphones, 2 - HDMI");
+	SYSCTL_ADD_UQUAD(ctx, tree, OID_AUTO, "callbacks",
+			CTLFLAG_RD, &sc->pch.callbacks,
+			"callbacks total");
+	SYSCTL_ADD_UQUAD(ctx, tree, OID_AUTO, "submitted",
+			CTLFLAG_RD, &sc->pch.submitted_samples,
+			"last play submitted samples");
+	SYSCTL_ADD_UQUAD(ctx, tree, OID_AUTO, "retrieved",
+			CTLFLAG_RD, &sc->pch.retrieved_samples,
+			"last play retrieved samples");
+	SYSCTL_ADD_UQUAD(ctx, tree, OID_AUTO, "underruns",
+			CTLFLAG_RD, &sc->pch.underruns,
+			"callback underruns");
+	SYSCTL_ADD_INT(ctx, tree, OID_AUTO, "freebuffer",
+			CTLFLAG_RD, &sc->pch.available_space,
+			sc->pch.available_space, "callbacks total");
+	SYSCTL_ADD_INT(ctx, tree, OID_AUTO, "starved",
+			CTLFLAG_RD, &sc->pch.starved,
+			sc->pch.starved, "number of starved conditions");
 }
 
 static void
@@ -816,7 +848,6 @@ bcm2835_audio_probe(device_t dev)
 	return (BUS_PROBE_DEFAULT);
 }
 
-
 static void
 bcm2835_audio_delayed_init(void *xsc)
 {
@@ -837,7 +868,7 @@ bcm2835_audio_delayed_init(void *xsc)
 		goto no;
 	}
 
-    	if (pcm_register(sc->dev, sc, 1, 1)) {
+    	if (pcm_register(sc->dev, sc, 1, 0)) {
 		device_printf(sc->dev, "pcm_register failed\n");
 		goto no;
 	}
@@ -865,14 +896,12 @@ bcm2835_audio_attach(device_t dev)
 	sc->dev = dev;
 	sc->bufsz = VCHIQ_AUDIO_BUFFER_SIZE;
 
-	sc->lock = snd_mtxcreate(device_get_nameunit(dev), "bcm2835_audio softc");
-
-	sx_init(&sc->vchi_lock, device_get_nameunit(dev));
-	sx_init(&sc->worker_lock, "bcm_audio_worker_lock");
+	mtx_init(&sc->lock, device_get_nameunit(dev),
+	    "bcm_audio_lock", MTX_DEF);
 	cv_init(&sc->worker_cv, "worker_cv");
 	sc->vchi_handle = VCHIQ_SERVICE_HANDLE_INVALID;
 
-	/* 
+	/*
 	 * We need interrupts enabled for VCHI to work properly,
 	 * so delay initialization until it happens.
 	 */
@@ -896,26 +925,23 @@ bcm2835_audio_detach(device_t dev)
 	sc = pcm_getdevinfo(dev);
 
 	/* Stop worker thread */
-	sx_xlock(&sc->worker_lock);
-	sc->unloading = 1;
-	sx_xunlock(&sc->worker_lock);
+	BCM2835_AUDIO_LOCK(sc);
+	sc->worker_state = WORKER_STOPPING;
 	cv_signal(&sc->worker_cv);
+	/* Wait for thread to exit */
+	while (sc->worker_state != WORKER_STOPPED)
+		cv_wait_sig(&sc->worker_cv, &sc->lock);
+	BCM2835_AUDIO_UNLOCK(sc);
 
 	r = pcm_unregister(dev);
 	if (r)
 		return r;
 
-	sx_destroy(&sc->vchi_lock);
-	sx_destroy(&sc->worker_lock);
+	mtx_destroy(&sc->lock);
 	cv_destroy(&sc->worker_cv);
 
 	bcm2835_audio_release(sc);
 
-	if (sc->lock) {
-		snd_mtxfree(sc->lock);
-		sc->lock = NULL;
-	}
-
     	free(sc, M_DEVBUF);
 
 	return 0;

From owner-svn-src-all@freebsd.org  Tue Dec 27 20:06:27 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D1E2AC9384C;
 Tue, 27 Dec 2016 20:06:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 9A5FA1854;
 Tue, 27 Dec 2016 20:06:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRK6Q5Q071263;
 Tue, 27 Dec 2016 20:06:26 GMT (envelope-from jhb@FreeBSD.org)
Received: (from jhb@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRK6Qhw071259;
 Tue, 27 Dec 2016 20:06:26 GMT (envelope-from jhb@FreeBSD.org)
Message-Id: <201612272006.uBRK6Qhw071259@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org
 using -f
From: John Baldwin <jhb@FreeBSD.org>
Date: Tue, 27 Dec 2016 20:06:26 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310637 - in stable: 10/share/man/man4 11/share/man/man4
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 20:06:27 -0000

Author: jhb
Date: Tue Dec 27 20:06:26 2016
New Revision: 310637
URL: https://svnweb.freebsd.org/changeset/base/310637

Log:
  MFC 309581,309582,310424: Document T6 support.
  
  309581:
  Document support for Terminator 6 adapters in cxgbe(4) and cxgbev(4).
  
  309582:
  Bump Dd for addition of T6.
  
  310424:
  Replace passive voice with active voice and other tweaks.
  
  - Drop uses of 'will'.
  - Replace 'to use' with active voice.
  - Tidy language around interrupt types and clarify that INTx doesn't
    work on VFs.
  - Drop leading articles from sysctl/tunable descriptions.
  - Tweak the wording of several sysctl/tunable descriptions.

Modified:
  stable/11/share/man/man4/Makefile
  stable/11/share/man/man4/cxgbe.4
  stable/11/share/man/man4/cxgbev.4
Directory Properties:
  stable/11/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/10/share/man/man4/Makefile
  stable/10/share/man/man4/cxgbe.4
  stable/10/share/man/man4/cxgbev.4
Directory Properties:
  stable/10/   (props changed)

Modified: stable/11/share/man/man4/Makefile
==============================================================================
--- stable/11/share/man/man4/Makefile	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/11/share/man/man4/Makefile	Tue Dec 27 20:06:26 2016	(r310637)
@@ -608,11 +608,21 @@ MLINKS+=crypto.4 cryptodev.4
 MLINKS+=cue.4 if_cue.4
 MLINKS+=cxgb.4 if_cxgb.4
 MLINKS+=cxgbe.4 if_cxgbe.4 \
+	cxgbe.4 vcxgbe.4 \
+	cxgbe.4 if_vcxgbe.4 \
 	cxgbe.4 cxl.4 \
-	cxgbe.4 if_cxl.4
+	cxgbe.4 if_cxl.4 \
+	cxgbe.4 vcxl.4 \
+	cxgbe.4 if_vcxl.4 \
+	cxgbe.4 cc.4 \
+	cxgbe.4 if_cc.4 \
+	cxgbe.4 vcc.4 \
+	cxgbe.4 if_vcc.4
 MLINKS+=cxgbev.4 if_cxgbev.4 \
 	cxgbev.4 cxlv.4 \
-	cxgbev.4 if_cxlv.4
+	cxgbev.4 if_cxlv.4 \
+	cxgbev.4 ccv.4 \
+	cxgbev.4 if_ccv.4
 MLINKS+=dc.4 if_dc.4
 MLINKS+=de.4 if_de.4
 MLINKS+=disc.4 if_disc.4

Modified: stable/11/share/man/man4/cxgbe.4
==============================================================================
--- stable/11/share/man/man4/cxgbe.4	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/11/share/man/man4/cxgbe.4	Tue Dec 27 20:06:26 2016	(r310637)
@@ -1,4 +1,4 @@
-.\" Copyright (c) 2011-2014, Chelsio Inc
+.\" Copyright (c) 2011-2016, Chelsio Inc
 .\" All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
@@ -31,12 +31,12 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd December 2, 2015
+.Dd December 22, 2016
 .Dt CXGBE 4
 .Os
 .Sh NAME
 .Nm cxgbe
-.Nd "Chelsio T4 and T5 based 40Gb, 10Gb, and 1Gb Ethernet adapter driver"
+.Nd "Chelsio T4-, T5-, and T6-based 100Gb, 40Gb, 25Gb, 10Gb, and 1Gb Ethernet adapter driver"
 .Sh SYNOPSIS
 To compile this driver into the kernel,
 place the following lines in your
@@ -51,13 +51,14 @@ module at boot time, place the following
 .Bd -literal -offset indent
 t4fw_cfg_load="YES"
 t5fw_cfg_load="YES"
+t6fw_cfg_load="YES"
 if_cxgbe_load="YES"
 .Ed
 .Sh DESCRIPTION
 The
 .Nm
 driver provides support for PCI Express Ethernet adapters based on
-the Chelsio Terminator 4 and Terminator 5 ASICs (T4 and T5).
+the Chelsio Terminator 4, Terminator 5, and Terminator 6 ASICs (T4, T5, and T6).
 The driver supports Jumbo Frames, Transmit/Receive checksum offload,
 TCP segmentation offload (TSO), Large Receive Offload (LRO), VLAN
 tag insertion/extraction, VLAN checksum offload, VLAN TSO, and
@@ -66,17 +67,46 @@ For further hardware information and que
 requirements, see
 .Pa http://www.chelsio.com/ .
 .Pp
-Note that ports of T5 cards are named cxl and attach to a t5nex parent device
-(in contrast to ports named cxgbe that attach to a t4nex parent for a T4 card).
-Loader tunables with the hw.cxgbe prefix apply to both T4 and T5 cards.
-The sysctl MIBs are at dev.t5nex and dev.cxl for T5 cards and at dev.t4nex and
-dev.cxgbe for T4 cards.
+The
+.Nm
+driver uses different names for devices based on the associated ASIC:
+.Bl -column -offset indent "ASIC" "Port Name" "Parent Device"
+.It Sy ASIC Ta Sy Port Name Ta Sy Parent Device Ta Sy Virtual Interface
+.It T4 Ta cxgbe Ta t4nex Ta vcxgbe
+.It T5 Ta cxl Ta t5nex Ta vcxl
+.It T6 Ta cc Ta t6nex Ta vcc
+.El
+.Pp
+Loader tunables with the hw.cxgbe prefix apply to all cards.
+The driver provides sysctl MIBs for both ports and parent devices using
+the names above.
+For example, a T5 adapter provides port MIBs under dev.cxl and
+adapter-wide MIBs under dev.t5nex.
+References to sysctl MIBs in the remainder of this page use
+dev.<port> for port MIBs and dev.<nexus> for adapter-wide MIBs.
 .Pp
 For more information on configuring this device, see
 .Xr ifconfig 8 .
 .Sh HARDWARE
 The
 .Nm
+driver supports 100Gb and 25Gb Ethernet adapters based on the T6 ASIC:
+.Pp
+.Bl -bullet -compact
+.It
+Chelsio T6225-CR
+.It
+Chelsio T6225-SO-CR
+.It
+Chelsio T62100-LP-CR
+.It
+Chelsio T62100-SO-CR
+.It
+Chelsio T62100-CR
+.El
+.Pp
+The
+.Nm
 driver supports 40Gb, 10Gb and 1Gb Ethernet adapters based on the T5 ASIC:
 .Pp
 .Bl -bullet -compact
@@ -139,92 +169,89 @@ prompt before booting the kernel or stor
 .Xr loader.conf 5 .
 .Bl -tag -width indent
 .It Va hw.cxgbe.ntxq10g
-The number of tx queues to use for a 10Gb or 40Gb port.
+Number of tx queues used for a 10Gb or higher-speed port.
 The default is 16 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq10g
-The number of rx queues to use for a 10Gb or 40Gb port.
+Number of rx queues used for a 10Gb or higher-speed port.
 The default is 8 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.ntxq1g
-The number of tx queues to use for a 1Gb port.
+Number of tx queues used for a 1Gb port.
 The default is 4 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq1g
-The number of rx queues to use for a 1Gb port.
+Number of rx queues used for a 1Gb port.
 The default is 2 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldtxq10g
-The number of TOE tx queues to use for a 10Gb or 40Gb port.
+Number of TOE tx queues used for a 10Gb or higher-speed port.
 The default is 8 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldrxq10g
-The number of TOE rx queues to use for a 10Gb or 40Gb port.
+Number of TOE rx queues used for a 10Gb or higher-speed port.
 The default is 2 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldtxq1g
-The number of TOE tx queues to use for a 1Gb port.
+Number of TOE tx queues used for a 1Gb port.
 The default is 2 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldrxq1g
-The number of TOE rx queues to use for a 1Gb port.
+Number of TOE rx queues used for a 1Gb port.
 The default is 1.
 .It Va hw.cxgbe.num_vis
-The number of virtual interfaces (VIs) created for each port.
+Number of virtual interfaces (VIs) created for each port.
 Each virtual interface creates a separate network interface.
 The first virtual interface on each port is required and represents
 the primary network interface on the port.
-Additional virtual interfaces on a port are named vcxgbe (T4) or
-vcxl (T5) and only use a single rx and tx queue.
+Additional virtual interfaces on a port are named using the Virtual Interface
+name from the table above.
 Additional virtual interfaces use a single pair of queues
 for rx and tx as well an additional pair of queues for TOE rx and tx.
 The default is 1.
 .It Va hw.cxgbe.holdoff_timer_idx_10G
 .It Va hw.cxgbe.holdoff_timer_idx_1G
-The timer index value to use to delay interrupts.
+Timer index value used to delay interrupts.
 The holdoff timer list has the values 1, 5, 10, 50, 100, and 200
 by default (all values are in microseconds) and the index selects a
 value from this list.
 The default value is 1 which means the timer value is 5us.
 Different interfaces can be assigned different values at any time via the
-dev.cxgbe.X.holdoff_tmr_idx or dev.cxl.X.holdoff_tmr_idx sysctl.
+dev.<port>.X.holdoff_tmr_idx sysctl.
 .It Va hw.cxgbe.holdoff_pktc_idx_10G
 .It Va hw.cxgbe.holdoff_pktc_idx_1G
-The packet-count index value to use to delay interrupts.
-The packet-count list has the values 1, 8, 16, and 32 by default
+Packet-count index value used to delay interrupts.
+The packet-count list has the values 1, 8, 16, and 32 by default,
 and the index selects a value from this list.
 The default value is -1 which means packet counting is disabled and interrupts
 are generated based solely on the holdoff timer value.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.holdoff_pktc_idx or dev.cxl.X.holdoff_pktc_idx sysctl.
+dev.<port>.X.holdoff_pktc_idx sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_txq
-The size, in number of entries, of the descriptor ring used for a tx
-queue.
+Number of entries in a transmit queue's descriptor ring.
 A buf_ring of the same size is also allocated for additional
 software queuing.
 See
 .Xr ifnet 9 .
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.qsize_txq sysctl or dev.cxl.X.qsize_txq sysctl.
+dev.<port>.X.qsize_txq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_rxq
-The size, in number of entries, of the descriptor ring used for an
-rx queue.
+Number of entries in a receive queue's descriptor ring.
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.qsize_rxq or dev.cxl.X.qsize_rxq sysctl.
+dev.<port>.X.qsize_rxq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.interrupt_types
-The interrupt types that the driver is allowed to use.
-Bit 0 represents INTx (line interrupts), bit 1 MSI, bit 2 MSI-X.
+Permitted interrupt types.
+Bit 0 represents INTx (line interrupts), bit 1 MSI, and bit 2 MSI-X.
 The default is 7 (all allowed).
-The driver will select the best possible type out of the allowed types by
-itself.
+The driver selects the best possible type out of the allowed types.
 .It Va hw.cxgbe.fw_install
 0 prohibits the driver from installing a firmware on the card.
 1 allows the driver to install a new firmware if internal driver
@@ -235,7 +262,7 @@ long as it is compatible with the driver
 the one already on the card.
 The default is 1.
 .It Va hw.cxgbe.fl_pktshift
-The number of bytes of padding inserted before the beginning of an Ethernet
+Number of padding bytes inserted before the beginning of an Ethernet
 frame in the receive buffer.
 The default value of 2 ensures that the Ethernet payload (usually the IP header)
 is at a 4 byte aligned address.
@@ -261,7 +288,7 @@ reaches a high threshold, 0 prohibits th
 The default is 3 (both rx_pause and tx_pause = 1).
 This tunable establishes the default PAUSE settings for all ports.
 Settings can be displayed and controlled on a per-port basis via the
-dev.cxgbe.X.pause_settings (dev.cxl.X.pause_settings for T5 cards) sysctl.
+dev.<port>.X.pause_settings sysctl.
 .It Va hw.cxgbe.buffer_packing
 Allow the hardware to deliver multiple frames in the same receive buffer
 opportunistically.
@@ -279,8 +306,8 @@ Each of these must be set to one of the 
 (usually 2048, 4096, 9216, and 16384) and largest_rx_cluster must be greater
 than or equal to safest_rx_cluster.
 The defaults are 16384 and 4096 respectively.
-The driver will never attempt to allocate a receive buffer larger than
-largest_rx_cluster and will fall back to allocating buffers of
+The driver never attempts to allocate a receive buffer larger than
+largest_rx_cluster and falls back to allocating buffers of
 safest_rx_cluster size if an allocation larger than safest_rx_cluster fails.
 Note that largest_rx_cluster merely establishes a ceiling -- the driver is
 allowed to allocate buffers of smaller sizes.
@@ -290,8 +317,8 @@ A configuration file contains a recipe f
 hardware resources on the card.
 This tunable is for specialized applications only and should not be used in
 normal operation.
-The configuration profile currently in use is available in the dev.t4nex.X.cf
-and dev.t4nex.X.cfcsum (dev.t5nex for T5 cards) sysctls.
+The configuration profile currently in use is available in the dev.<nexus>.X.cf
+and dev.<nexus>.X.cfcsum sysctls.
 .It Va hw.cxgbe.linkcaps_allowed
 .It Va hw.cxgbe.niccaps_allowed
 .It Va hw.cxgbe.toecaps_allowed
@@ -305,7 +332,7 @@ capability.
 This tunable is for specialized applications only and should not be used in
 normal operation.
 The capabilities for which hardware resources have been reserved are listed in
-dev.t4nex.X.*caps or dev.t5nex.X.*caps sysctls.
+dev.<nexus>.X.*caps sysctls.
 .El
 .Sh SUPPORT
 For general information and support,
@@ -332,6 +359,10 @@ Support for T5 cards first appeared in
 .Fx 9.2
 and
 .Fx 10.0 .
+Support for T6 cards first appeared in
+.Fx 11.1
+and
+.Fx 12.0 .
 .Sh AUTHORS
 .An -nosplit
 The

Modified: stable/11/share/man/man4/cxgbev.4
==============================================================================
--- stable/11/share/man/man4/cxgbev.4	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/11/share/man/man4/cxgbev.4	Tue Dec 27 20:06:26 2016	(r310637)
@@ -31,12 +31,12 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd August 22, 2016
+.Dd December 22, 2016
 .Dt CXGBEV 4
 .Os
 .Sh NAME
 .Nm cxgbev
-.Nd "Chelsio T4 and T5 based 40Gb, 10Gb, and 1Gb Ethernet VF driver"
+.Nd "Chelsio T4-, T5-, and T6-based 100Gb, 40Gb, 25Gb, 10Gb, and 1Gb Ethernet VF driver"
 .Sh SYNOPSIS
 To compile this driver into the kernel,
 place the following lines in your
@@ -56,7 +56,8 @@ if_cxgbev_load="YES"
 The
 .Nm
 driver provides support for Virtual Functions on PCI Express Ethernet adapters
-based on the Chelsio Terminator 4 and Terminator 5 ASICs (T4 and T5).
+based on the Chelsio Terminator 4, Terminator 5, and Terminator 6 ASICs
+(T4, T5, and T6).
 The driver supports Jumbo Frames, Transmit/Receive checksum offload,
 TCP segmentation offload (TSO), Large Receive Offload (LRO), VLAN
 tag insertion/extraction, VLAN checksum offload, VLAN TSO, and
@@ -65,18 +66,49 @@ For further hardware information and que
 requirements, see
 .Pa http://www.chelsio.com/ .
 .Pp
-Note that ports of T5 VFs are named cxlv and attach to a t5vf parent device
-(in contrast to ports named cxgbev that attach to a t4vf parent for a T4 VF).
-Loader tunables with the hw.cxgbe prefix apply to both T4 and T5 VFs.
-The Physical Function driver for T4 and T5 adapters shares these tunables.
-The sysctl MIBs are at dev.t5vf and dev.cxlv for T5 cards and at dev.t4vf and
-dev.cxgbev for T4 cards.
+The
+.Nm
+driver uses different names for devices based on the associated ASIC:
+.Bl -column -offset indent "ASIC" "Port Name"
+.It Sy ASIC Ta Sy Port Name Ta Sy Parent Device
+.It T4 Ta cxgbev Ta t4vf
+.It T5 Ta cxlv Ta t5vf
+.It T6 Ta ccv Ta t6vf
+.El
+.Pp
+Loader tunables with the hw.cxgbe prefix apply to VFs from all cards.
+The Physical Function driver for Chelsio Terminator adapters shares these
+tunables.
+The driver provides sysctl MIBs for both ports and parent devices using
+the names above.
+For example, a T5 VF provides port MIBs under dev.cxlv and
+parent device MIBs under dev.t5vf.
+References to sysctl MIBs in the remainder of this page use
+dev.<port> for port MIBs and dev.<nexus> for parent device MIBs.
 .Pp
 For more information on configuring this device, see
 .Xr ifconfig 8 .
 .Sh HARDWARE
 The
 .Nm
+driver supports Virtual Functions on 100Gb and 25Gb Ethernet adapters
+based on the T6 ASIC:
+.Pp
+.Bl -bullet -compact
+.It
+Chelsio T6225-CR
+.It
+Chelsio T6225-SO-CR
+.It
+Chelsio T62100-LP-CR
+.It
+Chelsio T62100-SO-CR
+.It
+Chelsio T62100-CR
+.El
+.Pp
+The
+.Nm
 driver supports Virtual Functions on 40Gb, 10Gb and 1Gb Ethernet adapters
 based on the T5 ASIC:
 .Pp
@@ -141,69 +173,68 @@ prompt before booting the kernel or stor
 .Xr loader.conf 5 .
 .Bl -tag -width indent
 .It Va hw.cxgbe.ntxq10g
-The number of tx queues to use for a 10Gb or 40Gb port.
+Number of tx queues used for a 10Gb or higher-speed port.
 The default is 16 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq10g
-The number of rx queues to use for a 10Gb or 40Gb port.
+Number of rx queues used for a 10Gb or higher-speed port.
 The default is 8 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.ntxq1g
-The number of tx queues to use for a 1Gb port.
+Number of tx queues used for a 1Gb port.
 The default is 4 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq1g
-The number of rx queues to use for a 1Gb port.
+Number of rx queues used for a 1Gb port.
 The default is 2 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.holdoff_timer_idx_10G
 .It Va hw.cxgbe.holdoff_timer_idx_1G
-The timer index value to use to delay interrupts.
+Timer index value used to delay interrupts.
 The holdoff timer list has the values 1, 5, 10, 50, 100, and 200
 by default (all values are in microseconds) and the index selects a
 value from this list.
 The default value is 1 which means the timer value is 5us.
 Different interfaces can be assigned different values at any time via the
-dev.cxgbev.X.holdoff_tmr_idx or dev.cxlv.X.holdoff_tmr_idx sysctl.
+dev.<port>.X.holdoff_tmr_idx sysctl.
 .It Va hw.cxgbe.holdoff_pktc_idx_10G
 .It Va hw.cxgbe.holdoff_pktc_idx_1G
-The packet-count index value to use to delay interrupts.
-The packet-count list has the values 1, 8, 16, and 32 by default
+Packet-count index value used to delay interrupts.
+The packet-count list has the values 1, 8, 16, and 32 by default,
 and the index selects a value from this list.
 The default value is -1 which means packet counting is disabled and interrupts
 are generated based solely on the holdoff timer value.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.holdoff_pktc_idx or dev.cxlv.X.holdoff_pktc_idx sysctl.
+dev.<port>.X.holdoff_pktc_idx sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_txq
-The size, in number of entries, of the descriptor ring used for a tx
-queue.
+Number of entries in a transmit queue's descriptor ring.
 A buf_ring of the same size is also allocated for additional
 software queuing.
 See
 .Xr ifnet 9 .
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.qsize_txq sysctl or dev.cxlv.X.qsize_txq sysctl.
+dev.<port>.X.qsize_txq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_rxq
-The size, in number of entries, of the descriptor ring used for an
-rx queue.
+Number of entries in a receive queue's descriptor ring.
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.qsize_rxq or dev.cxlv.X.qsize_rxq sysctl.
+dev.<port>.X.qsize_rxq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.interrupt_types
-The interrupt types that the driver is allowed to use.
-Bit 0 represents INTx (line interrupts), bit 1 MSI, bit 2 MSI-X.
+Permitted interrupt types.
+Bit 0 represents INTx (line interrupts), bit 1 MSI, and bit 2 MSI-X.
 The default is 7 (all allowed).
-The driver will select the best possible type out of the allowed types by
-itself.
+The driver selects the best possible type out of the allowed types.
+Note that Virtual Functions do not support INTx interrupts and fail
+to attach if neither MSI nor MSI-X are enabled.
 .It Va hw.cxgbe.fl_pktshift
-The number of bytes of padding inserted before the beginning of an Ethernet
+Number of padding bytes inserted before the beginning of an Ethernet
 frame in the receive buffer.
 The default value of 2 ensures that the Ethernet payload (usually the IP header)
 is at a 4 byte aligned address.
@@ -230,8 +261,8 @@ Each of these must be set to one of the 
 (usually 2048, 4096, 9216, and 16384) and largest_rx_cluster must be greater
 than or equal to safest_rx_cluster.
 The defaults are 16384 and 4096 respectively.
-The driver will never attempt to allocate a receive buffer larger than
-largest_rx_cluster and will fall back to allocating buffers of
+The driver never attempts to allocate a receive buffer larger than
+largest_rx_cluster and falls back to allocating buffers of
 safest_rx_cluster size if an allocation larger than safest_rx_cluster fails.
 Note that largest_rx_cluster merely establishes a ceiling -- the driver is
 allowed to allocate buffers of smaller sizes.
@@ -239,8 +270,8 @@ allowed to allocate buffers of smaller s
 .Pp
 Certain settings and resources for Virtual Functions are dictated
 by the parent Physical Function driver.
-For example, the Physical Function driver limits the number of queues a
-Virtual Function is permitted to use.
+For example, the Physical Function driver limits the number of queues
+available to a Virtual Function.
 Some of these limits can be adjusted in the firmware configuration file
 used with the Physical Function driver.
 .Pp
@@ -258,7 +289,7 @@ to 1
 .Pc .
 .Pp
 The VF driver currently depends on the PF driver.
-As a result, loading the VF driver will also load the PF driver as a
+As a result, loading the VF driver also loads the PF driver as a
 dependency.
 .Sh SUPPORT
 For general information and support,
@@ -279,6 +310,8 @@ email all the specific information relat
 The
 .Nm
 device driver first appeared in
+.Fx 11.1
+and
 .Fx 12.0 .
 .Sh AUTHORS
 .An -nosplit

From owner-svn-src-all@freebsd.org  Tue Dec 27 20:06:27 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 80ADCC93844;
 Tue, 27 Dec 2016 20:06:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 490E51852;
 Tue, 27 Dec 2016 20:06:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRK6QN5071254;
 Tue, 27 Dec 2016 20:06:26 GMT (envelope-from jhb@FreeBSD.org)
Received: (from jhb@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRK6QKw071251;
 Tue, 27 Dec 2016 20:06:26 GMT (envelope-from jhb@FreeBSD.org)
Message-Id: <201612272006.uBRK6QKw071251@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org
 using -f
From: John Baldwin <jhb@FreeBSD.org>
Date: Tue, 27 Dec 2016 20:06:26 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310637 - in stable: 10/share/man/man4 11/share/man/man4
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 20:06:27 -0000

Author: jhb
Date: Tue Dec 27 20:06:26 2016
New Revision: 310637
URL: https://svnweb.freebsd.org/changeset/base/310637

Log:
  MFC 309581,309582,310424: Document T6 support.
  
  309581:
  Document support for Terminator 6 adapters in cxgbe(4) and cxgbev(4).
  
  309582:
  Bump Dd for addition of T6.
  
  310424:
  Replace passive voice with active voice and other tweaks.
  
  - Drop uses of 'will'.
  - Replace 'to use' with active voice.
  - Tidy language around interrupt types and clarify that INTx doesn't
    work on VFs.
  - Drop leading articles from sysctl/tunable descriptions.
  - Tweak the wording of several sysctl/tunable descriptions.

Modified:
  stable/10/share/man/man4/Makefile
  stable/10/share/man/man4/cxgbe.4
  stable/10/share/man/man4/cxgbev.4
Directory Properties:
  stable/10/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/11/share/man/man4/Makefile
  stable/11/share/man/man4/cxgbe.4
  stable/11/share/man/man4/cxgbev.4
Directory Properties:
  stable/11/   (props changed)

Modified: stable/10/share/man/man4/Makefile
==============================================================================
--- stable/10/share/man/man4/Makefile	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/10/share/man/man4/Makefile	Tue Dec 27 20:06:26 2016	(r310637)
@@ -584,11 +584,21 @@ MLINKS+=crypto.4 cryptodev.4
 MLINKS+=cue.4 if_cue.4
 MLINKS+=cxgb.4 if_cxgb.4
 MLINKS+=cxgbe.4 if_cxgbe.4 \
+	cxgbe.4 vcxgbe.4 \
+	cxgbe.4 if_vcxgbe.4 \
 	cxgbe.4 cxl.4 \
-	cxgbe.4 if_cxl.4
+	cxgbe.4 if_cxl.4 \
+	cxgbe.4 vcxl.4 \
+	cxgbe.4 if_vcxl.4 \
+	cxgbe.4 cc.4 \
+	cxgbe.4 if_cc.4 \
+	cxgbe.4 vcc.4 \
+	cxgbe.4 if_vcc.4
 MLINKS+=cxgbev.4 if_cxgbev.4 \
 	cxgbev.4 cxlv.4 \
-	cxgbev.4 if_cxlv.4
+	cxgbev.4 if_cxlv.4 \
+	cxgbev.4 ccv.4 \
+	cxgbev.4 if_ccv.4
 MLINKS+=dc.4 if_dc.4
 MLINKS+=de.4 if_de.4
 MLINKS+=disc.4 if_disc.4

Modified: stable/10/share/man/man4/cxgbe.4
==============================================================================
--- stable/10/share/man/man4/cxgbe.4	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/10/share/man/man4/cxgbe.4	Tue Dec 27 20:06:26 2016	(r310637)
@@ -1,4 +1,4 @@
-.\" Copyright (c) 2011-2014, Chelsio Inc
+.\" Copyright (c) 2011-2016, Chelsio Inc
 .\" All rights reserved.
 .\"
 .\" Redistribution and use in source and binary forms, with or without
@@ -31,12 +31,12 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd December 2, 2015
+.Dd December 22, 2016
 .Dt CXGBE 4
 .Os
 .Sh NAME
 .Nm cxgbe
-.Nd "Chelsio T4 and T5 based 40Gb, 10Gb, and 1Gb Ethernet adapter driver"
+.Nd "Chelsio T4-, T5-, and T6-based 100Gb, 40Gb, 25Gb, 10Gb, and 1Gb Ethernet adapter driver"
 .Sh SYNOPSIS
 To compile this driver into the kernel,
 place the following lines in your
@@ -51,13 +51,14 @@ module at boot time, place the following
 .Bd -literal -offset indent
 t4fw_cfg_load="YES"
 t5fw_cfg_load="YES"
+t6fw_cfg_load="YES"
 if_cxgbe_load="YES"
 .Ed
 .Sh DESCRIPTION
 The
 .Nm
 driver provides support for PCI Express Ethernet adapters based on
-the Chelsio Terminator 4 and Terminator 5 ASICs (T4 and T5).
+the Chelsio Terminator 4, Terminator 5, and Terminator 6 ASICs (T4, T5, and T6).
 The driver supports Jumbo Frames, Transmit/Receive checksum offload,
 TCP segmentation offload (TSO), Large Receive Offload (LRO), VLAN
 tag insertion/extraction, VLAN checksum offload, VLAN TSO, and
@@ -66,18 +67,47 @@ For further hardware information and que
 requirements, see
 .Pa http://www.chelsio.com/ .
 .Pp
-Note that ports of T5 cards are named cxl and attach to a t5nex parent device
-(in contrast to ports named cxgbe that attach to a t4nex parent for a T4 card).
-Loader tunables with the hw.cxgbe prefix apply to both T4 and T5 cards.
-The sysctl MIBs are at dev.t5nex and dev.cxl for T5 cards and at dev.t4nex and
-dev.cxgbe for T4 cards.
+The
+.Nm
+driver uses different names for devices based on the associated ASIC:
+.Bl -column -offset indent "ASIC" "Port Name" "Parent Device"
+.It Sy ASIC Ta Sy Port Name Ta Sy Parent Device Ta Sy Virtual Interface
+.It T4 Ta cxgbe Ta t4nex Ta vcxgbe
+.It T5 Ta cxl Ta t5nex Ta vcxl
+.It T6 Ta cc Ta t6nex Ta vcc
+.El
 
 .Pp
+Loader tunables with the hw.cxgbe prefix apply to all cards.
+The driver provides sysctl MIBs for both ports and parent devices using
+the names above.
+For example, a T5 adapter provides port MIBs under dev.cxl and
+adapter-wide MIBs under dev.t5nex.
+References to sysctl MIBs in the remainder of this page use
+dev.<port> for port MIBs and dev.<nexus> for adapter-wide MIBs.
+.Pp
 For more information on configuring this device, see
 .Xr ifconfig 8 .
 .Sh HARDWARE
 The
 .Nm
+driver supports 100Gb and 25Gb Ethernet adapters based on the T6 ASIC:
+.Pp
+.Bl -bullet -compact
+.It
+Chelsio T6225-CR
+.It
+Chelsio T6225-SO-CR
+.It
+Chelsio T62100-LP-CR
+.It
+Chelsio T62100-SO-CR
+.It
+Chelsio T62100-CR
+.El
+.Pp
+The
+.Nm
 driver supports 40Gb, 10Gb and 1Gb Ethernet adapters based on the T5 ASIC:
 .Pp
 .Bl -bullet -compact
@@ -140,92 +170,89 @@ prompt before booting the kernel or stor
 .Xr loader.conf 5 .
 .Bl -tag -width indent
 .It Va hw.cxgbe.ntxq10g
-The number of tx queues to use for a 10Gb or 40Gb port.
+Number of tx queues used for a 10Gb or higher-speed port.
 The default is 16 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq10g
-The number of rx queues to use for a 10Gb or 40Gb port.
+Number of rx queues used for a 10Gb or higher-speed port.
 The default is 8 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.ntxq1g
-The number of tx queues to use for a 1Gb port.
+Number of tx queues used for a 1Gb port.
 The default is 4 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq1g
-The number of rx queues to use for a 1Gb port.
+Number of rx queues used for a 1Gb port.
 The default is 2 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldtxq10g
-The number of TOE tx queues to use for a 10Gb or 40Gb port.
+Number of TOE tx queues used for a 10Gb or higher-speed port.
 The default is 8 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldrxq10g
-The number of TOE rx queues to use for a 10Gb or 40Gb port.
+Number of TOE rx queues used for a 10Gb or higher-speed port.
 The default is 2 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldtxq1g
-The number of TOE tx queues to use for a 1Gb port.
+Number of TOE tx queues used for a 1Gb port.
 The default is 2 or the
 number of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nofldrxq1g
-The number of TOE rx queues to use for a 1Gb port.
+Number of TOE rx queues used for a 1Gb port.
 The default is 1.
 .It Va hw.cxgbe.num_vis
-The number of virtual interfaces (VIs) created for each port.
+Number of virtual interfaces (VIs) created for each port.
 Each virtual interface creates a separate network interface.
 The first virtual interface on each port is required and represents
 the primary network interface on the port.
-Additional virtual interfaces on a port are named vcxgbe (T4) or
-vcxl (T5) and only use a single rx and tx queue.
+Additional virtual interfaces on a port are named using the Virtual Interface
+name from the table above.
 Additional virtual interfaces use a single pair of queues
 for rx and tx as well an additional pair of queues for TOE rx and tx.
 The default is 1.
 .It Va hw.cxgbe.holdoff_timer_idx_10G
 .It Va hw.cxgbe.holdoff_timer_idx_1G
-The timer index value to use to delay interrupts.
+Timer index value used to delay interrupts.
 The holdoff timer list has the values 1, 5, 10, 50, 100, and 200
 by default (all values are in microseconds) and the index selects a
 value from this list.
 The default value is 1 which means the timer value is 5us.
 Different interfaces can be assigned different values at any time via the
-dev.cxgbe.X.holdoff_tmr_idx or dev.cxl.X.holdoff_tmr_idx sysctl.
+dev.<port>.X.holdoff_tmr_idx sysctl.
 .It Va hw.cxgbe.holdoff_pktc_idx_10G
 .It Va hw.cxgbe.holdoff_pktc_idx_1G
-The packet-count index value to use to delay interrupts.
-The packet-count list has the values 1, 8, 16, and 32 by default
+Packet-count index value used to delay interrupts.
+The packet-count list has the values 1, 8, 16, and 32 by default,
 and the index selects a value from this list.
 The default value is -1 which means packet counting is disabled and interrupts
 are generated based solely on the holdoff timer value.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.holdoff_pktc_idx or dev.cxl.X.holdoff_pktc_idx sysctl.
+dev.<port>.X.holdoff_pktc_idx sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_txq
-The size, in number of entries, of the descriptor ring used for a tx
-queue.
+Number of entries in a transmit queue's descriptor ring.
 A buf_ring of the same size is also allocated for additional
 software queuing.
 See
 .Xr ifnet 9 .
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.qsize_txq sysctl or dev.cxl.X.qsize_txq sysctl.
+dev.<port>.X.qsize_txq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_rxq
-The size, in number of entries, of the descriptor ring used for an
-rx queue.
+Number of entries in a receive queue's descriptor ring.
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbe.X.qsize_rxq or dev.cxl.X.qsize_rxq sysctl.
+dev.<port>.X.qsize_rxq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.interrupt_types
-The interrupt types that the driver is allowed to use.
-Bit 0 represents INTx (line interrupts), bit 1 MSI, bit 2 MSI-X.
+Permitted interrupt types.
+Bit 0 represents INTx (line interrupts), bit 1 MSI, and bit 2 MSI-X.
 The default is 7 (all allowed).
-The driver will select the best possible type out of the allowed types by
-itself.
+The driver selects the best possible type out of the allowed types.
 .It Va hw.cxgbe.fw_install
 0 prohibits the driver from installing a firmware on the card.
 1 allows the driver to install a new firmware if internal driver
@@ -236,7 +263,7 @@ long as it is compatible with the driver
 the one already on the card.
 The default is 1.
 .It Va hw.cxgbe.fl_pktshift
-The number of bytes of padding inserted before the beginning of an Ethernet
+Number of padding bytes inserted before the beginning of an Ethernet
 frame in the receive buffer.
 The default value of 2 ensures that the Ethernet payload (usually the IP header)
 is at a 4 byte aligned address.
@@ -262,7 +289,7 @@ reaches a high threshold, 0 prohibits th
 The default is 3 (both rx_pause and tx_pause = 1).
 This tunable establishes the default PAUSE settings for all ports.
 Settings can be displayed and controlled on a per-port basis via the
-dev.cxgbe.X.pause_settings (dev.cxl.X.pause_settings for T5 cards) sysctl.
+dev.<port>.X.pause_settings sysctl.
 .It Va hw.cxgbe.buffer_packing
 Allow the hardware to deliver multiple frames in the same receive buffer
 opportunistically.
@@ -278,8 +305,8 @@ Sizes of rx clusters.  Each of these mus
 (usually 2048, 4096, 9216, and 16384) and largest_rx_cluster must be greater
 than or equal to safest_rx_cluster.
 The defaults are 16384 and 4096 respectively.
-The driver will never attempt to allocate a receive buffer larger than
-largest_rx_cluster and will fall back to allocating buffers of
+The driver never attempts to allocate a receive buffer larger than
+largest_rx_cluster and falls back to allocating buffers of
 safest_rx_cluster size if an allocation larger than safest_rx_cluster fails.
 Note that largest_rx_cluster merely establishes a ceiling -- the driver is
 allowed to allocate buffers of smaller sizes.
@@ -289,8 +316,8 @@ A configuration file contains a recipe f
 hardware resources on the card.
 This tunable is for specialized applications only and should not be used in
 normal operation.
-The configuration profile currently in use is available in the dev.t4nex.X.cf
-and dev.t4nex.X.cfcsum (dev.t5nex for T5 cards) sysctls.
+The configuration profile currently in use is available in the dev.<nexus>.X.cf
+and dev.<nexus>.X.cfcsum sysctls.
 .It Va hw.cxgbe.linkcaps_allowed
 .It Va hw.cxgbe.niccaps_allowed
 .It Va hw.cxgbe.toecaps_allowed
@@ -304,7 +331,7 @@ capability.
 This tunable is for specialized applications only and should not be used in
 normal operation.
 The capabilities for which hardware resources have been reserved are listed in
-dev.t4nex.X.*caps or dev.t5nex.X.*caps sysctls.
+dev.<nexus>.X.*caps sysctls.
 .El
 .Sh SUPPORT
 For general information and support,
@@ -331,6 +358,10 @@ Support for T5 cards first appeared in
 .Fx 9.2
 and
 .Fx 10.0 .
+Support for T6 cards first appeared in
+.Fx 11.1
+and
+.Fx 12.0 .
 .Sh AUTHORS
 .An -nosplit
 The

Modified: stable/10/share/man/man4/cxgbev.4
==============================================================================
--- stable/10/share/man/man4/cxgbev.4	Tue Dec 27 19:08:08 2016	(r310636)
+++ stable/10/share/man/man4/cxgbev.4	Tue Dec 27 20:06:26 2016	(r310637)
@@ -31,12 +31,12 @@
 .\"
 .\" $FreeBSD$
 .\"
-.Dd August 22, 2016
+.Dd December 22, 2016
 .Dt CXGBEV 4
 .Os
 .Sh NAME
 .Nm cxgbev
-.Nd "Chelsio T4 and T5 based 40Gb, 10Gb, and 1Gb Ethernet VF driver"
+.Nd "Chelsio T4-, T5-, and T6-based 100Gb, 40Gb, 25Gb, 10Gb, and 1Gb Ethernet VF driver"
 .Sh SYNOPSIS
 To compile this driver into the kernel,
 place the following lines in your
@@ -56,7 +56,8 @@ if_cxgbev_load="YES"
 The
 .Nm
 driver provides support for Virtual Functions on PCI Express Ethernet adapters
-based on the Chelsio Terminator 4 and Terminator 5 ASICs (T4 and T5).
+based on the Chelsio Terminator 4, Terminator 5, and Terminator 6 ASICs
+(T4, T5, and T6).
 The driver supports Jumbo Frames, Transmit/Receive checksum offload,
 TCP segmentation offload (TSO), Large Receive Offload (LRO), VLAN
 tag insertion/extraction, VLAN checksum offload, VLAN TSO, and
@@ -65,18 +66,49 @@ For further hardware information and que
 requirements, see
 .Pa http://www.chelsio.com/ .
 .Pp
-Note that ports of T5 VFs are named cxlv and attach to a t5vf parent device
-(in contrast to ports named cxgbev that attach to a t4vf parent for a T4 VF).
-Loader tunables with the hw.cxgbe prefix apply to both T4 and T5 VFs.
-The Physical Function driver for T4 and T5 adapters shares these tunables.
-The sysctl MIBs are at dev.t5vf and dev.cxlv for T5 cards and at dev.t4vf and
-dev.cxgbev for T4 cards.
+The
+.Nm
+driver uses different names for devices based on the associated ASIC:
+.Bl -column -offset indent "ASIC" "Port Name"
+.It Sy ASIC Ta Sy Port Name Ta Sy Parent Device
+.It T4 Ta cxgbev Ta t4vf
+.It T5 Ta cxlv Ta t5vf
+.It T6 Ta ccv Ta t6vf
+.El
+.Pp
+Loader tunables with the hw.cxgbe prefix apply to VFs from all cards.
+The Physical Function driver for Chelsio Terminator adapters shares these
+tunables.
+The driver provides sysctl MIBs for both ports and parent devices using
+the names above.
+For example, a T5 VF provides port MIBs under dev.cxlv and
+parent device MIBs under dev.t5vf.
+References to sysctl MIBs in the remainder of this page use
+dev.<port> for port MIBs and dev.<nexus> for parent device MIBs.
 .Pp
 For more information on configuring this device, see
 .Xr ifconfig 8 .
 .Sh HARDWARE
 The
 .Nm
+driver supports Virtual Functions on 100Gb and 25Gb Ethernet adapters
+based on the T6 ASIC:
+.Pp
+.Bl -bullet -compact
+.It
+Chelsio T6225-CR
+.It
+Chelsio T6225-SO-CR
+.It
+Chelsio T62100-LP-CR
+.It
+Chelsio T62100-SO-CR
+.It
+Chelsio T62100-CR
+.El
+.Pp
+The
+.Nm
 driver supports Virtual Functions on 40Gb, 10Gb and 1Gb Ethernet adapters
 based on the T5 ASIC:
 .Pp
@@ -141,69 +173,68 @@ prompt before booting the kernel or stor
 .Xr loader.conf 5 .
 .Bl -tag -width indent
 .It Va hw.cxgbe.ntxq10g
-The number of tx queues to use for a 10Gb or 40Gb port.
+Number of tx queues used for a 10Gb or higher-speed port.
 The default is 16 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq10g
-The number of rx queues to use for a 10Gb or 40Gb port.
+Number of rx queues used for a 10Gb or higher-speed port.
 The default is 8 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.ntxq1g
-The number of tx queues to use for a 1Gb port.
+Number of tx queues used for a 1Gb port.
 The default is 4 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.nrxq1g
-The number of rx queues to use for a 1Gb port.
+Number of rx queues used for a 1Gb port.
 The default is 2 or the number
 of CPU cores in the system, whichever is less.
 .It Va hw.cxgbe.holdoff_timer_idx_10G
 .It Va hw.cxgbe.holdoff_timer_idx_1G
-The timer index value to use to delay interrupts.
+Timer index value used to delay interrupts.
 The holdoff timer list has the values 1, 5, 10, 50, 100, and 200
 by default (all values are in microseconds) and the index selects a
 value from this list.
 The default value is 1 which means the timer value is 5us.
 Different interfaces can be assigned different values at any time via the
-dev.cxgbev.X.holdoff_tmr_idx or dev.cxlv.X.holdoff_tmr_idx sysctl.
+dev.<port>.X.holdoff_tmr_idx sysctl.
 .It Va hw.cxgbe.holdoff_pktc_idx_10G
 .It Va hw.cxgbe.holdoff_pktc_idx_1G
-The packet-count index value to use to delay interrupts.
-The packet-count list has the values 1, 8, 16, and 32 by default
+Packet-count index value used to delay interrupts.
+The packet-count list has the values 1, 8, 16, and 32 by default,
 and the index selects a value from this list.
 The default value is -1 which means packet counting is disabled and interrupts
 are generated based solely on the holdoff timer value.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.holdoff_pktc_idx or dev.cxlv.X.holdoff_pktc_idx sysctl.
+dev.<port>.X.holdoff_pktc_idx sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_txq
-The size, in number of entries, of the descriptor ring used for a tx
-queue.
+Number of entries in a transmit queue's descriptor ring.
 A buf_ring of the same size is also allocated for additional
 software queuing.
 See
 .Xr ifnet 9 .
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.qsize_txq sysctl or dev.cxlv.X.qsize_txq sysctl.
+dev.<port>.X.qsize_txq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.qsize_rxq
-The size, in number of entries, of the descriptor ring used for an
-rx queue.
+Number of entries in a receive queue's descriptor ring.
 The default value is 1024.
 Different interfaces can be assigned different values via the
-dev.cxgbev.X.qsize_rxq or dev.cxlv.X.qsize_rxq sysctl.
+dev.<port>.X.qsize_rxq sysctl.
 This sysctl works only when the interface has never been marked up (as done by
 ifconfig up).
 .It Va hw.cxgbe.interrupt_types
-The interrupt types that the driver is allowed to use.
-Bit 0 represents INTx (line interrupts), bit 1 MSI, bit 2 MSI-X.
+Permitted interrupt types.
+Bit 0 represents INTx (line interrupts), bit 1 MSI, and bit 2 MSI-X.
 The default is 7 (all allowed).
-The driver will select the best possible type out of the allowed types by
-itself.
+The driver selects the best possible type out of the allowed types.
+Note that Virtual Functions do not support INTx interrupts and fail
+to attach if neither MSI nor MSI-X are enabled.
 .It Va hw.cxgbe.fl_pktshift
-The number of bytes of padding inserted before the beginning of an Ethernet
+Number of padding bytes inserted before the beginning of an Ethernet
 frame in the receive buffer.
 The default value of 2 ensures that the Ethernet payload (usually the IP header)
 is at a 4 byte aligned address.
@@ -230,8 +261,8 @@ Each of these must be set to one of the 
 (usually 2048, 4096, 9216, and 16384) and largest_rx_cluster must be greater
 than or equal to safest_rx_cluster.
 The defaults are 16384 and 4096 respectively.
-The driver will never attempt to allocate a receive buffer larger than
-largest_rx_cluster and will fall back to allocating buffers of
+The driver never attempts to allocate a receive buffer larger than
+largest_rx_cluster and falls back to allocating buffers of
 safest_rx_cluster size if an allocation larger than safest_rx_cluster fails.
 Note that largest_rx_cluster merely establishes a ceiling -- the driver is
 allowed to allocate buffers of smaller sizes.
@@ -239,8 +270,8 @@ allowed to allocate buffers of smaller s
 .Pp
 Certain settings and resources for Virtual Functions are dictated
 by the parent Physical Function driver.
-For example, the Physical Function driver limits the number of queues a
-Virtual Function is permitted to use.
+For example, the Physical Function driver limits the number of queues
+available to a Virtual Function.
 Some of these limits can be adjusted in the firmware configuration file
 used with the Physical Function driver.
 .Pp
@@ -258,7 +289,7 @@ to 1
 .Pc .
 .Pp
 The VF driver currently depends on the PF driver.
-As a result, loading the VF driver will also load the PF driver as a
+As a result, loading the VF driver also loads the PF driver as a
 dependency.
 .Sh SUPPORT
 For general information and support,
@@ -279,6 +310,8 @@ email all the specific information relat
 The
 .Nm
 device driver first appeared in
+.Fx 11.1
+and
 .Fx 12.0 .
 .Sh AUTHORS
 .An -nosplit

From owner-svn-src-all@freebsd.org  Tue Dec 27 20:21:13 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3722DC93BB8;
 Tue, 27 Dec 2016 20:21:13 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 11CE91038;
 Tue, 27 Dec 2016 20:21:12 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRKLCoL075449;
 Tue, 27 Dec 2016 20:21:12 GMT (envelope-from jhb@FreeBSD.org)
Received: (from jhb@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRKLBJd075441;
 Tue, 27 Dec 2016 20:21:11 GMT (envelope-from jhb@FreeBSD.org)
Message-Id: <201612272021.uBRKLBJd075441@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org
 using -f
From: John Baldwin <jhb@FreeBSD.org>
Date: Tue, 27 Dec 2016 20:21:11 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310638 - in head: lib/libc/gen lib/libc/sys
 sys/compat/freebsd32 sys/kern sys/sys
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 20:21:13 -0000

Author: jhb
Date: Tue Dec 27 20:21:11 2016
New Revision: 310638
URL: https://svnweb.freebsd.org/changeset/base/310638

Log:
  Rename the 'flags' argument to getfsstat() to 'mode' and validate it.
  
  This argument is not a bitmask of flags, but only accepts a single value.
  Fail with EINVAL if an invalid value is passed to 'flag'.  Rename the
  'flags' argument to getmntinfo(3) to 'mode' as well to match.
  
  This is a followup to r308088.
  
  Reviewed by:	kib
  MFC after:	1 month

Modified:
  head/lib/libc/gen/getmntinfo.3
  head/lib/libc/gen/getmntinfo.c
  head/lib/libc/sys/getfsstat.2
  head/sys/compat/freebsd32/freebsd32_misc.c
  head/sys/compat/freebsd32/syscalls.master
  head/sys/kern/syscalls.master
  head/sys/kern/vfs_syscalls.c
  head/sys/sys/syscallsubr.h

Modified: head/lib/libc/gen/getmntinfo.3
==============================================================================
--- head/lib/libc/gen/getmntinfo.3	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/lib/libc/gen/getmntinfo.3	Tue Dec 27 20:21:11 2016	(r310638)
@@ -28,7 +28,7 @@
 .\"     @(#)getmntinfo.3	8.1 (Berkeley) 6/9/93
 .\" $FreeBSD$
 .\"
-.Dd June 9, 1993
+.Dd December 27, 2016
 .Dt GETMNTINFO 3
 .Os
 .Sh NAME
@@ -41,7 +41,7 @@
 .In sys/ucred.h
 .In sys/mount.h
 .Ft int
-.Fn getmntinfo "struct statfs **mntbufp" "int flags"
+.Fn getmntinfo "struct statfs **mntbufp" "int mode"
 .Sh DESCRIPTION
 The
 .Fn getmntinfo
@@ -55,7 +55,7 @@ The
 .Fn getmntinfo
 function
 passes its
-.Fa flags
+.Fa mode
 argument transparently to
 .Xr getfsstat 2 .
 .Sh RETURN VALUES

Modified: head/lib/libc/gen/getmntinfo.c
==============================================================================
--- head/lib/libc/gen/getmntinfo.c	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/lib/libc/gen/getmntinfo.c	Tue Dec 27 20:21:11 2016	(r310638)
@@ -42,7 +42,7 @@ __FBSDID("$FreeBSD$");
  * Return information about mounted filesystems.
  */
 int
-getmntinfo(struct statfs **mntbufp, int flags)
+getmntinfo(struct statfs **mntbufp, int mode)
 {
 	static struct statfs *mntbuf;
 	static int mntsize;
@@ -50,7 +50,7 @@ getmntinfo(struct statfs **mntbufp, int 
 
 	if (mntsize <= 0 && (mntsize = getfsstat(0, 0, MNT_NOWAIT)) < 0)
 		return (0);
-	if (bufsize > 0 && (mntsize = getfsstat(mntbuf, bufsize, flags)) < 0)
+	if (bufsize > 0 && (mntsize = getfsstat(mntbuf, bufsize, mode)) < 0)
 		return (0);
 	while (bufsize <= mntsize * sizeof(struct statfs)) {
 		if (mntbuf)
@@ -58,7 +58,7 @@ getmntinfo(struct statfs **mntbufp, int 
 		bufsize = (mntsize + 1) * sizeof(struct statfs);
 		if ((mntbuf = malloc(bufsize)) == NULL)
 			return (0);
-		if ((mntsize = getfsstat(mntbuf, bufsize, flags)) < 0)
+		if ((mntsize = getfsstat(mntbuf, bufsize, mode)) < 0)
 			return (0);
 	}
 	*mntbufp = mntbuf;

Modified: head/lib/libc/sys/getfsstat.2
==============================================================================
--- head/lib/libc/sys/getfsstat.2	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/lib/libc/sys/getfsstat.2	Tue Dec 27 20:21:11 2016	(r310638)
@@ -28,7 +28,7 @@
 .\"	@(#)getfsstat.2	8.3 (Berkeley) 5/25/95
 .\" $FreeBSD$
 .\"
-.Dd November 6, 2016
+.Dd December 27, 2016
 .Dt GETFSSTAT 2
 .Os
 .Sh NAME
@@ -41,7 +41,7 @@
 .In sys/ucred.h
 .In sys/mount.h
 .Ft int
-.Fn getfsstat "struct statfs *buf" "long bufsize" "int flags"
+.Fn getfsstat "struct statfs *buf" "long bufsize" "int mode"
 .Sh DESCRIPTION
 The
 .Fn getfsstat
@@ -74,11 +74,11 @@ is given as NULL,
 returns just the number of mounted file systems.
 .Pp
 Normally
-.Fa flags
+.Fa mode
 should be specified as
 .Dv MNT_WAIT .
 If
-.Fa flags
+.Fa mode
 is set to
 .Dv MNT_NOWAIT ,
 .Fn getfsstat
@@ -108,6 +108,12 @@ The
 .Fa buf
 argument
 points to an invalid address.
+.It Bq Er EINVAL
+.Fa mode
+is set to a value other than
+.Dv MNT_WAIT
+or
+.Dv MNT_NOWAIT .
 .It Bq Er EIO
 An
 .Tn I/O

Modified: head/sys/compat/freebsd32/freebsd32_misc.c
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_misc.c	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/sys/compat/freebsd32/freebsd32_misc.c	Tue Dec 27 20:21:11 2016	(r310638)
@@ -253,7 +253,7 @@ freebsd4_freebsd32_getfsstat(struct thre
 
 	count = uap->bufsize / sizeof(struct statfs32);
 	size = count * sizeof(struct statfs);
-	error = kern_getfsstat(td, &buf, size, &count, UIO_SYSSPACE, uap->flags);
+	error = kern_getfsstat(td, &buf, size, &count, UIO_SYSSPACE, uap->mode);
 	if (size > 0) {
 		sp = buf;
 		copycount = count;

Modified: head/sys/compat/freebsd32/syscalls.master
==============================================================================
--- head/sys/compat/freebsd32/syscalls.master	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/sys/compat/freebsd32/syscalls.master	Tue Dec 27 20:21:11 2016	(r310638)
@@ -89,7 +89,7 @@
 				    obreak_args int
 18	AUE_GETFSSTAT	COMPAT4	{ int freebsd32_getfsstat( \
 				    struct statfs32 *buf, long bufsize, \
-				    int flags); }
+				    int mode); }
 19	AUE_LSEEK	COMPAT	{ int freebsd32_lseek(int fd, int offset, \
 				    int whence); }
 20	AUE_GETPID	NOPROTO	{ pid_t getpid(void); }
@@ -711,7 +711,7 @@
 				    off_t *sbytes, int flags); }
 394	AUE_NULL	UNIMPL	mac_syscall
 395	AUE_GETFSSTAT	NOPROTO	{ int getfsstat(struct statfs *buf, \
-				    long bufsize, int flags); }
+				    long bufsize, int mode); }
 396	AUE_STATFS	NOPROTO	{ int statfs(char *path, \
 				    struct statfs *buf); }
 397	AUE_FSTATFS	NOPROTO	{ int fstatfs(int fd, struct statfs *buf); }

Modified: head/sys/kern/syscalls.master
==============================================================================
--- head/sys/kern/syscalls.master	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/sys/kern/syscalls.master	Tue Dec 27 20:21:11 2016	(r310638)
@@ -85,7 +85,7 @@
 17	AUE_NULL	STD	{ int obreak(char *nsize); } break \
 				    obreak_args int
 18	AUE_GETFSSTAT	COMPAT4	{ int getfsstat(struct ostatfs *buf, \
-				    long bufsize, int flags); }
+				    long bufsize, int mode); }
 19	AUE_LSEEK	COMPAT	{ long lseek(int fd, long offset, \
 				    int whence); }
 20	AUE_GETPID	STD	{ pid_t getpid(void); }
@@ -706,7 +706,7 @@
 394	AUE_NULL	STD	{ int mac_syscall(const char *policy, \
 				    int call, void *arg); }
 395	AUE_GETFSSTAT	STD	{ int getfsstat(struct statfs *buf, \
-				    long bufsize, int flags); }
+				    long bufsize, int mode); }
 396	AUE_STATFS	STD	{ int statfs(char *path, \
 				    struct statfs *buf); }
 397	AUE_FSTATFS	STD	{ int fstatfs(int fd, struct statfs *buf); }

Modified: head/sys/kern/vfs_syscalls.c
==============================================================================
--- head/sys/kern/vfs_syscalls.c	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/sys/kern/vfs_syscalls.c	Tue Dec 27 20:21:11 2016	(r310638)
@@ -412,7 +412,7 @@ out:
 struct getfsstat_args {
 	struct statfs *buf;
 	long bufsize;
-	int flags;
+	int mode;
 };
 #endif
 int
@@ -421,7 +421,7 @@ sys_getfsstat(td, uap)
 	register struct getfsstat_args /* {
 		struct statfs *buf;
 		long bufsize;
-		int flags;
+		int mode;
 	} */ *uap;
 {
 	size_t count;
@@ -430,7 +430,7 @@ sys_getfsstat(td, uap)
 	if (uap->bufsize < 0 || uap->bufsize > SIZE_MAX)
 		return (EINVAL);
 	error = kern_getfsstat(td, &uap->buf, uap->bufsize, &count,
-	    UIO_USERSPACE, uap->flags);
+	    UIO_USERSPACE, uap->mode);
 	if (error == 0)
 		td->td_retval[0] = count;
 	return (error);
@@ -443,13 +443,20 @@ sys_getfsstat(td, uap)
  */
 int
 kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize,
-    size_t *countp, enum uio_seg bufseg, int flags)
+    size_t *countp, enum uio_seg bufseg, int mode)
 {
 	struct mount *mp, *nmp;
 	struct statfs *sfsp, *sp, sb, *tofree;
 	size_t count, maxcount;
 	int error;
 
+	switch (mode) {
+	case MNT_WAIT:
+	case MNT_NOWAIT:
+		break;
+	default:
+		return (EINVAL);
+	}
 restart:
 	maxcount = bufsize / sizeof(struct statfs);
 	if (bufsize == 0) {
@@ -483,7 +490,7 @@ restart:
 			continue;
 		}
 #endif
-		if (flags == MNT_WAIT) {
+		if (mode == MNT_WAIT) {
 			if (vfs_busy(mp, MBF_MNTLSTLOCK) != 0) {
 				/*
 				 * If vfs_busy() failed, and MBF_NOWAIT
@@ -512,10 +519,10 @@ restart:
 			sp->f_namemax = NAME_MAX;
 			sp->f_flags = mp->mnt_flag & MNT_VISFLAGMASK;
 			/*
-			 * If MNT_NOWAIT or MNT_LAZY is specified, do not
-			 * refresh the fsstat cache.
+			 * If MNT_NOWAIT is specified, do not refresh
+			 * the fsstat cache.
 			 */
-			if (flags != MNT_LAZY && flags != MNT_NOWAIT) {
+			if (mode != MNT_NOWAIT) {
 				error = VFS_STATFS(mp, sp);
 				if (error != 0) {
 					mtx_lock(&mountlist_mtx);
@@ -620,7 +627,7 @@ freebsd4_fstatfs(td, uap)
 struct freebsd4_getfsstat_args {
 	struct ostatfs *buf;
 	long bufsize;
-	int flags;
+	int mode;
 };
 #endif
 int
@@ -629,7 +636,7 @@ freebsd4_getfsstat(td, uap)
 	register struct freebsd4_getfsstat_args /* {
 		struct ostatfs *buf;
 		long bufsize;
-		int flags;
+		int mode;
 	} */ *uap;
 {
 	struct statfs *buf, *sp;
@@ -644,7 +651,7 @@ freebsd4_getfsstat(td, uap)
 		return (EINVAL);
 	size = count * sizeof(struct statfs);
 	error = kern_getfsstat(td, &buf, size, &count, UIO_SYSSPACE,
-	    uap->flags);
+	    uap->mode);
 	td->td_retval[0] = count;
 	if (size != 0) {
 		sp = buf;

Modified: head/sys/sys/syscallsubr.h
==============================================================================
--- head/sys/sys/syscallsubr.h	Tue Dec 27 20:06:26 2016	(r310637)
+++ head/sys/sys/syscallsubr.h	Tue Dec 27 20:21:11 2016	(r310638)
@@ -109,7 +109,7 @@ int	kern_futimens(struct thread *td, int
 int	kern_getdirentries(struct thread *td, int fd, char *buf, u_int count,
 	    long *basep, ssize_t *residp, enum uio_seg bufseg);
 int	kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize,
-	    size_t *countp, enum uio_seg bufseg, int flags);
+	    size_t *countp, enum uio_seg bufseg, int mode);
 int	kern_getitimer(struct thread *, u_int, struct itimerval *);
 int	kern_getppid(struct thread *);
 int	kern_getpeername(struct thread *td, int fd, struct sockaddr **sa,

From owner-svn-src-all@freebsd.org  Tue Dec 27 20:22:20 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 10582C93D67;
 Tue, 27 Dec 2016 20:22:20 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C567E12BA;
 Tue, 27 Dec 2016 20:22:19 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRKMIdd079142;
 Tue, 27 Dec 2016 20:22:18 GMT (envelope-from jhb@FreeBSD.org)
Received: (from jhb@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRKMH4s079131;
 Tue, 27 Dec 2016 20:22:17 GMT (envelope-from jhb@FreeBSD.org)
Message-Id: <201612272022.uBRKMH4s079131@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org
 using -f
From: John Baldwin <jhb@FreeBSD.org>
Date: Tue, 27 Dec 2016 20:22:17 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310639 - in head/sys: compat/freebsd32 kern sys
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 20:22:20 -0000

Author: jhb
Date: Tue Dec 27 20:22:17 2016
New Revision: 310639
URL: https://svnweb.freebsd.org/changeset/base/310639

Log:
  Regen after r310638.
  
  Differential Revision:	https://reviews.freebsd.org/D8854

Modified:
  head/sys/compat/freebsd32/freebsd32_proto.h
  head/sys/compat/freebsd32/freebsd32_syscall.h
  head/sys/compat/freebsd32/freebsd32_syscalls.c
  head/sys/compat/freebsd32/freebsd32_sysent.c
  head/sys/compat/freebsd32/freebsd32_systrace_args.c
  head/sys/kern/init_sysent.c
  head/sys/kern/syscalls.c
  head/sys/kern/systrace_args.c
  head/sys/sys/syscall.h
  head/sys/sys/syscall.mk
  head/sys/sys/sysproto.h

Modified: head/sys/compat/freebsd32/freebsd32_proto.h
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_proto.h	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/compat/freebsd32/freebsd32_proto.h	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 305954 2016-09-18 22:03:07Z kib 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #ifndef _FREEBSD32_SYSPROTO_H_
@@ -917,7 +917,7 @@ int	ofreebsd32_getdirentries(struct thre
 struct freebsd4_freebsd32_getfsstat_args {
 	char buf_l_[PADL_(struct statfs32 *)]; struct statfs32 * buf; char buf_r_[PADR_(struct statfs32 *)];
 	char bufsize_l_[PADL_(long)]; long bufsize; char bufsize_r_[PADR_(long)];
-	char flags_l_[PADL_(int)]; int flags; char flags_r_[PADR_(int)];
+	char mode_l_[PADL_(int)]; int mode; char mode_r_[PADR_(int)];
 };
 struct freebsd4_freebsd32_statfs_args {
 	char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)];

Modified: head/sys/compat/freebsd32/freebsd32_syscall.h
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_syscall.h	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/compat/freebsd32/freebsd32_syscall.h	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 305954 2016-09-18 22:03:07Z kib 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #define	FREEBSD32_SYS_syscall	0

Modified: head/sys/compat/freebsd32/freebsd32_syscalls.c
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_syscalls.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/compat/freebsd32/freebsd32_syscalls.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 305954 2016-09-18 22:03:07Z kib 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 const char *freebsd32_syscallnames[] = {

Modified: head/sys/compat/freebsd32/freebsd32_sysent.c
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_sysent.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/compat/freebsd32/freebsd32_sysent.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 305954 2016-09-18 22:03:07Z kib 
+ * created from FreeBSD: head/sys/compat/freebsd32/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #include "opt_compat.h"

Modified: head/sys/compat/freebsd32/freebsd32_systrace_args.c
==============================================================================
--- head/sys/compat/freebsd32/freebsd32_systrace_args.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/compat/freebsd32/freebsd32_systrace_args.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -1960,7 +1960,7 @@ systrace_args(int sysnum, void *params, 
 		struct getfsstat_args *p = params;
 		uarg[0] = (intptr_t) p->buf; /* struct statfs * */
 		iarg[1] = p->bufsize; /* long */
-		iarg[2] = p->flags; /* int */
+		iarg[2] = p->mode; /* int */
 		*n_args = 3;
 		break;
 	}

Modified: head/sys/kern/init_sysent.c
==============================================================================
--- head/sys/kern/init_sysent.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/kern/init_sysent.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/kern/syscalls.master 309677 2016-12-07 16:11:55Z rwatson
+ * created from FreeBSD: head/sys/kern/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #include "opt_compat.h"

Modified: head/sys/kern/syscalls.c
==============================================================================
--- head/sys/kern/syscalls.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/kern/syscalls.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/kern/syscalls.master 309677 2016-12-07 16:11:55Z rwatson
+ * created from FreeBSD: head/sys/kern/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 const char *syscallnames[] = {

Modified: head/sys/kern/systrace_args.c
==============================================================================
--- head/sys/kern/systrace_args.c	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/kern/systrace_args.c	Tue Dec 27 20:22:17 2016	(r310639)
@@ -2072,7 +2072,7 @@ systrace_args(int sysnum, void *params, 
 		struct getfsstat_args *p = params;
 		uarg[0] = (intptr_t) p->buf; /* struct statfs * */
 		iarg[1] = p->bufsize; /* long */
-		iarg[2] = p->flags; /* int */
+		iarg[2] = p->mode; /* int */
 		*n_args = 3;
 		break;
 	}

Modified: head/sys/sys/syscall.h
==============================================================================
--- head/sys/sys/syscall.h	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/sys/syscall.h	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/kern/syscalls.master 309677 2016-12-07 16:11:55Z rwatson
+ * created from FreeBSD: head/sys/kern/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #define	SYS_syscall	0

Modified: head/sys/sys/syscall.mk
==============================================================================
--- head/sys/sys/syscall.mk	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/sys/syscall.mk	Tue Dec 27 20:22:17 2016	(r310639)
@@ -1,7 +1,7 @@
 # FreeBSD system call object files.
 # DO NOT EDIT-- this file is automatically generated.
 # $FreeBSD$
-# created from FreeBSD: head/sys/kern/syscalls.master 309677 2016-12-07 16:11:55Z rwatson
+# created from FreeBSD: head/sys/kern/syscalls.master 310638 2016-12-27 20:21:11Z jhb
 MIASM =  \
 	syscall.o \
 	exit.o \

Modified: head/sys/sys/sysproto.h
==============================================================================
--- head/sys/sys/sysproto.h	Tue Dec 27 20:21:11 2016	(r310638)
+++ head/sys/sys/sysproto.h	Tue Dec 27 20:22:17 2016	(r310639)
@@ -3,7 +3,7 @@
  *
  * DO NOT EDIT-- this file is automatically generated.
  * $FreeBSD$
- * created from FreeBSD: head/sys/kern/syscalls.master 309677 2016-12-07 16:11:55Z rwatson
+ * created from FreeBSD: head/sys/kern/syscalls.master 310638 2016-12-27 20:21:11Z jhb
  */
 
 #ifndef _SYS_SYSPROTO_H_
@@ -1102,7 +1102,7 @@ struct mac_syscall_args {
 struct getfsstat_args {
 	char buf_l_[PADL_(struct statfs *)]; struct statfs * buf; char buf_r_[PADR_(struct statfs *)];
 	char bufsize_l_[PADL_(long)]; long bufsize; char bufsize_r_[PADR_(long)];
-	char flags_l_[PADL_(int)]; int flags; char flags_r_[PADR_(int)];
+	char mode_l_[PADL_(int)]; int mode; char mode_r_[PADR_(int)];
 };
 struct statfs_args {
 	char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)];
@@ -2350,7 +2350,7 @@ int	ogetdirentries(struct thread *, stru
 struct freebsd4_getfsstat_args {
 	char buf_l_[PADL_(struct ostatfs *)]; struct ostatfs * buf; char buf_r_[PADR_(struct ostatfs *)];
 	char bufsize_l_[PADL_(long)]; long bufsize; char bufsize_r_[PADR_(long)];
-	char flags_l_[PADL_(int)]; int flags; char flags_r_[PADR_(int)];
+	char mode_l_[PADL_(int)]; int mode; char mode_r_[PADR_(int)];
 };
 struct freebsd4_statfs_args {
 	char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)];

From owner-svn-src-all@freebsd.org  Tue Dec 27 20:22:45 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id A0E9DC93DFF;
 Tue, 27 Dec 2016 20:22:45 +0000 (UTC) (envelope-from jhb@freebsd.org)
Received: from mail.baldwin.cx (bigwig.baldwin.cx [96.47.65.170])
 (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 7DDC414C2;
 Tue, 27 Dec 2016 20:22:45 +0000 (UTC) (envelope-from jhb@freebsd.org)
Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net
 [73.231.226.104])
 by mail.baldwin.cx (Postfix) with ESMTPSA id 771EB10AA64;
 Tue, 27 Dec 2016 15:22:44 -0500 (EST)
From: John Baldwin <jhb@freebsd.org>
To: Andriy Gapon <avg@freebsd.org>
Cc: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: Re: svn commit: r308371 - in stable/10: share/man/man4 sys/conf
 sys/dev/jedec_ts sys/modules/i2c sys/modules/i2c/jedec_ts
Date: Tue, 27 Dec 2016 11:51:50 -0800
Message-ID: <1756673.351QfCkGNL@ralph.baldwin.cx>
User-Agent: KMail/4.14.10 (FreeBSD/11.0-STABLE; KDE/4.14.10; amd64; ; )
In-Reply-To: <9c234848-2d27-b417-b78d-18bde988bc07@FreeBSD.org>
References: <201611061356.uA6DuYcO079294@repo.freebsd.org>
 <2547422.gn4y6NaJ31@ralph.baldwin.cx>
 <9c234848-2d27-b417-b78d-18bde988bc07@FreeBSD.org>
MIME-Version: 1.0
Content-Transfer-Encoding: 7Bit
Content-Type: text/plain; charset="us-ascii"
X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.4.3
 (mail.baldwin.cx); Tue, 27 Dec 2016 15:22:44 -0500 (EST)
X-Virus-Scanned: clamav-milter 0.99.2 at mail.baldwin.cx
X-Virus-Status: Clean
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 20:22:45 -0000

On Saturday, December 24, 2016 03:35:37 PM Andriy Gapon wrote:
> On 19/12/2016 18:55, John Baldwin wrote:
> > Yes.  Well, it fixes linking of kernels at least.  Now make tinderbox
> > on 10 fails for the following kernels:
> > 
> > _.ia64.GENERIC: Maxmem is not available on ia64.  It is spelled
> >     paddr_max instead.  The firewire code is trying to use Maxmem.
> > _.ia64.LINT: Same.
> > _.arm.LINT: Many link errors and warnings, though lack of 'kbd_*' symbols
> >     seems to be the only actual errors.
> > 
> > I suspect you recently MFC'd changes to fwohci.c that are using Maxmem.
> > However, I'm not sure it is worth fixing fwohci on ia64.
> 
> The ia64 problem should be fixed now.
> I added Maxmem as we discussed.

Thanks!

-- 
John Baldwin

From owner-svn-src-all@freebsd.org  Tue Dec 27 21:11:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 065CDC9352C;
 Tue, 27 Dec 2016 21:11:56 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id D4E3A14BD;
 Tue, 27 Dec 2016 21:11:55 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRLBtga001229;
 Tue, 27 Dec 2016 21:11:55 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRLBsBf001226;
 Tue, 27 Dec 2016 21:11:54 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612272111.uBRLBsBf001226@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 21:11:54 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310640 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 21:11:56 -0000

Author: mav
Date: Tue Dec 27 21:11:54 2016
New Revision: 310640
URL: https://svnweb.freebsd.org/changeset/base/310640

Log:
  Add support for revert to defaults (RTD) bit in MODE SELECT.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c
  head/sys/cam/ctl/ctl.h
  head/sys/cam/ctl/ctl_cmd_table.c

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Tue Dec 27 20:22:17 2016	(r310639)
+++ head/sys/cam/ctl/ctl.c	Tue Dec 27 21:11:54 2016	(r310640)
@@ -6158,10 +6158,13 @@ bailout_no_done:
 int
 ctl_mode_select(struct ctl_scsiio *ctsio)
 {
-	int param_len, pf, sp;
-	int header_size, bd_len;
+	struct ctl_lun *lun;
 	union ctl_modepage_info *modepage_info;
+	int bd_len, i, header_size, param_len, pf, rtd, sp;
+	uint32_t initidx;
 
+	lun = ctsio->io_hdr.ctl_private[CTL_PRIV_LUN].ptr;
+	initidx = ctl_get_initindex(&ctsio->io_hdr.nexus);
 	switch (ctsio->cdb[0]) {
 	case MODE_SELECT_6: {
 		struct scsi_mode_select_6 *cdb;
@@ -6169,6 +6172,7 @@ ctl_mode_select(struct ctl_scsiio *ctsio
 		cdb = (struct scsi_mode_select_6 *)ctsio->cdb;
 
 		pf = (cdb->byte2 & SMS_PF) ? 1 : 0;
+		rtd = (cdb->byte2 & SMS_RTD) ? 1 : 0;
 		sp = (cdb->byte2 & SMS_SP) ? 1 : 0;
 		param_len = cdb->length;
 		header_size = sizeof(struct scsi_mode_header_6);
@@ -6180,6 +6184,7 @@ ctl_mode_select(struct ctl_scsiio *ctsio
 		cdb = (struct scsi_mode_select_10 *)ctsio->cdb;
 
 		pf = (cdb->byte2 & SMS_PF) ? 1 : 0;
+		rtd = (cdb->byte2 & SMS_RTD) ? 1 : 0;
 		sp = (cdb->byte2 & SMS_SP) ? 1 : 0;
 		param_len = scsi_2btoul(cdb->length);
 		header_size = sizeof(struct scsi_mode_header_10);
@@ -6191,6 +6196,30 @@ ctl_mode_select(struct ctl_scsiio *ctsio
 		return (CTL_RETVAL_COMPLETE);
 	}
 
+	if (rtd) {
+		if (param_len != 0) {
+			ctl_set_invalid_field(ctsio, /*sks_valid*/ 0,
+			    /*command*/ 1, /*field*/ 0,
+			    /*bit_valid*/ 0, /*bit*/ 0);
+			ctl_done((union ctl_io *)ctsio);
+			return (CTL_RETVAL_COMPLETE);
+		}
+
+		/* Revert to defaults. */
+		ctl_init_page_index(lun);
+		mtx_lock(&lun->lun_lock);
+		ctl_est_ua_all(lun, initidx, CTL_UA_MODE_CHANGE);
+		mtx_unlock(&lun->lun_lock);
+		for (i = 0; i < CTL_NUM_MODE_PAGES; i++) {
+			ctl_isc_announce_mode(lun, -1,
+			    lun->mode_pages.index[i].page_code & SMPH_PC_MASK,
+			    lun->mode_pages.index[i].subpage);
+		}
+		ctl_set_success(ctsio);
+		ctl_done((union ctl_io *)ctsio);
+		return (CTL_RETVAL_COMPLETE);
+	}
+
 	/*
 	 * From SPC-3:
 	 * "A parameter list length of zero indicates that the Data-Out Buffer
@@ -9563,6 +9592,11 @@ ctl_inquiry_evpd_eid(struct ctl_scsiio *
 	eid_ptr->flags4 = SVPD_EID_LUICLR;
 
 	/*
+	 * We support revert to defaults (RTD) bit in MODE SELECT.
+	 */
+	eid_ptr->flags5 = SVPD_EID_RTD_SUP;
+
+	/*
 	 * XXX KDM in order to correctly answer this, we would need
 	 * information from the SIM to determine how much sense data it
 	 * can send.  So this would really be a path inquiry field, most

Modified: head/sys/cam/ctl/ctl.h
==============================================================================
--- head/sys/cam/ctl/ctl.h	Tue Dec 27 20:22:17 2016	(r310639)
+++ head/sys/cam/ctl/ctl.h	Tue Dec 27 21:11:54 2016	(r310640)
@@ -78,14 +78,8 @@ struct ctl_modepage_header {
 	int32_t len_left;
 };
 
-struct ctl_modepage_aps {
-	struct ctl_modepage_header header;
-	uint8_t lock_active;
-};
-
 union ctl_modepage_info {
 	struct ctl_modepage_header header;
-	struct ctl_modepage_aps aps;
 };
 
 /*

Modified: head/sys/cam/ctl/ctl_cmd_table.c
==============================================================================
--- head/sys/cam/ctl/ctl_cmd_table.c	Tue Dec 27 20:22:17 2016	(r310639)
+++ head/sys/cam/ctl/ctl_cmd_table.c	Tue Dec 27 21:11:54 2016	(r310640)
@@ -990,7 +990,7 @@ const struct ctl_cmd_entry ctl_cmd_table
 				     CTL_CMD_FLAG_OK_ON_NO_MEDIA |
 				     CTL_CMD_FLAG_OK_ON_STANDBY |
 				     CTL_FLAG_DATA_OUT,
- CTL_LUN_PAT_NONE, 6, {0x11, 0, 0, 0xff, 0x07}},
+ CTL_LUN_PAT_NONE, 6, {0x13, 0, 0, 0xff, 0x07}},
 
 /* 16 RESERVE(6) */
 {ctl_scsi_reserve, CTL_SERIDX_RES, CTL_CMD_FLAG_ALLOW_ON_RESV |
@@ -1260,7 +1260,7 @@ const struct ctl_cmd_entry ctl_cmd_table
 				     CTL_CMD_FLAG_OK_ON_NO_MEDIA |
 				     CTL_CMD_FLAG_OK_ON_STANDBY |
 				     CTL_FLAG_DATA_OUT,
- CTL_LUN_PAT_NONE, 10, {0x11, 0, 0, 0, 0, 0, 0xff, 0xff, 0x07} },
+ CTL_LUN_PAT_NONE, 10, {0x13, 0, 0, 0, 0, 0, 0xff, 0xff, 0x07} },
 
 /* 56 RESERVE(10) */
 {ctl_scsi_reserve, CTL_SERIDX_RES, CTL_CMD_FLAG_ALLOW_ON_RESV |

From owner-svn-src-all@freebsd.org  Tue Dec 27 22:14:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D440FC9480C;
 Tue, 27 Dec 2016 22:14:42 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 87B111A2D;
 Tue, 27 Dec 2016 22:14:42 +0000 (UTC)
 (envelope-from tuexen@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRMEfHw028306;
 Tue, 27 Dec 2016 22:14:41 GMT (envelope-from tuexen@FreeBSD.org)
Received: (from tuexen@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRMEf2c028305;
 Tue, 27 Dec 2016 22:14:41 GMT (envelope-from tuexen@FreeBSD.org)
Message-Id: <201612272214.uBRMEf2c028305@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: tuexen set sender to
 tuexen@FreeBSD.org using -f
From: Michael Tuexen <tuexen@FreeBSD.org>
Date: Tue, 27 Dec 2016 22:14:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310642 - head/sys/netinet
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 22:14:42 -0000

Author: tuexen
Date: Tue Dec 27 22:14:41 2016
New Revision: 310642
URL: https://svnweb.freebsd.org/changeset/base/310642

Log:
  Consistent handling of errors reported from the lower layer.
  
  MFC after:	3 days

Modified:
  head/sys/netinet/sctp_output.c

Modified: head/sys/netinet/sctp_output.c
==============================================================================
--- head/sys/netinet/sctp_output.c	Tue Dec 27 21:16:08 2016	(r310641)
+++ head/sys/netinet/sctp_output.c	Tue Dec 27 22:14:41 2016	(r310642)
@@ -4678,7 +4678,7 @@ sctp_send_initiate(struct sctp_inpcb *in
 	struct sctp_supported_chunk_types_param *pr_supported;
 	struct sctp_paramhdr *ph;
 	int cnt_inits_to = 0;
-	int ret;
+	int error;
 	uint16_t num_ext, chunk_len, padding_len, parameter_len;
 
 	/* INIT's always go to the primary (and usually ONLY address) */
@@ -4927,14 +4927,21 @@ sctp_send_initiate(struct sctp_inpcb *in
 		}
 	}
 	SCTPDBG(SCTP_DEBUG_OUTPUT4, "Sending INIT - calls lowlevel_output\n");
-	ret = sctp_lowlevel_chunk_output(inp, stcb, net,
+	if ((error = sctp_lowlevel_chunk_output(inp, stcb, net,
 	    (struct sockaddr *)&net->ro._l_addr,
 	    m, 0, NULL, 0, 0, 0, 0,
 	    inp->sctp_lport, stcb->rport, htonl(0),
 	    net->port, NULL,
 	    0, 0,
-	    so_locked);
-	SCTPDBG(SCTP_DEBUG_OUTPUT4, "lowlevel_output - %d\n", ret);
+	    so_locked))) {
+		SCTPDBG(SCTP_DEBUG_OUTPUT4, "Gak send error %d\n", error);
+		if (error == ENOBUFS) {
+			stcb->asoc.ifp_had_enobuf = 1;
+			SCTP_STAT_INCR(sctps_lowlevelerr);
+		}
+	} else {
+		stcb->asoc.ifp_had_enobuf = 0;
+	}
 	SCTP_STAT_INCR_COUNTER64(sctps_outcontrolchunks);
 	(void)SCTP_GETTIME_TIMEVAL(&net->last_sent_time);
 }
@@ -5502,6 +5509,7 @@ sctp_send_initiate_ack(struct sctp_inpcb
 	uint16_t his_limit, i_want;
 	int abort_flag;
 	int nat_friendly = 0;
+	int error;
 	struct socket *so;
 	uint16_t num_ext, chunk_len, padding_len, parameter_len;
 
@@ -6116,12 +6124,24 @@ do_a_abort:
 		over_addr = NULL;
 	}
 
-	(void)sctp_lowlevel_chunk_output(inp, NULL, NULL, to, m, 0, NULL, 0, 0,
+	if ((error = sctp_lowlevel_chunk_output(inp, NULL, NULL, to, m, 0, NULL, 0, 0,
 	    0, 0,
 	    inp->sctp_lport, sh->src_port, init_chk->init.initiate_tag,
 	    port, over_addr,
 	    mflowtype, mflowid,
-	    SCTP_SO_NOT_LOCKED);
+	    SCTP_SO_NOT_LOCKED))) {
+		SCTPDBG(SCTP_DEBUG_OUTPUT4, "Gak send error %d\n", error);
+		if (error == ENOBUFS) {
+			if (asoc != NULL) {
+				asoc->ifp_had_enobuf = 1;
+			}
+			SCTP_STAT_INCR(sctps_lowlevelerr);
+		}
+	} else {
+		if (asoc != NULL) {
+			asoc->ifp_had_enobuf = 0;
+		}
+	}
 	SCTP_STAT_INCR_COUNTER64(sctps_outcontrolchunks);
 }
 
@@ -8821,8 +8841,8 @@ no_data_fill:
 					SCTP_STAT_INCR(sctps_lowlevelerrusr);
 				}
 				if (error == ENOBUFS) {
-					SCTP_STAT_INCR(sctps_lowlevelerr);
 					asoc->ifp_had_enobuf = 1;
+					SCTP_STAT_INCR(sctps_lowlevelerr);
 				}
 				if (error == EHOSTUNREACH) {
 					/*
@@ -9509,8 +9529,14 @@ sctp_chunk_retransmission(struct sctp_in
 		    chk->whoTo->port, NULL,
 		    0, 0,
 		    so_locked))) {
-			SCTP_STAT_INCR(sctps_lowlevelerr);
+			SCTPDBG(SCTP_DEBUG_OUTPUT3, "Gak send error %d\n", error);
+			if (error == ENOBUFS) {
+				asoc->ifp_had_enobuf = 1;
+				SCTP_STAT_INCR(sctps_lowlevelerr);
+			}
 			return (error);
+		} else {
+			asoc->ifp_had_enobuf = 0;
 		}
 		endofchain = NULL;
 		auth = NULL;
@@ -9781,8 +9807,14 @@ one_chunk_around:
 			    0, 0,
 			    so_locked))) {
 				/* error, we could not output */
-				SCTP_STAT_INCR(sctps_lowlevelerr);
+				SCTPDBG(SCTP_DEBUG_OUTPUT3, "Gak send error %d\n", error);
+				if (error == ENOBUFS) {
+					asoc->ifp_had_enobuf = 1;
+					SCTP_STAT_INCR(sctps_lowlevelerr);
+				}
 				return (error);
+			} else {
+				asoc->ifp_had_enobuf = 0;
 			}
 			endofchain = NULL;
 			auth = NULL;
@@ -10872,6 +10904,7 @@ sctp_send_abort_tcb(struct sctp_tcb *stc
 	struct sctp_nets *net;
 	uint32_t vtag;
 	uint32_t auth_offset = 0;
+	int error;
 	uint16_t cause_len, chunk_len, padding_len;
 
 	SCTP_TCB_LOCK_ASSERT(stcb);
@@ -10943,13 +10976,21 @@ sctp_send_abort_tcb(struct sctp_tcb *stc
 			return;
 		}
 	}
-	(void)sctp_lowlevel_chunk_output(stcb->sctp_ep, stcb, net,
+	if ((error = sctp_lowlevel_chunk_output(stcb->sctp_ep, stcb, net,
 	    (struct sockaddr *)&net->ro._l_addr,
 	    m_out, auth_offset, auth, stcb->asoc.authinfo.active_keyid, 1, 0, 0,
 	    stcb->sctp_ep->sctp_lport, stcb->rport, htonl(vtag),
 	    stcb->asoc.primary_destination->port, NULL,
 	    0, 0,
-	    so_locked);
+	    so_locked))) {
+		SCTPDBG(SCTP_DEBUG_OUTPUT3, "Gak send error %d\n", error);
+		if (error == ENOBUFS) {
+			stcb->asoc.ifp_had_enobuf = 1;
+			SCTP_STAT_INCR(sctps_lowlevelerr);
+		}
+	} else {
+		stcb->asoc.ifp_had_enobuf = 0;
+	}
 	SCTP_STAT_INCR_COUNTER64(sctps_outcontrolchunks);
 }
 
@@ -10962,6 +11003,7 @@ sctp_send_shutdown_complete(struct sctp_
 	struct mbuf *m_shutdown_comp;
 	struct sctp_shutdown_complete_chunk *shutdown_complete;
 	uint32_t vtag;
+	int error;
 	uint8_t flags;
 
 	m_shutdown_comp = sctp_get_mbuf_for_msg(sizeof(struct sctp_chunkhdr), 0, M_NOWAIT, 1, MT_HEADER);
@@ -10981,14 +11023,22 @@ sctp_send_shutdown_complete(struct sctp_
 	shutdown_complete->ch.chunk_flags = flags;
 	shutdown_complete->ch.chunk_length = htons(sizeof(struct sctp_shutdown_complete_chunk));
 	SCTP_BUF_LEN(m_shutdown_comp) = sizeof(struct sctp_shutdown_complete_chunk);
-	(void)sctp_lowlevel_chunk_output(stcb->sctp_ep, stcb, net,
+	if ((error = sctp_lowlevel_chunk_output(stcb->sctp_ep, stcb, net,
 	    (struct sockaddr *)&net->ro._l_addr,
 	    m_shutdown_comp, 0, NULL, 0, 1, 0, 0,
 	    stcb->sctp_ep->sctp_lport, stcb->rport,
 	    htonl(vtag),
 	    net->port, NULL,
 	    0, 0,
-	    SCTP_SO_NOT_LOCKED);
+	    SCTP_SO_NOT_LOCKED))) {
+		SCTPDBG(SCTP_DEBUG_OUTPUT3, "Gak send error %d\n", error);
+		if (error == ENOBUFS) {
+			stcb->asoc.ifp_had_enobuf = 1;
+			SCTP_STAT_INCR(sctps_lowlevelerr);
+		}
+	} else {
+		stcb->asoc.ifp_had_enobuf = 0;
+	}
 	SCTP_STAT_INCR_COUNTER64(sctps_outcontrolchunks);
 	return;
 }

From owner-svn-src-all@freebsd.org  Tue Dec 27 22:28:15 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3ADB1C94B5C;
 Tue, 27 Dec 2016 22:28:15 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 0A8321023;
 Tue, 27 Dec 2016 22:28:14 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRMSEuV032474;
 Tue, 27 Dec 2016 22:28:14 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRMSEOK032473;
 Tue, 27 Dec 2016 22:28:14 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612272228.uBRMSEOK032473@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 22:28:14 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310643 - head/sys/cam/scsi
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 22:28:15 -0000

Author: mav
Date: Tue Dec 27 22:28:14 2016
New Revision: 310643
URL: https://svnweb.freebsd.org/changeset/base/310643

Log:
  Missed piece of r310640.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/scsi/scsi_all.h

Modified: head/sys/cam/scsi/scsi_all.h
==============================================================================
--- head/sys/cam/scsi/scsi_all.h	Tue Dec 27 22:14:41 2016	(r310642)
+++ head/sys/cam/scsi/scsi_all.h	Tue Dec 27 22:28:14 2016	(r310643)
@@ -228,6 +228,7 @@ struct scsi_mode_select_6
 	u_int8_t opcode;
 	u_int8_t byte2;
 #define	SMS_SP	0x01
+#define	SMS_RTD	0x02
 #define	SMS_PF	0x10
 	u_int8_t unused[2];
 	u_int8_t length;

From owner-svn-src-all@freebsd.org  Tue Dec 27 22:31:07 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6EE41C94BE0;
 Tue, 27 Dec 2016 22:31:07 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 3EBFF1247;
 Tue, 27 Dec 2016 22:31:07 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRMV66W034750;
 Tue, 27 Dec 2016 22:31:06 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRMV6dO034748;
 Tue, 27 Dec 2016 22:31:06 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612272231.uBRMV6dO034748@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 22:31:06 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310644 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 22:31:07 -0000

Author: mav
Date: Tue Dec 27 22:31:06 2016
New Revision: 310644
URL: https://svnweb.freebsd.org/changeset/base/310644

Log:
  Fix/synchronize field types in struct ctl_modepage_header.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c
  head/sys/cam/ctl/ctl.h

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Tue Dec 27 22:28:14 2016	(r310643)
+++ head/sys/cam/ctl/ctl.c	Tue Dec 27 22:31:06 2016	(r310644)
@@ -5939,7 +5939,7 @@ ctl_do_mode_select(union ctl_io *io)
 	int page_len, page_len_offset, page_len_size;
 	union ctl_modepage_info *modepage_info;
 	struct ctl_lun *lun;
-	int *len_left, *len_used;
+	uint16_t *len_left, *len_used;
 	int retval, i;
 
 	ctsio = &io->scsiio;

Modified: head/sys/cam/ctl/ctl.h
==============================================================================
--- head/sys/cam/ctl/ctl.h	Tue Dec 27 22:28:14 2016	(r310643)
+++ head/sys/cam/ctl/ctl.h	Tue Dec 27 22:31:06 2016	(r310644)
@@ -74,8 +74,8 @@ struct ctl_port_entry {
 struct ctl_modepage_header {
 	uint8_t page_code;
 	uint8_t subpage;
-	int32_t len_used;
-	int32_t len_left;
+	uint16_t len_used;
+	uint16_t len_left;
 };
 
 union ctl_modepage_info {

From owner-svn-src-all@freebsd.org  Tue Dec 27 22:37:26 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 354A3C94E7A;
 Tue, 27 Dec 2016 22:37:26 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 03E9E194C;
 Tue, 27 Dec 2016 22:37:25 +0000 (UTC)
 (envelope-from gonzo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRMbPx6036727;
 Tue, 27 Dec 2016 22:37:25 GMT (envelope-from gonzo@FreeBSD.org)
Received: (from gonzo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRMbO6S036722;
 Tue, 27 Dec 2016 22:37:24 GMT (envelope-from gonzo@FreeBSD.org)
Message-Id: <201612272237.uBRMbO6S036722@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: gonzo set sender to
 gonzo@FreeBSD.org using -f
From: Oleksandr Tymoshenko <gonzo@FreeBSD.org>
Date: Tue, 27 Dec 2016 22:37:24 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310645 - in head/sys: conf dev/intel modules
 modules/intelspi
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 22:37:26 -0000

Author: gonzo
Date: Tue Dec 27 22:37:24 2016
New Revision: 310645
URL: https://svnweb.freebsd.org/changeset/base/310645

Log:
  [intelspi] Add SPI driver for Intel BayTrail SoC
  
  Add SPI mode (PIO-only) support for Intel Synchronous Serial Port that
  can be found in several Intel's products starting from PXA family.
  Most of implementations have slight differences in behavior and in
  addresses for registers subset. This driver covers only BayTrail SoC
  implementation for it's the only hardware I have to test it on.
  
  Driver attaches to ACPI bus only and does not have PCI or FDT support
  for now due to lack of hardware to test it on.
  
  "intelspi" is the best name I've managed to come up with. Linux driver
  name (spi-pxa2xx) does not make sense because current implementation
  does not support actual PXA2xx SoCs. And as far as I know there is no
  codename assigned to Intel SSP chip.
  
  Reviewed by:	br, manu
  MFC after:	1 month
  Differential Revision:	https://reviews.freebsd.org/D8896

Added:
  head/sys/dev/intel/
  head/sys/dev/intel/spi.c   (contents, props changed)
  head/sys/modules/intelspi/
  head/sys/modules/intelspi/Makefile   (contents, props changed)
Modified:
  head/sys/conf/files.amd64
  head/sys/conf/files.i386
  head/sys/modules/Makefile

Modified: head/sys/conf/files.amd64
==============================================================================
--- head/sys/conf/files.amd64	Tue Dec 27 22:31:06 2016	(r310644)
+++ head/sys/conf/files.amd64	Tue Dec 27 22:37:24 2016	(r310645)
@@ -228,6 +228,7 @@ dev/if_ndis/if_ndis.c		optional	ndis
 dev/if_ndis/if_ndis_pccard.c	optional	ndis pccard
 dev/if_ndis/if_ndis_pci.c	optional	ndis cardbus | ndis pci
 dev/if_ndis/if_ndis_usb.c	optional	ndis usb
+dev/intel/spi.c			optional	intelspi
 dev/io/iodev.c			optional	io
 dev/ioat/ioat.c			optional	ioat pci
 dev/ioat/ioat_test.c		optional	ioat pci

Modified: head/sys/conf/files.i386
==============================================================================
--- head/sys/conf/files.i386	Tue Dec 27 22:31:06 2016	(r310644)
+++ head/sys/conf/files.i386	Tue Dec 27 22:37:24 2016	(r310645)
@@ -275,6 +275,7 @@ dev/if_ndis/if_ndis.c		optional ndis
 dev/if_ndis/if_ndis_pccard.c	optional ndis pccard
 dev/if_ndis/if_ndis_pci.c	optional ndis cardbus | ndis pci
 dev/if_ndis/if_ndis_usb.c	optional ndis usb
+dev/intel/spi.c			optional intelspi
 dev/io/iodev.c			optional io
 dev/ipmi/ipmi.c			optional ipmi
 dev/ipmi/ipmi_acpi.c		optional ipmi acpi

Added: head/sys/dev/intel/spi.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sys/dev/intel/spi.c	Tue Dec 27 22:37:24 2016	(r310645)
@@ -0,0 +1,533 @@
+/*-
+ * Copyright (c) 2016 Oleksandr Tymoshenko <gonzo@FreeBSD.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
+
+#include "opt_acpi.h"
+
+#include <sys/param.h>
+#include <sys/bus.h>
+#include <sys/kernel.h>
+#include <sys/module.h>
+#include <sys/proc.h>
+#include <sys/rman.h>
+
+#include <machine/bus.h>
+#include <machine/resource.h>
+
+#include <dev/spibus/spi.h>
+#include <dev/spibus/spibusvar.h>
+
+#include <contrib/dev/acpica/include/acpi.h>
+#include <contrib/dev/acpica/include/accommon.h>
+
+#include <dev/acpica/acpivar.h>
+
+#include "spibus_if.h"
+
+/**
+ *	Macros for driver mutex locking
+ */
+#define	INTELSPI_LOCK(_sc)		mtx_lock(&(_sc)->sc_mtx)
+#define	INTELSPI_UNLOCK(_sc)		mtx_unlock(&(_sc)->sc_mtx)
+#define	INTELSPI_LOCK_INIT(_sc)		\
+	mtx_init(&_sc->sc_mtx, device_get_nameunit((_sc)->sc_dev), \
+	    "intelspi", MTX_DEF)
+#define	INTELSPI_LOCK_DESTROY(_sc)	mtx_destroy(&(_sc)->sc_mtx)
+#define	INTELSPI_ASSERT_LOCKED(_sc)	mtx_assert(&(_sc)->sc_mtx, MA_OWNED)
+#define	INTELSPI_ASSERT_UNLOCKED(_sc)	mtx_assert(&(_sc)->sc_mtx, MA_NOTOWNED)
+
+#define INTELSPI_WRITE(_sc, _off, _val)		\
+    bus_write_4((_sc)->sc_mem_res, (_off), (_val))
+#define INTELSPI_READ(_sc, _off)			\
+    bus_read_4((_sc)->sc_mem_res, (_off))
+
+#define	INTELSPI_BUSY		0x1
+#define	TX_FIFO_THRESHOLD	2
+#define	RX_FIFO_THRESHOLD	2
+#define	CLOCK_DIV_10MHZ		5
+#define	DATA_SIZE_8BITS		8
+
+#define	CS_LOW		0
+#define	CS_HIGH		1
+
+#define	INTELSPI_SSPREG_SSCR0	 	0x0
+#define	 SSCR0_SCR(n)				(((n) - 1) << 8)
+#define	 SSCR0_SSE				(1 << 7)
+#define	 SSCR0_FRF_SPI				(0 << 4)
+#define	 SSCR0_DSS(n)				(((n) - 1) << 0)
+#define	INTELSPI_SSPREG_SSCR1	 	0x4
+#define	 SSCR1_TINTE				(1 << 19)
+#define	 SSCR1_RFT(n)				(((n) - 1) << 10)
+#define	 SSCR1_RFT_MASK				(0xf << 10)
+#define	 SSCR1_TFT(n)				(((n) - 1) << 6)
+#define	 SSCR1_SPI_SPH				(1 << 4)
+#define	 SSCR1_SPI_SPO				(1 << 3)
+#define	 SSCR1_MODE_MASK				(SSCR1_SPI_SPO | SSCR1_SPI_SPH)
+#define	 SSCR1_MODE_0				(0)
+#define	 SSCR1_MODE_1				(SSCR1_SPI_SPH)
+#define	 SSCR1_MODE_2				(SSCR1_SPI_SPO)
+#define	 SSCR1_MODE_3				(SSCR1_SPI_SPO | SSCR1_SPI_SPH)
+#define	 SSCR1_TIE				(1 << 1)
+#define	 SSCR1_RIE				(1 << 0)
+#define	INTELSPI_SSPREG_SSSR	 	0x8
+#define	 SSSR_RFL_MASK				(0xf << 12)
+#define	 SSSR_TFL_MASK				(0xf << 8)
+#define	 SSSR_RNE				(1 << 3)
+#define	 SSSR_TNF				(1 << 2)
+#define	INTELSPI_SSPREG_SSITR	 	0xC
+#define	INTELSPI_SSPREG_SSDR	 	0x10
+#define	INTELSPI_SSPREG_SSTO	 	0x28
+#define	INTELSPI_SSPREG_SSPSP	 	0x2C
+#define	INTELSPI_SSPREG_SSTSA	 	0x30
+#define	INTELSPI_SSPREG_SSRSA	 	0x34
+#define	INTELSPI_SSPREG_SSTSS	 	0x38
+#define	INTELSPI_SSPREG_SSACD	 	0x3C
+#define	INTELSPI_SSPREG_ITF	 	0x40
+#define	INTELSPI_SSPREG_SITF	 	0x44
+#define	INTELSPI_SSPREG_SIRF	 	0x48
+#define	INTELSPI_SSPREG_PRV_CLOCK_PARAMS	0x400
+#define	INTELSPI_SSPREG_RESETS	 	0x404
+#define	INTELSPI_SSPREG_GENERAL	 	0x408
+#define	INTELSPI_SSPREG_SSP_REG	 	0x40C
+#define	INTELSPI_SSPREG_SPI_CS_CTRL	 0x418
+#define	 SPI_CS_CTRL_CS_MASK			(3)
+#define	 SPI_CS_CTRL_SW_MODE			(1 << 0)
+#define	 SPI_CS_CTRL_HW_MODE			(1 << 0)
+#define	 SPI_CS_CTRL_CS_HIGH			(1 << 1)
+#define	 SPI_CS_CTRL_CS_LOW			(0 << 1)
+
+struct intelspi_softc {
+	ACPI_HANDLE		sc_handle;
+	device_t		sc_dev;
+	struct mtx		sc_mtx;
+	int			sc_mem_rid;
+	struct resource		*sc_mem_res;
+	int			sc_irq_rid;
+	struct resource		*sc_irq_res;
+	void			*sc_irq_ih;
+	struct spi_command	*sc_cmd;
+	uint32_t		sc_len;
+	uint32_t		sc_read;
+	uint32_t		sc_flags;
+	uint32_t		sc_written;
+};
+
+static int	intelspi_probe(device_t dev);
+static int	intelspi_attach(device_t dev);
+static int	intelspi_detach(device_t dev);
+static void	intelspi_intr(void *);
+
+static int
+intelspi_txfifo_full(struct intelspi_softc *sc)
+{
+	uint32_t sssr;
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	sssr = INTELSPI_READ(sc, INTELSPI_SSPREG_SSSR);
+	if (sssr & SSSR_TNF)
+		return (0);
+
+	return (1);
+}
+
+static int
+intelspi_rxfifo_empty(struct intelspi_softc *sc)
+{
+	uint32_t sssr;
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	sssr = INTELSPI_READ(sc, INTELSPI_SSPREG_SSSR);
+	if (sssr & SSSR_RNE)
+		return (0);
+	else
+		return (1);
+}
+
+static void
+intelspi_fill_tx_fifo(struct intelspi_softc *sc)
+{
+	struct spi_command *cmd;
+	uint32_t written;
+	uint8_t *data;
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	cmd = sc->sc_cmd;
+	while (sc->sc_written < sc->sc_len &&
+	    !intelspi_txfifo_full(sc)) {
+		data = (uint8_t *)cmd->tx_cmd;
+		written = sc->sc_written++;
+
+		if (written >= cmd->tx_cmd_sz) {
+			data = (uint8_t *)cmd->tx_data;
+			written -= cmd->tx_cmd_sz;
+		}
+		INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSDR, data[written]);
+	}
+}
+
+static void
+intelspi_drain_rx_fifo(struct intelspi_softc *sc)
+{
+	struct spi_command *cmd;
+	uint32_t  read;
+	uint8_t *data;
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	cmd = sc->sc_cmd;
+	while (sc->sc_read < sc->sc_len &&
+	    !intelspi_rxfifo_empty(sc)) {
+		data = (uint8_t *)cmd->rx_cmd;
+		read = sc->sc_read++;
+		if (read >= cmd->rx_cmd_sz) {
+			data = (uint8_t *)cmd->rx_data;
+			read -= cmd->rx_cmd_sz;
+		}
+		data[read] = INTELSPI_READ(sc, INTELSPI_SSPREG_SSDR) & 0xff;
+	}
+}
+
+static int
+intelspi_transaction_done(struct intelspi_softc *sc)
+{
+	int txfifo_empty;
+	uint32_t sssr;
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	if (sc->sc_written != sc->sc_len ||
+	    sc->sc_read != sc->sc_len)
+		return (0);
+
+	sssr = INTELSPI_READ(sc, INTELSPI_SSPREG_SSSR);
+	txfifo_empty = ((sssr & SSSR_TFL_MASK) == 0) &&
+		(sssr & SSSR_TNF);
+
+	if (txfifo_empty && !(sssr & SSSR_RNE))
+		return (1);
+
+	return (0);
+}
+
+static int
+intelspi_transact(struct intelspi_softc *sc)
+{
+
+	INTELSPI_ASSERT_LOCKED(sc);
+
+	/* TX - Fill up the FIFO. */
+	intelspi_fill_tx_fifo(sc);
+
+	/* RX - Drain the FIFO. */
+	intelspi_drain_rx_fifo(sc);
+
+	/* Check for end of transfer. */
+	return intelspi_transaction_done(sc);
+}
+
+static void
+intelspi_intr(void *arg)
+{
+	struct intelspi_softc *sc;
+	uint32_t reg;
+
+	sc = (struct intelspi_softc *)arg;
+
+	INTELSPI_LOCK(sc);
+	if ((sc->sc_flags & INTELSPI_BUSY) == 0) {
+		INTELSPI_UNLOCK(sc);
+		return;
+	}
+
+	/* Check if SSP if off */
+	reg = INTELSPI_READ(sc, INTELSPI_SSPREG_SSSR);
+	if (reg == 0xffffffffU) {
+		INTELSPI_UNLOCK(sc);
+		return;
+	}
+
+	/* Check for end of transfer. */
+	if (intelspi_transact(sc)) {
+		/* Disable interrupts */
+		reg = INTELSPI_READ(sc, INTELSPI_SSPREG_SSCR1);
+		reg &= ~(SSCR1_TIE | SSCR1_RIE | SSCR1_TINTE);
+		INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR1, reg);
+		wakeup(sc->sc_dev);
+	}
+
+	INTELSPI_UNLOCK(sc);
+}
+
+static void
+intelspi_init(struct intelspi_softc *sc)
+{
+	uint32_t reg;
+
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR0, 0);
+
+	/* Manual CS control */
+	reg = INTELSPI_READ(sc, INTELSPI_SSPREG_SPI_CS_CTRL);
+	reg &= ~(SPI_CS_CTRL_CS_MASK);
+	reg |= (SPI_CS_CTRL_SW_MODE | SPI_CS_CTRL_CS_HIGH);
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SPI_CS_CTRL, reg);
+
+	/* Set TX/RX FIFO IRQ threshold levels */
+	reg = SSCR1_TFT(TX_FIFO_THRESHOLD) | SSCR1_RFT(RX_FIFO_THRESHOLD);
+	/*
+	 * Set SPI mode. This should be part of transaction or sysctl
+	 */
+	reg |= SSCR1_MODE_0;
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR1, reg);
+
+	/*
+	 * Parent clock on Minowboard Turbot is 50MHz
+	 * divide it by 5 to set to more or less reasonable
+	 * value. But this should be part of transaction config
+	 * or sysctl
+	 */
+	reg = SSCR0_SCR(CLOCK_DIV_10MHZ);
+	/* Put SSP in SPI mode */
+	reg |= SSCR0_FRF_SPI;
+	/* Data size */
+	reg |= SSCR0_DSS(DATA_SIZE_8BITS);
+	/* Enable SSP */
+	reg |= SSCR0_SSE;
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR0, reg);
+}
+
+static void
+intelspi_set_cs(struct intelspi_softc *sc, int level)
+{
+	uint32_t reg;
+
+	reg = INTELSPI_READ(sc, INTELSPI_SSPREG_SPI_CS_CTRL);
+	reg &= ~(SPI_CS_CTRL_CS_MASK);
+	reg |= SPI_CS_CTRL_SW_MODE;
+
+	if (level == CS_HIGH)
+		reg |= SPI_CS_CTRL_CS_HIGH;
+	else
+		reg |= SPI_CS_CTRL_CS_LOW;
+		
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SPI_CS_CTRL, reg);
+}
+
+static int
+intelspi_transfer(device_t dev, device_t child, struct spi_command *cmd)
+{
+	struct intelspi_softc *sc;
+	int err;
+	uint32_t sscr1;
+
+	sc = device_get_softc(dev);
+	err = 0;
+
+	KASSERT(cmd->tx_cmd_sz == cmd->rx_cmd_sz, 
+	    ("TX/RX command sizes should be equal"));
+	KASSERT(cmd->tx_data_sz == cmd->rx_data_sz, 
+	    ("TX/RX data sizes should be equal"));
+
+	INTELSPI_LOCK(sc);
+
+	/* If the controller is in use wait until it is available. */
+	while (sc->sc_flags & INTELSPI_BUSY) {
+		err = mtx_sleep(dev, &sc->sc_mtx, 0, "intelspi", 0);
+		if (err == EINTR) {
+			INTELSPI_UNLOCK(sc);
+			return (err);
+		}
+	}
+
+	/* Now we have control over SPI controller. */
+	sc->sc_flags = INTELSPI_BUSY;
+
+	/* Save a pointer to the SPI command. */
+	sc->sc_cmd = cmd;
+	sc->sc_read = 0;
+	sc->sc_written = 0;
+	sc->sc_len = cmd->tx_cmd_sz + cmd->tx_data_sz;
+
+	/* Enable CS */
+	intelspi_set_cs(sc, CS_LOW);
+	/* Transfer as much as possible to FIFOs */
+	if (!intelspi_transact(sc)) {
+		/* If FIFO is not large enough - enable interrupts */
+		sscr1 = INTELSPI_READ(sc, INTELSPI_SSPREG_SSCR1);
+		sscr1 |= (SSCR1_TIE | SSCR1_RIE | SSCR1_TINTE);
+		INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR1, sscr1);
+
+		/* and wait for transaction to complete */
+		err = mtx_sleep(dev, &sc->sc_mtx, 0, "intelspi", hz * 2);
+	}
+
+	/* de-asser CS */
+	intelspi_set_cs(sc, CS_HIGH);
+
+	/* Clear transaction details */
+	sc->sc_cmd = NULL;
+	sc->sc_read = 0;
+	sc->sc_written = 0;
+	sc->sc_len = 0;
+
+	/* Make sure the SPI engine and interrupts are disabled. */
+	sscr1 = INTELSPI_READ(sc, INTELSPI_SSPREG_SSCR1);
+	sscr1 &= ~(SSCR1_TIE | SSCR1_RIE | SSCR1_TINTE);
+	INTELSPI_WRITE(sc, INTELSPI_SSPREG_SSCR1, sscr1);
+
+	/* Release the controller and wakeup the next thread waiting for it. */
+	sc->sc_flags = 0;
+	wakeup_one(dev);
+	INTELSPI_UNLOCK(sc);
+
+	/*
+	 * Check for transfer timeout.  The SPI controller doesn't
+	 * return errors.
+	 */
+	if (err == EWOULDBLOCK) {
+		device_printf(sc->sc_dev, "transfer timeout\n");
+		err = EIO;
+	}
+
+	return (err);
+}
+
+static int
+intelspi_probe(device_t dev)
+{
+	static char *gpio_ids[] = { "80860F0E", NULL };
+
+	if (acpi_disabled("spi") ||
+	    ACPI_ID_PROBE(device_get_parent(dev), dev, gpio_ids) == NULL)
+	return (ENXIO);
+
+	device_set_desc(dev, "Intel SPI Controller");
+	return (0);
+}
+
+static int
+intelspi_attach(device_t dev)
+{
+	struct intelspi_softc	*sc;
+
+	sc = device_get_softc(dev);
+	sc->sc_dev = dev;
+	sc->sc_handle = acpi_get_handle(dev);
+
+	INTELSPI_LOCK_INIT(sc);
+
+	sc->sc_mem_rid = 0;
+	sc->sc_mem_res = bus_alloc_resource_any(sc->sc_dev,
+	    SYS_RES_MEMORY, &sc->sc_mem_rid, RF_ACTIVE);
+	if (sc->sc_mem_res == NULL) {
+		device_printf(dev, "can't allocate memory resource\n");
+		goto error;
+	}
+
+	sc->sc_irq_rid = 0;
+	sc->sc_irq_res = bus_alloc_resource_any(sc->sc_dev,
+	    SYS_RES_IRQ, &sc->sc_irq_rid, RF_ACTIVE);
+	if (sc->sc_irq_res == NULL) {
+		device_printf(dev, "can't allocate IRQ resource\n");
+		goto error;
+	}
+
+	/* Hook up our interrupt handler. */
+	if (bus_setup_intr(dev, sc->sc_irq_res, INTR_TYPE_MISC | INTR_MPSAFE,
+	    NULL, intelspi_intr, sc, &sc->sc_irq_ih)) {
+		device_printf(dev, "cannot setup the interrupt handler\n");
+		goto error;
+	}
+
+	intelspi_init(sc);
+
+	device_add_child(dev, "spibus", -1);
+
+	return (bus_generic_attach(dev));
+
+error:
+	INTELSPI_LOCK_DESTROY(sc);
+
+	if (sc->sc_mem_res != NULL)
+		bus_release_resource(dev, SYS_RES_MEMORY,
+		    sc->sc_mem_rid, sc->sc_mem_res);
+
+	if (sc->sc_irq_res != NULL)
+		bus_release_resource(dev, SYS_RES_MEMORY,
+		    sc->sc_irq_rid, sc->sc_irq_res);
+
+	return (ENXIO);
+}
+
+static int
+intelspi_detach(device_t dev)
+{
+	struct intelspi_softc	*sc;
+
+	sc = device_get_softc(dev);
+
+	INTELSPI_LOCK_DESTROY(sc);
+
+	if (sc->sc_irq_ih)
+		bus_teardown_intr(dev, sc->sc_irq_res, sc->sc_irq_ih);
+
+	if (sc->sc_mem_res != NULL)
+		bus_release_resource(dev, SYS_RES_MEMORY,
+		    sc->sc_mem_rid, sc->sc_mem_res);
+
+	if (sc->sc_irq_res != NULL)
+		bus_release_resource(dev, SYS_RES_MEMORY,
+		    sc->sc_irq_rid, sc->sc_irq_res);
+
+	return (0);
+}
+
+static device_method_t intelspi_methods[] = {
+	/* Device interface */
+	DEVMETHOD(device_probe, intelspi_probe),
+	DEVMETHOD(device_attach, intelspi_attach),
+	DEVMETHOD(device_detach, intelspi_detach),
+
+	/* SPI interface */
+	DEVMETHOD(spibus_transfer,	intelspi_transfer),
+
+	DEVMETHOD_END
+};
+
+static driver_t intelspi_driver = {
+	"spi",
+	intelspi_methods,
+	sizeof(struct intelspi_softc),
+};
+
+static devclass_t intelspi_devclass;
+DRIVER_MODULE(intelspi, acpi, intelspi_driver, intelspi_devclass, 0, 0);
+MODULE_DEPEND(intelspi, acpi, 1, 1, 1);
+MODULE_DEPEND(intelspi, spibus, 1, 1, 1);

Modified: head/sys/modules/Makefile
==============================================================================
--- head/sys/modules/Makefile	Tue Dec 27 22:31:06 2016	(r310644)
+++ head/sys/modules/Makefile	Tue Dec 27 22:37:24 2016	(r310645)
@@ -166,6 +166,7 @@ SUBDIR=	\
 	${_igb} \
 	${_iir} \
 	imgact_binmisc \
+	${_intelspi} \
 	${_io} \
 	${_ioat} \
         ${_ipoib} \
@@ -627,6 +628,7 @@ _hyperv=	hyperv
 _ichwd=		ichwd
 _ida=		ida
 _iir=		iir
+_intelspi=	intelspi
 _ipmi=		ipmi
 _ips=		ips
 _isci=		isci

Added: head/sys/modules/intelspi/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sys/modules/intelspi/Makefile	Tue Dec 27 22:37:24 2016	(r310645)
@@ -0,0 +1,8 @@
+# $FreeBSD$
+
+.PATH:	${.CURDIR}/../../dev/intel
+KMOD=	intelspi
+SRCS=	spi.c
+SRCS+=	acpi_if.h device_if.h bus_if.h spibus_if.h
+
+.include <bsd.kmod.mk>

From owner-svn-src-all@freebsd.org  Tue Dec 27 22:38:46 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 28265C94EEB;
 Tue, 27 Dec 2016 22:38:46 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id EC0A51AE6;
 Tue, 27 Dec 2016 22:38:45 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRMcjiH036831;
 Tue, 27 Dec 2016 22:38:45 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRMcjxJ036830;
 Tue, 27 Dec 2016 22:38:45 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612272238.uBRMcjxJ036830@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 22:38:45 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310646 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 22:38:46 -0000

Author: mav
Date: Tue Dec 27 22:38:44 2016
New Revision: 310646
URL: https://svnweb.freebsd.org/changeset/base/310646

Log:
  Do not update "saved" mode page on every MODE SELECT.
  
  We do not have non-volatile memory to really save those values, so we
  neither report nor support this capability.  Also saved mode pages are
  not replicated between HA peers now.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl.c

Modified: head/sys/cam/ctl/ctl.c
==============================================================================
--- head/sys/cam/ctl/ctl.c	Tue Dec 27 22:37:24 2016	(r310645)
+++ head/sys/cam/ctl/ctl.c	Tue Dec 27 22:38:44 2016	(r310646)
@@ -5833,7 +5833,7 @@ ctl_default_page_handler(struct ctl_scsi
 			 struct ctl_page_index *page_index, uint8_t *page_ptr)
 {
 	struct ctl_lun *lun;
-	uint8_t *current_cp, *saved_cp;
+	uint8_t *current_cp;
 	int set_ua;
 	uint32_t initidx;
 
@@ -5843,13 +5843,10 @@ ctl_default_page_handler(struct ctl_scsi
 
 	current_cp = (page_index->page_data + (page_index->page_len *
 	    CTL_PAGE_CURRENT));
-	saved_cp = (page_index->page_data + (page_index->page_len *
-	    CTL_PAGE_SAVED));
 
 	mtx_lock(&lun->lun_lock);
 	if (memcmp(current_cp, page_ptr, page_index->page_len)) {
 		memcpy(current_cp, page_ptr, page_index->page_len);
-		memcpy(saved_cp, page_ptr, page_index->page_len);
 		set_ua = 1;
 	}
 	if (set_ua != 0)

From owner-svn-src-all@freebsd.org  Tue Dec 27 23:31:33 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 52723C93DF2;
 Tue, 27 Dec 2016 23:31:33 +0000 (UTC)
 (envelope-from markj@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 21EAD1F7D;
 Tue, 27 Dec 2016 23:31:33 +0000 (UTC)
 (envelope-from markj@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRNVWb7060821;
 Tue, 27 Dec 2016 23:31:32 GMT (envelope-from markj@FreeBSD.org)
Received: (from markj@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRNVWhW060820;
 Tue, 27 Dec 2016 23:31:32 GMT (envelope-from markj@FreeBSD.org)
Message-Id: <201612272331.uBRNVWhW060820@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: markj set sender to
 markj@FreeBSD.org using -f
From: Mark Johnston <markj@FreeBSD.org>
Date: Tue, 27 Dec 2016 23:31:32 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310647 - head/sys/cddl/contrib/opensolaris/uts/common/sys
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 23:31:33 -0000

Author: markj
Date: Tue Dec 27 23:31:32 2016
New Revision: 310647
URL: https://svnweb.freebsd.org/changeset/base/310647

Log:
  Remove an obsolete pragma from dtrace.h.
  
  It triggers a compiler warning and has been removed upstream.
  
  MFC after:	1 week

Modified:
  head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h

Modified: head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h
==============================================================================
--- head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h	Tue Dec 27 22:38:44 2016	(r310646)
+++ head/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h	Tue Dec 27 23:31:32 2016	(r310647)
@@ -32,8 +32,6 @@
 #ifndef _SYS_DTRACE_H
 #define	_SYS_DTRACE_H
 
-#pragma ident	"%Z%%M%	%I%	%E% SMI"
-
 #ifdef	__cplusplus
 extern "C" {
 #endif

From owner-svn-src-all@freebsd.org  Tue Dec 27 23:33:00 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1F641C93FB3;
 Tue, 27 Dec 2016 23:33:00 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B7C6412D5;
 Tue, 27 Dec 2016 23:32:59 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRNWwKj061715;
 Tue, 27 Dec 2016 23:32:58 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRNWtca061677;
 Tue, 27 Dec 2016 23:32:55 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612272332.uBRNWtca061677@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Tue, 27 Dec 2016 23:32:55 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310648 - in head: contrib/bsnmp/gensnmpdef
 contrib/bsnmp/gensnmptree contrib/bsnmp/lib contrib/bsnmp/snmp_mibII
 contrib/bsnmp/snmp_ntp contrib/bsnmp/snmp_target contrib/bsnmp/snmp_usm ...
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 23:33:00 -0000

Author: ngie
Date: Tue Dec 27 23:32:54 2016
New Revision: 310648
URL: https://svnweb.freebsd.org/changeset/base/310648

Log:
  style(9): clean up trailing whitespace
  
  MFC after:	3 weeks

Modified:
  head/contrib/bsnmp/gensnmpdef/gensnmpdef.1
  head/contrib/bsnmp/gensnmpdef/gensnmpdef.c
  head/contrib/bsnmp/gensnmptree/gensnmptree.1
  head/contrib/bsnmp/gensnmptree/gensnmptree.c
  head/contrib/bsnmp/lib/asn1.3
  head/contrib/bsnmp/lib/asn1.c
  head/contrib/bsnmp/lib/asn1.h
  head/contrib/bsnmp/lib/bsnmpagent.3
  head/contrib/bsnmp/lib/bsnmpclient.3
  head/contrib/bsnmp/lib/bsnmplib.3
  head/contrib/bsnmp/lib/snmp.c
  head/contrib/bsnmp/lib/snmp.h
  head/contrib/bsnmp/lib/snmpagent.c
  head/contrib/bsnmp/lib/snmpagent.h
  head/contrib/bsnmp/lib/snmpclient.c
  head/contrib/bsnmp/lib/snmpclient.h
  head/contrib/bsnmp/lib/snmpcrypto.c
  head/contrib/bsnmp/lib/snmppriv.h
  head/contrib/bsnmp/lib/support.c
  head/contrib/bsnmp/lib/support.h
  head/contrib/bsnmp/snmp_mibII/mibII.c
  head/contrib/bsnmp/snmp_mibII/mibII.h
  head/contrib/bsnmp/snmp_mibII/mibII_begemot.c
  head/contrib/bsnmp/snmp_mibII/mibII_ifmib.c
  head/contrib/bsnmp/snmp_mibII/mibII_ifstack.c
  head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c
  head/contrib/bsnmp/snmp_mibII/mibII_ip.c
  head/contrib/bsnmp/snmp_mibII/mibII_ipaddr.c
  head/contrib/bsnmp/snmp_mibII/mibII_nettomedia.c
  head/contrib/bsnmp/snmp_mibII/mibII_rcvaddr.c
  head/contrib/bsnmp/snmp_mibII/mibII_route.c
  head/contrib/bsnmp/snmp_mibII/mibII_tcp.c
  head/contrib/bsnmp/snmp_mibII/mibII_tree.def
  head/contrib/bsnmp/snmp_mibII/mibII_udp.c
  head/contrib/bsnmp/snmp_mibII/snmp_mibII.3
  head/contrib/bsnmp/snmp_mibII/snmp_mibII.h
  head/contrib/bsnmp/snmp_ntp/NTP-MIB.txt
  head/contrib/bsnmp/snmp_ntp/NTP-PROXY-MIB.txt
  head/contrib/bsnmp/snmp_target/snmp_target.3
  head/contrib/bsnmp/snmp_usm/snmp_usm.3
  head/contrib/bsnmp/snmp_usm/usm_snmp.c
  head/contrib/bsnmp/snmp_vacm/snmp_vacm.3
  head/contrib/bsnmp/snmp_vacm/vacm_snmp.c
  head/contrib/bsnmp/snmpd/BEGEMOT-MIB.txt
  head/contrib/bsnmp/snmpd/BEGEMOT-SNMPD.txt
  head/contrib/bsnmp/snmpd/FOKUS-MIB.txt
  head/contrib/bsnmp/snmpd/action.c
  head/contrib/bsnmp/snmpd/config.c
  head/contrib/bsnmp/snmpd/export.c
  head/contrib/bsnmp/snmpd/main.c
  head/contrib/bsnmp/snmpd/snmpd.config
  head/contrib/bsnmp/snmpd/snmpd.h
  head/contrib/bsnmp/snmpd/snmpd.sh
  head/contrib/bsnmp/snmpd/snmpmod.3
  head/contrib/bsnmp/snmpd/snmpmod.h
  head/contrib/bsnmp/snmpd/trans_lsock.c
  head/contrib/bsnmp/snmpd/trans_lsock.h
  head/contrib/bsnmp/snmpd/trans_udp.c
  head/contrib/bsnmp/snmpd/trans_udp.h
  head/contrib/bsnmp/snmpd/trap.c
  head/contrib/bsnmp/snmpd/tree.def
  head/usr.sbin/bsnmpd/modules/snmp_atm/BEGEMOT-ATM-FREEBSD-MIB.txt
  head/usr.sbin/bsnmpd/modules/snmp_atm/atm_sys.c
  head/usr.sbin/bsnmpd/modules/snmp_bridge/BEGEMOT-BRIDGE-MIB.txt
  head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_addrs.c
  head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_if.c
  head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_port.c
  head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_sys.c
  head/usr.sbin/bsnmpd/modules/snmp_bridge/snmp_bridge.3
  head/usr.sbin/bsnmpd/modules/snmp_hostres/snmp_hostres.3
  head/usr.sbin/bsnmpd/modules/snmp_netgraph/snmp_netgraph.c
  head/usr.sbin/bsnmpd/modules/snmp_pf/BEGEMOT-PF-MIB.txt
  head/usr.sbin/bsnmpd/modules/snmp_pf/Makefile
  head/usr.sbin/bsnmpd/modules/snmp_pf/pf_snmp.c
  head/usr.sbin/bsnmpd/modules/snmp_target/Makefile
  head/usr.sbin/bsnmpd/modules/snmp_usm/Makefile
  head/usr.sbin/bsnmpd/modules/snmp_vacm/Makefile
  head/usr.sbin/bsnmpd/modules/snmp_wlan/wlan_snmp.c
  head/usr.sbin/bsnmpd/modules/snmp_wlan/wlan_snmp.h
  head/usr.sbin/bsnmpd/modules/snmp_wlan/wlan_sys.c
  head/usr.sbin/bsnmpd/tools/bsnmptools/bsnmpget.c
  head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmpimport.c
  head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmpmap.c
  head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptc.c
  head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c

Modified: head/contrib/bsnmp/gensnmpdef/gensnmpdef.1
==============================================================================
--- head/contrib/bsnmp/gensnmpdef/gensnmpdef.1	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/gensnmpdef/gensnmpdef.1	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -13,7 +13,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/gensnmpdef/gensnmpdef.c
==============================================================================
--- head/contrib/bsnmp/gensnmpdef/gensnmpdef.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/gensnmpdef/gensnmpdef.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -1,10 +1,10 @@
-/* 
+/*
  * Copyright (C) 2004-2006
  * 	Hartmut Brandt.
  * 	All rights reserved.
- * 
+ *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -233,7 +233,7 @@ print_scalar(SmiNode *n, u_int level)
 	printf(" op_%s", p->name);
 
 	print_access(n->access);
-	
+
 	printf(")\n");
 }
 
@@ -422,7 +422,7 @@ static void
 print_enum_typedef(SmiType *t)
 {
 	SmiNamedNumber *nnum;
-	
+
 	for (nnum = smiGetFirstNamedNumber(t); nnum != NULL;
 	    nnum = smiGetNextNamedNumber(nnum)) {
 		printf("\t%ld %s\n" , nnum->value.value.integer32, nnum->name);
@@ -434,10 +434,10 @@ print_stype(SmiNode *n)
 {
 	SmiType *type;
 	struct tdef *t = NULL;
-	
+
 	type = smiGetNodeType(n);
 	assert(type != NULL);
-	
+
 	if (type->basetype == SMI_BASETYPE_ENUM) {
 		if (do_typedef == 'e' && type->name != NULL) {
 			SLIST_FOREACH(t, &tdefs, link) {
@@ -450,7 +450,7 @@ print_stype(SmiNode *n)
 			printf("typedef %sType ENUM (\n", n->name);
 		else
 			return;
-		
+
 		print_enum_typedef(type);
 		printf(")\n\n");
 
@@ -476,7 +476,7 @@ static void
 print_typdefs(SmiNode *n)
 {
 	SmiNode *p;
-	
+
 	p = n;
 	n = smiGetFirstChildNode(n);
 	while (n != NULL) {

Modified: head/contrib/bsnmp/gensnmptree/gensnmptree.1
==============================================================================
--- head/contrib/bsnmp/gensnmptree/gensnmptree.1	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/gensnmptree/gensnmptree.1	Tue Dec 27 23:32:54 2016	(r310648)
@@ -7,7 +7,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -16,7 +16,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/gensnmptree/gensnmptree.c
==============================================================================
--- head/contrib/bsnmp/gensnmptree/gensnmptree.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/gensnmptree/gensnmptree.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -8,7 +8,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -17,7 +17,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -738,7 +738,7 @@ parse_type(enum tok *tok, struct type *t
 				e->value = -(long)val;
 			} else
 				e->value = val;
-			
+
 			if (*tok != TOK_NUM)
 				report("need value for ENUM/BITS");
 			if (gettoken() != TOK_STR)

Modified: head/contrib/bsnmp/lib/asn1.3
==============================================================================
--- head/contrib/bsnmp/lib/asn1.3	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/asn1.3	Tue Dec 27 23:32:54 2016	(r310648)
@@ -5,9 +5,9 @@
 .\" Copyright (c) 2001-2003
 .\"	Fraunhofer Institute for Open Communication Systems (FhG Fokus).
 .\"	All rights reserved.
-.\" 
+.\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -16,7 +16,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/asn1.c
==============================================================================
--- head/contrib/bsnmp/lib/asn1.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/asn1.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -285,7 +285,7 @@ asn_put_real_integer(struct asn_buf *b, 
 	enum asn_err ret;
 
 	if (ival < 0) {
-		/* this may fail if |INT64_MIN| > |INT64_MAX| and 
+		/* this may fail if |INT64_MIN| > |INT64_MAX| and
 		 * the value is between * INT64_MIN <= ival < -(INT64_MAX+1) */
 		val = (uint64_t)-(ival + 1);
 		neg = 1;
@@ -890,7 +890,7 @@ asn_slice_oid(struct asn_oid *dest, cons
 	memcpy(dest->subs, &src->subs[from], dest->len * sizeof(dest->subs[0]));
 }
 
-/* 
+/*
  * Append from to to
  */
 void

Modified: head/contrib/bsnmp/lib/asn1.h
==============================================================================
--- head/contrib/bsnmp/lib/asn1.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/asn1.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/bsnmpagent.3
==============================================================================
--- head/contrib/bsnmp/lib/bsnmpagent.3	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/bsnmpagent.3	Tue Dec 27 23:32:54 2016	(r310648)
@@ -7,7 +7,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -16,7 +16,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/bsnmpclient.3
==============================================================================
--- head/contrib/bsnmp/lib/bsnmpclient.3	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/bsnmpclient.3	Tue Dec 27 23:32:54 2016	(r310648)
@@ -7,7 +7,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -16,7 +16,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/bsnmplib.3
==============================================================================
--- head/contrib/bsnmp/lib/bsnmplib.3	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/bsnmplib.3	Tue Dec 27 23:32:54 2016	(r310648)
@@ -13,7 +13,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -22,7 +22,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/snmp.c
==============================================================================
--- head/contrib/bsnmp/lib/snmp.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmp.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Copyright (c) 2010 The FreeBSD Foundation
  * All rights reserved.
  *
@@ -19,7 +19,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -684,7 +684,7 @@ snmp_pdu_snoop(const struct asn_buf *b0)
 	struct asn_buf b = *b0;
 
 	/* <0x10|0x20> <len> <data...> */
-	
+
 	if (b.asn_len == 0)
 		return (0);
 	if (b.asn_cptr[0] != (ASN_TYPE_SEQUENCE | ASN_TYPE_CONSTRUCTED)) {
@@ -759,7 +759,7 @@ snmp_pdu_encode_header(struct asn_buf *b
 		if (asn_put_temp_header(b, (ASN_TYPE_SEQUENCE |
 		    ASN_TYPE_CONSTRUCTED), &v3_hdr_ptr) != ASN_ERR_OK)
 			return (SNMP_CODE_FAILED);
-	
+
 		if (asn_put_integer(b, pdu->identifier) != ASN_ERR_OK)
 			return (SNMP_CODE_FAILED);
 

Modified: head/contrib/bsnmp/lib/snmp.h
==============================================================================
--- head/contrib/bsnmp/lib/snmp.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmp.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,14 +4,14 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Copyright (c) 2010 The FreeBSD Foundation
  * All rights reserved.
  *
  * Portions of this software were developed by Shteryana Sotirova Shopova
  * under sponsorship from the FreeBSD Foundation.
  *
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -20,7 +20,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/snmpagent.c
==============================================================================
--- head/contrib/bsnmp/lib/snmpagent.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmpagent.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -518,7 +518,7 @@ snmp_getbulk(struct snmp_pdu *pdu, struc
 				/* PDU is full */
 				goto done;
 
-			if (cnt == 0) 
+			if (cnt == 0)
 				result = do_getnext(&context, &pdu->bindings[i],
 				    &resp->bindings[resp->nbindings], pdu);
 			else
@@ -692,7 +692,7 @@ snmp_set(struct snmp_pdu *pdu, struct as
 	if (snmp_pdu_encode_header(resp_b, resp))
 		return (SNMP_RET_IGN);
 
-	/* 
+	/*
 	 * 1. Find all nodes, check that they are writeable and
 	 *    that the syntax is ok, copy over the binding to the response.
 	 */
@@ -970,7 +970,7 @@ snmp_dep_lookup(struct snmp_context *ctx
 /*
  * Make an error response from a PDU. We do this without decoding the
  * variable bindings. This means we can sent the junk back to a caller
- * that has sent us junk in the first place. 
+ * that has sent us junk in the first place.
  */
 enum snmp_ret
 snmp_make_errresp(const struct snmp_pdu *pdu, struct asn_buf *pdu_b,

Modified: head/contrib/bsnmp/lib/snmpagent.h
==============================================================================
--- head/contrib/bsnmp/lib/snmpagent.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmpagent.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/snmpclient.c
==============================================================================
--- head/contrib/bsnmp/lib/snmpclient.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmpclient.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -68,7 +68,7 @@
 struct snmp_client snmp_client;
 
 /* List of all outstanding requests */
-struct sent_pdu {	
+struct sent_pdu {
 	int		reqid;
 	struct snmp_pdu	*pdu;
 	struct timeval	time;
@@ -510,7 +510,7 @@ table_check_response(struct tabwork *wor
 				table_free(work, 1);
 				return (-2);
 			}
-					
+
 			continue;
 		}
 		if (!asn_is_suboid(&work->descr->table, &b->var) ||
@@ -754,7 +754,7 @@ snmp_oid_append(struct asn_oid *oid, con
 	ret = 0;
 	while (*fmt != '\0') {
 		switch (*fmt++) {
-		  case 'i': 
+		  case 'i':
 			/* just an integer more */
 			if (oid->len + 1 > ASN_MAXOIDLEN) {
 				warnx("%s: OID too long for integer", __func__);
@@ -804,7 +804,7 @@ snmp_oid_append(struct asn_oid *oid, con
 			break;
 
 		  case 'b':
-			/* append `size` characters */ 
+			/* append `size` characters */
 			str = (const u_char *)va_arg(va, const char *);
 			if (oid->len + size > ASN_MAXOIDLEN) {
 				warnx("%s: OID too long for string", __func__);
@@ -852,7 +852,7 @@ snmp_client_init(struct snmp_client *c)
 
 	strcpy(c->read_community, "public");
 	strcpy(c->write_community, "private");
-	
+
 	c->security_model = SNMP_SECMODEL_USM;
 	strcpy(c->cname, "");
 
@@ -863,7 +863,7 @@ snmp_client_init(struct snmp_client *c)
 	c->txbuflen = c->rxbuflen = 10000;
 
 	c->fd = -1;
-	
+
 	c->max_reqid = INT32_MAX;
 	c->min_reqid = 0;
 	c->next_reqid = 0;

Modified: head/contrib/bsnmp/lib/snmpclient.h
==============================================================================
--- head/contrib/bsnmp/lib/snmpclient.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmpclient.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -5,7 +5,7 @@
  *
  * Author: Harti Brandt <harti@freebsd.org>
  *	   Kendy Kutzner
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -14,7 +14,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -59,7 +59,7 @@ typedef void (*snmp_send_cb_f)(struct sn
 typedef void (*snmp_timeout_cb_f)(void * );
 
 /* timeout start function */
-typedef void *(*snmp_timeout_start_f)(struct timeval *timeout,  
+typedef void *(*snmp_timeout_start_f)(struct timeval *timeout,
     snmp_timeout_cb_f callback, void *);
 
 /* timeout stop function */

Modified: head/contrib/bsnmp/lib/snmpcrypto.c
==============================================================================
--- head/contrib/bsnmp/lib/snmpcrypto.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmpcrypto.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -322,7 +322,7 @@ snmp_calc_keychange(struct snmp_user *us
 
 	for (i = 0; i < keylen / 4; i++)
 		rvalue[i] = random();
-	
+
 	memcpy(keychange, user->auth_key, keylen);
 	memcpy(keychange + keylen, rvalue, keylen);
 

Modified: head/contrib/bsnmp/lib/snmppriv.h
==============================================================================
--- head/contrib/bsnmp/lib/snmppriv.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/snmppriv.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/support.c
==============================================================================
--- head/contrib/bsnmp/lib/support.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/support.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -1,10 +1,10 @@
-/* 
+/*
  * Copyright (C) 2004
  * 	Hartmut Brandt.
  * 	All rights reserved.
- * 
+ *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/lib/support.h
==============================================================================
--- head/contrib/bsnmp/lib/support.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/lib/support.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -1228,7 +1228,7 @@ mib_fetch_rtab(int af, int info, int arg
 			return (NULL);
 		}
 		buf = newbuf;
-			
+
 		if (sysctl(name, 6, buf, lenp, NULL, 0) == 0)
 			break;
 
@@ -1329,7 +1329,7 @@ mib_arp_update(void)
 		in_update_arp = 0;
 		return;
 	}
-	
+
 	next = buf;
 	while (next < buf + needed) {
 		rtm = (struct rt_msghdr *)(void *)next;
@@ -1521,7 +1521,7 @@ mib_unmodify_ifa(struct mibifa *ifa)
 }
 
 /*
- * Modify an IFA. 
+ * Modify an IFA.
  */
 int
 mib_modify_ifa(struct mibifa *ifa)

Modified: head/contrib/bsnmp/snmp_mibII/mibII.h
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_begemot.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_begemot.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_begemot.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_ifmib.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_ifmib.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_ifmib.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_ifstack.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_ifstack.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_ifstack.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_ip.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_ip.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_ip.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_ipaddr.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_ipaddr.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_ipaddr.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_nettomedia.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_nettomedia.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_nettomedia.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_rcvaddr.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_rcvaddr.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_rcvaddr.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_route.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_route.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_route.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
@@ -257,7 +257,7 @@ mib_fetch_route(void)
 			continue;
 		mib_extract_addrs(rtm->rtm_addrs, (u_char *)(rtm + 1), addrs);
 
-		
+
 		mib_sroute_process(rtm, addrs[RTAX_GATEWAY], addrs[RTAX_DST],
 		    addrs[RTAX_NETMASK]);
 	}

Modified: head/contrib/bsnmp/snmp_mibII/mibII_tcp.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_tcp.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_tcp.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_tree.def
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_tree.def	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_tree.def	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
 #	All rights reserved.
 #
 # Author: Harti Brandt <harti@freebsd.org>
-# 
+#
 # Redistribution and use in source and binary forms, with or without
 # modification, are permitted provided that the following conditions
 # are met:
@@ -13,7 +13,7 @@
 # 2. Redistributions in binary form must reproduce the above copyright
 #    notice, this list of conditions and the following disclaimer in the
 #    documentation and/or other materials provided with the distribution.
-# 
+#
 # THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/mibII_udp.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_udp.c	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/mibII_udp.c	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/snmp_mibII.3
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/snmp_mibII.3	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/snmp_mibII.3	Tue Dec 27 23:32:54 2016	(r310648)
@@ -7,7 +7,7 @@
 .\"	All rights reserved.
 .\"
 .\" Author: Harti Brandt <harti@FreeBSD.org>
-.\" 
+.\"
 .\" Redistribution and use in source and binary forms, with or without
 .\" modification, are permitted provided that the following conditions
 .\" are met:
@@ -16,7 +16,7 @@
 .\" 2. Redistributions in binary form must reproduce the above copyright
 .\"    notice, this list of conditions and the following disclaimer in the
 .\"    documentation and/or other materials provided with the distribution.
-.\" 
+.\"
 .\" THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_mibII/snmp_mibII.h
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/snmp_mibII.h	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_mibII/snmp_mibII.h	Tue Dec 27 23:32:54 2016	(r310648)
@@ -4,7 +4,7 @@
  *	All rights reserved.
  *
  * Author: Harti Brandt <harti@freebsd.org>
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
  * are met:
@@ -13,7 +13,7 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE

Modified: head/contrib/bsnmp/snmp_ntp/NTP-MIB.txt
==============================================================================
--- head/contrib/bsnmp/snmp_ntp/NTP-MIB.txt	Tue Dec 27 23:31:32 2016	(r310647)
+++ head/contrib/bsnmp/snmp_ntp/NTP-MIB.txt	Tue Dec 27 23:32:54 2016	(r310648)
@@ -5,7 +5,7 @@
 NTP-MIB DEFINITIONS ::= BEGIN
 
 IMPORTS
-    Integer32, IpAddress, MODULE-IDENTITY, OBJECT-TYPE, Unsigned32, 
+    Integer32, IpAddress, MODULE-IDENTITY, OBJECT-TYPE, Unsigned32,
     enterprises
         FROM SNMPv2-SMI
 
@@ -14,9 +14,9 @@ IMPORTS
 
 ntpMIB MODULE-IDENTITY
     LAST-UPDATED "199707251530Z"
-    ORGANIZATION 
+    ORGANIZATION
         "University of Delaware"
-    CONTACT-INFO 
+    CONTACT-INFO
         "Adarsh Sethi
          Department of Computer & Information Sciences
          University of Delaware
@@ -30,7 +30,7 @@ ntpMIB MODULE-IDENTITY
          Newark, DE 19716
          Tel: +1 302 831 ????
          E-mail: mills@ee.udel.edu"
-    DESCRIPTION 
+    DESCRIPTION
         "This MIB module defines a MIB which provides mechanisms to
          monitor and control an NTP server."
     ::= { udel 3 }
@@ -60,18 +60,18 @@ ntpFilter OBJECT IDENTIFIER
 NTPTimeStamp ::= TEXTUAL-CONVENTION
     DISPLAY-HINT "4x.4x"
     STATUS      current
-    DESCRIPTION 
+    DESCRIPTION
         ""
     SYNTAX      OCTET STRING (SIZE(8))
 
 NTPLeapIndicator ::= TEXTUAL-CONVENTION
     STATUS      current
-    DESCRIPTION 
+    DESCRIPTION
         ""
     SYNTAX      INTEGER {
 		    noWarning(0),
 		    addSecond(1),
-		    subtractSecond(2), 
+		    subtractSecond(2),
                     alarm(3) }
 
 --
@@ -82,7 +82,7 @@ ntpSysLeap OBJECT-TYPE
     SYNTAX      NTPLeapIndicator
     MAX-ACCESS  read-only
     STATUS      current
-    DESCRIPTION 
+    DESCRIPTION
         " two-bit code warning of an impending leap
          second to be inserted in the NTP timescale."
     ::= { ntpSystem 1 }
@@ -91,7 +91,7 @@ ntpSysStratum OBJECT-TYPE
     SYNTAX      Integer32 (0..255)
     MAX-ACCESS  read-only

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***

From owner-svn-src-all@freebsd.org  Tue Dec 27 23:56:47 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9A21BC944F8;
 Tue, 27 Dec 2016 23:56:47 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6A0901CB0;
 Tue, 27 Dec 2016 23:56:47 +0000 (UTC) (envelope-from mav@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBRNuk5p069991;
 Tue, 27 Dec 2016 23:56:46 GMT (envelope-from mav@FreeBSD.org)
Received: (from mav@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBRNukwC069989;
 Tue, 27 Dec 2016 23:56:46 GMT (envelope-from mav@FreeBSD.org)
Message-Id: <201612272356.uBRNukwC069989@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org
 using -f
From: Alexander Motin <mav@FreeBSD.org>
Date: Tue, 27 Dec 2016 23:56:46 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310649 - head/sys/cam/ctl
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Tue, 27 Dec 2016 23:56:47 -0000

Author: mav
Date: Tue Dec 27 23:56:46 2016
New Revision: 310649
URL: https://svnweb.freebsd.org/changeset/base/310649

Log:
  Allow more efficient use of private area.
  
  There are 16 bytes of space, so we may store two pointers in one.
  
  MFC after:	2 weeks

Modified:
  head/sys/cam/ctl/ctl_io.h
  head/sys/cam/ctl/scsi_ctl.c

Modified: head/sys/cam/ctl/ctl_io.h
==============================================================================
--- head/sys/cam/ctl/ctl_io.h	Tue Dec 27 23:32:54 2016	(r310648)
+++ head/sys/cam/ctl/ctl_io.h	Tue Dec 27 23:56:46 2016	(r310649)
@@ -145,7 +145,9 @@ struct ctl_ptr_len_flags {
 union ctl_priv {
 	uint8_t		bytes[sizeof(uint64_t) * 2];
 	uint64_t	integer;
+	uint64_t	integers[2];
 	void		*ptr;
+	void		*ptrs[2];
 };
 
 /*

Modified: head/sys/cam/ctl/scsi_ctl.c
==============================================================================
--- head/sys/cam/ctl/scsi_ctl.c	Tue Dec 27 23:32:54 2016	(r310648)
+++ head/sys/cam/ctl/scsi_ctl.c	Tue Dec 27 23:56:46 2016	(r310649)
@@ -185,6 +185,9 @@ MALLOC_DEFINE(M_CTLFE, "CAM CTL FE", "CA
 /* This is only used in the CTIO */
 #define	ccb_atio	ppriv_ptr1
 
+#define PRIV_CCB(io)	((io)->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptrs[0])
+#define PRIV_INFO(io)	((io)->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptrs[1])
+
 int			ctlfeinitialize(void);
 void			ctlfeshutdown(void);
 static periph_init_t	ctlfeperiphinit;
@@ -554,7 +557,7 @@ ctlferegister(struct cam_periph *periph,
 			status = CAM_RESRC_UNAVAIL;
 			break;
 		}
-		new_io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr = cmd_info;
+		PRIV_INFO(new_io) = cmd_info;
 		softc->atios_alloced++;
 		new_ccb->ccb_h.io_ptr = new_io;
 
@@ -702,7 +705,7 @@ ctlfedata(struct ctlfe_lun_softc *softc,
 	size_t off;
 	int i, idx;
 
-	cmd_info = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr;
+	cmd_info = PRIV_INFO(io);
 	bus_softc = softc->parent_softc;
 
 	/*
@@ -806,7 +809,7 @@ ctlfestart(struct cam_periph *periph, un
 
 	flags = atio->ccb_h.flags &
 		(CAM_DIS_DISCONNECT|CAM_TAG_ACTION_VALID|CAM_DIR_MASK);
-	cmd_info = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr;
+	cmd_info = PRIV_INFO(io);
 	cmd_info->cur_transfer_index = 0;
 	cmd_info->cur_transfer_off = 0;
 	cmd_info->flags = 0;
@@ -987,7 +990,7 @@ ctlfe_free_ccb(struct cam_periph *periph
 	switch (ccb->ccb_h.func_code) {
 	case XPT_ACCEPT_TARGET_IO:
 		softc->atios_freed++;
-		cmd_info = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr;
+		cmd_info = PRIV_INFO(io);
 		free(cmd_info, M_CTLFE);
 		break;
 	case XPT_IMMEDIATE_NOTIFY:
@@ -1154,12 +1157,12 @@ ctlfedone(struct cam_periph *periph, uni
 		 */
 		mtx_unlock(mtx);
 		io = done_ccb->ccb_h.io_ptr;
-		cmd_info = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr;
+		cmd_info = PRIV_INFO(io);
 		ctl_zero_io(io);
 
 		/* Save pointers on both sides */
-		io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr = done_ccb;
-		io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr = cmd_info;
+		PRIV_CCB(io) = done_ccb;
+		PRIV_INFO(io) = cmd_info;
 		done_ccb->ccb_h.io_ptr = io;
 
 		/*
@@ -1315,7 +1318,7 @@ ctlfedone(struct cam_periph *periph, uni
 			struct ccb_scsiio *csio;
 
 			csio = &done_ccb->csio;
-			cmd_info = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND2].ptr;
+			cmd_info = PRIV_INFO(io);
 
 			io->io_hdr.flags &= ~CTL_FLAG_DMA_INPROG;
 
@@ -1444,7 +1447,7 @@ ctlfedone(struct cam_periph *periph, uni
 		send_ctl_io = 1;
 
 		io->io_hdr.io_type = CTL_IO_TASK;
-		io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr =done_ccb;
+		PRIV_CCB(io) = done_ccb;
 		inot->ccb_h.io_ptr = io;
 		io->io_hdr.nexus.initid = inot->initiator_id;
 		io->io_hdr.nexus.targ_port = bus_softc->port.targ_port;
@@ -2002,7 +2005,7 @@ ctlfe_datamove(union ctl_io *io)
 	KASSERT(io->io_hdr.io_type == CTL_IO_SCSI,
 	    ("Unexpected io_type (%d) in ctlfe_datamove", io->io_hdr.io_type));
 
-	ccb = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr;
+	ccb = PRIV_CCB(io);
 	periph = xpt_path_periph(ccb->ccb_h.path);
 	cam_periph_lock(periph);
 	softc = (struct ctlfe_lun_softc *)periph->softc;
@@ -2022,7 +2025,7 @@ ctlfe_done(union ctl_io *io)
 	struct cam_periph *periph;
 	struct ctlfe_lun_softc *softc;
 
-	ccb = io->io_hdr.ctl_private[CTL_PRIV_FRONTEND].ptr;
+	ccb = PRIV_CCB(io);
 	periph = xpt_path_periph(ccb->ccb_h.path);
 	cam_periph_lock(periph);
 	softc = (struct ctlfe_lun_softc *)periph->softc;

From owner-svn-src-all@freebsd.org  Wed Dec 28 02:55:28 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5C9B1C93625;
 Wed, 28 Dec 2016 02:55:28 +0000 (UTC) (envelope-from kan@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 1D3171DEF;
 Wed, 28 Dec 2016 02:55:28 +0000 (UTC) (envelope-from kan@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS2tRaj045517;
 Wed, 28 Dec 2016 02:55:27 GMT (envelope-from kan@FreeBSD.org)
Received: (from kan@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS2tQeR045512;
 Wed, 28 Dec 2016 02:55:26 GMT (envelope-from kan@FreeBSD.org)
Message-Id: <201612280255.uBS2tQeR045512@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kan set sender to kan@FreeBSD.org
 using -f
From: Alexander Kabaev <kan@FreeBSD.org>
Date: Wed, 28 Dec 2016 02:55:26 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310650 - in head/sys/mips: include mips
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 02:55:28 -0000

Author: kan
Date: Wed Dec 28 02:55:26 2016
New Revision: 310650
URL: https://svnweb.freebsd.org/changeset/base/310650

Log:
  Implement pmap_change_attr and related APIs on MIPS
  
  On platforms that have uncached-accelerate cache attribute, map it
  to VM_MEMATTR_WRITE_COMBINING. Otherwise, leave write comining
  undefined.
  
  Reviewed by:	adrian, jhb (glance)
  Differential Revision:	https://reviews.freebsd.org/D8894

Modified:
  head/sys/mips/include/cpuregs.h
  head/sys/mips/include/pmap.h
  head/sys/mips/include/pte.h
  head/sys/mips/include/vm.h
  head/sys/mips/mips/pmap.c

Modified: head/sys/mips/include/cpuregs.h
==============================================================================
--- head/sys/mips/include/cpuregs.h	Tue Dec 27 23:56:46 2016	(r310649)
+++ head/sys/mips/include/cpuregs.h	Wed Dec 28 02:55:26 2016	(r310650)
@@ -171,6 +171,10 @@
 #define	MIPS_CCA_CACHED		MIPS_CCA_CCS
 #endif
 
+#if defined(CPU_XBURST)
+#define	MIPS_CCA_UA		0x01
+#endif
+
 #ifndef	MIPS_CCA_UNCACHED
 #define	MIPS_CCA_UNCACHED	MIPS_CCA_UC
 #endif
@@ -188,6 +192,16 @@
 #endif
 #endif
 
+/*
+ * Use uncached-accelerated mode for write-combining maps, if one is defined,
+ * otherwise fall back to uncached
+ */
+#ifndef MIPS_CCA_WC
+#ifdef MIPS_CCA_UA
+#define	MIPS_CCA_WC MIPS_CCA_UA
+#endif
+#endif
+
 #define	MIPS_PHYS_TO_XKPHYS(cca,x) \
 	((0x2ULL << 62) | ((unsigned long long)(cca) << 59) | (x))
 #define	MIPS_PHYS_TO_XKPHYS_CACHED(x) \

Modified: head/sys/mips/include/pmap.h
==============================================================================
--- head/sys/mips/include/pmap.h	Tue Dec 27 23:56:46 2016	(r310649)
+++ head/sys/mips/include/pmap.h	Wed Dec 28 02:55:26 2016	(r310650)
@@ -74,7 +74,8 @@ struct md_page {
 };
 
 #define	PV_TABLE_REF		0x02	/* referenced */
-#define	PV_MEMATTR_UNCACHEABLE	0x04
+#define	PV_MEMATTR_MASK		0xf0	/* store vm_memattr_t here */
+#define	PV_MEMATTR_SHIFT	0x04
 
 #define	ASID_BITS		8
 #define	ASIDGEN_BITS		(32 - ASID_BITS)
@@ -163,22 +164,24 @@ extern vm_offset_t virtual_end;
 
 extern vm_paddr_t dump_avail[PHYS_AVAIL_ENTRIES + 2];
 
-#define	pmap_page_get_memattr(m)	VM_MEMATTR_DEFAULT
+#define	pmap_page_get_memattr(m) (((m)->md.pv_flags & PV_MEMATTR_MASK) >> PV_MEMATTR_SHIFT)
 #define	pmap_page_is_mapped(m)	(!TAILQ_EMPTY(&(m)->md.pv_list))
 #define	pmap_page_is_write_mapped(m)	(((m)->aflags & PGA_WRITEABLE) != 0)
 
 void pmap_bootstrap(void);
 void *pmap_mapdev(vm_paddr_t, vm_size_t);
+void *pmap_mapdev_attr(vm_paddr_t, vm_size_t, vm_memattr_t);
 void pmap_unmapdev(vm_offset_t, vm_size_t);
 vm_offset_t pmap_steal_memory(vm_size_t size);
 void pmap_kenter(vm_offset_t va, vm_paddr_t pa);
-void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, int attr);
+void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t attr);
 void pmap_kremove(vm_offset_t va);
 void *pmap_kenter_temporary(vm_paddr_t pa, int i);
 void pmap_kenter_temporary_free(vm_paddr_t pa);
 void pmap_flush_pvcache(vm_page_t m);
 int pmap_emulate_modified(pmap_t pmap, vm_offset_t va);
 void pmap_page_set_memattr(vm_page_t, vm_memattr_t);
+int pmap_change_attr(vm_offset_t, vm_size_t, vm_memattr_t);
 
 #endif				/* _KERNEL */
 

Modified: head/sys/mips/include/pte.h
==============================================================================
--- head/sys/mips/include/pte.h	Tue Dec 27 23:56:46 2016	(r310649)
+++ head/sys/mips/include/pte.h	Wed Dec 28 02:55:26 2016	(r310650)
@@ -132,8 +132,10 @@ typedef	pt_entry_t *pd_entry_t;
  * 		it is matched.
  */
 #define	PTE_C(attr)		((attr & 0x07) << 3)
+#define	PTE_C_MASK		(PTE_C(0x07))
 #define	PTE_C_UNCACHED		(PTE_C(MIPS_CCA_UNCACHED))
 #define	PTE_C_CACHE		(PTE_C(MIPS_CCA_CACHED))
+#define	PTE_C_WC		(PTE_C(MIPS_CCA_WC))
 #define	PTE_D			0x04
 #define	PTE_V			0x02
 #define	PTE_G			0x01
@@ -158,6 +160,7 @@ typedef	pt_entry_t *pd_entry_t;
 #define	pte_clear(pte, bit)	(*(pte) &= ~(bit))
 #define	pte_set(pte, bit)	(*(pte) |= (bit))
 #define	pte_test(pte, bit)	((*(pte) & (bit)) == (bit))
+#define	pte_cache_bits(pte)	((*(pte) >> 3) & 0x07)
 
 /* Assembly support for PTE access*/
 #ifdef LOCORE

Modified: head/sys/mips/include/vm.h
==============================================================================
--- head/sys/mips/include/vm.h	Tue Dec 27 23:56:46 2016	(r310649)
+++ head/sys/mips/include/vm.h	Wed Dec 28 02:55:26 2016	(r310650)
@@ -32,7 +32,11 @@
 #include <machine/pte.h>
 
 /* Memory attributes. */
-#define	VM_MEMATTR_UNCACHEABLE	((vm_memattr_t)PTE_C_UNCACHED)
-#define	VM_MEMATTR_DEFAULT	((vm_memattr_t)PTE_C_CACHE)
+#define	VM_MEMATTR_UNCACHEABLE		((vm_memattr_t)MIPS_CCA_UNCACHED)
+#define	VM_MEMATTR_WRITE_BACK		((vm_memattr_t)MIPS_CCA_CACHED)
+#define	VM_MEMATTR_DEFAULT		VM_MEMATTR_WRITE_BACK
+#ifdef MIPS_CCA_WC
+#define	VM_MEMATTR_WRITE_COMBINING	((vm_memattr_t)MIPS_CCA_WC)
+#endif
 
 #endif /* !_MACHINE_VM_H_ */

Modified: head/sys/mips/mips/pmap.c
==============================================================================
--- head/sys/mips/mips/pmap.c	Tue Dec 27 23:56:46 2016	(r310649)
+++ head/sys/mips/mips/pmap.c	Wed Dec 28 02:55:26 2016	(r310650)
@@ -189,10 +189,10 @@ static void pmap_update_page_action(void
  * The highmem area does not have a KSEG0 mapping, and we need a mechanism to
  * do temporary per-CPU mappings for pmap_zero_page, pmap_copy_page etc.
  *
- * At bootup, we reserve 2 virtual pages per CPU for mapping highmem pages. To 
+ * At bootup, we reserve 2 virtual pages per CPU for mapping highmem pages. To
  * access a highmem physical address on a CPU, we map the physical address to
- * the reserved virtual address for the CPU in the kernel pagetable.  This is 
- * done with interrupts disabled(although a spinlock and sched_pin would be 
+ * the reserved virtual address for the CPU in the kernel pagetable.  This is
+ * done with interrupts disabled(although a spinlock and sched_pin would be
  * sufficient).
  */
 struct local_sysmaps {
@@ -303,7 +303,7 @@ pmap_lmem_map2(vm_paddr_t phys1, vm_padd
 	return (0);
 }
 
-static __inline vm_offset_t 
+static __inline vm_offset_t
 pmap_lmem_unmap(void)
 {
 
@@ -312,12 +312,18 @@ pmap_lmem_unmap(void)
 #endif /* !__mips_n64 */
 
 static __inline int
-is_cacheable_page(vm_paddr_t pa, vm_page_t m)
+pmap_pte_cache_bits(vm_paddr_t pa, vm_page_t m)
 {
+	vm_memattr_t ma;
 
-	return ((m->md.pv_flags & PV_MEMATTR_UNCACHEABLE) == 0 &&
-	    is_cacheable_mem(pa));
-
+	ma = pmap_page_get_memattr(m);
+	if (ma == VM_MEMATTR_WRITE_BACK && !is_cacheable_mem(pa))
+		ma = VM_MEMATTR_UNCACHEABLE;
+	return PTE_C(ma);
+}
+#define PMAP_PTE_SET_CACHE_BITS(pte, ps, m) {	\
+	pte &= ~PTE_C_MASK;			\
+	pte |= pmap_pte_cache_bits(pa, m);	\
 }
 
 /*
@@ -359,7 +365,7 @@ pmap_pdpe_to_pde(pd_entry_t *pdpe, vm_of
 	return (pdpe);
 }
 
-static __inline 
+static __inline
 pd_entry_t *pmap_pde(pmap_t pmap, vm_offset_t va)
 {
 
@@ -423,7 +429,7 @@ pmap_steal_memory(vm_size_t size)
  * Bootstrap the system enough to run with virtual memory.  This
  * assumes that the phys_avail array has been initialized.
  */
-static void 
+static void
 pmap_create_kernel_pagetable(void)
 {
 	int i, j;
@@ -486,7 +492,7 @@ void
 pmap_bootstrap(void)
 {
 	int i;
-	int need_local_mappings = 0; 
+	int need_local_mappings = 0;
 
 	/* Sort. */
 again:
@@ -600,7 +606,7 @@ pmap_page_init(vm_page_t m)
 {
 
 	TAILQ_INIT(&m->md.pv_list);
-	m->md.pv_flags = 0;
+	m->md.pv_flags = VM_MEMATTR_DEFAULT << PV_MEMATTR_SHIFT;
 }
 
 /*
@@ -635,8 +641,8 @@ pmap_call_on_active_cpus(pmap_t pmap, vo
 			pmap->pm_asid[cpu].gen = 0;
 	}
 	cpuid = PCPU_GET(cpuid);
-	/* 
-	 * XXX: barrier/locking for active? 
+	/*
+	 * XXX: barrier/locking for active?
 	 *
 	 * Take a snapshot of active here, any further changes are ignored.
 	 * tlb update/invalidate should be harmless on inactive CPUs
@@ -819,7 +825,7 @@ retry:
  * add a wired page to the kva
  */
 void
-pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, int attr)
+pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t ma)
 {
 	pt_entry_t *pte;
 	pt_entry_t opte, npte;
@@ -830,7 +836,7 @@ pmap_kenter_attr(vm_offset_t va, vm_padd
 
 	pte = pmap_pte(kernel_pmap, va);
 	opte = *pte;
-	npte = TLBLO_PA_TO_PFN(pa) | attr | PTE_D | PTE_V | PTE_G;
+	npte = TLBLO_PA_TO_PFN(pa) | PTE_C(ma) | PTE_D | PTE_V | PTE_G;
 	*pte = npte;
 	if (pte_test(&opte, PTE_V) && opte != npte)
 		pmap_update_page(kernel_pmap, va, npte);
@@ -843,7 +849,7 @@ pmap_kenter(vm_offset_t va, vm_paddr_t p
 	KASSERT(is_cacheable_mem(pa),
 		("pmap_kenter: memory at 0x%lx is not cacheable", (u_long)pa));
 
-	pmap_kenter_attr(va, pa, PTE_C_CACHE);
+	pmap_kenter_attr(va, pa, VM_MEMATTR_DEFAULT);
 }
 
 /*
@@ -1144,11 +1150,11 @@ _pmap_allocpte(pmap_t pmap, unsigned pte
 		int segindex = ptepindex >> (SEGSHIFT - PDRSHIFT);
 		int pdeindex = ptepindex & (NPDEPG - 1);
 		vm_page_t pg;
-		
+
 		pdep = &pmap->pm_segtab[segindex];
-		if (*pdep == NULL) { 
+		if (*pdep == NULL) {
 			/* recurse for allocating page dir */
-			if (_pmap_allocpte(pmap, NUPDE + segindex, 
+			if (_pmap_allocpte(pmap, NUPDE + segindex,
 			    flags) == NULL) {
 				/* alloc failed, release current */
 				--m->wire_count;
@@ -1680,7 +1686,7 @@ pmap_try_insert_pv_entry(pmap_t pmap, vm
  * pmap_remove_pte: do the things to unmap a page in a process
  */
 static int
-pmap_remove_pte(struct pmap *pmap, pt_entry_t *ptq, vm_offset_t va, 
+pmap_remove_pte(struct pmap *pmap, pt_entry_t *ptq, vm_offset_t va,
     pd_entry_t pde)
 {
 	pt_entry_t oldpte;
@@ -1864,7 +1870,7 @@ pmap_remove_all(vm_page_t m)
 		PMAP_LOCK(pmap);
 
 		/*
-		 * If it's last mapping writeback all caches from 
+		 * If it's last mapping writeback all caches from
 		 * the page being destroyed
 	 	 */
 		if (TAILQ_NEXT(pv, pv_list) == NULL)
@@ -2030,10 +2036,7 @@ pmap_enter(pmap_t pmap, vm_offset_t va, 
 		newpte |= PTE_W;
 	if (is_kernel_pmap(pmap))
 		newpte |= PTE_G;
-	if (is_cacheable_page(pa, m))
-		newpte |= PTE_C_CACHE;
-	else
-		newpte |= PTE_C_UNCACHED;
+	PMAP_PTE_SET_CACHE_BITS(newpte, pa, m);
 
 	mpte = NULL;
 
@@ -2218,7 +2221,7 @@ static vm_page_t
 pmap_enter_quick_locked(pmap_t pmap, vm_offset_t va, vm_page_t m,
     vm_prot_t prot, vm_page_t mpte)
 {
-	pt_entry_t *pte;
+	pt_entry_t *pte, npte;
 	vm_paddr_t pa;
 
 	KASSERT(va < kmi.clean_sva || va >= kmi.clean_eva ||
@@ -2297,18 +2300,16 @@ pmap_enter_quick_locked(pmap_t pmap, vm_
 	/*
 	 * Now validate mapping with RO protection
 	 */
-	*pte = PTE_RO | TLBLO_PA_TO_PFN(pa) | PTE_V;
+	npte = PTE_RO | TLBLO_PA_TO_PFN(pa) | PTE_V;
 	if ((m->oflags & VPO_UNMANAGED) == 0)
-		*pte |= PTE_MANAGED;
+		npte |= PTE_MANAGED;
 
-	if (is_cacheable_page(pa, m))
-		*pte |= PTE_C_CACHE;
-	else
-		*pte |= PTE_C_UNCACHED;
+	PMAP_PTE_SET_CACHE_BITS(npte, pa, m);
 
 	if (is_kernel_pmap(pmap))
-		*pte |= PTE_G;
+		*pte = npte | PTE_G;
 	else {
+		*pte = npte;
 		/*
 		 * Sync I & D caches.  Do this only if the target pmap
 		 * belongs to the current process.  Otherwise, an
@@ -2649,12 +2650,12 @@ pmap_quick_enter_page(vm_page_t m)
 #else
 	vm_paddr_t pa;
 	struct local_sysmaps *sysm;
-	pt_entry_t *pte;
+	pt_entry_t *pte, npte;
 
 	pa = VM_PAGE_TO_PHYS(m);
 
 	if (MIPS_DIRECT_MAPPABLE(pa)) {
-		if (m->md.pv_flags & PV_MEMATTR_UNCACHEABLE)
+		if (pmap_page_get_memattr(m) != VM_MEMATTR_WRITE_BACK)
 			return (MIPS_PHYS_TO_DIRECT_UNCACHED(pa));
 		else
 			return (MIPS_PHYS_TO_DIRECT(pa));
@@ -2665,8 +2666,9 @@ pmap_quick_enter_page(vm_page_t m)
 	KASSERT(sysm->valid1 == 0, ("pmap_quick_enter_page: PTE busy"));
 
 	pte = pmap_pte(kernel_pmap, sysm->base);
-	*pte = TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G |
-	    (is_cacheable_page(pa, m) ? PTE_C_CACHE : PTE_C_UNCACHED);
+	npte = TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G;
+	PMAP_PTE_SET_CACHE_BITS(npte, pa, m);
+	*pte = npte;
 	sysm->valid1 = 1;
 
 	return (sysm->base);
@@ -3146,26 +3148,26 @@ pmap_is_referenced(vm_page_t m)
  * Use XKPHYS uncached for 64 bit, and KSEG1 where possible for 32 bit.
  */
 void *
-pmap_mapdev(vm_paddr_t pa, vm_size_t size)
+pmap_mapdev_attr(vm_paddr_t pa, vm_size_t size, vm_memattr_t ma)
 {
         vm_offset_t va, tmpva, offset;
 
-	/* 
-	 * KSEG1 maps only first 512M of phys address space. For 
+	/*
+	 * KSEG1 maps only first 512M of phys address space. For
 	 * pa > 0x20000000 we should make proper mapping * using pmap_kenter.
 	 */
-	if (MIPS_DIRECT_MAPPABLE(pa + size - 1))
+	if (MIPS_DIRECT_MAPPABLE(pa + size - 1) && ma == VM_MEMATTR_UNCACHEABLE)
 		return ((void *)MIPS_PHYS_TO_DIRECT_UNCACHED(pa));
 	else {
 		offset = pa & PAGE_MASK;
 		size = roundup(size + offset, PAGE_SIZE);
-        
+
 		va = kva_alloc(size);
 		if (!va)
 			panic("pmap_mapdev: Couldn't alloc kernel virtual memory");
 		pa = trunc_page(pa);
 		for (tmpva = va; size > 0;) {
-			pmap_kenter_attr(tmpva, pa, PTE_C_UNCACHED);
+			pmap_kenter_attr(tmpva, pa, ma);
 			size -= PAGE_SIZE;
 			tmpva += PAGE_SIZE;
 			pa += PAGE_SIZE;
@@ -3175,6 +3177,12 @@ pmap_mapdev(vm_paddr_t pa, vm_size_t siz
 	return ((void *)(va + offset));
 }
 
+void *
+pmap_mapdev(vm_paddr_t pa, vm_size_t size)
+{
+	return pmap_mapdev_attr(pa, size, VM_MEMATTR_UNCACHEABLE);
+}
+
 void
 pmap_unmapdev(vm_offset_t va, vm_size_t size)
 {
@@ -3220,7 +3228,7 @@ retry:
 		 * This may falsely report the given address as
 		 * MINCORE_REFERENCED.  Unfortunately, due to the lack of
 		 * per-PTE reference information, it is impossible to
-		 * determine if the address is MINCORE_REFERENCED.  
+		 * determine if the address is MINCORE_REFERENCED.
 		 */
 		m = PHYS_TO_VM_PAGE(pa);
 		if ((m->aflags & PGA_REFERENCED) != 0)
@@ -3500,7 +3508,7 @@ pmap_kextract(vm_offset_t va)
 	mapped = (va >= MIPS_KSEG2_START || va < MIPS_KSEG2_END);
 #if defined(__mips_n64)
 	mapped = mapped || (va >= MIPS_XKSEG_START || va < MIPS_XKSEG_END);
-#endif 
+#endif
 	/*
 	 * Kernel virtual.
 	 */
@@ -3524,7 +3532,7 @@ pmap_kextract(vm_offset_t va)
 }
 
 
-void 
+void
 pmap_flush_pvcache(vm_page_t m)
 {
 	pv_entry_t pv;
@@ -3551,12 +3559,85 @@ pmap_page_set_memattr(vm_page_t m, vm_me
 	if (TAILQ_FIRST(&m->md.pv_list) != NULL)
 		panic("Can't change memattr on page with existing mappings");
 
-	/*
-	 * The only memattr we support is UNCACHEABLE, translate the (semi-)MI
-	 * representation of that into our internal flag in the page MD struct.
-	 */
-	if (ma == VM_MEMATTR_UNCACHEABLE)
-		m->md.pv_flags |= PV_MEMATTR_UNCACHEABLE;
-	else
-		m->md.pv_flags &= ~PV_MEMATTR_UNCACHEABLE;
+	/* Clean memattr portion of pv_flags */
+	m->md.pv_flags &= ~PV_MEMATTR_MASK;
+	m->md.pv_flags |= (ma << PV_MEMATTR_SHIFT) & PV_MEMATTR_MASK;
+}
+
+static __inline void
+pmap_pte_attr(pt_entry_t *pte, vm_memattr_t ma)
+{
+	u_int npte;
+
+	npte = *(u_int *)pte;
+	npte &= ~PTE_C_MASK;
+	npte |= PTE_C(ma);
+	*pte = npte;
+}
+
+int
+pmap_change_attr(vm_offset_t sva, vm_size_t size, vm_memattr_t ma)
+{
+	pd_entry_t *pde, *pdpe;
+	pt_entry_t *pte;
+	vm_offset_t ova, eva, va, va_next;
+	pmap_t pmap;
+
+	ova = sva;
+	eva = sva + size;
+	if (eva < sva)
+		return (EINVAL);
+
+	pmap = kernel_pmap;
+	PMAP_LOCK(pmap);
+
+	for (; sva < eva; sva = va_next) {
+		pdpe = pmap_segmap(pmap, sva);
+#ifdef __mips_n64
+		if (*pdpe == 0) {
+			va_next = (sva + NBSEG) & ~SEGMASK;
+			if (va_next < sva)
+				va_next = eva;
+			continue;
+		}
+#endif
+		va_next = (sva + NBPDR) & ~PDRMASK;
+		if (va_next < sva)
+			va_next = eva;
+
+		pde = pmap_pdpe_to_pde(pdpe, sva);
+		if (*pde == NULL)
+			continue;
+
+		/*
+		 * Limit our scan to either the end of the va represented
+		 * by the current page table page, or to the end of the
+		 * range being removed.
+		 */
+		if (va_next > eva)
+			va_next = eva;
+
+		va = va_next;
+		for (pte = pmap_pde_to_pte(pde, sva); sva != va_next; pte++,
+		    sva += PAGE_SIZE) {
+			if (!pte_test(pte, PTE_V) || pte_cache_bits(pte) == ma) {
+				if (va != va_next) {
+					pmap_invalidate_range(pmap, va, sva);
+					va = va_next;
+				}
+				continue;
+			}
+			if (va == va_next)
+				va = sva;
+
+			pmap_pte_attr(pte, ma);
+		}
+		if (va != va_next)
+			pmap_invalidate_range(pmap, va, sva);
+	}
+	PMAP_UNLOCK(pmap);
+
+	/* Flush caches to be in the safe side */
+	mips_dcache_wbinv_range(ova, size);
+	return 0;
 }

From owner-svn-src-all@freebsd.org  Wed Dec 28 03:08:00 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 00D6BC94126;
 Wed, 28 Dec 2016 03:08:00 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id CFA681EA4;
 Wed, 28 Dec 2016 03:07:59 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS37x8d051160;
 Wed, 28 Dec 2016 03:07:59 GMT (envelope-from sephe@FreeBSD.org)
Received: (from sephe@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS37wRP051157;
 Wed, 28 Dec 2016 03:07:58 GMT (envelope-from sephe@FreeBSD.org)
Message-Id: <201612280307.uBS37wRP051157@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: sephe set sender to
 sephe@FreeBSD.org using -f
From: Sepherosa Ziehau <sephe@FreeBSD.org>
Date: Wed, 28 Dec 2016 03:07:58 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310651 - head/sys/dev/hyperv/vmbus
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 03:08:00 -0000

Author: sephe
Date: Wed Dec 28 03:07:58 2016
New Revision: 310651
URL: https://svnweb.freebsd.org/changeset/base/310651

Log:
  hyperv/vmbus: Nuke unnecessary critical sections.
  
  MFC after:	1 week
  Sponsored by:	Microsoft
  Differential Revision:	https://reviews.freebsd.org/D8906

Modified:
  head/sys/dev/hyperv/vmbus/vmbus.c
  head/sys/dev/hyperv/vmbus/vmbus_chan.c
  head/sys/dev/hyperv/vmbus/vmbus_var.h

Modified: head/sys/dev/hyperv/vmbus/vmbus.c
==============================================================================
--- head/sys/dev/hyperv/vmbus/vmbus.c	Wed Dec 28 02:55:26 2016	(r310650)
+++ head/sys/dev/hyperv/vmbus/vmbus.c	Wed Dec 28 03:07:58 2016	(r310651)
@@ -1393,7 +1393,7 @@ cleanup:
 		vmbus_xact_ctx_destroy(sc->vmbus_xc);
 		sc->vmbus_xc = NULL;
 	}
-	free(sc->vmbus_chmap, M_DEVBUF);
+	free(__DEVOLATILE(void *, sc->vmbus_chmap), M_DEVBUF);
 	mtx_destroy(&sc->vmbus_prichan_lock);
 	mtx_destroy(&sc->vmbus_chan_lock);
 
@@ -1480,7 +1480,7 @@ vmbus_detach(device_t dev)
 		sc->vmbus_xc = NULL;
 	}
 
-	free(sc->vmbus_chmap, M_DEVBUF);
+	free(__DEVOLATILE(void *, sc->vmbus_chmap), M_DEVBUF);
 	mtx_destroy(&sc->vmbus_prichan_lock);
 	mtx_destroy(&sc->vmbus_chan_lock);
 

Modified: head/sys/dev/hyperv/vmbus/vmbus_chan.c
==============================================================================
--- head/sys/dev/hyperv/vmbus/vmbus_chan.c	Wed Dec 28 02:55:26 2016	(r310650)
+++ head/sys/dev/hyperv/vmbus/vmbus_chan.c	Wed Dec 28 03:07:58 2016	(r310651)
@@ -775,9 +775,7 @@ vmbus_chan_clrchmap_task(void *xchan, in
 {
 	struct vmbus_channel *chan = xchan;
 
-	critical_enter();
 	chan->ch_vmbus->vmbus_chmap[chan->ch_id] = NULL;
-	critical_exit();
 }
 
 static void
@@ -1308,15 +1306,17 @@ vmbus_chan_pollcfg_task(void *xarg, int 
 	chan->ch_poll_flags = poll_flags;
 
 	/*
-	 * Disable interrupt from the RX bufring (TX bufring does not
-	 * generate interrupt to VM), and disconnect this channel from
-	 * the channel map to make sure that ISR can not enqueue this
-	 * channel task anymore.
+	 * Disconnect this channel from the channel map to make sure that
+	 * the RX bufring interrupt enabling bit can not be touched, and
+	 * ISR can not enqueue this channel task anymore.  THEN, disable
+	 * interrupt from the RX bufring (TX bufring does not generate
+	 * interrupt to VM).
+	 *
+	 * NOTE: order is critical.
 	 */
-	critical_enter();
-	vmbus_rxbr_intr_mask(&chan->ch_rxbr);
 	chan->ch_vmbus->vmbus_chmap[chan->ch_id] = NULL;
-	critical_exit();
+	__compiler_membar();
+	vmbus_rxbr_intr_mask(&chan->ch_rxbr);
 
 	/*
 	 * NOTE:
@@ -1380,11 +1380,9 @@ vmbus_chan_polldis_task(void *xchan, int
 	 * Plug this channel back to the channel map and unmask
 	 * the RX bufring interrupt.
 	 */
-	critical_enter();
 	chan->ch_vmbus->vmbus_chmap[chan->ch_id] = chan;
 	__compiler_membar();
 	vmbus_rxbr_intr_unmask(&chan->ch_rxbr);
-	critical_exit();
 
 	/*
 	 * Kick start the interrupt task, just in case unmasking

Modified: head/sys/dev/hyperv/vmbus/vmbus_var.h
==============================================================================
--- head/sys/dev/hyperv/vmbus/vmbus_var.h	Wed Dec 28 02:55:26 2016	(r310650)
+++ head/sys/dev/hyperv/vmbus/vmbus_var.h	Wed Dec 28 03:07:58 2016	(r310651)
@@ -93,7 +93,7 @@ struct vmbus_softc {
 
 	u_long			*vmbus_rx_evtflags;
 						/* compat evtflgs from host */
-	struct vmbus_channel	**vmbus_chmap;
+	struct vmbus_channel *volatile *vmbus_chmap;
 	struct vmbus_xact_ctx	*vmbus_xc;
 	struct vmbus_pcpu_data	vmbus_pcpu[MAXCPU];
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 03:20:01 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2BC37C944D2;
 Wed, 28 Dec 2016 03:20:01 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id EF5AA18D6;
 Wed, 28 Dec 2016 03:20:00 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS3K0mk055782;
 Wed, 28 Dec 2016 03:20:00 GMT (envelope-from sephe@FreeBSD.org)
Received: (from sephe@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS3K00r055781;
 Wed, 28 Dec 2016 03:20:00 GMT (envelope-from sephe@FreeBSD.org)
Message-Id: <201612280320.uBS3K00r055781@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: sephe set sender to
 sephe@FreeBSD.org using -f
From: Sepherosa Ziehau <sephe@FreeBSD.org>
Date: Wed, 28 Dec 2016 03:20:00 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310652 - head/sys/dev/hyperv/netvsc
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 03:20:01 -0000

Author: sephe
Date: Wed Dec 28 03:19:59 2016
New Revision: 310652
URL: https://svnweb.freebsd.org/changeset/base/310652

Log:
  hyperv/hn: Consolidate hn_{suspend,resume}
  
  MFC after:	1 week
  Sponsored by:	Microsoft
  Differential Revision:	https://reviews.freebsd.org/D8907

Modified:
  head/sys/dev/hyperv/netvsc/if_hn.c

Modified: head/sys/dev/hyperv/netvsc/if_hn.c
==============================================================================
--- head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 03:07:58 2016	(r310651)
+++ head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 03:19:59 2016	(r310652)
@@ -2367,9 +2367,6 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, 
 			break;
 		}
 
-		/* Disable polling. */
-		hn_polling(sc, 0);
-
 		/*
 		 * Suspend this interface before the synthetic parts
 		 * are ripped.
@@ -2415,13 +2412,6 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, 
 		 */
 		hn_resume(sc);
 
-		/*
-		 * Re-enable polling if this interface is running and
-		 * the polling is requested.
-		 */
-		if ((ifp->if_drv_flags & IFF_DRV_RUNNING) && sc->hn_pollhz > 0)
-			hn_polling(sc, sc->hn_pollhz);
-
 		HN_UNLOCK(sc);
 		break;
 
@@ -4900,6 +4890,9 @@ static void
 hn_suspend(struct hn_softc *sc)
 {
 
+	/* Disable polling. */
+	hn_polling(sc, 0);
+
 	if (sc->hn_ifp->if_drv_flags & IFF_DRV_RUNNING)
 		hn_suspend_data(sc);
 	hn_suspend_mgmt(sc);
@@ -4992,6 +4985,13 @@ hn_resume(struct hn_softc *sc)
 	if (sc->hn_ifp->if_drv_flags & IFF_DRV_RUNNING)
 		hn_resume_data(sc);
 	hn_resume_mgmt(sc);
+
+	/*
+	 * Re-enable polling if this interface is running and
+	 * the polling is requested.
+	 */
+	if ((sc->hn_ifp->if_drv_flags & IFF_DRV_RUNNING) && sc->hn_pollhz > 0)
+		hn_polling(sc, sc->hn_pollhz);
 }
 
 static void 

From owner-svn-src-all@freebsd.org  Wed Dec 28 03:40:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 058A4C94B91;
 Wed, 28 Dec 2016 03:40:56 +0000 (UTC)
 (envelope-from jhibbits@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B0E62179A;
 Wed, 28 Dec 2016 03:40:55 +0000 (UTC)
 (envelope-from jhibbits@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS3esA4064784;
 Wed, 28 Dec 2016 03:40:54 GMT (envelope-from jhibbits@FreeBSD.org)
Received: (from jhibbits@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS3esDp064783;
 Wed, 28 Dec 2016 03:40:54 GMT (envelope-from jhibbits@FreeBSD.org)
Message-Id: <201612280340.uBS3esDp064783@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: jhibbits set sender to
 jhibbits@FreeBSD.org using -f
From: Justin Hibbits <jhibbits@FreeBSD.org>
Date: Wed, 28 Dec 2016 03:40:54 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310653 - head/sys/powerpc/powerpc
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 03:40:56 -0000

Author: jhibbits
Date: Wed Dec 28 03:40:54 2016
New Revision: 310653
URL: https://svnweb.freebsd.org/changeset/base/310653

Log:
  Restrict SLB handler to powerpc64 and AIM
  
  Only Book-S has SLBs.  Book-E does not, so restrict it to only Book-S (which we
  call AIM).

Modified:
  head/sys/powerpc/powerpc/trap.c

Modified: head/sys/powerpc/powerpc/trap.c
==============================================================================
--- head/sys/powerpc/powerpc/trap.c	Wed Dec 28 03:19:59 2016	(r310652)
+++ head/sys/powerpc/powerpc/trap.c	Wed Dec 28 03:40:54 2016	(r310653)
@@ -88,7 +88,7 @@ static int	fix_unaligned(struct thread *
 static int	handle_onfault(struct trapframe *frame);
 static void	syscall(struct trapframe *frame);
 
-#ifdef __powerpc64__
+#if defined(__powerpc64__) && defined(AIM)
        void	handle_kernel_slb_spill(int, register_t, register_t);
 static int	handle_user_slb_spill(pmap_t pm, vm_offset_t addr);
 extern int	n_slbs;
@@ -208,7 +208,7 @@ trap(struct trapframe *frame)
 			ucode = TRAP_TRACE;
 			break;
 
-#ifdef __powerpc64__
+#if defined(__powerpc64__) && defined(AIM)
 		case EXC_ISE:
 		case EXC_DSE:
 			if (handle_user_slb_spill(&p->p_vmspace->vm_pmap,
@@ -347,7 +347,7 @@ trap(struct trapframe *frame)
 			}
 			break;
 #endif
-#ifdef __powerpc64__
+#if defined(__powerpc64__) && defined(AIM)
 		case EXC_DSE:
 			if ((frame->dar & SEGMENT_MASK) == USER_ADDR) {
 				__asm __volatile ("slbmte %0, %1" ::
@@ -578,7 +578,7 @@ syscall(struct trapframe *frame)
 	td = curthread;
 	td->td_frame = frame;
 
-#ifdef __powerpc64__
+#if defined(__powerpc64__) && defined(AIM)
 	/*
 	 * Speculatively restore last user SLB segment, which we know is
 	 * invalid already, since we are likely to do copyin()/copyout().
@@ -591,7 +591,7 @@ syscall(struct trapframe *frame)
 	syscallret(td, error, &sa);
 }
 
-#ifdef __powerpc64__
+#if defined(__powerpc64__) && defined(AIM)
 /* Handle kernel SLB faults -- runs in real mode, all seat belts off */
 void
 handle_kernel_slb_spill(int type, register_t dar, register_t srr0)

From owner-svn-src-all@freebsd.org  Wed Dec 28 03:56:26 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8AA44C94F8F;
 Wed, 28 Dec 2016 03:56:26 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 4C1E81E7A;
 Wed, 28 Dec 2016 03:56:26 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS3uPvR072683;
 Wed, 28 Dec 2016 03:56:25 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS3uP9R072681;
 Wed, 28 Dec 2016 03:56:25 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280356.uBS3uP9R072681@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 03:56:25 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310654 - in head: tools/build/mk usr.sbin/bsnmpd/bsnmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 03:56:26 -0000

Author: ngie
Date: Wed Dec 28 03:56:25 2016
New Revision: 310654
URL: https://svnweb.freebsd.org/changeset/base/310654

Log:
  Install snmpmod.3 as all of the bsnmpd APIs it documents
  
  MFC after:	3 days

Modified:
  head/tools/build/mk/OptionalObsoleteFiles.inc
  head/usr.sbin/bsnmpd/bsnmpd/Makefile

Modified: head/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 03:40:54 2016	(r310653)
+++ head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 03:56:25 2016	(r310654)
@@ -782,22 +782,119 @@ OLD_FILES+=usr/share/man/man1/bsnmpget.1
 OLD_FILES+=usr/share/man/man1/bsnmpset.1.gz
 OLD_FILES+=usr/share/man/man1/bsnmpwalk.1.gz
 OLD_FILES+=usr/share/man/man1/gensnmptree.1.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_INT.3.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_INT_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_INT_LINK_INDEX.3.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_OID.3.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_OID_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/FIND_OBJECT_OID_LINK_INDEX.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_INT.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_INT_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_INT_LINK_INDEX.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_OID.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_OID_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/INSERT_OBJECT_OID_LINK_INDEX.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_INT.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_INT_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_INT_LINK_INDEX.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_OID.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_OID_LINK.3.gz
+OLD_FILES+=usr/share/man/man3/NEXT_OBJECT_OID_LINK_INDEX.3.gz
 OLD_FILES+=usr/share/man/man3/asn1.3.gz
 OLD_FILES+=usr/share/man/man3/bsnmpagent.3.gz
 OLD_FILES+=usr/share/man/man3/bsnmpclient.3.gz
+OLD_FILES+=usr/share/man/man3/bsnmpd_get_target_stats.3.gz
+OLD_FILES+=usr/share/man/man3/bsnmpd_get_usm_stats.3.gz
+OLD_FILES+=usr/share/man/man3/bsnmpd_reset_usm_stats.3.gz
 OLD_FILES+=usr/share/man/man3/bsnmplib.3.gz
+OLD_FILES+=usr/share/man/man3/buf_alloc.3.gz
+OLD_FILES+=usr/share/man/man3/buf_size.3.gz
+OLD_FILES+=usr/share/man/man3/comm_define.3.gz
+OLD_FILES+=usr/share/man/man3/community.3.gz
+OLD_FILES+=usr/share/man/man3/fd_deselect.3.gz
+OLD_FILES+=usr/share/man/man3/fd_resume.3.gz
+OLD_FILES+=usr/share/man/man3/fd_select.3.gz
+OLD_FILES+=usr/share/man/man3/fd_suspend.3.gz
+OLD_FILES+=usr/share/man/man3/get_ticks.3.gz
+OLD_FILES+=usr/share/man/man3/index_append.3.gz
+OLD_FILES+=usr/share/man/man3/index_append_off.3.gz
+OLD_FILES+=usr/share/man/man3/index_compare.3.gz
+OLD_FILES+=usr/share/man/man3/index_compare_off.3.gz
+OLD_FILES+=usr/share/man/man3/index_decode.3.gz
+OLD_FILES+=usr/share/man/man3/ip_commit.3.gz
+OLD_FILES+=usr/share/man/man3/ip_get.3.gz
+OLD_FILES+=usr/share/man/man3/ip_rollback.3.gz
+OLD_FILES+=usr/share/man/man3/ip_save.3.gz
+OLD_FILES+=usr/share/man/man3/or_register.3.gz
+OLD_FILES+=usr/share/man/man3/or_unregister.3.gz
+OLD_FILES+=usr/share/man/man3/oid_commit.3.gz
+OLD_FILES+=usr/share/man/man3/oid_get.3.gz
+OLD_FILES+=usr/share/man/man3/oid_rollback.3.gz
+OLD_FILES+=usr/share/man/man3/oid_save.3.gz
+OLD_FILES+=usr/share/man/man3/oid_usmNotInTimeWindows.3.gz
+OLD_FILES+=usr/share/man/man3/oid_usmUnknownEngineIDs.3.gz
+OLD_FILES+=usr/share/man/man3/oid_zeroDotZero.3.gz
+OLD_FILES+=usr/share/man/man3/reqid_allocate.3.gz
+OLD_FILES+=usr/share/man/man3/reqid_base.3.gz
+OLD_FILES+=usr/share/man/man3/reqid_istype.3.gz
+OLD_FILES+=usr/share/man/man3/reqid_next.3.gz
+OLD_FILES+=usr/share/man/man3/reqid_type.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_atm.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_bridge.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_hast.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_hostres.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_input_finish.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_input_start.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_lm75.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_mibII.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_netgraph.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_output.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_pdu_auth_access.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_send_port.3.gz
+OLD_FILES+=usr/share/man/man3/snmp_send_trap.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_target.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_usm.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_vacm.3.gz
 OLD_FILES+=usr/share/man/man3/snmp_wlan.3.gz
+OLD_FILES+=usr/share/man/man3/snmpd_target_stat.3.gz
+OLD_FILES+=usr/share/man/man3/snmpd_usmstats.3.gz
 OLD_FILES+=usr/share/man/man3/snmpmod.3.gz
+OLD_FILES+=usr/share/man/man3/start_tick.3.gz
+OLD_FILES+=usr/share/man/man3/string_commit.3.gz
+OLD_FILES+=usr/share/man/man3/string_free.3.gz
+OLD_FILES+=usr/share/man/man3/string_get.3.gz
+OLD_FILES+=usr/share/man/man3/string_get_max.3.gz
+OLD_FILES+=usr/share/man/man3/string_rollback.3.gz
+OLD_FILES+=usr/share/man/man3/string_save.3.gz
+OLD_FILES+=usr/share/man/man3/systemg.3.gz
+OLD_FILES+=usr/share/man/man3/this_tick.3.gz
+OLD_FILES+=usr/share/man/man3/timer_start.3.gz
+OLD_FILES+=usr/share/man/man3/timer_start_repeat.3.gz
+OLD_FILES+=usr/share/man/man3/timer_stop.3.gz
+OLD_FILES+=usr/share/man/man3/target_activate_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_delete_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_delete_notify.3.gz
+OLD_FILES+=usr/share/man/man3/target_delete_param.3.gz
+OLD_FILES+=usr/share/man/man3/target_first_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_first_notify.3.gz
+OLD_FILES+=usr/share/man/man3/target_first_param.3.gz
+OLD_FILES+=usr/share/man/man3/target_flush_all.3.gz
+OLD_FILES+=usr/share/man/man3/target_next_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_next_notify.3.gz
+OLD_FILES+=usr/share/man/man3/target_next_param.3.gz
+OLD_FILES+=usr/share/man/man3/target_new_address.3.gz
+OLD_FILES+=usr/share/man/man3/target_new_notify.3.gz
+OLD_FILES+=usr/share/man/man3/target_new_param.3.gz
+OLD_FILES+=usr/share/man/man3/target_notify.3.gz
+OLD_FILES+=usr/share/man/man3/target_param.3.gz
+OLD_FILES+=usr/share/man/man3/usm_delete_user.3.gz
+OLD_FILES+=usr/share/man/man3/usm_find_user.3.gz
+OLD_FILES+=usr/share/man/man3/usm_first_user.3.gz
+OLD_FILES+=usr/share/man/man3/usm_flush_users.3.gz
+OLD_FILES+=usr/share/man/man3/usm_next_user.3.gz
+OLD_FILES+=usr/share/man/man3/usm_new_user.3.gz
+OLD_FILES+=usr/share/man/man3/usm_user.3.gz
 OLD_FILES+=usr/share/snmp/defs/atm_freebsd.def
 OLD_FILES+=usr/share/snmp/defs/atm_tree.def
 OLD_FILES+=usr/share/snmp/defs/bridge_tree.def

Modified: head/usr.sbin/bsnmpd/bsnmpd/Makefile
==============================================================================
--- head/usr.sbin/bsnmpd/bsnmpd/Makefile	Wed Dec 28 03:40:54 2016	(r310653)
+++ head/usr.sbin/bsnmpd/bsnmpd/Makefile	Wed Dec 28 03:56:25 2016	(r310654)
@@ -15,8 +15,107 @@ XSYM=	snmpMIB begemotSnmpdModuleTable be
 	begemotSnmpdTransUdp begemotSnmpdTransLsock begemotSnmpdLocalPortTable \
 	freeBSD freeBSDVersion
 CLEANFILES= oid.h tree.c tree.h
+
 MAN=	bsnmpd.1 snmpmod.3
 
+MLINKS+=	snmpmod.3 FIND_OBJECT_INT.3
+MLINKS+=	snmpmod.3 FIND_OBJECT_INT_LINK.3
+MLINKS+=	snmpmod.3 FIND_OBJECT_INT_LINK_INDEX.3
+MLINKS+=	snmpmod.3 FIND_OBJECT_OID.3
+MLINKS+=	snmpmod.3 FIND_OBJECT_OID_LINK.3
+MLINKS+=	snmpmod.3 FIND_OBJECT_OID_LINK_INDEX.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_INT.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_INT_LINK.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_INT_LINK_INDEX.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_OID.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_OID_LINK.3
+MLINKS+=	snmpmod.3 INSERT_OBJECT_OID_LINK_INDEX.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_INT.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_INT_LINK.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_INT_LINK_INDEX.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_OID.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_OID_LINK.3
+MLINKS+=	snmpmod.3 NEXT_OBJECT_OID_LINK_INDEX.3
+MLINKS+=	snmpmod.3 bsnmpd_get_target_stats.3
+MLINKS+=	snmpmod.3 bsnmpd_get_usm_stats.3
+MLINKS+=	snmpmod.3 bsnmpd_reset_usm_stats.3
+MLINKS+=	snmpmod.3 buf_alloc.3
+MLINKS+=	snmpmod.3 buf_size.3
+MLINKS+=	snmpmod.3 comm_define.3
+MLINKS+=	snmpmod.3 community.3
+MLINKS+=	snmpmod.3 fd_deselect.3
+MLINKS+=	snmpmod.3 fd_resume.3
+MLINKS+=	snmpmod.3 fd_select.3
+MLINKS+=	snmpmod.3 fd_suspend.3
+MLINKS+=	snmpmod.3 get_ticks.3
+MLINKS+=	snmpmod.3 index_append.3
+MLINKS+=	snmpmod.3 index_append_off.3
+MLINKS+=	snmpmod.3 index_compare.3
+MLINKS+=	snmpmod.3 index_compare_off.3
+MLINKS+=	snmpmod.3 index_decode.3
+MLINKS+=	snmpmod.3 ip_commit.3
+MLINKS+=	snmpmod.3 ip_get.3
+MLINKS+=	snmpmod.3 ip_rollback.3
+MLINKS+=	snmpmod.3 ip_save.3
+MLINKS+=	snmpmod.3 or_register.3
+MLINKS+=	snmpmod.3 or_unregister.3
+MLINKS+=	snmpmod.3 oid_commit.3
+MLINKS+=	snmpmod.3 oid_get.3
+MLINKS+=	snmpmod.3 oid_rollback.3
+MLINKS+=	snmpmod.3 oid_save.3
+MLINKS+=	snmpmod.3 oid_usmNotInTimeWindows.3
+MLINKS+=	snmpmod.3 oid_usmUnknownEngineIDs.3
+MLINKS+=	snmpmod.3 oid_zeroDotZero.3
+MLINKS+=	snmpmod.3 reqid_allocate.3
+MLINKS+=	snmpmod.3 reqid_base.3
+MLINKS+=	snmpmod.3 reqid_istype.3
+MLINKS+=	snmpmod.3 reqid_next.3
+MLINKS+=	snmpmod.3 reqid_type.3
+MLINKS+=	snmpmod.3 snmp_input_finish.3
+MLINKS+=	snmpmod.3 snmp_input_start.3
+MLINKS+=	snmpmod.3 snmp_output.3
+MLINKS+=	snmpmod.3 snmp_pdu_auth_access.3
+MLINKS+=	snmpmod.3 snmp_send_port.3
+MLINKS+=	snmpmod.3 snmp_send_trap.3
+MLINKS+=	snmpmod.3 snmpd_target_stat.3
+MLINKS+=	snmpmod.3 snmpd_usmstats.3
+MLINKS+=	snmpmod.3 start_tick.3
+MLINKS+=	snmpmod.3 string_commit.3
+MLINKS+=	snmpmod.3 string_free.3
+MLINKS+=	snmpmod.3 string_get.3
+MLINKS+=	snmpmod.3 string_get_max.3
+MLINKS+=	snmpmod.3 string_rollback.3
+MLINKS+=	snmpmod.3 string_save.3
+MLINKS+=	snmpmod.3 systemg.3
+MLINKS+=	snmpmod.3 this_tick.3
+MLINKS+=	snmpmod.3 timer_start.3
+MLINKS+=	snmpmod.3 timer_start_repeat.3
+MLINKS+=	snmpmod.3 timer_stop.3
+MLINKS+=	snmpmod.3 target_activate_address.3
+MLINKS+=	snmpmod.3 target_address.3
+MLINKS+=	snmpmod.3 target_delete_address.3
+MLINKS+=	snmpmod.3 target_delete_notify.3
+MLINKS+=	snmpmod.3 target_delete_param.3
+MLINKS+=	snmpmod.3 target_first_address.3
+MLINKS+=	snmpmod.3 target_first_notify.3
+MLINKS+=	snmpmod.3 target_first_param.3
+MLINKS+=	snmpmod.3 target_flush_all.3
+MLINKS+=	snmpmod.3 target_next_address.3
+MLINKS+=	snmpmod.3 target_next_notify.3
+MLINKS+=	snmpmod.3 target_next_param.3
+MLINKS+=	snmpmod.3 target_new_address.3
+MLINKS+=	snmpmod.3 target_new_notify.3
+MLINKS+=	snmpmod.3 target_new_param.3
+MLINKS+=	snmpmod.3 target_notify.3
+MLINKS+=	snmpmod.3 target_param.3
+MLINKS+=	snmpmod.3 usm_delete_user.3
+MLINKS+=	snmpmod.3 usm_find_user.3
+MLINKS+=	snmpmod.3 usm_first_user.3
+MLINKS+=	snmpmod.3 usm_flush_users.3
+MLINKS+=	snmpmod.3 usm_next_user.3
+MLINKS+=	snmpmod.3 usm_new_user.3
+MLINKS+=	snmpmod.3 usm_user.3
+
 FILESGROUPS= BMIBS DEFS
 
 BMIBS=	FOKUS-MIB.txt BEGEMOT-MIB.txt BEGEMOT-SNMPD.txt

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:29:11 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 806EDC90E44;
 Wed, 28 Dec 2016 04:29:11 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 5AF551022;
 Wed, 28 Dec 2016 04:29:11 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4TANU085326;
 Wed, 28 Dec 2016 04:29:10 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4TA1W085321;
 Wed, 28 Dec 2016 04:29:10 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280429.uBS4TA1W085321@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:29:10 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310655 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:29:11 -0000

Author: ngie
Date: Wed Dec 28 04:29:09 2016
New Revision: 310655
URL: https://svnweb.freebsd.org/changeset/base/310655

Log:
  Fix bsnmpd sending/receiving with multi-homed configurations or INADDR_ANY used
  as the listening address in snmpd_input(..)
  
  Stash the IPv4 address of the receiver via the recv(..) callback and use it in
  the send(..) callback for the transport by specifying IP_SENDSRCADDR for the
  control message type.
  
  Add sendmsg logic to the UDP transport's send(..) callback and use the
  respective send(..) callback for the transport instead of calling sendto in
  snmpd_input(..).
  
  MFC after:      3 weeks
  Obtained from:  Isilon OneFS (^/onefs/branches/BR_8_0_0_DEV@r507595)
  Submitted by:   Thor Steingrimsson <thor.steingrimsson@isilon.com>
  Sponsored by:   Dell EMC Isilon

Modified:
  head/contrib/bsnmp/snmpd/main.c
  head/contrib/bsnmp/snmpd/snmpd.h
  head/contrib/bsnmp/snmpd/trans_lsock.c
  head/contrib/bsnmp/snmpd/trans_udp.c
  head/contrib/bsnmp/snmpd/trans_udp.h

Modified: head/contrib/bsnmp/snmpd/main.c
==============================================================================
--- head/contrib/bsnmp/snmpd/main.c	Wed Dec 28 03:56:25 2016	(r310654)
+++ head/contrib/bsnmp/snmpd/main.c	Wed Dec 28 04:29:09 2016	(r310655)
@@ -1040,10 +1040,8 @@ snmpd_input(struct port_input *pi, struc
 #ifdef USE_TCPWRAPPERS
 	char client[16];
 #endif
-	struct msghdr msg;
-	struct iovec iov[1];
 
-	ret = tport->transport->vtab->recv(pi);
+	ret = tport->transport->vtab->recv(tport, pi);
 	if (ret == -1)
 		return (-1);
 
@@ -1186,21 +1184,15 @@ snmpd_input(struct port_input *pi, struc
 	    sndbuf, &sndlen, "SNMP", ierr, vi, NULL);
 
 	if (ferr == SNMPD_INPUT_OK) {
-		msg.msg_name = pi->peer;
-		msg.msg_namelen = pi->peerlen;
-		msg.msg_iov = iov;
-		msg.msg_iovlen = 1;
-		msg.msg_flags = 0;
-		iov[0].iov_base = sndbuf;
-		iov[0].iov_len = sndlen;
-
-		slen = sendmsg(pi->fd, &msg, 0);
+		slen = tport->transport->vtab->send(tport, sndbuf, sndlen,
+		    pi->peer, pi->peerlen);
 		if (slen == -1)
-			syslog(LOG_ERR, "sendmsg: %m");
+			syslog(LOG_ERR, "send*: %m");
 		else if ((size_t)slen != sndlen)
-			syslog(LOG_ERR, "sendmsg: short write %zu/%zu",
-			    sndlen, (size_t)slen);
+			syslog(LOG_ERR, "send*: short write %zu/%zu", sndlen,
+			    (size_t)slen);
 	}
+
 	snmp_pdu_free(&pdu);
 	free(sndbuf);
 	snmp_input_consume(pi);

Modified: head/contrib/bsnmp/snmpd/snmpd.h
==============================================================================
--- head/contrib/bsnmp/snmpd/snmpd.h	Wed Dec 28 03:56:25 2016	(r310654)
+++ head/contrib/bsnmp/snmpd/snmpd.h	Wed Dec 28 04:29:09 2016	(r310655)
@@ -193,7 +193,7 @@ struct transport_def {
 
 	ssize_t		(*send)(struct tport *, const u_char *, size_t,
 			    const struct sockaddr *, size_t);
-	ssize_t         (*recv)(struct port_input *);
+	ssize_t         (*recv)(struct tport *, struct port_input *);
 };
 struct transport {
 	struct asn_oid	index;		/* transport table index */

Modified: head/contrib/bsnmp/snmpd/trans_lsock.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_lsock.c	Wed Dec 28 03:56:25 2016	(r310654)
+++ head/contrib/bsnmp/snmpd/trans_lsock.c	Wed Dec 28 04:29:09 2016	(r310655)
@@ -59,7 +59,7 @@ static void lsock_close_port(struct tpor
 static int lsock_init_port(struct tport *);
 static ssize_t lsock_send(struct tport *, const u_char *, size_t,
     const struct sockaddr *, size_t);
-static ssize_t lsock_recv(struct port_input *);
+static ssize_t lsock_recv(struct tport *, struct port_input *);
 
 /* exported */
 const struct transport_def lsock_trans = {
@@ -444,7 +444,7 @@ check_priv_stream(struct port_input *pi)
  * Receive something
  */
 static ssize_t
-lsock_recv(struct port_input *pi)
+lsock_recv(struct tport *tp __unused, struct port_input *pi)
 {
 	struct msghdr msg;
 	struct iovec iov[1];

Modified: head/contrib/bsnmp/snmpd/trans_udp.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_udp.c	Wed Dec 28 03:56:25 2016	(r310654)
+++ head/contrib/bsnmp/snmpd/trans_udp.c	Wed Dec 28 04:29:09 2016	(r310655)
@@ -55,7 +55,7 @@ static void udp_close_port(struct tport 
 static int udp_init_port(struct tport *);
 static ssize_t udp_send(struct tport *, const u_char *, size_t,
     const struct sockaddr *, size_t);
-static ssize_t udp_recv(struct port_input *);
+static ssize_t udp_recv(struct tport *, struct port_input *);
 
 /* exported */
 const struct transport_def udp_trans = {
@@ -217,8 +217,30 @@ udp_send(struct tport *tp, const u_char 
     const struct sockaddr *addr, size_t addrlen)
 {
 	struct udp_port *p = (struct udp_port *)tp;
+	struct cmsghdr *cmsg;
+	struct in_addr *src_addr;
+	struct msghdr msg;
+	char cbuf[CMSG_SPACE(sizeof(struct in_addr))];
+	struct iovec iov;
 
-	return (sendto(p->input.fd, buf, len, 0, addr, addrlen));
+	iov.iov_base = __DECONST(void*, buf);
+	iov.iov_len = len;
+
+	msg.msg_iov = &iov;
+	msg.msg_iovlen = 1;
+	msg.msg_name = __DECONST(void *, addr);
+	msg.msg_namelen = addrlen;
+	msg.msg_control = cbuf;
+	msg.msg_controllen = sizeof(cbuf);
+
+	cmsg = CMSG_FIRSTHDR(&msg);
+	cmsg->cmsg_level = IPPROTO_IP;
+	cmsg->cmsg_type = IP_SENDSRCADDR;
+	cmsg->cmsg_len = CMSG_LEN(sizeof(struct in_addr));
+	src_addr = (struct in_addr *)(void*)CMSG_DATA(cmsg);
+	memcpy(src_addr, &p->recv_addr, sizeof(struct in_addr));
+
+	return (sendmsg(p->input.fd, &msg, 0));
 }
 
 static void
@@ -309,8 +331,9 @@ recv_dgram(struct port_input *pi, struct
  * Receive something
  */
 static ssize_t
-udp_recv(struct port_input *pi)
+udp_recv(struct tport *tp, struct port_input *pi)
 {
+	struct udp_port *p = (struct udp_port *)tp;
 	struct in_addr *laddr;
 	struct msghdr msg;
 	char cbuf[CMSG_SPACE(sizeof(struct in_addr))];
@@ -330,6 +353,8 @@ udp_recv(struct port_input *pi)
 
 	ret = recv_dgram(pi, laddr);
 
+	memcpy(&p->recv_addr, laddr, sizeof(struct in_addr));
+
 	if (laddr->s_addr == INADDR_ANY) {
 		msg.msg_control = NULL;
 		msg.msg_controllen = 0;

Modified: head/contrib/bsnmp/snmpd/trans_udp.h
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_udp.h	Wed Dec 28 03:56:25 2016	(r310654)
+++ head/contrib/bsnmp/snmpd/trans_udp.h	Wed Dec 28 04:29:09 2016	(r310655)
@@ -39,6 +39,7 @@ struct udp_port {
 	struct port_input input;	/* common input stuff */
 
 	struct sockaddr_in ret;		/* the return address */
+	struct in_addr recv_addr;	/* the address the request was sent to */
 };
 
 /* argument for open call */

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:31:09 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1E546C90F0B;
 Wed, 28 Dec 2016 04:31:09 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E21DA1239;
 Wed, 28 Dec 2016 04:31:08 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4V8PD088303;
 Wed, 28 Dec 2016 04:31:08 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4V8hA088302;
 Wed, 28 Dec 2016 04:31:08 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280431.uBS4V8hA088302@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:31:08 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310656 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:31:09 -0000

Author: ngie
Date: Wed Dec 28 04:31:07 2016
New Revision: 310656
URL: https://svnweb.freebsd.org/changeset/base/310656

Log:
  style(9): sort alignment in udp_recv(..)
  
  MFC after:	3 weeks

Modified:
  head/contrib/bsnmp/snmpd/trans_udp.c

Modified: head/contrib/bsnmp/snmpd/trans_udp.c
==============================================================================
--- head/contrib/bsnmp/snmpd/trans_udp.c	Wed Dec 28 04:29:09 2016	(r310655)
+++ head/contrib/bsnmp/snmpd/trans_udp.c	Wed Dec 28 04:31:07 2016	(r310656)
@@ -334,10 +334,10 @@ static ssize_t
 udp_recv(struct tport *tp, struct port_input *pi)
 {
 	struct udp_port *p = (struct udp_port *)tp;
+	struct cmsghdr *cmsgp;
 	struct in_addr *laddr;
 	struct msghdr msg;
 	char cbuf[CMSG_SPACE(sizeof(struct in_addr))];
-	struct cmsghdr *cmsgp;
 	ssize_t ret;
 
 	memset(cbuf, 0, sizeof(cbuf));

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:35:54 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0DC6FC910E0;
 Wed, 28 Dec 2016 04:35:54 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A9EE9164F;
 Wed, 28 Dec 2016 04:35:53 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4Zqhk089214;
 Wed, 28 Dec 2016 04:35:52 GMT (envelope-from sephe@FreeBSD.org)
Received: (from sephe@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4Zqk3089213;
 Wed, 28 Dec 2016 04:35:52 GMT (envelope-from sephe@FreeBSD.org)
Message-Id: <201612280435.uBS4Zqk3089213@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: sephe set sender to
 sephe@FreeBSD.org using -f
From: Sepherosa Ziehau <sephe@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:35:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310657 - head/sys/dev/hyperv/netvsc
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:35:54 -0000

Author: sephe
Date: Wed Dec 28 04:35:52 2016
New Revision: 310657
URL: https://svnweb.freebsd.org/changeset/base/310657

Log:
  hyperv/hn: Function renaming; no functional changes.
  
  MFC after:	1 week
  Sponsored by:	Microsoft
  Differential Revision:	https://reviews.freebsd.org/D8908

Modified:
  head/sys/dev/hyperv/netvsc/if_hn.c

Modified: head/sys/dev/hyperv/netvsc/if_hn.c
==============================================================================
--- head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 04:31:07 2016	(r310656)
+++ head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 04:35:52 2016	(r310657)
@@ -333,7 +333,7 @@ static void			hn_link_status(struct hn_s
 static int			hn_create_rx_data(struct hn_softc *, int);
 static void			hn_destroy_rx_data(struct hn_softc *);
 static int			hn_check_iplen(const struct mbuf *, int);
-static int			hn_set_rxfilter(struct hn_softc *);
+static int			hn_rxfilter_config(struct hn_softc *);
 #ifndef RSS
 static int			hn_rss_reconfig(struct hn_softc *);
 #endif
@@ -684,7 +684,7 @@ do {							\
 #endif	/* INET6 || INET */
 
 static int
-hn_set_rxfilter(struct hn_softc *sc)
+hn_rxfilter_config(struct hn_softc *sc)
 {
 	struct ifnet *ifp = sc->hn_ifp;
 	uint32_t filter;
@@ -2431,7 +2431,7 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, 
 				 * reply.
 				 */
 				HN_NO_SLEEPING(sc);
-				hn_set_rxfilter(sc);
+				hn_rxfilter_config(sc);
 				HN_SLEEPING_OK(sc);
 			} else {
 				hn_init_locked(sc);
@@ -2508,7 +2508,7 @@ hn_ioctl(struct ifnet *ifp, u_long cmd, 
 			 * the RNDIS reply.
 			 */
 			HN_NO_SLEEPING(sc);
-			hn_set_rxfilter(sc);
+			hn_rxfilter_config(sc);
 			HN_SLEEPING_OK(sc);
 		}
 
@@ -2566,7 +2566,7 @@ hn_init_locked(struct hn_softc *sc)
 		return;
 
 	/* Configure RX filter */
-	hn_set_rxfilter(sc);
+	hn_rxfilter_config(sc);
 
 	/* Clear OACTIVE bit. */
 	atomic_clear_int(&ifp->if_drv_flags, IFF_DRV_OACTIVE);
@@ -4925,7 +4925,7 @@ hn_resume_data(struct hn_softc *sc)
 	/*
 	 * Re-enable RX.
 	 */
-	hn_set_rxfilter(sc);
+	hn_rxfilter_config(sc);
 
 	/*
 	 * Make sure to clear suspend status on "all" TX rings,

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:47:18 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 69F95C9136A;
 Wed, 28 Dec 2016 04:47:18 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 147FD1BCB;
 Wed, 28 Dec 2016 04:47:18 +0000 (UTC)
 (envelope-from sephe@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4lHqQ093641;
 Wed, 28 Dec 2016 04:47:17 GMT (envelope-from sephe@FreeBSD.org)
Received: (from sephe@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4lHok093639;
 Wed, 28 Dec 2016 04:47:17 GMT (envelope-from sephe@FreeBSD.org)
Message-Id: <201612280447.uBS4lHok093639@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: sephe set sender to
 sephe@FreeBSD.org using -f
From: Sepherosa Ziehau <sephe@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:47:17 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310658 - head/sys/dev/hyperv/netvsc
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:47:18 -0000

Author: sephe
Date: Wed Dec 28 04:47:17 2016
New Revision: 310658
URL: https://svnweb.freebsd.org/changeset/base/310658

Log:
  hyperv/hn: Factor out function to set rxfilter.
  
  MFC after:	1 week
  Sponsored by:	Microsoft
  Differential Revision:	https://reviews.freebsd.org/D8928

Modified:
  head/sys/dev/hyperv/netvsc/if_hn.c

Modified: head/sys/dev/hyperv/netvsc/if_hn.c
==============================================================================
--- head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 04:35:52 2016	(r310657)
+++ head/sys/dev/hyperv/netvsc/if_hn.c	Wed Dec 28 04:47:17 2016	(r310658)
@@ -333,6 +333,7 @@ static void			hn_link_status(struct hn_s
 static int			hn_create_rx_data(struct hn_softc *, int);
 static void			hn_destroy_rx_data(struct hn_softc *);
 static int			hn_check_iplen(const struct mbuf *, int);
+static int			hn_set_rxfilter(struct hn_softc *, uint32_t);
 static int			hn_rxfilter_config(struct hn_softc *);
 #ifndef RSS
 static int			hn_rss_reconfig(struct hn_softc *);
@@ -684,11 +685,25 @@ do {							\
 #endif	/* INET6 || INET */
 
 static int
+hn_set_rxfilter(struct hn_softc *sc, uint32_t filter)
+{
+	int error = 0;
+
+	HN_LOCK_ASSERT(sc);
+
+	if (sc->hn_rx_filter != filter) {
+		error = hn_rndis_set_rxfilter(sc, filter);
+		if (!error)
+			sc->hn_rx_filter = filter;
+	}
+	return (error);
+}
+
+static int
 hn_rxfilter_config(struct hn_softc *sc)
 {
 	struct ifnet *ifp = sc->hn_ifp;
 	uint32_t filter;
-	int error = 0;
 
 	HN_LOCK_ASSERT(sc);
 
@@ -703,13 +718,7 @@ hn_rxfilter_config(struct hn_softc *sc)
 		    !TAILQ_EMPTY(&ifp->if_multiaddrs))
 			filter |= NDIS_PACKET_TYPE_ALL_MULTICAST;
 	}
-
-	if (sc->hn_rx_filter != filter) {
-		error = hn_rndis_set_rxfilter(sc, filter);
-		if (!error)
-			sc->hn_rx_filter = filter;
-	}
-	return (error);
+	return (hn_set_rxfilter(sc, filter));
 }
 
 static void
@@ -4817,8 +4826,7 @@ hn_suspend_data(struct hn_softc *sc)
 	/*
 	 * Disable RX by clearing RX filter.
 	 */
-	sc->hn_rx_filter = NDIS_PACKET_TYPE_NONE;
-	hn_rndis_set_rxfilter(sc, sc->hn_rx_filter);
+	hn_set_rxfilter(sc, NDIS_PACKET_TYPE_NONE);
 
 	/*
 	 * Give RNDIS enough time to flush all pending data packets.

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:48:31 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77DACC9141B;
 Wed, 28 Dec 2016 04:48:31 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 38A051D58;
 Wed, 28 Dec 2016 04:48:31 +0000 (UTC) (envelope-from kib@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4mUp8093736;
 Wed, 28 Dec 2016 04:48:30 GMT (envelope-from kib@FreeBSD.org)
Received: (from kib@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4mUqI093734;
 Wed, 28 Dec 2016 04:48:30 GMT (envelope-from kib@FreeBSD.org)
Message-Id: <201612280448.uBS4mUqI093734@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org
 using -f
From: Konstantin Belousov <kib@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:48:30 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310659 - in stable/11/sys: amd64/amd64 i386/i386
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:48:31 -0000

Author: kib
Date: Wed Dec 28 04:48:30 2016
New Revision: 310659
URL: https://svnweb.freebsd.org/changeset/base/310659

Log:
  MFC r304957, r304958,  r306310 (by bde):
  Fix vm86 initialization.
  
  MFC r310050:
  Improve very early trap handling on amd64.

Modified:
  stable/11/sys/amd64/amd64/machdep.c
  stable/11/sys/i386/i386/machdep.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/amd64/amd64/machdep.c
==============================================================================
--- stable/11/sys/amd64/amd64/machdep.c	Wed Dec 28 04:47:17 2016	(r310658)
+++ stable/11/sys/amd64/amd64/machdep.c	Wed Dec 28 04:48:30 2016	(r310659)
@@ -1506,6 +1506,16 @@ native_parse_preload_data(u_int64_t modu
 	return (kmdp);
 }
 
+static void
+amd64_kdb_init(void)
+{
+	kdb_init();
+#ifdef KDB
+	if (boothowto & RB_KDB)
+		kdb_enter(KDB_WHY_BOOTFLAGS, "Boot flags requested debugger");
+#endif
+}
+
 u_int64_t
 hammer_time(u_int64_t modulep, u_int64_t physfree)
 {
@@ -1517,6 +1527,7 @@ hammer_time(u_int64_t modulep, u_int64_t
 	u_int64_t msr;
 	char *env;
 	size_t kstack0_sz;
+	int late_console;
 
 	/*
  	 * This may be done better later if it gets more high level
@@ -1561,6 +1572,7 @@ hammer_time(u_int64_t modulep, u_int64_t
 	physfree += DPCPU_SIZE;
 	PCPU_SET(prvspace, pc);
 	PCPU_SET(curthread, &thread0);
+	/* Non-late cninit() and printf() can be moved up to here. */
 	PCPU_SET(tssp, &common_tss[0]);
 	PCPU_SET(commontssp, &common_tss[0]);
 	PCPU_SET(tss, (struct system_segment_descriptor *)&gdt[GPROC0_SEL]);
@@ -1660,12 +1672,36 @@ hammer_time(u_int64_t modulep, u_int64_t
 	wrmsr(MSR_STAR, msr);
 	wrmsr(MSR_SF_MASK, PSL_NT|PSL_T|PSL_I|PSL_C|PSL_D);
 
+	/*
+	 * Temporary forge some valid pointer to PCB, for exception
+	 * handlers.  It is reinitialized properly below after FPU is
+	 * set up.  Also set up td_critnest to short-cut the page
+	 * fault handler.
+	 */
+	cpu_max_ext_state_size = sizeof(struct savefpu);
+	thread0.td_pcb = get_pcb_td(&thread0);
+	thread0.td_critnest = 1;
+
+	/*
+	 * The console and kdb should be initialized even earlier than here,
+	 * but some console drivers don't work until after getmemsize().
+	 * Default to late console initialization to support these drivers.
+	 * This loses mainly printf()s in getmemsize() and early debugging.
+	 */
+	late_console = 1;
+	TUNABLE_INT_FETCH("debug.late_console", &late_console);
+	if (!late_console) {
+		cninit();
+		amd64_kdb_init();
+	}
+
 	getmemsize(kmdp, physfree);
 	init_param2(physmem);
 
 	/* now running on new page tables, configured,and u/iom is accessible */
 
-	cninit();
+	if (late_console)
+		cninit();
 
 #ifdef DEV_ISA
 #ifdef DEV_ATPIC
@@ -1686,13 +1722,8 @@ hammer_time(u_int64_t modulep, u_int64_t
 #error "have you forgotten the isa device?";
 #endif
 
-	kdb_init();
-
-#ifdef KDB
-	if (boothowto & RB_KDB)
-		kdb_enter(KDB_WHY_BOOTFLAGS,
-		    "Boot flags requested debugger");
-#endif
+	if (late_console)
+		amd64_kdb_init();
 
 	msgbufinit(msgbufp, msgbufsize);
 	fpuinit();
@@ -1741,6 +1772,7 @@ hammer_time(u_int64_t modulep, u_int64_t
 #ifdef FDT
 	x86_init_fdt();
 #endif
+	thread0.td_critnest = 0;
 
 	/* Location of kernel stack for locore */
 	return ((u_int64_t)thread0.td_pcb);

Modified: stable/11/sys/i386/i386/machdep.c
==============================================================================
--- stable/11/sys/i386/i386/machdep.c	Wed Dec 28 04:47:17 2016	(r310658)
+++ stable/11/sys/i386/i386/machdep.c	Wed Dec 28 04:48:30 2016	(r310659)
@@ -2089,7 +2089,6 @@ getmemsize(int first)
 	 * use that and do not make any VM86 calls.
 	 */
 	physmap_idx = 0;
-	smapbase = NULL;
 	kmdp = preload_search_by_type("elf kernel");
 	if (kmdp == NULL)
 		kmdp = preload_search_by_type("elf32 kernel");
@@ -2223,6 +2222,9 @@ physmap_done:
 	 * highest page of the physical address space.  It should be
 	 * called something like "Maxphyspage".  We may adjust this 
 	 * based on ``hw.physmem'' and the results of the memory test.
+	 *
+	 * This is especially confusing when it is much larger than the
+	 * memory size and is displayed as "realmem".
 	 */
 	Maxmem = atop(physmap[physmap_idx + 1]);
 
@@ -2428,6 +2430,19 @@ do_next:
 }
 #endif /* PC98 */
 
+static void
+i386_kdb_init(void)
+{
+#ifdef DDB
+	db_fetch_ksymtab(bootinfo.bi_symtab, bootinfo.bi_esymtab);
+#endif
+	kdb_init();
+#ifdef KDB
+	if (boothowto & RB_KDB)
+		kdb_enter(KDB_WHY_BOOTFLAGS, "Boot flags requested debugger");
+#endif
+}
+
 register_t
 init386(first)
 	int first;
@@ -2438,6 +2453,7 @@ init386(first)
 #ifdef CPU_ENABLE_SSE
 	struct xstate_hdr *xhdr;
 #endif
+	int late_console;
 
 	thread0.td_kstack = proc0kstack;
 	thread0.td_kstack_pages = TD0_KSTACK_PAGES;
@@ -2502,6 +2518,7 @@ init386(first)
 	first += DPCPU_SIZE;
 	PCPU_SET(prvspace, pc);
 	PCPU_SET(curthread, &thread0);
+	/* Non-late cninit() and printf() can be moved up to here. */
 
 	/*
 	 * Initialize mutexes.
@@ -2636,20 +2653,17 @@ init386(first)
 	dblfault_tss.tss_cs = GSEL(GCODE_SEL, SEL_KPL);
 	dblfault_tss.tss_ldt = GSEL(GLDT_SEL, SEL_KPL);
 
-	vm86_initialize();
-	getmemsize(first);
-	init_param2(physmem);
-
-	/* now running on new page tables, configured,and u/iom is accessible */
-
-	/*
-	 * Initialize the console before we print anything out.
-	 */
-	cninit();
-
-	if (metadata_missing)
-		printf("WARNING: loader(8) metadata is missing!\n");
+	/* Initialize the tss (except for the final esp0) early for vm86. */
+	PCPU_SET(common_tss.tss_esp0, thread0.td_kstack +
+	    thread0.td_kstack_pages * PAGE_SIZE - 16);
+	PCPU_SET(common_tss.tss_ss0, GSEL(GDATA_SEL, SEL_KPL));
+	gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
+	PCPU_SET(tss_gdt, &gdt[GPROC0_SEL].sd);
+	PCPU_SET(common_tssd, *PCPU_GET(tss_gdt));
+	PCPU_SET(common_tss.tss_ioopt, (sizeof (struct i386tss)) << 16);
+	ltr(gsel_tss);
 
+	/* Initialize the PIC early for vm86 calls. */
 #ifdef DEV_ISA
 #ifdef DEV_ATPIC
 #ifndef PC98
@@ -2671,16 +2685,33 @@ init386(first)
 #endif
 #endif
 
-#ifdef DDB
-	db_fetch_ksymtab(bootinfo.bi_symtab, bootinfo.bi_esymtab);
-#endif
+	/*
+	 * The console and kdb should be initialized even earlier than here,
+	 * but some console drivers don't work until after getmemsize().
+	 * Default to late console initialization to support these drivers.
+	 * This loses mainly printf()s in getmemsize() and early debugging.
+	 */
+	late_console = 1;
+	TUNABLE_INT_FETCH("debug.late_console", &late_console);
+	if (!late_console) {
+		cninit();
+		i386_kdb_init();
+	}
 
-	kdb_init();
+	vm86_initialize();
+	getmemsize(first);
+	init_param2(physmem);
 
-#ifdef KDB
-	if (boothowto & RB_KDB)
-		kdb_enter(KDB_WHY_BOOTFLAGS, "Boot flags requested debugger");
-#endif
+	/* now running on new page tables, configured,and u/iom is accessible */
+
+	if (late_console)
+		cninit();
+
+	if (metadata_missing)
+		printf("WARNING: loader(8) metadata is missing!\n");
+
+	if (late_console)
+		i386_kdb_init();
 
 	msgbufinit(msgbufp, msgbufsize);
 #ifdef DEV_NPX
@@ -2701,14 +2732,10 @@ init386(first)
 	}
 #endif
 	PCPU_SET(curpcb, thread0.td_pcb);
-	/* make an initial tss so cpu can get interrupt stack on syscall! */
+	/* Move esp0 in the tss to its final place. */
 	/* Note: -16 is so we can grow the trapframe if we came from vm86 */
 	PCPU_SET(common_tss.tss_esp0, (vm_offset_t)thread0.td_pcb - 16);
-	PCPU_SET(common_tss.tss_ss0, GSEL(GDATA_SEL, SEL_KPL));
-	gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
-	PCPU_SET(tss_gdt, &gdt[GPROC0_SEL].sd);
-	PCPU_SET(common_tssd, *PCPU_GET(tss_gdt));
-	PCPU_SET(common_tss.tss_ioopt, (sizeof (struct i386tss)) << 16);
+	gdt[GPROC0_SEL].sd.sd_type = SDT_SYS386TSS;	/* clear busy bit */
 	ltr(gsel_tss);
 
 	/* make a call gate to reenter kernel with */

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:53:53 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E8BC0C915F4;
 Wed, 28 Dec 2016 04:53:53 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B84321164;
 Wed, 28 Dec 2016 04:53:53 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4rqZQ097694;
 Wed, 28 Dec 2016 04:53:52 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4rqen097693;
 Wed, 28 Dec 2016 04:53:52 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280453.uBS4rqen097693@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:53:52 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310660 - head/contrib/bsnmp/lib
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:53:54 -0000

Author: ngie
Date: Wed Dec 28 04:53:52 2016
New Revision: 310660
URL: https://svnweb.freebsd.org/changeset/base/310660

Log:
  style(9): fix whitespace in pdu_encode_secparams(..)
  
  MFC after:	3 days

Modified:
  head/contrib/bsnmp/lib/snmp.c

Modified: head/contrib/bsnmp/lib/snmp.c
==============================================================================
--- head/contrib/bsnmp/lib/snmp.c	Wed Dec 28 04:48:30 2016	(r310659)
+++ head/contrib/bsnmp/lib/snmp.c	Wed Dec 28 04:53:52 2016	(r310660)
@@ -357,8 +357,8 @@ static enum snmp_code
 pdu_encode_secparams(struct asn_buf *b, struct snmp_pdu *pdu)
 {
 	u_char buf[256], *sptr;
-        struct asn_buf tb;
-        size_t auth_off, moved = 0;
+	struct asn_buf tb;
+	size_t auth_off, moved = 0;
 
 	auth_off = 0;
 	memset(buf, 0, 256);

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:55:44 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3C30FC916D0;
 Wed, 28 Dec 2016 04:55:44 +0000 (UTC)
 (envelope-from emaste@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 0BD75130D;
 Wed, 28 Dec 2016 04:55:43 +0000 (UTC)
 (envelope-from emaste@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4thbe097846;
 Wed, 28 Dec 2016 04:55:43 GMT (envelope-from emaste@FreeBSD.org)
Received: (from emaste@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4thlR097845;
 Wed, 28 Dec 2016 04:55:43 GMT (envelope-from emaste@FreeBSD.org)
Message-Id: <201612280455.uBS4thlR097845@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: emaste set sender to
 emaste@FreeBSD.org using -f
From: Ed Maste <emaste@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:55:43 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310661 - head/sys/boot/i386/loader
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:55:44 -0000

Author: emaste
Date: Wed Dec 28 04:55:43 2016
New Revision: 310661
URL: https://svnweb.freebsd.org/changeset/base/310661

Log:
  loader: use strip -o instead of cp and strip in place
  
  It is simpler and cleaner to have strip produce the stripped output
  directly than copying the input to the output first.
  
  MFC after:	1 week
  Sponsored by:	The FreeBSD Foundation

Modified:
  head/sys/boot/i386/loader/Makefile

Modified: head/sys/boot/i386/loader/Makefile
==============================================================================
--- head/sys/boot/i386/loader/Makefile	Wed Dec 28 04:53:52 2016	(r310660)
+++ head/sys/boot/i386/loader/Makefile	Wed Dec 28 04:55:43 2016	(r310661)
@@ -99,8 +99,7 @@ ${LOADER}: ${LOADER}.bin ${BTXLDR} ${BTX
 		-b ${BTXKERN} ${LOADER}.bin
 
 ${LOADER}.bin: ${LOADER}.sym
-	cp ${.ALLSRC} ${.TARGET}
-	strip -R .comment -R .note ${.TARGET}
+	strip -R .comment -R .note -o ${.TARGET} ${.ALLSRC}
 
 loader.help: help.common help.i386
 	cat ${.ALLSRC} | awk -f ${.CURDIR}/../../common/merge_help.awk > ${.TARGET}

From owner-svn-src-all@freebsd.org  Wed Dec 28 04:56:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D03FC91786;
 Wed, 28 Dec 2016 04:56:16 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 2CBD214D2;
 Wed, 28 Dec 2016 04:56:16 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS4uFJV097921;
 Wed, 28 Dec 2016 04:56:15 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS4uFHs097920;
 Wed, 28 Dec 2016 04:56:15 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280456.uBS4uFHs097920@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 04:56:15 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310662 - head/contrib/bsnmp/lib
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 04:56:16 -0000

Author: ngie
Date: Wed Dec 28 04:56:15 2016
New Revision: 310662
URL: https://svnweb.freebsd.org/changeset/base/310662

Log:
  style(9): snmp_send_packet(..): fix whitespace
  
  MFC after:	3 days

Modified:
  head/contrib/bsnmp/lib/snmpclient.c

Modified: head/contrib/bsnmp/lib/snmpclient.c
==============================================================================
--- head/contrib/bsnmp/lib/snmpclient.c	Wed Dec 28 04:55:43 2016	(r310661)
+++ head/contrib/bsnmp/lib/snmpclient.c	Wed Dec 28 04:56:15 2016	(r310662)
@@ -1227,9 +1227,9 @@ snmp_next_reqid(struct snmp_client * c)
 static int32_t
 snmp_send_packet(struct snmp_pdu * pdu)
 {
-        u_char *buf;
-        struct asn_buf b;
-        ssize_t ret;
+	u_char *buf;
+	struct asn_buf b;
+	ssize_t ret;
 
 	if ((buf = malloc(snmp_client.txbuflen)) == NULL) {
 		seterr(&snmp_client, "%s", strerror(errno));

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:05:10 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 32F04C919AB;
 Wed, 28 Dec 2016 05:05:10 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 029E51949;
 Wed, 28 Dec 2016 05:05:09 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS559Nb002081;
 Wed, 28 Dec 2016 05:05:09 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS559rZ002080;
 Wed, 28 Dec 2016 05:05:09 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280505.uBS559rZ002080@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:05:09 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310663 - head/contrib/bsnmp/snmpd
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:05:10 -0000

Author: ngie
Date: Wed Dec 28 05:05:08 2016
New Revision: 310663
URL: https://svnweb.freebsd.org/changeset/base/310663

Log:
  style(9): ip_get(..): clean up whitespace
  
  MFC after:	3 days

Modified:
  head/contrib/bsnmp/snmpd/export.c

Modified: head/contrib/bsnmp/snmpd/export.c
==============================================================================
--- head/contrib/bsnmp/snmpd/export.c	Wed Dec 28 04:56:15 2016	(r310662)
+++ head/contrib/bsnmp/snmpd/export.c	Wed Dec 28 05:05:08 2016	(r310663)
@@ -194,6 +194,7 @@ ip_get(struct snmp_value *value, u_char 
 	value->v.ipaddress[1] = valp[1];
 	value->v.ipaddress[2] = valp[2];
 	value->v.ipaddress[3] = valp[3];
+
 	return (SNMP_ERR_NOERROR);
 }
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:16:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id C753FC91CE6;
 Wed, 28 Dec 2016 05:16:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 8930E1049;
 Wed, 28 Dec 2016 05:16:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS5Gfnx006672;
 Wed, 28 Dec 2016 05:16:41 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS5Gfxl006670;
 Wed, 28 Dec 2016 05:16:41 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280516.uBS5Gfxl006670@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:16:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310664 - in head: tools/build/mk usr.sbin/bsnmpd/modules
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:16:42 -0000

Author: ngie
Date: Wed Dec 28 05:16:41 2016
New Revision: 310664
URL: https://svnweb.freebsd.org/changeset/base/310664

Log:
  Only build/install usr.sbin/bsnmpd/modules/snmp_wlan if MK_WIRELESS != no
  
  MFC after:	1 week

Modified:
  head/tools/build/mk/OptionalObsoleteFiles.inc
  head/usr.sbin/bsnmpd/modules/Makefile

Modified: head/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 05:05:08 2016	(r310663)
+++ head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 05:16:41 2016	(r310664)
@@ -9021,6 +9021,12 @@ OLD_FILES+=usr/share/man/man8/wlandebug.
 OLD_FILES+=usr/share/man/man8/wpa_cli.8.gz
 OLD_FILES+=usr/share/man/man8/wpa_passphrase.8.gz
 OLD_FILES+=usr/share/man/man8/wpa_supplicant.8.gz
+OLD_FILES+=usr/lib/snmp_wlan.so
+OLD_LIBS+=usr/lib/snmp_wlan.so.6
+# bsnmp module
+OLD_FILES+=usr/share/man/man3/snmp_wlan.3.gz
+OLD_FILES+=usr/share/snmp/defs/wlan_tree.def
+OLD_FILES+=usr/share/snmp/mibs/BEGEMOT-WIRELESS-MIB.txt
 .endif
 
 .if ${MK_SVNLITE} == no || ${MK_SVN} == yes

Modified: head/usr.sbin/bsnmpd/modules/Makefile
==============================================================================
--- head/usr.sbin/bsnmpd/modules/Makefile	Wed Dec 28 05:05:08 2016	(r310663)
+++ head/usr.sbin/bsnmpd/modules/Makefile	Wed Dec 28 05:16:41 2016	(r310664)
@@ -17,7 +17,6 @@ SUBDIR=	${_snmp_atm} \
 	snmp_target \
 	snmp_usm \
 	snmp_vacm \
-	snmp_wlan
 
 .if ${MK_PF} != "no"
 SUBDIR+=snmp_pf
@@ -27,6 +26,10 @@ SUBDIR+=snmp_pf
 SUBDIR+=snmp_netgraph
 .endif
 
+.if ${MK_WIRELESS} != "no"
+SUBDIR+=snmp_wlan
+.endif
+
 INCS=	snmpmod.h
 INCSDIR= ${INCLUDEDIR}/bsnmp
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:21:23 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7D024C92078;
 Wed, 28 Dec 2016 05:21:23 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 458151322;
 Wed, 28 Dec 2016 05:21:23 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS5LMvW007576;
 Wed, 28 Dec 2016 05:21:22 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS5LMrT007574;
 Wed, 28 Dec 2016 05:21:22 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280521.uBS5LMrT007574@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:21:22 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310665 - in head: tools/build/mk usr.sbin/bsnmpd/modules
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:21:23 -0000

Author: ngie
Date: Wed Dec 28 05:21:22 2016
New Revision: 310665
URL: https://svnweb.freebsd.org/changeset/base/310665

Log:
  Only build/install usr.sbin/bsnmpd/modules/snmp_hast if MK_HAST != no
  
  MFC after:	1 week

Modified:
  head/tools/build/mk/OptionalObsoleteFiles.inc
  head/usr.sbin/bsnmpd/modules/Makefile

Modified: head/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 05:16:41 2016	(r310664)
+++ head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 05:21:22 2016	(r310665)
@@ -3004,6 +3004,12 @@ OLD_FILES+=usr/share/man/man5/hast.conf.
 OLD_FILES+=usr/share/man/man8/hastctl.8.gz
 OLD_FILES+=usr/share/man/man8/hastd.8.gz
 OLD_DIRS+=usr/share/examples/hast
+# bsnmp
+OLD_FILES+=usr/lib/snmp_hast.so
+OLD_LIBS+=usr/lib/snmp_hast.so.6
+OLD_FILES+=usr/share/man/man3/snmp_hast.3.gz
+OLD_FILES+=usr/share/snmp/defs/hast_tree.def
+OLD_FILES+=usr/share/snmp/mibs/BEGEMOT-HAST-MIB.txt
 .endif
 
 .if ${MK_HESIOD} == no

Modified: head/usr.sbin/bsnmpd/modules/Makefile
==============================================================================
--- head/usr.sbin/bsnmpd/modules/Makefile	Wed Dec 28 05:16:41 2016	(r310664)
+++ head/usr.sbin/bsnmpd/modules/Makefile	Wed Dec 28 05:21:22 2016	(r310665)
@@ -10,7 +10,6 @@ _snmp_atm= snmp_atm
 
 SUBDIR=	${_snmp_atm} \
 	snmp_bridge \
-	snmp_hast \
 	snmp_hostres \
 	snmp_lm75 \
 	snmp_mibII \
@@ -18,6 +17,10 @@ SUBDIR=	${_snmp_atm} \
 	snmp_usm \
 	snmp_vacm \
 
+.if ${MK_HAST} != "no"
+SUBDIR+=snmp_hast
+.endif
+
 .if ${MK_PF} != "no"
 SUBDIR+=snmp_pf
 .endif

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:41:55 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 25CA0C9240F;
 Wed, 28 Dec 2016 05:41:55 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id DA47F1E6E;
 Wed, 28 Dec 2016 05:41:54 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS5fsot018290;
 Wed, 28 Dec 2016 05:41:54 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS5frw9018284;
 Wed, 28 Dec 2016 05:41:53 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280541.uBS5frw9018284@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:41:53 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310666 - head/usr.sbin/bsnmpd/modules/snmp_hostres
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:41:55 -0000

Author: ngie
Date: Wed Dec 28 05:41:53 2016
New Revision: 310666
URL: https://svnweb.freebsd.org/changeset/base/310666

Log:
  style(9) fixes
  
  - Clean up trailing whitespace
  - Fix variable type alignment in storage_OS_get_swap(..)
  
  MFC after:	3 days

Modified:
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_partition_tbl.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_scalars.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_swinstalled_tbl.c

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_device_tbl.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -123,7 +123,7 @@ device_entry_create(const char *name, co
 	if (map == NULL) {
 		/* new object - get a new index */
 		if (next_device_index > INT_MAX) {
-		        syslog(LOG_ERR,
+			syslog(LOG_ERR,
 			    "%s: hrDeviceTable index wrap", __func__);
 			/* There isn't much we can do here.
 			 * If the next_swins_index is consumed

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -131,7 +131,7 @@ static const struct {
 	const struct asn_oid	*oid;	/* the OID to return */
 } fs_type_map[] = {
 	{ "ufs",	&OIDX_hrFSBerkeleyFFS_c },
-	{ "zfs",        &OIDX_hrFSOther_c },
+	{ "zfs",	&OIDX_hrFSOther_c },
 	{ "cd9660",	&OIDX_hrFSiso9660_c },
 	{ "nfs",	&OIDX_hrFSNFS_c },
 	{ "ext2fs",	&OIDX_hrFSLinuxExt2_c },
@@ -167,7 +167,7 @@ fs_entry_create(const char *name)
 		/* new object - get a new index */
 		if (next_fs_index > INT_MAX) {
 			/* Unrecoverable error - die clean and quicly*/
-		        syslog(LOG_ERR, "%s: hrFSTable index wrap", __func__);
+			syslog(LOG_ERR, "%s: hrFSTable index wrap", __func__);
 			errx(EX_SOFTWARE, "hrFSTable index wrap");
 		}
 

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_partition_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_partition_tbl.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_partition_tbl.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -177,7 +177,7 @@ partition_entry_create(int32_t ds_index,
 
 		if (next_partition_index > INT_MAX) {
 			/* Unrecoverable error - die clean and quicly*/
-		        syslog(LOG_ERR, "%s: hrPartitionTable index wrap",
+			syslog(LOG_ERR, "%s: hrPartitionTable index wrap",
 			    __func__);
 			errx(EX_SOFTWARE, "hrPartitionTable index wrap");
 		}

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_scalars.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_scalars.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_scalars.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -193,7 +193,7 @@ OS_getSystemInitialLoadParameters(u_char
 			syslog(LOG_ERR, "malloc failed");
 			return (SNMP_ERR_GENERR);
 		}
-                if (sysctl(mib, 2, buf, &buf_len, NULL, 0)) {
+		if (sysctl(mib, 2, buf, &buf_len, NULL, 0)) {
 			syslog(LOG_ERR,
 			    "sysctl({CTL_KERN,KERN_BOOTFILE}) failed: %m");
 			free(buf);
@@ -296,7 +296,7 @@ OS_getMemorySize(uint32_t *ms)
 		*ms = UINT32_MAX;
 	else
 		*ms = phys_mem_size;
-        return (SNMP_ERR_NOERROR);
+	return (SNMP_ERR_NOERROR);
 }
 
 /*
@@ -360,7 +360,7 @@ OS_setSystemDate(const struct timeval *t
 	if (settimeofday(timeval_to_set, NULL) == -1) {
 		syslog(LOG_ERR, "settimeofday failed: %m");
 		return (SNMP_ERR_GENERR);
-        }
+	}
 	return (SNMP_ERR_NOERROR);
 }
 
@@ -378,7 +378,7 @@ op_hrSystem(struct snmp_context *ctx, st
 
 	switch (curr_op) {
 
-          case SNMP_OP_GET:
+	  case SNMP_OP_GET:
 		switch (value->var.subs[sub - 1]) {
 
 		case LEAF_hrSystemUptime:

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_snmp.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -163,7 +163,7 @@ hostres_start(void)
 	start_processor_tbl(hostres_module);
 	start_network_tbl();
 
-        HRDBG("done.");
+	HRDBG("done.");
 }
 
 /* this identifies the HOST RESOURCES mib module */
@@ -175,8 +175,8 @@ const struct snmp_module config = {
 	NULL,
 	NULL,
 	hostres_start,
-	NULL,                   /* proxy a PDU */
-	hostres_ctree,          /* see the generated hostres_tree.h */
+	NULL,		   /* proxy a PDU */
+	hostres_ctree,	  /* see the generated hostres_tree.h */
 	hostres_CTREE_SIZE,     /* see the generated hostres_tree.h */
 	NULL
 };

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -153,7 +153,7 @@ storage_entry_create(const char *name)
 	if (map == NULL) {
 		/* new object - get a new index */
 		if (next_storage_index > INT_MAX) {
-		        syslog(LOG_ERR,
+			syslog(LOG_ERR,
 			    "%s: hrStorageTable index wrap", __func__);
 			errx(EX_SOFTWARE, "hrStorageTable index wrap");
 		}
@@ -188,7 +188,7 @@ storage_entry_create(const char *name)
 		syslog(LOG_WARNING, "%s: %m", __func__);
 		return (NULL);
 	}
-        memset(entry, 0, sizeof(*entry));
+	memset(entry, 0, sizeof(*entry));
 
 	entry->index = map->hrIndex;
 
@@ -374,10 +374,10 @@ storage_OS_get_memstat(void)
 static void
 storage_OS_get_swap(void)
 {
-        int nswapdev = 0;
-	size_t len = sizeof(nswapdev);
 	struct storage_entry *entry;
 	char swap_w_prefix[SE_DESC_MLEN];
+	size_t len = sizeof(nswapdev);
+	int nswapdev = 0;
 
 	if (sysctlbyname("vm.nswapdev", &nswapdev, &len, NULL,0 ) < 0) {
 		syslog(LOG_ERR,

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_swinstalled_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_swinstalled_tbl.c	Wed Dec 28 05:21:22 2016	(r310665)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_swinstalled_tbl.c	Wed Dec 28 05:41:53 2016	(r310666)
@@ -50,7 +50,7 @@
 #include "hostres_oid.h"
 #include "hostres_tree.h"
 
-#define	CONTENTS_FNAME          "+CONTENTS"
+#define	CONTENTS_FNAME	"+CONTENTS"
 
 enum SWInstalledType {
 	SWI_UNKNOWN		= 1,
@@ -136,7 +136,7 @@ swins_entry_create(const char *name)
 		size_t name_len;
 		/* new object - get a new index */
 		if (next_swins_index > INT_MAX) {
-		        syslog(LOG_ERR, "%s: hrSWInstalledTable index wrap",
+			syslog(LOG_ERR, "%s: hrSWInstalledTable index wrap",
 			    __func__ );
 			/* There isn't much we can do here.
 			 * If the next_swins_index is consumed
@@ -292,7 +292,7 @@ swins_get_packages(void)
 	struct stat sb;
 	DIR *p_dir;
 	struct dirent *ent;
-        struct tm k_ts;
+	struct tm k_ts;
 	char *pkg_file;
 	struct swins_entry *entry;
 	int ret = 0;
@@ -327,7 +327,7 @@ swins_get_packages(void)
 		return (-1);
 	}
 
-        while (errno = 0, (ent = readdir(p_dir)) != NULL) {
+	while (errno = 0, (ent = readdir(p_dir)) != NULL) {
 		HRDBG("  pkg file: %s", ent->d_name);
 
 		/* check that the contents file is a regular file */
@@ -371,7 +371,7 @@ swins_get_packages(void)
 		entry->type = (int32_t)SWI_APPLICATION;
 
 		entry->date_len = make_date_time(entry->date, &k_ts, 0);
-        }
+	}
 
 	if (errno != 0) {
 		syslog(LOG_ERR, "hrSWInstalledTable: readdir_r(\"%s\") failed:"

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:42:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9FDBEC925ED;
 Wed, 28 Dec 2016 05:42:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6F559105C;
 Wed, 28 Dec 2016 05:42:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS5gfnO019220;
 Wed, 28 Dec 2016 05:42:41 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS5gfj8019219;
 Wed, 28 Dec 2016 05:42:41 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280542.uBS5gfj8019219@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:42:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310667 - head/usr.sbin/bsnmpd/modules/snmp_bridge
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:42:42 -0000

Author: ngie
Date: Wed Dec 28 05:42:41 2016
New Revision: 310667
URL: https://svnweb.freebsd.org/changeset/base/310667

Log:
  style(9) fixes: clean up leading whitespace
  
  MFC after:	3 days

Modified:
  head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_sys.c

Modified: head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_sys.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_sys.c	Wed Dec 28 05:41:53 2016	(r310666)
+++ head/usr.sbin/bsnmpd/modules/snmp_bridge/bridge_sys.c	Wed Dec 28 05:42:41 2016	(r310667)
@@ -1472,7 +1472,7 @@ bridge_do_pfctl(int32_t bridge_ctl, enum
 	} else
 		s_len = 0;
 
-        len = sizeof(i);
+	len = sizeof(i);
 
 	strcpy(mib_name, bridge_sysctl);
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:43:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 345AFC9265B;
 Wed, 28 Dec 2016 05:43:16 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 041B011D7;
 Wed, 28 Dec 2016 05:43:15 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS5hFMc019285;
 Wed, 28 Dec 2016 05:43:15 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS5hFQj019284;
 Wed, 28 Dec 2016 05:43:15 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280543.uBS5hFQj019284@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 05:43:15 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310668 - head/usr.sbin/bsnmpd/tools/libbsnmptools
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:43:16 -0000

Author: ngie
Date: Wed Dec 28 05:43:14 2016
New Revision: 310668
URL: https://svnweb.freebsd.org/changeset/base/310668

Log:
  style(9) fixes: clean up leading whitespace
  
  MFC after:	3 days

Modified:
  head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c

Modified: head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c
==============================================================================
--- head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c	Wed Dec 28 05:42:41 2016	(r310667)
+++ head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c	Wed Dec 28 05:43:14 2016	(r310668)
@@ -1090,6 +1090,7 @@ snmp_ip2asn_oid(char *str, struct asn_oi
 	char *endptr, *ptr;
 
 	ptr = str;
+
 	for (i = 0; i < 4; i++) {
 		v = strtoul(ptr, &endptr, 10);
 		if (v > 0xff)

From owner-svn-src-all@freebsd.org  Wed Dec 28 05:50:36 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33FC5C927EC;
 Wed, 28 Dec 2016 05:50:36 +0000 (UTC)
 (envelope-from adrian.chadd@gmail.com)
Received: from mail-wj0-x241.google.com (mail-wj0-x241.google.com
 [IPv6:2a00:1450:400c:c01::241])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id AD5B2142F;
 Wed, 28 Dec 2016 05:50:35 +0000 (UTC)
 (envelope-from adrian.chadd@gmail.com)
Received: by mail-wj0-x241.google.com with SMTP id hb5so20146502wjc.2;
 Tue, 27 Dec 2016 21:50:35 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=mime-version:in-reply-to:references:from:date:message-id:subject:to
 :cc:content-transfer-encoding;
 bh=tTBsUyC/ATHDANXIUrVm0CJxWmQ2yX7avsB/X5sP6K0=;
 b=TA6DWbV3Hvca6ag4Yj0T2oLN9RjF+UGG/LH3xva3/AuBqfqS3lE6oCaCGB5FCpNDcm
 RAcmgChjPE8n5NltDIqcp+P6gkXAq6mzZqG9e241BSda6+P4VAQFhtG9ZGfvm6eyjYsi
 srRHnWwa6BMVvGoX4mZ1CZNcPJZvhAdGi14+ZDxk1cWsiDeHxmfsfcAVwbBhkqgdC0XC
 pEUUB2vFa4KSJW9jCTbWPmovWksnlC8xaU2vpvG3cXSZ9cI3Bh+vCEzGAbuU/u1Ugoo8
 M3T2co5nle4L9hli0cdijPhhrWNOYOLab46awf2v+gQWCcScw2xKYHxu3JO5DuBJ9RLM
 jsXQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:mime-version:in-reply-to:references:from:date
 :message-id:subject:to:cc:content-transfer-encoding;
 bh=tTBsUyC/ATHDANXIUrVm0CJxWmQ2yX7avsB/X5sP6K0=;
 b=YykA1diOHN9Qcx76MPt9VrRhvf8q11E6gPJSVzjfXcZs+EX+VhBuUTrs//ctjJc+vM
 KWpYxDNxfjZddgvvL9NvcKthrneLeVWjxW6tQ1Lz33UMukmRoTMPh6TwuXlm+RrmkZpP
 9fW3V2ttAJ60A6kfWLxQ/Ks4MwbpyhWQFmFiB89xrB8zgzx2Q/v7l/0GhtXIcNwHFl/7
 tjaYuMzYlWdZST6lAJTi6tukdknUMWDMY7MaT7fnFf/AQt0KUuhtvlmf54JBCi6bqYRq
 wxunOb2mDIfvBRbVzSMfYMQIgD+PUYukKczJnyTVXm2uuCj2Ct8v2gwVC6Mvu+YL8Uin
 Ealg==
X-Gm-Message-State: AIkVDXK+iTHAwiNmK/MTp12g+iPn324pBgpVcHumfd1sslFfLN3F4pnKSzSrWyqg8eOAFiK2+EKYAwREGKh8Rg==
X-Received: by 10.194.67.67 with SMTP id l3mr33322622wjt.151.1482904233541;
 Tue, 27 Dec 2016 21:50:33 -0800 (PST)
MIME-Version: 1.0
Received: by 10.194.44.1 with HTTP; Tue, 27 Dec 2016 21:50:32 -0800 (PST)
In-Reply-To: <201612280255.uBS2tQeR045512@repo.freebsd.org>
References: <201612280255.uBS2tQeR045512@repo.freebsd.org>
From: Adrian Chadd <adrian.chadd@gmail.com>
Date: Tue, 27 Dec 2016 21:50:32 -0800
Message-ID: <CAJ-Vmo=bMUNbfgaTdUC8ToN9yLZuyqN5ws79vmwP8OJcRfR1ag@mail.gmail.com>
Subject: Re: svn commit: r310650 - in head/sys/mips: include mips
To: Alexander Kabaev <kan@freebsd.org>
Cc: "src-committers@freebsd.org" <src-committers@freebsd.org>, 
 "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>, 
 "svn-src-head@freebsd.org" <svn-src-head@freebsd.org>
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 05:50:36 -0000

hiya,

so I dug into the mips24k definition of this. It says this:

"
3.4.3 Uncached accelerated writes
The 24K core permits memory regions to be marked as =E2=80=9Cuncached
accelerated=E2=80=9D. This type of region is useful to hard-
ware which is =E2=80=9Cwrite only=E2=80=9D - perhaps video frame buffers, o=
r some
other hardware stream. Sequential word stores in
such regions are gathered into cache-line-sized chunks, before being
written with a single burst cycle on the CPU
interface.
Such regions are uncached for read, and partial-word or
out-of-sequence writes have =E2=80=9Cunpredictable=E2=80=9D effects - don=
=E2=80=99t
do them. The burst write is normally performed when software writes to
the last location in the memory block or does
an uncached-accelerated write to some other block; but it can also be
triggered by a
sync instruction, a pref nudge, a matching load or any exception. If
the block is not completely written by the time it=E2=80=99s pushed out, it
will be written using a series of doubleword or smaller write cycles
over the 24K core=E2=80=99s 64-bit memory interface.
"

So, question is - is our write combining page attribute in the VM
suitable for this? Is it defined as "only do full sequential word
writes"? Or do we risk having some other platform use it in a less
"don't do this" way and then MIPS is the one at fault again? :)


-adrian



On 27 December 2016 at 18:55, Alexander Kabaev <kan@freebsd.org> wrote:
> Author: kan
> Date: Wed Dec 28 02:55:26 2016
> New Revision: 310650
> URL: https://svnweb.freebsd.org/changeset/base/310650
>
> Log:
>   Implement pmap_change_attr and related APIs on MIPS
>
>   On platforms that have uncached-accelerate cache attribute, map it
>   to VM_MEMATTR_WRITE_COMBINING. Otherwise, leave write comining
>   undefined.
>
>   Reviewed by:  adrian, jhb (glance)
>   Differential Revision:        https://reviews.freebsd.org/D8894
>
> Modified:
>   head/sys/mips/include/cpuregs.h
>   head/sys/mips/include/pmap.h
>   head/sys/mips/include/pte.h
>   head/sys/mips/include/vm.h
>   head/sys/mips/mips/pmap.c
>
> Modified: head/sys/mips/include/cpuregs.h
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/mips/include/cpuregs.h     Tue Dec 27 23:56:46 2016        (=
r310649)
> +++ head/sys/mips/include/cpuregs.h     Wed Dec 28 02:55:26 2016        (=
r310650)
> @@ -171,6 +171,10 @@
>  #define        MIPS_CCA_CACHED         MIPS_CCA_CCS
>  #endif
>
> +#if defined(CPU_XBURST)
> +#define        MIPS_CCA_UA             0x01
> +#endif
> +
>  #ifndef        MIPS_CCA_UNCACHED
>  #define        MIPS_CCA_UNCACHED       MIPS_CCA_UC
>  #endif
> @@ -188,6 +192,16 @@
>  #endif
>  #endif
>
> +/*
> + * Use uncached-accelerated mode for write-combining maps, if one is def=
ined,
> + * otherwise fall back to uncached
> + */
> +#ifndef MIPS_CCA_WC
> +#ifdef MIPS_CCA_UA
> +#define        MIPS_CCA_WC MIPS_CCA_UA
> +#endif
> +#endif
> +
>  #define        MIPS_PHYS_TO_XKPHYS(cca,x) \
>         ((0x2ULL << 62) | ((unsigned long long)(cca) << 59) | (x))
>  #define        MIPS_PHYS_TO_XKPHYS_CACHED(x) \
>
> Modified: head/sys/mips/include/pmap.h
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/mips/include/pmap.h        Tue Dec 27 23:56:46 2016        (=
r310649)
> +++ head/sys/mips/include/pmap.h        Wed Dec 28 02:55:26 2016        (=
r310650)
> @@ -74,7 +74,8 @@ struct md_page {
>  };
>
>  #define        PV_TABLE_REF            0x02    /* referenced */
> -#define        PV_MEMATTR_UNCACHEABLE  0x04
> +#define        PV_MEMATTR_MASK         0xf0    /* store vm_memattr_t her=
e */
> +#define        PV_MEMATTR_SHIFT        0x04
>
>  #define        ASID_BITS               8
>  #define        ASIDGEN_BITS            (32 - ASID_BITS)
> @@ -163,22 +164,24 @@ extern vm_offset_t virtual_end;
>
>  extern vm_paddr_t dump_avail[PHYS_AVAIL_ENTRIES + 2];
>
> -#define        pmap_page_get_memattr(m)        VM_MEMATTR_DEFAULT
> +#define        pmap_page_get_memattr(m) (((m)->md.pv_flags & PV_MEMATTR_=
MASK) >> PV_MEMATTR_SHIFT)
>  #define        pmap_page_is_mapped(m)  (!TAILQ_EMPTY(&(m)->md.pv_list))
>  #define        pmap_page_is_write_mapped(m)    (((m)->aflags & PGA_WRITE=
ABLE) !=3D 0)
>
>  void pmap_bootstrap(void);
>  void *pmap_mapdev(vm_paddr_t, vm_size_t);
> +void *pmap_mapdev_attr(vm_paddr_t, vm_size_t, vm_memattr_t);
>  void pmap_unmapdev(vm_offset_t, vm_size_t);
>  vm_offset_t pmap_steal_memory(vm_size_t size);
>  void pmap_kenter(vm_offset_t va, vm_paddr_t pa);
> -void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, int attr);
> +void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t attr);
>  void pmap_kremove(vm_offset_t va);
>  void *pmap_kenter_temporary(vm_paddr_t pa, int i);
>  void pmap_kenter_temporary_free(vm_paddr_t pa);
>  void pmap_flush_pvcache(vm_page_t m);
>  int pmap_emulate_modified(pmap_t pmap, vm_offset_t va);
>  void pmap_page_set_memattr(vm_page_t, vm_memattr_t);
> +int pmap_change_attr(vm_offset_t, vm_size_t, vm_memattr_t);
>
>  #endif                         /* _KERNEL */
>
>
> Modified: head/sys/mips/include/pte.h
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/mips/include/pte.h Tue Dec 27 23:56:46 2016        (r310649)
> +++ head/sys/mips/include/pte.h Wed Dec 28 02:55:26 2016        (r310650)
> @@ -132,8 +132,10 @@ typedef    pt_entry_t *pd_entry_t;
>   *             it is matched.
>   */
>  #define        PTE_C(attr)             ((attr & 0x07) << 3)
> +#define        PTE_C_MASK              (PTE_C(0x07))
>  #define        PTE_C_UNCACHED          (PTE_C(MIPS_CCA_UNCACHED))
>  #define        PTE_C_CACHE             (PTE_C(MIPS_CCA_CACHED))
> +#define        PTE_C_WC                (PTE_C(MIPS_CCA_WC))
>  #define        PTE_D                   0x04
>  #define        PTE_V                   0x02
>  #define        PTE_G                   0x01
> @@ -158,6 +160,7 @@ typedef     pt_entry_t *pd_entry_t;
>  #define        pte_clear(pte, bit)     (*(pte) &=3D ~(bit))
>  #define        pte_set(pte, bit)       (*(pte) |=3D (bit))
>  #define        pte_test(pte, bit)      ((*(pte) & (bit)) =3D=3D (bit))
> +#define        pte_cache_bits(pte)     ((*(pte) >> 3) & 0x07)
>
>  /* Assembly support for PTE access*/
>  #ifdef LOCORE
>
> Modified: head/sys/mips/include/vm.h
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/mips/include/vm.h  Tue Dec 27 23:56:46 2016        (r310649)
> +++ head/sys/mips/include/vm.h  Wed Dec 28 02:55:26 2016        (r310650)
> @@ -32,7 +32,11 @@
>  #include <machine/pte.h>
>
>  /* Memory attributes. */
> -#define        VM_MEMATTR_UNCACHEABLE  ((vm_memattr_t)PTE_C_UNCACHED)
> -#define        VM_MEMATTR_DEFAULT      ((vm_memattr_t)PTE_C_CACHE)
> +#define        VM_MEMATTR_UNCACHEABLE          ((vm_memattr_t)MIPS_CCA_U=
NCACHED)
> +#define        VM_MEMATTR_WRITE_BACK           ((vm_memattr_t)MIPS_CCA_C=
ACHED)
> +#define        VM_MEMATTR_DEFAULT              VM_MEMATTR_WRITE_BACK
> +#ifdef MIPS_CCA_WC
> +#define        VM_MEMATTR_WRITE_COMBINING      ((vm_memattr_t)MIPS_CCA_W=
C)
> +#endif
>
>  #endif /* !_MACHINE_VM_H_ */
>
> Modified: head/sys/mips/mips/pmap.c
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/sys/mips/mips/pmap.c   Tue Dec 27 23:56:46 2016        (r310649)
> +++ head/sys/mips/mips/pmap.c   Wed Dec 28 02:55:26 2016        (r310650)
> @@ -189,10 +189,10 @@ static void pmap_update_page_action(void
>   * The highmem area does not have a KSEG0 mapping, and we need a mechani=
sm to
>   * do temporary per-CPU mappings for pmap_zero_page, pmap_copy_page etc.
>   *
> - * At bootup, we reserve 2 virtual pages per CPU for mapping highmem pag=
es. To
> + * At bootup, we reserve 2 virtual pages per CPU for mapping highmem pag=
es. To
>   * access a highmem physical address on a CPU, we map the physical addre=
ss to
> - * the reserved virtual address for the CPU in the kernel pagetable.  Th=
is is
> - * done with interrupts disabled(although a spinlock and sched_pin would=
 be
> + * the reserved virtual address for the CPU in the kernel pagetable.  Th=
is is
> + * done with interrupts disabled(although a spinlock and sched_pin would=
 be
>   * sufficient).
>   */
>  struct local_sysmaps {
> @@ -303,7 +303,7 @@ pmap_lmem_map2(vm_paddr_t phys1, vm_padd
>         return (0);
>  }
>
> -static __inline vm_offset_t
> +static __inline vm_offset_t
>  pmap_lmem_unmap(void)
>  {
>
> @@ -312,12 +312,18 @@ pmap_lmem_unmap(void)
>  #endif /* !__mips_n64 */
>
>  static __inline int
> -is_cacheable_page(vm_paddr_t pa, vm_page_t m)
> +pmap_pte_cache_bits(vm_paddr_t pa, vm_page_t m)
>  {
> +       vm_memattr_t ma;
>
> -       return ((m->md.pv_flags & PV_MEMATTR_UNCACHEABLE) =3D=3D 0 &&
> -           is_cacheable_mem(pa));
> -
> +       ma =3D pmap_page_get_memattr(m);
> +       if (ma =3D=3D VM_MEMATTR_WRITE_BACK && !is_cacheable_mem(pa))
> +               ma =3D VM_MEMATTR_UNCACHEABLE;
> +       return PTE_C(ma);
> +}
> +#define PMAP_PTE_SET_CACHE_BITS(pte, ps, m) {  \
> +       pte &=3D ~PTE_C_MASK;                     \
> +       pte |=3D pmap_pte_cache_bits(pa, m);      \
>  }
>
>  /*
> @@ -359,7 +365,7 @@ pmap_pdpe_to_pde(pd_entry_t *pdpe, vm_of
>         return (pdpe);
>  }
>
> -static __inline
> +static __inline
>  pd_entry_t *pmap_pde(pmap_t pmap, vm_offset_t va)
>  {
>
> @@ -423,7 +429,7 @@ pmap_steal_memory(vm_size_t size)
>   * Bootstrap the system enough to run with virtual memory.  This
>   * assumes that the phys_avail array has been initialized.
>   */
> -static void
> +static void
>  pmap_create_kernel_pagetable(void)
>  {
>         int i, j;
> @@ -486,7 +492,7 @@ void
>  pmap_bootstrap(void)
>  {
>         int i;
> -       int need_local_mappings =3D 0;
> +       int need_local_mappings =3D 0;
>
>         /* Sort. */
>  again:
> @@ -600,7 +606,7 @@ pmap_page_init(vm_page_t m)
>  {
>
>         TAILQ_INIT(&m->md.pv_list);
> -       m->md.pv_flags =3D 0;
> +       m->md.pv_flags =3D VM_MEMATTR_DEFAULT << PV_MEMATTR_SHIFT;
>  }
>
>  /*
> @@ -635,8 +641,8 @@ pmap_call_on_active_cpus(pmap_t pmap, vo
>                         pmap->pm_asid[cpu].gen =3D 0;
>         }
>         cpuid =3D PCPU_GET(cpuid);
> -       /*
> -        * XXX: barrier/locking for active?
> +       /*
> +        * XXX: barrier/locking for active?
>          *
>          * Take a snapshot of active here, any further changes are ignore=
d.
>          * tlb update/invalidate should be harmless on inactive CPUs
> @@ -819,7 +825,7 @@ retry:
>   * add a wired page to the kva
>   */
>  void
> -pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, int attr)
> +pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, vm_memattr_t ma)
>  {
>         pt_entry_t *pte;
>         pt_entry_t opte, npte;
> @@ -830,7 +836,7 @@ pmap_kenter_attr(vm_offset_t va, vm_padd
>
>         pte =3D pmap_pte(kernel_pmap, va);
>         opte =3D *pte;
> -       npte =3D TLBLO_PA_TO_PFN(pa) | attr | PTE_D | PTE_V | PTE_G;
> +       npte =3D TLBLO_PA_TO_PFN(pa) | PTE_C(ma) | PTE_D | PTE_V | PTE_G;
>         *pte =3D npte;
>         if (pte_test(&opte, PTE_V) && opte !=3D npte)
>                 pmap_update_page(kernel_pmap, va, npte);
> @@ -843,7 +849,7 @@ pmap_kenter(vm_offset_t va, vm_paddr_t p
>         KASSERT(is_cacheable_mem(pa),
>                 ("pmap_kenter: memory at 0x%lx is not cacheable", (u_long=
)pa));
>
> -       pmap_kenter_attr(va, pa, PTE_C_CACHE);
> +       pmap_kenter_attr(va, pa, VM_MEMATTR_DEFAULT);
>  }
>
>  /*
> @@ -1144,11 +1150,11 @@ _pmap_allocpte(pmap_t pmap, unsigned pte
>                 int segindex =3D ptepindex >> (SEGSHIFT - PDRSHIFT);
>                 int pdeindex =3D ptepindex & (NPDEPG - 1);
>                 vm_page_t pg;
> -
> +
>                 pdep =3D &pmap->pm_segtab[segindex];
> -               if (*pdep =3D=3D NULL) {
> +               if (*pdep =3D=3D NULL) {
>                         /* recurse for allocating page dir */
> -                       if (_pmap_allocpte(pmap, NUPDE + segindex,
> +                       if (_pmap_allocpte(pmap, NUPDE + segindex,
>                             flags) =3D=3D NULL) {
>                                 /* alloc failed, release current */
>                                 --m->wire_count;
> @@ -1680,7 +1686,7 @@ pmap_try_insert_pv_entry(pmap_t pmap, vm
>   * pmap_remove_pte: do the things to unmap a page in a process
>   */
>  static int
> -pmap_remove_pte(struct pmap *pmap, pt_entry_t *ptq, vm_offset_t va,
> +pmap_remove_pte(struct pmap *pmap, pt_entry_t *ptq, vm_offset_t va,
>      pd_entry_t pde)
>  {
>         pt_entry_t oldpte;
> @@ -1864,7 +1870,7 @@ pmap_remove_all(vm_page_t m)
>                 PMAP_LOCK(pmap);
>
>                 /*
> -                * If it's last mapping writeback all caches from
> +                * If it's last mapping writeback all caches from
>                  * the page being destroyed
>                  */
>                 if (TAILQ_NEXT(pv, pv_list) =3D=3D NULL)
> @@ -2030,10 +2036,7 @@ pmap_enter(pmap_t pmap, vm_offset_t va,
>                 newpte |=3D PTE_W;
>         if (is_kernel_pmap(pmap))
>                 newpte |=3D PTE_G;
> -       if (is_cacheable_page(pa, m))
> -               newpte |=3D PTE_C_CACHE;
> -       else
> -               newpte |=3D PTE_C_UNCACHED;
> +       PMAP_PTE_SET_CACHE_BITS(newpte, pa, m);
>
>         mpte =3D NULL;
>
> @@ -2218,7 +2221,7 @@ static vm_page_t
>  pmap_enter_quick_locked(pmap_t pmap, vm_offset_t va, vm_page_t m,
>      vm_prot_t prot, vm_page_t mpte)
>  {
> -       pt_entry_t *pte;
> +       pt_entry_t *pte, npte;
>         vm_paddr_t pa;
>
>         KASSERT(va < kmi.clean_sva || va >=3D kmi.clean_eva ||
> @@ -2297,18 +2300,16 @@ pmap_enter_quick_locked(pmap_t pmap, vm_
>         /*
>          * Now validate mapping with RO protection
>          */
> -       *pte =3D PTE_RO | TLBLO_PA_TO_PFN(pa) | PTE_V;
> +       npte =3D PTE_RO | TLBLO_PA_TO_PFN(pa) | PTE_V;
>         if ((m->oflags & VPO_UNMANAGED) =3D=3D 0)
> -               *pte |=3D PTE_MANAGED;
> +               npte |=3D PTE_MANAGED;
>
> -       if (is_cacheable_page(pa, m))
> -               *pte |=3D PTE_C_CACHE;
> -       else
> -               *pte |=3D PTE_C_UNCACHED;
> +       PMAP_PTE_SET_CACHE_BITS(npte, pa, m);
>
>         if (is_kernel_pmap(pmap))
> -               *pte |=3D PTE_G;
> +               *pte =3D npte | PTE_G;
>         else {
> +               *pte =3D npte;
>                 /*
>                  * Sync I & D caches.  Do this only if the target pmap
>                  * belongs to the current process.  Otherwise, an
> @@ -2649,12 +2650,12 @@ pmap_quick_enter_page(vm_page_t m)
>  #else
>         vm_paddr_t pa;
>         struct local_sysmaps *sysm;
> -       pt_entry_t *pte;
> +       pt_entry_t *pte, npte;
>
>         pa =3D VM_PAGE_TO_PHYS(m);
>
>         if (MIPS_DIRECT_MAPPABLE(pa)) {
> -               if (m->md.pv_flags & PV_MEMATTR_UNCACHEABLE)
> +               if (pmap_page_get_memattr(m) !=3D VM_MEMATTR_WRITE_BACK)
>                         return (MIPS_PHYS_TO_DIRECT_UNCACHED(pa));
>                 else
>                         return (MIPS_PHYS_TO_DIRECT(pa));
> @@ -2665,8 +2666,9 @@ pmap_quick_enter_page(vm_page_t m)
>         KASSERT(sysm->valid1 =3D=3D 0, ("pmap_quick_enter_page: PTE busy"=
));
>
>         pte =3D pmap_pte(kernel_pmap, sysm->base);
> -       *pte =3D TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G |
> -           (is_cacheable_page(pa, m) ? PTE_C_CACHE : PTE_C_UNCACHED);
> +       npte =3D TLBLO_PA_TO_PFN(pa) | PTE_D | PTE_V | PTE_G;
> +       PMAP_PTE_SET_CACHE_BITS(npte, pa, m);
> +       *pte =3D npte;
>         sysm->valid1 =3D 1;
>
>         return (sysm->base);
> @@ -3146,26 +3148,26 @@ pmap_is_referenced(vm_page_t m)
>   * Use XKPHYS uncached for 64 bit, and KSEG1 where possible for 32 bit.
>   */
>  void *
> -pmap_mapdev(vm_paddr_t pa, vm_size_t size)
> +pmap_mapdev_attr(vm_paddr_t pa, vm_size_t size, vm_memattr_t ma)
>  {
>          vm_offset_t va, tmpva, offset;
>
> -       /*
> -        * KSEG1 maps only first 512M of phys address space. For
> +       /*
> +        * KSEG1 maps only first 512M of phys address space. For
>          * pa > 0x20000000 we should make proper mapping * using pmap_ken=
ter.
>          */
> -       if (MIPS_DIRECT_MAPPABLE(pa + size - 1))
> +       if (MIPS_DIRECT_MAPPABLE(pa + size - 1) && ma =3D=3D VM_MEMATTR_U=
NCACHEABLE)
>                 return ((void *)MIPS_PHYS_TO_DIRECT_UNCACHED(pa));
>         else {
>                 offset =3D pa & PAGE_MASK;
>                 size =3D roundup(size + offset, PAGE_SIZE);
> -
> +
>                 va =3D kva_alloc(size);
>                 if (!va)
>                         panic("pmap_mapdev: Couldn't alloc kernel virtual=
 memory");
>                 pa =3D trunc_page(pa);
>                 for (tmpva =3D va; size > 0;) {
> -                       pmap_kenter_attr(tmpva, pa, PTE_C_UNCACHED);
> +                       pmap_kenter_attr(tmpva, pa, ma);
>                         size -=3D PAGE_SIZE;
>                         tmpva +=3D PAGE_SIZE;
>                         pa +=3D PAGE_SIZE;
> @@ -3175,6 +3177,12 @@ pmap_mapdev(vm_paddr_t pa, vm_size_t siz
>         return ((void *)(va + offset));
>  }
>
> +void *
> +pmap_mapdev(vm_paddr_t pa, vm_size_t size)
> +{
> +       return pmap_mapdev_attr(pa, size, VM_MEMATTR_UNCACHEABLE);
> +}
> +
>  void
>  pmap_unmapdev(vm_offset_t va, vm_size_t size)
>  {
> @@ -3220,7 +3228,7 @@ retry:
>                  * This may falsely report the given address as
>                  * MINCORE_REFERENCED.  Unfortunately, due to the lack of
>                  * per-PTE reference information, it is impossible to
> -                * determine if the address is MINCORE_REFERENCED.
> +                * determine if the address is MINCORE_REFERENCED.
>                  */
>                 m =3D PHYS_TO_VM_PAGE(pa);
>                 if ((m->aflags & PGA_REFERENCED) !=3D 0)
> @@ -3500,7 +3508,7 @@ pmap_kextract(vm_offset_t va)
>         mapped =3D (va >=3D MIPS_KSEG2_START || va < MIPS_KSEG2_END);
>  #if defined(__mips_n64)
>         mapped =3D mapped || (va >=3D MIPS_XKSEG_START || va < MIPS_XKSEG=
_END);
> -#endif
> +#endif
>         /*
>          * Kernel virtual.
>          */
> @@ -3524,7 +3532,7 @@ pmap_kextract(vm_offset_t va)
>  }
>
>
> -void
> +void
>  pmap_flush_pvcache(vm_page_t m)
>  {
>         pv_entry_t pv;
> @@ -3551,12 +3559,85 @@ pmap_page_set_memattr(vm_page_t m, vm_me
>         if (TAILQ_FIRST(&m->md.pv_list) !=3D NULL)
>                 panic("Can't change memattr on page with existing mapping=
s");
>
> -       /*
> -        * The only memattr we support is UNCACHEABLE, translate the (sem=
i-)MI
> -        * representation of that into our internal flag in the page MD s=
truct.
> -        */
> -       if (ma =3D=3D VM_MEMATTR_UNCACHEABLE)
> -               m->md.pv_flags |=3D PV_MEMATTR_UNCACHEABLE;
> -       else
> -               m->md.pv_flags &=3D ~PV_MEMATTR_UNCACHEABLE;
> +       /* Clean memattr portion of pv_flags */
> +       m->md.pv_flags &=3D ~PV_MEMATTR_MASK;
> +       m->md.pv_flags |=3D (ma << PV_MEMATTR_SHIFT) & PV_MEMATTR_MASK;
> +}
> +
> +static __inline void
> +pmap_pte_attr(pt_entry_t *pte, vm_memattr_t ma)
> +{
> +       u_int npte;
> +
> +       npte =3D *(u_int *)pte;
> +       npte &=3D ~PTE_C_MASK;
> +       npte |=3D PTE_C(ma);
> +       *pte =3D npte;
> +}
> +
> +int
> +pmap_change_attr(vm_offset_t sva, vm_size_t size, vm_memattr_t ma)
> +{
> +       pd_entry_t *pde, *pdpe;
> +       pt_entry_t *pte;
> +       vm_offset_t ova, eva, va, va_next;
> +       pmap_t pmap;
> +
> +       ova =3D sva;
> +       eva =3D sva + size;
> +       if (eva < sva)
> +               return (EINVAL);
> +
> +       pmap =3D kernel_pmap;
> +       PMAP_LOCK(pmap);
> +
> +       for (; sva < eva; sva =3D va_next) {
> +               pdpe =3D pmap_segmap(pmap, sva);
> +#ifdef __mips_n64
> +               if (*pdpe =3D=3D 0) {
> +                       va_next =3D (sva + NBSEG) & ~SEGMASK;
> +                       if (va_next < sva)
> +                               va_next =3D eva;
> +                       continue;
> +               }
> +#endif
> +               va_next =3D (sva + NBPDR) & ~PDRMASK;
> +               if (va_next < sva)
> +                       va_next =3D eva;
> +
> +               pde =3D pmap_pdpe_to_pde(pdpe, sva);
> +               if (*pde =3D=3D NULL)
> +                       continue;
> +
> +               /*
> +                * Limit our scan to either the end of the va represented
> +                * by the current page table page, or to the end of the
> +                * range being removed.
> +                */
> +               if (va_next > eva)
> +                       va_next =3D eva;
> +
> +               va =3D va_next;
> +               for (pte =3D pmap_pde_to_pte(pde, sva); sva !=3D va_next;=
 pte++,
> +                   sva +=3D PAGE_SIZE) {
> +                       if (!pte_test(pte, PTE_V) || pte_cache_bits(pte) =
=3D=3D ma) {
> +                               if (va !=3D va_next) {
> +                                       pmap_invalidate_range(pmap, va, s=
va);
> +                                       va =3D va_next;
> +                               }
> +                               continue;
> +                       }
> +                       if (va =3D=3D va_next)
> +                               va =3D sva;
> +
> +                       pmap_pte_attr(pte, ma);
> +               }
> +               if (va !=3D va_next)
> +                       pmap_invalidate_range(pmap, va, sva);
> +       }
> +       PMAP_UNLOCK(pmap);
> +
> +       /* Flush caches to be in the safe side */
> +       mips_dcache_wbinv_range(ova, size);
> +       return 0;
>  }
>

From owner-svn-src-all@freebsd.org  Wed Dec 28 06:10:59 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8FFB7C92CD2;
 Wed, 28 Dec 2016 06:10:59 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 5F8671CE4;
 Wed, 28 Dec 2016 06:10:59 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS6Aw1r027880;
 Wed, 28 Dec 2016 06:10:58 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS6AwlU027879;
 Wed, 28 Dec 2016 06:10:58 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280610.uBS6AwlU027879@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 06:10:58 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310669 - head/usr.sbin/bsnmpd/modules/snmp_pf
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 06:10:59 -0000

Author: ngie
Date: Wed Dec 28 06:10:58 2016
New Revision: 310669
URL: https://svnweb.freebsd.org/changeset/base/310669

Log:
  style(9): clean up whitespace
  
  MFC after:	3 days

Modified:
  head/usr.sbin/bsnmpd/modules/snmp_pf/pf_snmp.c

Modified: head/usr.sbin/bsnmpd/modules/snmp_pf/pf_snmp.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_pf/pf_snmp.c	Wed Dec 28 05:43:14 2016	(r310668)
+++ head/usr.sbin/bsnmpd/modules/snmp_pf/pf_snmp.c	Wed Dec 28 06:10:58 2016	(r310669)
@@ -1640,20 +1640,20 @@ err:
 static int
 altq_is_enabled(int pfdev)
 {
-        struct pfioc_altq pa;
+	struct pfioc_altq pa;
 
 	errno = 0;
-        if (ioctl(pfdev, DIOCGETALTQS, &pa)) {
-                if (errno == ENODEV) {
+	if (ioctl(pfdev, DIOCGETALTQS, &pa)) {
+		if (errno == ENODEV) {
 			syslog(LOG_INFO, "No ALTQ support in kernel\n"
 			    "ALTQ related functions disabled\n");
-                        return (0);
-                } else
-                        syslog(LOG_ERR, "DIOCGETALTQS returned an error: %s",
+			return (0);
+		} else
+			syslog(LOG_ERR, "DIOCGETALTQS returned an error: %s",
 			    strerror(errno));
 			return (-1);
-        }
-        return (1);
+	}
+	return (1);
 }
 
 /*

From owner-svn-src-all@freebsd.org  Wed Dec 28 06:14:51 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5F4BC92EFC;
 Wed, 28 Dec 2016 06:14:51 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B530910B2;
 Wed, 28 Dec 2016 06:14:51 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS6EoJe031620;
 Wed, 28 Dec 2016 06:14:50 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS6EoRt031619;
 Wed, 28 Dec 2016 06:14:50 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280614.uBS6EoRt031619@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 06:14:50 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310670 - stable/11/contrib/bsnmp/snmp_target
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 06:14:52 -0000

Author: ngie
Date: Wed Dec 28 06:14:50 2016
New Revision: 310670
URL: https://svnweb.freebsd.org/changeset/base/310670

Log:
  MFC r310503:
  
  style(9): delete stray trailing whitespace after break statement

Modified:
  stable/11/contrib/bsnmp/snmp_target/target_snmp.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/bsnmp/snmp_target/target_snmp.c
==============================================================================
--- stable/11/contrib/bsnmp/snmp_target/target_snmp.c	Wed Dec 28 06:10:58 2016	(r310669)
+++ stable/11/contrib/bsnmp/snmp_target/target_snmp.c	Wed Dec 28 06:14:50 2016	(r310670)
@@ -299,7 +299,7 @@ op_snmp_target_addrs(struct snmp_context
 				return (target_delete_address(addrs));
 			break;
 		default:
-			break;	
+			break;
 		}
 		return (SNMP_ERR_NOERROR);
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 06:15:40 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id BB0EAC92F72;
 Wed, 28 Dec 2016 06:15:40 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 89CFA1228;
 Wed, 28 Dec 2016 06:15:40 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS6FdCw031736;
 Wed, 28 Dec 2016 06:15:39 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS6FdTk031735;
 Wed, 28 Dec 2016 06:15:39 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280615.uBS6FdTk031735@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 06:15:39 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310671 - stable/10/contrib/bsnmp/snmp_target
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 06:15:40 -0000

Author: ngie
Date: Wed Dec 28 06:15:39 2016
New Revision: 310671
URL: https://svnweb.freebsd.org/changeset/base/310671

Log:
  MFstable/11 r310670:
  
  MFC r310503:
  
  style(9): delete stray trailing whitespace after break statement

Modified:
  stable/10/contrib/bsnmp/snmp_target/target_snmp.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/bsnmp/snmp_target/target_snmp.c
==============================================================================
--- stable/10/contrib/bsnmp/snmp_target/target_snmp.c	Wed Dec 28 06:14:50 2016	(r310670)
+++ stable/10/contrib/bsnmp/snmp_target/target_snmp.c	Wed Dec 28 06:15:39 2016	(r310671)
@@ -299,7 +299,7 @@ op_snmp_target_addrs(struct snmp_context
 				return (target_delete_address(addrs));
 			break;
 		default:
-			break;	
+			break;
 		}
 		return (SNMP_ERR_NOERROR);
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 06:16:20 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 71A69C92FE4;
 Wed, 28 Dec 2016 06:16:20 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 40DBA138D;
 Wed, 28 Dec 2016 06:16:20 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS6GJAr031816;
 Wed, 28 Dec 2016 06:16:19 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS6GJh4031815;
 Wed, 28 Dec 2016 06:16:19 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280616.uBS6GJh4031815@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 06:16:19 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject: svn commit: r310672 - stable/11/contrib/bsnmp/lib
X-SVN-Group: stable-11
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 06:16:20 -0000

Author: ngie
Date: Wed Dec 28 06:16:19 2016
New Revision: 310672
URL: https://svnweb.freebsd.org/changeset/base/310672

Log:
  MFC r310499:
  
  Sort #includes
  
  No functional change

Modified:
  stable/11/contrib/bsnmp/lib/snmp.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/contrib/bsnmp/lib/snmp.c
==============================================================================
--- stable/11/contrib/bsnmp/lib/snmp.c	Wed Dec 28 06:15:39 2016	(r310671)
+++ stable/11/contrib/bsnmp/lib/snmp.c	Wed Dec 28 06:16:19 2016	(r310672)
@@ -38,19 +38,19 @@
  */
 #include <sys/types.h>
 #include <sys/socket.h>
+#include <ctype.h>
+#include <errno.h>
+#include <netdb.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <stddef.h>
 #include <stdarg.h>
+#include <string.h>
 #ifdef HAVE_STDINT_H
 #include <stdint.h>
 #elif defined(HAVE_INTTYPES_H)
 #include <inttypes.h>
 #endif
-#include <string.h>
-#include <ctype.h>
-#include <netdb.h>
-#include <errno.h>
 
 #include "asn1.h"
 #include "snmp.h"

From owner-svn-src-all@freebsd.org  Wed Dec 28 06:16:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D8D1EC94082;
 Wed, 28 Dec 2016 06:16:56 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id A803B1579;
 Wed, 28 Dec 2016 06:16:56 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS6Gtch031902;
 Wed, 28 Dec 2016 06:16:55 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS6Gt5o031901;
 Wed, 28 Dec 2016 06:16:55 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280616.uBS6Gt5o031901@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 06:16:55 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject: svn commit: r310673 - stable/10/contrib/bsnmp/lib
X-SVN-Group: stable-10
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 06:16:57 -0000

Author: ngie
Date: Wed Dec 28 06:16:55 2016
New Revision: 310673
URL: https://svnweb.freebsd.org/changeset/base/310673

Log:
  MFstable/11 r310672:
  
  MFC r310499:
  
  Sort #includes
  
  No functional change

Modified:
  stable/10/contrib/bsnmp/lib/snmp.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/contrib/bsnmp/lib/snmp.c
==============================================================================
--- stable/10/contrib/bsnmp/lib/snmp.c	Wed Dec 28 06:16:19 2016	(r310672)
+++ stable/10/contrib/bsnmp/lib/snmp.c	Wed Dec 28 06:16:55 2016	(r310673)
@@ -38,19 +38,19 @@
  */
 #include <sys/types.h>
 #include <sys/socket.h>
+#include <ctype.h>
+#include <errno.h>
+#include <netdb.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <stddef.h>
 #include <stdarg.h>
+#include <string.h>
 #ifdef HAVE_STDINT_H
 #include <stdint.h>
 #elif defined(HAVE_INTTYPES_H)
 #include <inttypes.h>
 #endif
-#include <string.h>
-#include <ctype.h>
-#include <netdb.h>
-#include <errno.h>
 
 #include "asn1.h"
 #include "snmp.h"

From owner-svn-src-all@freebsd.org  Wed Dec 28 07:37:28 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 45D1BC90214;
 Wed, 28 Dec 2016 07:37:28 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id EF09E179E;
 Wed, 28 Dec 2016 07:37:27 +0000 (UTC)
 (envelope-from mmel@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS7bR6I065394;
 Wed, 28 Dec 2016 07:37:27 GMT (envelope-from mmel@FreeBSD.org)
Received: (from mmel@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS7bQQJ065391;
 Wed, 28 Dec 2016 07:37:26 GMT (envelope-from mmel@FreeBSD.org)
Message-Id: <201612280737.uBS7bQQJ065391@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: mmel set sender to
 mmel@FreeBSD.org using -f
From: Michal Meloun <mmel@FreeBSD.org>
Date: Wed, 28 Dec 2016 07:37:26 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310674 - head/sys/dev/sound/pci/hda
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 07:37:28 -0000

Author: mmel
Date: Wed Dec 28 07:37:26 2016
New Revision: 310674
URL: https://svnweb.freebsd.org/changeset/base/310674

Log:
  Limit number of stripes supported by HDA codec to maximum number
  announced by HDA controller.
  Incorrectly implermented HDA codec may report support for more stripes
  that HDA controller already have. Due to this, always limit number of
  enabled stripes by global controller maximum.
  
  Reviewed by:	mav
  MFC after:	1 month
  Differential Revision: https://reviews.freebsd.org/D8922

Modified:
  head/sys/dev/sound/pci/hda/hdaa.c
  head/sys/dev/sound/pci/hda/hdac.c
  head/sys/dev/sound/pci/hda/hdac.h

Modified: head/sys/dev/sound/pci/hda/hdaa.c
==============================================================================
--- head/sys/dev/sound/pci/hda/hdaa.c	Wed Dec 28 06:16:55 2016	(r310673)
+++ head/sys/dev/sound/pci/hda/hdaa.c	Wed Dec 28 07:37:26 2016	(r310674)
@@ -2130,7 +2130,8 @@ hdaa_channel_start(struct hdaa_chan *ch)
 	uint32_t fmt;
 
 	fmt = hdaa_stream_format(ch);
-	ch->stripectl = fls(ch->stripecap & hdaa_allowed_stripes(fmt)) - 1;
+	ch->stripectl = fls(ch->stripecap & hdaa_allowed_stripes(fmt) &
+	    hda_get_stripes_mask(devinfo->dev)) - 1;
 	ch->sid = HDAC_STREAM_ALLOC(device_get_parent(devinfo->dev), devinfo->dev,
 	    ch->dir == PCMDIR_PLAY ? 1 : 0, fmt, ch->stripectl, &ch->dmapos);
 	if (ch->sid <= 0)

Modified: head/sys/dev/sound/pci/hda/hdac.c
==============================================================================
--- head/sys/dev/sound/pci/hda/hdac.c	Wed Dec 28 06:16:55 2016	(r310673)
+++ head/sys/dev/sound/pci/hda/hdac.c	Wed Dec 28 07:37:26 2016	(r310674)
@@ -1767,6 +1767,9 @@ hdac_read_ivar(device_t dev, device_t ch
 	case HDA_IVAR_DMA_NOCACHE:
 		*result = (sc->flags & HDAC_F_DMA_NOCACHE) != 0;
 		break;
+	case HDA_IVAR_STRIPES_MASK:
+		*result = (1 << (1 << sc->num_sdo)) - 1;
+		break;
 	default:
 		return (ENOENT);
 	}

Modified: head/sys/dev/sound/pci/hda/hdac.h
==============================================================================
--- head/sys/dev/sound/pci/hda/hdac.h	Wed Dec 28 06:16:55 2016	(r310673)
+++ head/sys/dev/sound/pci/hda/hdac.h	Wed Dec 28 07:37:26 2016	(r310674)
@@ -707,6 +707,7 @@ enum hdac_device_ivars {
     HDA_IVAR_SUBSYSTEM_ID,
     HDA_IVAR_NODE_TYPE,
     HDA_IVAR_DMA_NOCACHE,
+    HDA_IVAR_STRIPES_MASK,
 };
 
 #define HDA_ACCESSOR(var, ivar, type)					\
@@ -723,6 +724,7 @@ HDA_ACCESSOR(subdevice_id,	SUBDEVICE_ID,
 HDA_ACCESSOR(subsystem_id,	SUBSYSTEM_ID,	uint32_t);
 HDA_ACCESSOR(node_type,		NODE_TYPE,	uint8_t);
 HDA_ACCESSOR(dma_nocache,	DMA_NOCACHE,	uint8_t);
+HDA_ACCESSOR(stripes_mask,	STRIPES_MASK,	uint8_t);
 
 #define PCIS_MULTIMEDIA_HDA    0x03
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 08:11:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8F502C90F6B;
 Wed, 28 Dec 2016 08:11:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 567AE1D0B;
 Wed, 28 Dec 2016 08:11:42 +0000 (UTC)
 (envelope-from ngie@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS8BfBp080250;
 Wed, 28 Dec 2016 08:11:41 GMT (envelope-from ngie@FreeBSD.org)
Received: (from ngie@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS8BfN9080249;
 Wed, 28 Dec 2016 08:11:41 GMT (envelope-from ngie@FreeBSD.org)
Message-Id: <201612280811.uBS8BfN9080249@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: ngie set sender to
 ngie@FreeBSD.org using -f
From: Ngie Cooper <ngie@FreeBSD.org>
Date: Wed, 28 Dec 2016 08:11:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310675 - head/usr.sbin/bsnmpd/modules/snmp_hostres
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 08:11:42 -0000

Author: ngie
Date: Wed Dec 28 08:11:41 2016
New Revision: 310675
URL: https://svnweb.freebsd.org/changeset/base/310675

Log:
  Fix the build by moving the initializers for len/nswapdev down below the
  declarations
  
  MFC after:	3 days
  Pointyhat to:	ngie

Modified:
  head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c

Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c
==============================================================================
--- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c	Wed Dec 28 07:37:26 2016	(r310674)
+++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_storage_tbl.c	Wed Dec 28 08:11:41 2016	(r310675)
@@ -376,8 +376,11 @@ storage_OS_get_swap(void)
 {
 	struct storage_entry *entry;
 	char swap_w_prefix[SE_DESC_MLEN];
-	size_t len = sizeof(nswapdev);
-	int nswapdev = 0;
+	size_t len;
+	int nswapdev;
+
+	len = sizeof(nswapdev);
+	nswapdev = 0;
 
 	if (sysctlbyname("vm.nswapdev", &nswapdev, &len, NULL,0 ) < 0) {
 		syslog(LOG_ERR,

From owner-svn-src-all@freebsd.org  Wed Dec 28 09:32:03 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85898C94D1E;
 Wed, 28 Dec 2016 09:32:03 +0000 (UTC)
 (envelope-from avos@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 6018017C2;
 Wed, 28 Dec 2016 09:32:03 +0000 (UTC)
 (envelope-from avos@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBS9W2ML015894;
 Wed, 28 Dec 2016 09:32:02 GMT (envelope-from avos@FreeBSD.org)
Received: (from avos@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBS9W20h015892;
 Wed, 28 Dec 2016 09:32:02 GMT (envelope-from avos@FreeBSD.org)
Message-Id: <201612280932.uBS9W20h015892@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: avos set sender to
 avos@FreeBSD.org using -f
From: Andriy Voskoboinyk <avos@FreeBSD.org>
Date: Wed, 28 Dec 2016 09:32:02 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310676 - in head: share/man/man4 tools/build/mk
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 09:32:03 -0000

Author: avos
Date: Wed Dec 28 09:32:02 2016
New Revision: 310676
URL: https://svnweb.freebsd.org/changeset/base/310676

Log:
  rum.4, run.4, runfw.4, zyd.4: do not install when MK_USB == no.
  
  While here, add missing if_rtwn_usb.4.gz symlink into
  OptionalObsoleteFiles.inc

Modified:
  head/share/man/man4/Makefile
  head/tools/build/mk/OptionalObsoleteFiles.inc

Modified: head/share/man/man4/Makefile
==============================================================================
--- head/share/man/man4/Makefile	Wed Dec 28 08:11:41 2016	(r310675)
+++ head/share/man/man4/Makefile	Wed Dec 28 09:32:02 2016	(r310676)
@@ -438,9 +438,6 @@ MAN=	aac.4 \
 	rtwnfw.4 \
 	rtwn_pci.4 \
 	rue.4 \
-	rum.4 \
-	run.4 \
-	runfw.4 \
 	sa.4 \
 	safe.4 \
 	sbp.4 \
@@ -574,8 +571,7 @@ MAN=	aac.4 \
 	xl.4 \
 	${_xnb.4} \
 	xpt.4 \
-	zero.4 \
-	zyd.4
+	zero.4
 
 MLINKS=	ae.4 if_ae.4
 MLINKS+=age.4 if_age.4
@@ -710,8 +706,6 @@ MLINKS+=rl.4 if_rl.4
 MLINKS+=rtwn.4 if_rtwn.4
 MLINKS+=rtwn_pci.4 if_rtwn_pci.4
 MLINKS+=rue.4 if_rue.4
-MLINKS+=rum.4 if_rum.4
-MLINKS+=run.4 if_run.4
 MLINKS+=scsi.4 CAM.4 \
 	scsi.4 cam.4 \
 	scsi.4 scbus.4 \
@@ -756,7 +750,6 @@ MLINKS+=wi.4 if_wi.4
 MLINKS+=${_wpi.4} ${_if_wpi.4}
 MLINKS+=xe.4 if_xe.4
 MLINKS+=xl.4 if_xl.4
-MLINKS+=zyd.4 if_zyd.4
 
 .if ${MACHINE_CPUARCH} == "aarch64"
 _armv8crypto.4=	armv8crypto.4
@@ -915,6 +908,9 @@ MAN+=	\
 	rsu.4 \
 	rsufw.4 \
 	rtwn_usb.4 \
+	rum.4 \
+	run.4 \
+	runfw.4 \
 	u3g.4 \
 	uark.4 \
 	uart.4 \
@@ -965,10 +961,13 @@ MAN+=	\
 	utopia.4 \
 	uvisor.4 \
 	uvscom.4 \
+	zyd.4
 
 MLINKS+=otus.4 if_otus.4
 MLINKS+=rsu.4 if_rsu.4
 MLINKS+=rtwn_usb.4 if_rtwn_usb.4
+MLINKS+=rum.4 if_rum.4
+MLINKS+=run.4 if_run.4
 MLINKS+=u3g.4 u3gstub.4
 MLINKS+=uath.4 if_uath.4
 MLINKS+=udav.4 if_udav.4
@@ -976,6 +975,7 @@ MLINKS+=upgt.4 if_upgt.4
 MLINKS+=ural.4 if_ural.4
 MLINKS+=urndis.4 if_urndis.4
 MLINKS+=${_urtw.4} ${_if_urtw.4}
+MLINKS+=zyd.4 if_zyd.4
 .endif
 
 .include <bsd.prog.mk>

Modified: head/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 08:11:41 2016	(r310675)
+++ head/tools/build/mk/OptionalObsoleteFiles.inc	Wed Dec 28 09:32:02 2016	(r310676)
@@ -8870,11 +8870,18 @@ OLD_FILES+=usr/share/man/man3/usb_strerr
 OLD_FILES+=usr/share/man/man3/usbhid.3.gz
 OLD_FILES+=usr/share/man/man4/if_otus.4.gz
 OLD_FILES+=usr/share/man/man4/if_rsu.4.gz
+OLD_FILES+=usr/share/man/man4/if_rtwn_usb.4.gz
+OLD_FILES+=usr/share/man/man4/if_rum.4.gz
+OLD_FILES+=usr/share/man/man4/if_run.4.gz
+OLD_FILES+=usr/share/man/man4/if_zyd.4.gz
 OLD_FILES+=usr/share/man/man4/otus.4.gz
 OLD_FILES+=usr/share/man/man4/otusfw.4.gz
 OLD_FILES+=usr/share/man/man4/rsu.4.gz
 OLD_FILES+=usr/share/man/man4/rsufw.4.gz
 OLD_FILES+=usr/share/man/man4/rtwn_usb.4.gz
+OLD_FILES+=usr/share/man/man4/rum.4.gz
+OLD_FILES+=usr/share/man/man4/run.4.gz
+OLD_FILES+=usr/share/man/man4/runfw.4.gz
 OLD_FILES+=usr/share/man/man4/u3g.4.gz
 OLD_FILES+=usr/share/man/man4/u3gstub.4.gz
 OLD_FILES+=usr/share/man/man4/uark.4.gz
@@ -8924,6 +8931,7 @@ OLD_FILES+=usr/share/man/man4/uslcom.4.g
 OLD_FILES+=usr/share/man/man4/utopia.4.gz
 OLD_FILES+=usr/share/man/man4/uvisor.4.gz
 OLD_FILES+=usr/share/man/man4/uvscom.4.gz
+OLD_FILES+=usr/share/man/man4/zyd.4.gz
 OLD_FILES+=usr/share/man/man8/uathload.8.gz
 OLD_FILES+=usr/share/man/man8/usbconfig.8.gz
 OLD_FILES+=usr/share/man/man8/usbdump.8.gz

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:39:12 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8156CC93EFD;
 Wed, 28 Dec 2016 10:39:12 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 50F721038;
 Wed, 28 Dec 2016 10:39:12 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAdBbA040464;
 Wed, 28 Dec 2016 10:39:11 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAdB1T040463;
 Wed, 28 Dec 2016 10:39:11 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281039.uBSAdB1T040463@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:39:11 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310677 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:39:12 -0000

Author: arybchik
Date: Wed Dec 28 10:39:11 2016
New Revision: 310677
URL: https://svnweb.freebsd.org/changeset/base/310677

Log:
  sfxge(4): cleanup: fix typo in siena_mac_loopback_set() instrumentation
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/siena_mac.c

Modified: head/sys/dev/sfxge/common/siena_mac.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_mac.c	Wed Dec 28 09:32:02 2016	(r310676)
+++ head/sys/dev/sfxge/common/siena_mac.c	Wed Dec 28 10:39:11 2016	(r310677)
@@ -223,7 +223,7 @@ siena_mac_loopback_set(
 	return (0);
 
 fail1:
-	EFSYS_PROBE(fail2);
+	EFSYS_PROBE1(fail1, efx_rc_t, rc);
 
 	epp->ep_loopback_type = old_loopback_type;
 	epp->ep_loopback_link_mode = old_loopback_link_mode;

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:40:23 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 06852C940B3;
 Wed, 28 Dec 2016 10:40:23 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id CA0931337;
 Wed, 28 Dec 2016 10:40:22 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAeLFS040567;
 Wed, 28 Dec 2016 10:40:22 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAeLrL040566;
 Wed, 28 Dec 2016 10:40:21 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281040.uBSAeLrL040566@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:40:21 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310678 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:40:23 -0000

Author: arybchik
Date: Wed Dec 28 10:40:21 2016
New Revision: 310678
URL: https://svnweb.freebsd.org/changeset/base/310678

Log:
  sfxge(4): cleanup: remove trailing whitespace
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_types.h

Modified: head/sys/dev/sfxge/common/efx_types.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 10:39:11 2016	(r310677)
+++ head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 10:40:21 2016	(r310678)
@@ -1310,7 +1310,7 @@ extern int fix_lint;
 /*
  * Set or clear a numbered bit within an octword.
  */
- 
+
 #define	EFX_SHIFT64(_bit, _base)					\
 	(((_bit) >= (_base) && (_bit) < (_base) + 64) ?			\
 		((uint64_t)1 << ((_bit) - (_base))) :			\

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:43:06 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id F3E19C94251;
 Wed, 28 Dec 2016 10:43:05 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C3655179D;
 Wed, 28 Dec 2016 10:43:05 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAh4n1044487;
 Wed, 28 Dec 2016 10:43:04 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAh4vC044486;
 Wed, 28 Dec 2016 10:43:04 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281043.uBSAh4vC044486@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:43:04 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310679 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:43:06 -0000

Author: arybchik
Date: Wed Dec 28 10:43:04 2016
New Revision: 310679
URL: https://svnweb.freebsd.org/changeset/base/310679

Log:
  sfxge(4): cleanup: fix wrong indent
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_tx.c

Modified: head/sys/dev/sfxge/common/efx_tx.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_tx.c	Wed Dec 28 10:40:21 2016	(r310678)
+++ head/sys/dev/sfxge/common/efx_tx.c	Wed Dec 28 10:43:04 2016	(r310679)
@@ -329,7 +329,7 @@ efx_tx_qcreate(
 
 	if ((rc = etxop->etxo_qcreate(enp, index, label, esmp,
 	    n, id, flags, eep, etp, addedp)) != 0)
-			goto fail2;
+		goto fail2;
 
 	enp->en_tx_qcount++;
 	*etpp = etp;

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:44:04 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id F3602C942D5;
 Wed, 28 Dec 2016 10:44:04 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C2C8F1945;
 Wed, 28 Dec 2016 10:44:04 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAi39g044582;
 Wed, 28 Dec 2016 10:44:03 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAi3ki044581;
 Wed, 28 Dec 2016 10:44:03 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281044.uBSAi3ki044581@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:44:03 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310680 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:44:05 -0000

Author: arybchik
Date: Wed Dec 28 10:44:03 2016
New Revision: 310680
URL: https://svnweb.freebsd.org/changeset/base/310680

Log:
  sfxge(4): cleanup: use spaces around binary arithmetic operations
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_lic.c

Modified: head/sys/dev/sfxge/common/efx_lic.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:43:04 2016	(r310679)
+++ head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:44:03 2016	(r310680)
@@ -456,7 +456,7 @@ fail1:
  *  Value (V):  L bytes - payload
  */
 #define EFX_LICENSE_V1V2_PAYLOAD_LENGTH_MAX    (256)
-#define EFX_LICENSE_V1V2_HEADER_LENGTH         (2*sizeof(uint16_t))
+#define EFX_LICENSE_V1V2_HEADER_LENGTH         (2 * sizeof(uint16_t))
 
 	__checkReturn		efx_rc_t
 efx_lic_v1v2_find_start(
@@ -1082,9 +1082,10 @@ efx_mcdi_licensing_v3_get_id(
 	} else {
 		/* Shift ID down to start of buffer */
 		memmove(bufferp,
-		  bufferp+MC_CMD_LICENSING_GET_ID_V3_OUT_LICENSE_ID_OFST,
-		  *lengthp);
-		memset(bufferp+(*lengthp), 0, MC_CMD_LICENSING_GET_ID_V3_OUT_LICENSE_ID_OFST);
+		    bufferp + MC_CMD_LICENSING_GET_ID_V3_OUT_LICENSE_ID_OFST,
+		    *lengthp);
+		memset(bufferp + (*lengthp), 0,
+		    MC_CMD_LICENSING_GET_ID_V3_OUT_LICENSE_ID_OFST);
 	}
 
 	return (0);

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:45:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 13C0DC9435B;
 Wed, 28 Dec 2016 10:45:16 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id D75C01AD5;
 Wed, 28 Dec 2016 10:45:15 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAjFYU044673;
 Wed, 28 Dec 2016 10:45:15 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAjEi3044671;
 Wed, 28 Dec 2016 10:45:14 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281045.uBSAjEi3044671@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:45:14 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310681 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:45:16 -0000

Author: arybchik
Date: Wed Dec 28 10:45:14 2016
New Revision: 310681
URL: https://svnweb.freebsd.org/changeset/base/310681

Log:
  sfxge(4): cleanup: remove unnecessary spaces
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_impl.h
  head/sys/dev/sfxge/common/efx_lic.c

Modified: head/sys/dev/sfxge/common/efx_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 10:44:03 2016	(r310680)
+++ head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 10:45:14 2016	(r310681)
@@ -564,7 +564,7 @@ typedef struct efx_lic_ops_s {
 	efx_rc_t	(*elo_find_start)
 				(efx_nic_t *, caddr_t, size_t, uint32_t *);
 	efx_rc_t	(*elo_find_end)(efx_nic_t *, caddr_t, size_t,
-				uint32_t , uint32_t *);
+				uint32_t, uint32_t *);
 	boolean_t	(*elo_find_key)(efx_nic_t *, caddr_t, size_t,
 				uint32_t, uint32_t *, uint32_t *);
 	boolean_t	(*elo_validate_key)(efx_nic_t *,

Modified: head/sys/dev/sfxge/common/efx_lic.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:44:03 2016	(r310680)
+++ head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:45:14 2016	(r310681)
@@ -627,7 +627,7 @@ efx_lic_v1v2_write_key(
 
 	// Ensure space for terminator remains
 	if ((offset + length) >
-	    (buffer_size - EFX_LICENSE_V1V2_HEADER_LENGTH) ) {
+	    (buffer_size - EFX_LICENSE_V1V2_HEADER_LENGTH)) {
 		rc = ENOSPC;
 		goto fail1;
 	}

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:47:05 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id EEF01C943E7;
 Wed, 28 Dec 2016 10:47:05 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C8EB81C89;
 Wed, 28 Dec 2016 10:47:05 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAl4BK044777;
 Wed, 28 Dec 2016 10:47:04 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAl48D044774;
 Wed, 28 Dec 2016 10:47:04 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281047.uBSAl48D044774@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:47:04 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310682 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:47:06 -0000

Author: arybchik
Date: Wed Dec 28 10:47:04 2016
New Revision: 310682
URL: https://svnweb.freebsd.org/changeset/base/310682

Log:
  sfxge(4): cleanup: avoid C99 // comments
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/ef10_ev.c
  head/sys/dev/sfxge/common/ef10_nvram.c
  head/sys/dev/sfxge/common/efx_lic.c

Modified: head/sys/dev/sfxge/common/ef10_ev.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_ev.c	Wed Dec 28 10:45:14 2016	(r310681)
+++ head/sys/dev/sfxge/common/ef10_ev.c	Wed Dec 28 10:47:04 2016	(r310682)
@@ -800,7 +800,7 @@ ef10_ev_rx(
 		 * or headers that are too long for the parser.
 		 * Headers and checksums must be validated by the host.
 		 */
-		// TODO: EFX_EV_QSTAT_INCR(eep, EV_RX_PARSE_INCOMPLETE);
+		/* TODO: EFX_EV_QSTAT_INCR(eep, EV_RX_PARSE_INCOMPLETE); */
 		goto deliver;
 	}
 

Modified: head/sys/dev/sfxge/common/ef10_nvram.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_nvram.c	Wed Dec 28 10:45:14 2016	(r310681)
+++ head/sys/dev/sfxge/common/ef10_nvram.c	Wed Dec 28 10:47:04 2016	(r310682)
@@ -852,7 +852,7 @@ ef10_nvram_buffer_find_item_start(
 	__in			size_t buffer_size,
 	__out			uint32_t *startp)
 {
-	// Read past partition header to find start address of the first key
+	/* Read past partition header to find start address of the first key */
 	tlv_cursor_t cursor;
 	efx_rc_t rc;
 
@@ -898,7 +898,7 @@ ef10_nvram_buffer_find_end(
 	__in			uint32_t offset,
 	__out			uint32_t *endp)
 {
-	// Read to end of partition
+	/* Read to end of partition */
 	tlv_cursor_t cursor;
 	efx_rc_t rc;
 	uint32_t *segment_used;
@@ -956,7 +956,7 @@ ef10_nvram_buffer_find_item(
 	__out			uint32_t *startp,
 	__out			uint32_t *lengthp)
 {
-	// Find TLV at offset and return key start and length
+	/* Find TLV at offset and return key start and length */
 	tlv_cursor_t cursor;
 	uint8_t *key;
 	uint32_t tag;

Modified: head/sys/dev/sfxge/common/efx_lic.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:45:14 2016	(r310681)
+++ head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:47:04 2016	(r310682)
@@ -625,7 +625,7 @@ efx_lic_v1v2_write_key(
 	EFSYS_ASSERT(length <= (EFX_LICENSE_V1V2_PAYLOAD_LENGTH_MAX +
 	    EFX_LICENSE_V1V2_HEADER_LENGTH));
 
-	// Ensure space for terminator remains
+	/* Ensure space for terminator remains */
 	if ((offset + length) >
 	    (buffer_size - EFX_LICENSE_V1V2_HEADER_LENGTH)) {
 		rc = ENOSPC;
@@ -662,7 +662,7 @@ efx_lic_v1v2_delete_key(
 	_NOTE(ARGUNUSED(enp))
 	EFSYS_ASSERT(end <= buffer_size);
 
-	// Shift everything after the key down
+	/* Shift everything after the key down */
 	memmove(bufferp + offset, bufferp + move_start, move_length);
 
 	*deltap = length;
@@ -681,7 +681,7 @@ efx_lic_v1v2_create_partition(
 	_NOTE(ARGUNUSED(enp))
 	EFSYS_ASSERT(EFX_LICENSE_V1V2_HEADER_LENGTH <= buffer_size);
 
-	// Write terminator
+	/* Write terminator */
 	memset(bufferp, '\0', EFX_LICENSE_V1V2_HEADER_LENGTH);
 	return (0);
 }
@@ -1155,7 +1155,7 @@ efx_lic_v3_validate_key(
 	__in			uint32_t length
 	)
 {
-	// Check key is a valid V3 key
+	/* Check key is a valid V3 key */
 	uint8_t key_type;
 	uint8_t key_length;
 
@@ -1272,7 +1272,7 @@ efx_lic_v3_create_partition(
 {
 	efx_rc_t rc;
 
-	// Construct empty partition
+	/* Construct empty partition */
 	if ((rc = ef10_nvram_buffer_create(enp,
 	    NVRAM_PARTITION_TYPE_LICENSE,
 	    bufferp, buffer_size)) != 0) {
@@ -1303,7 +1303,7 @@ efx_lic_v3_finish_partition(
 		goto fail1;
 	}
 
-	// Validate completed partition
+	/* Validate completed partition */
 	if ((rc = ef10_nvram_buffer_validate(enp, NVRAM_PARTITION_TYPE_LICENSE,
 					bufferp, buffer_size)) != 0) {
 		goto fail2;

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:48:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9819BC94458;
 Wed, 28 Dec 2016 10:48:16 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 679941DF9;
 Wed, 28 Dec 2016 10:48:16 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAmFbP044859;
 Wed, 28 Dec 2016 10:48:15 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAmFfv044858;
 Wed, 28 Dec 2016 10:48:15 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281048.uBSAmFfv044858@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:48:15 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310683 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:48:16 -0000

Author: arybchik
Date: Wed Dec 28 10:48:15 2016
New Revision: 310683
URL: https://svnweb.freebsd.org/changeset/base/310683

Log:
  sfxge(4): cleanup: pointer symbol should go together with struct member name
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/ef10_impl.h

Modified: head/sys/dev/sfxge/common/ef10_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/ef10_impl.h	Wed Dec 28 10:47:04 2016	(r310682)
+++ head/sys/dev/sfxge/common/ef10_impl.h	Wed Dec 28 10:48:15 2016	(r310683)
@@ -950,7 +950,7 @@ typedef struct ef10_filter_entry_s {
 
 typedef struct ef10_filter_table_s {
 	ef10_filter_entry_t	eft_entry[EFX_EF10_FILTER_TBL_ROWS];
-	efx_rxq_t *		eft_default_rxq;
+	efx_rxq_t		*eft_default_rxq;
 	boolean_t		eft_using_rss;
 	uint32_t		eft_unicst_filter_indexes[
 	    EFX_EF10_FILTER_UNICAST_FILTERS_MAX];

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:49:42 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6DD5EC94511;
 Wed, 28 Dec 2016 10:49:42 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 3D5F41FF8;
 Wed, 28 Dec 2016 10:49:42 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAnfDY044951;
 Wed, 28 Dec 2016 10:49:41 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAnf9o044950;
 Wed, 28 Dec 2016 10:49:41 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281049.uBSAnf9o044950@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:49:41 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310684 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:49:42 -0000

Author: arybchik
Date: Wed Dec 28 10:49:41 2016
New Revision: 310684
URL: https://svnweb.freebsd.org/changeset/base/310684

Log:
  sfxge(4): cleanup: remove trailing whitespaces
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_types.h

Modified: head/sys/dev/sfxge/common/efx_types.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 10:48:15 2016	(r310683)
+++ head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 10:49:41 2016	(r310684)
@@ -238,7 +238,7 @@ typedef union efx_oword_u {
 #endif
 #if EFSYS_HAS_UINT64
 	uint64_t eo_u64[2];
-#endif	
+#endif
 	uint32_t eo_u32[4];
 	uint16_t eo_u16[8];
 	uint8_t eo_u8[16];

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:52:06 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 52899C94742;
 Wed, 28 Dec 2016 10:52:06 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 21C1614E1;
 Wed, 28 Dec 2016 10:52:06 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSAq53V047498;
 Wed, 28 Dec 2016 10:52:05 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSAq5Ua047255;
 Wed, 28 Dec 2016 10:52:05 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281052.uBSAq5Ua047255@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:52:05 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310685 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:52:06 -0000

Author: arybchik
Date: Wed Dec 28 10:52:04 2016
New Revision: 310685
URL: https://svnweb.freebsd.org/changeset/base/310685

Log:
  sfxge(4): cleanup: open brace should be on a type name line
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx.h
  head/sys/dev/sfxge/common/efx_mcdi.c

Modified: head/sys/dev/sfxge/common/efx.h
==============================================================================
--- head/sys/dev/sfxge/common/efx.h	Wed Dec 28 10:49:41 2016	(r310684)
+++ head/sys/dev/sfxge/common/efx.h	Wed Dec 28 10:52:04 2016	(r310685)
@@ -212,8 +212,7 @@ typedef enum efx_mcdi_exception_e {
 } efx_mcdi_exception_t;
 
 #if EFSYS_OPT_MCDI_LOGGING
-typedef enum efx_log_msg_e
-{
+typedef enum efx_log_msg_e {
 	EFX_LOG_INVALID,
 	EFX_LOG_MCDI_REQUEST,
 	EFX_LOG_MCDI_RESPONSE,
@@ -1172,8 +1171,7 @@ efx_nic_cfg_get(
 	__in		efx_nic_t *enp);
 
 /* Driver resource limits (minimum required/maximum usable). */
-typedef struct efx_drv_limits_s
-{
+typedef struct efx_drv_limits_s {
 	uint32_t	edl_min_evq_count;
 	uint32_t	edl_max_evq_count;
 

Modified: head/sys/dev/sfxge/common/efx_mcdi.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mcdi.c	Wed Dec 28 10:49:41 2016	(r310684)
+++ head/sys/dev/sfxge/common/efx_mcdi.c	Wed Dec 28 10:52:04 2016	(r310685)
@@ -1728,8 +1728,7 @@ fail1:
 
 #if EFSYS_OPT_MAC_STATS
 
-typedef enum efx_stats_action_e
-{
+typedef enum efx_stats_action_e {
 	EFX_STATS_CLEAR,
 	EFX_STATS_UPLOAD,
 	EFX_STATS_ENABLE_NOEVENTS,

From owner-svn-src-all@freebsd.org  Wed Dec 28 10:53:55 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 11421C948C0;
 Wed, 28 Dec 2016 10:53:55 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id BAF0016C4;
 Wed, 28 Dec 2016 10:53:54 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSArrmx048857;
 Wed, 28 Dec 2016 10:53:53 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSArrb9048855;
 Wed, 28 Dec 2016 10:53:53 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281053.uBSArrb9048855@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 10:53:53 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310686 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 10:53:55 -0000

Author: arybchik
Date: Wed Dec 28 10:53:53 2016
New Revision: 310686
URL: https://svnweb.freebsd.org/changeset/base/310686

Log:
  sfxge(4): cleanup: add missing space between type and pointer symbol
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx.h
  head/sys/dev/sfxge/common/efx_lic.c

Modified: head/sys/dev/sfxge/common/efx.h
==============================================================================
--- head/sys/dev/sfxge/common/efx.h	Wed Dec 28 10:52:04 2016	(r310685)
+++ head/sys/dev/sfxge/common/efx.h	Wed Dec 28 10:53:53 2016	(r310686)
@@ -435,7 +435,7 @@ typedef enum efx_link_mode_e {
 
 #define	EFX_MAC_ADDR_LEN 6
 
-#define	EFX_MAC_ADDR_IS_MULTICAST(_address) (((uint8_t*)_address)[0] & 0x01)
+#define	EFX_MAC_ADDR_IS_MULTICAST(_address) (((uint8_t *)_address)[0] & 0x01)
 
 #define	EFX_MAC_MULTICAST_LIST_MAX	256
 

Modified: head/sys/dev/sfxge/common/efx_lic.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:52:04 2016	(r310685)
+++ head/sys/dev/sfxge/common/efx_lic.c	Wed Dec 28 10:53:53 2016	(r310686)
@@ -509,8 +509,8 @@ efx_lic_v1v2_find_key(
 	if ((size_t)buffer_size - offset < EFX_LICENSE_V1V2_HEADER_LENGTH)
 		goto fail1;
 
-	tlv_type = __LE_TO_CPU_16(((uint16_t*)&bufferp[offset])[0]);
-	tlv_length = __LE_TO_CPU_16(((uint16_t*)&bufferp[offset])[1]);
+	tlv_type = __LE_TO_CPU_16(((uint16_t *)&bufferp[offset])[0]);
+	tlv_length = __LE_TO_CPU_16(((uint16_t *)&bufferp[offset])[1]);
 	if ((tlv_length > EFX_LICENSE_V1V2_PAYLOAD_LENGTH_MAX) ||
 	    (tlv_type == 0 && tlv_length == 0)) {
 		found = B_FALSE;
@@ -543,8 +543,8 @@ efx_lic_v1v2_validate_key(
 		goto fail1;
 	}
 
-	tlv_type = __LE_TO_CPU_16(((uint16_t*)keyp)[0]);
-	tlv_length = __LE_TO_CPU_16(((uint16_t*)keyp)[1]);
+	tlv_type = __LE_TO_CPU_16(((uint16_t *)keyp)[0]);
+	tlv_length = __LE_TO_CPU_16(((uint16_t *)keyp)[1]);
 
 	if (tlv_length > EFX_LICENSE_V1V2_PAYLOAD_LENGTH_MAX) {
 		goto fail2;
@@ -1169,8 +1169,8 @@ efx_lic_v3_validate_key(
 		goto fail2;
 	}
 
-	key_type = ((uint8_t*)keyp)[0];
-	key_length = ((uint8_t*)keyp)[1];
+	key_type = ((uint8_t *)keyp)[0];
+	key_length = ((uint8_t *)keyp)[1];
 
 	if (key_type < 3) {
 		goto fail3;

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:01:03 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4E0E3C94AEB;
 Wed, 28 Dec 2016 11:01:03 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 0F09D19B1;
 Wed, 28 Dec 2016 11:01:02 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSB12Yx050598;
 Wed, 28 Dec 2016 11:01:02 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSB11o9050590;
 Wed, 28 Dec 2016 11:01:01 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281101.uBSB11o9050590@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:01:01 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310687 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:01:03 -0000

Author: arybchik
Date: Wed Dec 28 11:01:01 2016
New Revision: 310687
URL: https://svnweb.freebsd.org/changeset/base/310687

Log:
  sfxge(4): cleanup: use TAB to indent
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx.h
  head/sys/dev/sfxge/common/efx_impl.h
  head/sys/dev/sfxge/common/efx_phy.c
  head/sys/dev/sfxge/common/hunt_nic.c
  head/sys/dev/sfxge/common/mcdi_mon.c
  head/sys/dev/sfxge/common/medford_nic.c
  head/sys/dev/sfxge/common/siena_flash.h
  head/sys/dev/sfxge/common/siena_impl.h

Modified: head/sys/dev/sfxge/common/efx.h
==============================================================================
--- head/sys/dev/sfxge/common/efx.h	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/efx.h	Wed Dec 28 11:01:01 2016	(r310687)
@@ -847,7 +847,7 @@ typedef enum efx_phy_cap_type_e {
 extern		void
 efx_phy_adv_cap_get(
 	__in		efx_nic_t *enp,
-	__in            uint32_t flag,
+	__in		uint32_t flag,
 	__out		uint32_t *maskp);
 
 extern	__checkReturn	efx_rc_t
@@ -1132,20 +1132,20 @@ typedef struct efx_nic_cfg_s {
 	boolean_t		enc_rx_batching_enabled;
 	/* Maximum number of descriptors completed in an rx event. */
 	uint32_t		enc_rx_batch_max;
-        /* Number of rx descriptors the hardware requires for a push. */
-        uint32_t		enc_rx_push_align;
+	/* Number of rx descriptors the hardware requires for a push. */
+	uint32_t		enc_rx_push_align;
 	/*
 	 * Maximum number of bytes into the packet the TCP header can start for
 	 * the hardware to apply TSO packet edits.
 	 */
-	uint32_t                enc_tx_tso_tcp_header_offset_limit;
-	boolean_t               enc_fw_assisted_tso_enabled;
-	boolean_t               enc_fw_assisted_tso_v2_enabled;
-	boolean_t               enc_hw_tx_insert_vlan_enabled;
+	uint32_t		enc_tx_tso_tcp_header_offset_limit;
+	boolean_t		enc_fw_assisted_tso_enabled;
+	boolean_t		enc_fw_assisted_tso_v2_enabled;
+	boolean_t		enc_hw_tx_insert_vlan_enabled;
 	/* Datapath firmware vadapter/vport/vswitch support */
 	boolean_t		enc_datapath_cap_evb;
-	boolean_t               enc_rx_disable_scatter_supported;
-	boolean_t               enc_allow_set_mac_with_installed_filters;
+	boolean_t		enc_rx_disable_scatter_supported;
+	boolean_t		enc_allow_set_mac_with_installed_filters;
 	boolean_t		enc_enhanced_set_mac_supported;
 	boolean_t		enc_init_evq_v2_supported;
 	/* External port identifier */
@@ -1846,8 +1846,8 @@ typedef enum efx_rx_hash_support_e {
 } efx_rx_hash_support_t;
 
 #define	EFX_RSS_TBL_SIZE	128	/* Rows in RX indirection table */
-#define	EFX_MAXRSS	    	64	/* RX indirection entry range */
-#define	EFX_MAXRSS_LEGACY   	16 	/* See bug16611 and bug17213 */
+#define	EFX_MAXRSS		64	/* RX indirection entry range */
+#define	EFX_MAXRSS_LEGACY	16	/* See bug16611 and bug17213 */
 
 typedef enum efx_rx_scale_support_e {
 	EFX_RX_SCALE_UNAVAILABLE = 0,	/* Not supported */
@@ -2059,7 +2059,7 @@ efx_tx_qpio_write(
 	__in			efx_txq_t *etp,
 	__in_ecount(buf_length)	uint8_t *buffer,
 	__in			size_t buf_length,
-	__in                    size_t pio_buf_offset);
+	__in			size_t pio_buf_offset);
 
 extern	__checkReturn	efx_rc_t
 efx_tx_qpio_post(

Modified: head/sys/dev/sfxge/common/efx_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 11:01:01 2016	(r310687)
@@ -252,7 +252,7 @@ efx_filter_reconfigure(
 
 typedef struct efx_port_s {
 	efx_mac_type_t		ep_mac_type;
-	uint32_t  		ep_phy_type;
+	uint32_t		ep_phy_type;
 	uint8_t			ep_port;
 	uint32_t		ep_mac_pdu;
 	uint8_t			ep_mac_addr[6];
@@ -600,7 +600,7 @@ struct efx_nic_s {
 	uint32_t		en_features;
 	efsys_identifier_t	*en_esip;
 	efsys_lock_t		*en_eslp;
-	efsys_bar_t 		*en_esbp;
+	efsys_bar_t		*en_esbp;
 	unsigned int		en_mod_flags;
 	unsigned int		en_reset_flags;
 	efx_nic_cfg_t		en_nic_cfg;

Modified: head/sys/dev/sfxge/common/efx_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 11:01:01 2016	(r310687)
@@ -47,7 +47,7 @@ static const efx_phy_ops_t	__efx_phy_sie
 #endif	/* EFSYS_OPT_PHY_STATS */
 #if EFSYS_OPT_BIST
 	NULL,				/* epo_bist_enable_offline */
-	siena_phy_bist_start, 		/* epo_bist_start */
+	siena_phy_bist_start,		/* epo_bist_start */
 	siena_phy_bist_poll,		/* epo_bist_poll */
 	siena_phy_bist_stop,		/* epo_bist_stop */
 #endif	/* EFSYS_OPT_BIST */

Modified: head/sys/dev/sfxge/common/hunt_nic.c
==============================================================================
--- head/sys/dev/sfxge/common/hunt_nic.c	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/hunt_nic.c	Wed Dec 28 11:01:01 2016	(r310687)
@@ -83,7 +83,7 @@ hunt_nic_get_required_pcie_bandwidth(
 
 		if ((rc = ef10_nic_get_port_mode_bandwidth(max_port_mode,
 							    &bandwidth)) != 0)
-		    goto fail2;
+			goto fail2;
 	}
 
 out:
@@ -295,7 +295,7 @@ hunt_board_cfg(
 
 	/* Check capabilities of running datapath firmware */
 	if ((rc = ef10_get_datapath_caps(enp)) != 0)
-	    goto fail12;
+		goto fail12;
 
 	/* Alignment for receive packet DMA buffers */
 	encp->enc_rx_buf_align_start = 1;

Modified: head/sys/dev/sfxge/common/mcdi_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/mcdi_mon.c	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/mcdi_mon.c	Wed Dec 28 11:01:01 2016	(r310687)
@@ -155,8 +155,8 @@ static const struct mcdi_sensor_map_s {
 	STAT(Px, PHY0_VCC),		/* 0x4c PHY0_VCC */
 	STAT(Px, PHY1_VCC),		/* 0x4d PHY1_VCC */
 	STAT(Px, CONTROLLER_TDIODE_TEMP), /* 0x4e CONTROLLER_TDIODE_TEMP */
-	STAT(Px, BOARD_FRONT_TEMP), 	/* 0x4f BOARD_FRONT_TEMP */
-	STAT(Px, BOARD_BACK_TEMP), 	/* 0x50 BOARD_BACK_TEMP */
+	STAT(Px, BOARD_FRONT_TEMP),	/* 0x4f BOARD_FRONT_TEMP */
+	STAT(Px, BOARD_BACK_TEMP),	/* 0x50 BOARD_BACK_TEMP */
 };
 
 #define	MCDI_STATIC_SENSOR_ASSERT(_field)				\

Modified: head/sys/dev/sfxge/common/medford_nic.c
==============================================================================
--- head/sys/dev/sfxge/common/medford_nic.c	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/medford_nic.c	Wed Dec 28 11:01:01 2016	(r310687)
@@ -283,7 +283,7 @@ medford_board_cfg(
 
 	/* Check capabilities of running datapath firmware */
 	if ((rc = ef10_get_datapath_caps(enp)) != 0)
-	    goto fail10;
+		goto fail10;
 
 	/* Alignment for receive packet DMA buffers */
 	encp->enc_rx_buf_align_start = 1;

Modified: head/sys/dev/sfxge/common/siena_flash.h
==============================================================================
--- head/sys/dev/sfxge/common/siena_flash.h	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/siena_flash.h	Wed Dec 28 11:01:01 2016	(r310687)
@@ -127,7 +127,7 @@ typedef struct siena_mc_boot_hdr_s {		/*
 } siena_mc_boot_hdr_t;
 
 #define	SIENA_MC_BOOT_HDR_PADDING \
-  (SIENA_MC_BOOT_HDR_LEN - sizeof(siena_mc_boot_hdr_t))
+	(SIENA_MC_BOOT_HDR_LEN - sizeof(siena_mc_boot_hdr_t))
 
 #define	SIENA_MC_STATIC_CONFIG_MAGIC (0xBDCF5555)
 #define	SIENA_MC_STATIC_CONFIG_VERSION (0)

Modified: head/sys/dev/sfxge/common/siena_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/siena_impl.h	Wed Dec 28 10:53:53 2016	(r310686)
+++ head/sys/dev/sfxge/common/siena_impl.h	Wed Dec 28 11:01:01 2016	(r310687)
@@ -294,7 +294,7 @@ siena_vpd_fini(
 typedef struct siena_link_state_s {
 	uint32_t		sls_adv_cap_mask;
 	uint32_t		sls_lp_cap_mask;
-	unsigned int 		sls_fcntl;
+	unsigned int		sls_fcntl;
 	efx_link_mode_t		sls_link_mode;
 #if EFSYS_OPT_LOOPBACK
 	efx_loopback_type_t	sls_loopback;
@@ -362,7 +362,7 @@ siena_phy_bist_poll(
 	__in			efx_bist_type_t type,
 	__out			efx_bist_result_t *resultp,
 	__out_opt __drv_when(count > 0, __notnull)
-	uint32_t 	*value_maskp,
+	uint32_t	*value_maskp,
 	__out_ecount_opt(count)	__drv_when(count > 0, __notnull)
 	unsigned long	*valuesp,
 	__in			size_t count);

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:03:08 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1421DC94B77;
 Wed, 28 Dec 2016 11:03:08 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id D73D31D66;
 Wed, 28 Dec 2016 11:03:07 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSB37x6052782;
 Wed, 28 Dec 2016 11:03:07 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSB37Ik052781;
 Wed, 28 Dec 2016 11:03:07 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281103.uBSB37Ik052781@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:03:07 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310688 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:03:08 -0000

Author: arybchik
Date: Wed Dec 28 11:03:06 2016
New Revision: 310688
URL: https://svnweb.freebsd.org/changeset/base/310688

Log:
  sfxge(4): cleanup: avoid space just before TAB in efx_types.h
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_types.h

Modified: head/sys/dev/sfxge/common/efx_types.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:01:01 2016	(r310687)
+++ head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:03:06 2016	(r310688)
@@ -688,21 +688,21 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[0] = EFX_INSERT_FIELDS64(0, 63,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[1] = EFX_INSERT_FIELDS64(64, 127,	\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_POPULATE_OWORD32(_oword,					\
@@ -711,35 +711,35 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[0] = EFX_INSERT_FIELDS32(0, 31,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[1] = EFX_INSERT_FIELDS32(32, 63,	\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[2] = EFX_INSERT_FIELDS32(64, 95,	\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[3] = EFX_INSERT_FIELDS32(96, 127,	\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_POPULATE_QWORD64(_qword,					\
@@ -748,14 +748,14 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u64[0] = EFX_INSERT_FIELDS64(0, 63,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_POPULATE_QWORD32(_qword,					\
@@ -764,21 +764,21 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[0] = EFX_INSERT_FIELDS32(0, 31,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[1] = EFX_INSERT_FIELDS32(32, 63,	\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
 		    _field5, _value5, _field6, _value6,			\
 		    _field7, _value7, _field8, _value8,			\
 		    _field9, _value9, _field10, _value10);		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_POPULATE_DWORD(_dword,					\
@@ -787,7 +787,7 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_dword).ed_u32[0] = EFX_INSERT_FIELDS32(0, 31,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
@@ -803,7 +803,7 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_word).ew_u16[0] = EFX_INSERT_FIELDS16(0, 15,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
@@ -819,7 +819,7 @@ extern int fix_lint;
 	    _field7, _value7, _field8, _value8,	_field9, _value9,	\
 	    _field10, _value10)						\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_byte).eb_u8[0] = EFX_INSERT_FIELDS8(0, 7,		\
 		    _field1, _value1, _field2, _value2,			\
 		    _field3, _value3, _field4, _value4,			\
@@ -1226,85 +1226,85 @@ extern int fix_lint;
 
 #define	EFX_SET_OWORD_FIELD64(_oword, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[0] = (((_oword).eo_u64[0] &		\
 		    ~EFX_INPLACE_MASK64(0, 63, _field)) |		\
 		    EFX_INSERT_FIELD64(0, 63, _field, _value));		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[1] = (((_oword).eo_u64[1] &		\
 		    ~EFX_INPLACE_MASK64(64, 127, _field)) |		\
 		    EFX_INSERT_FIELD64(64, 127, _field, _value));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_OWORD_FIELD32(_oword, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[0] = (((_oword).eo_u32[0] &		\
 		    ~EFX_INPLACE_MASK32(0, 31, _field)) |		\
 		    EFX_INSERT_FIELD32(0, 31, _field, _value));		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[1] = (((_oword).eo_u32[1] &		\
 		    ~EFX_INPLACE_MASK32(32, 63, _field)) |		\
 		    EFX_INSERT_FIELD32(32, 63, _field, _value));	\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[2] = (((_oword).eo_u32[2] &		\
 		    ~EFX_INPLACE_MASK32(64, 95, _field)) |		\
 		    EFX_INSERT_FIELD32(64, 95, _field, _value));	\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[3] = (((_oword).eo_u32[3] &		\
 		    ~EFX_INPLACE_MASK32(96, 127, _field)) |		\
 		    EFX_INSERT_FIELD32(96, 127, _field, _value));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_QWORD_FIELD64(_qword, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u64[0] = (((_qword).eq_u64[0] &		\
 		    ~EFX_INPLACE_MASK64(0, 63, _field)) |		\
 		    EFX_INSERT_FIELD64(0, 63, _field, _value));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_QWORD_FIELD32(_qword, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[0] = (((_qword).eq_u32[0] &		\
 		    ~EFX_INPLACE_MASK32(0, 31, _field)) |		\
 		    EFX_INSERT_FIELD32(0, 31, _field, _value));		\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[1] = (((_qword).eq_u32[1] &		\
 		    ~EFX_INPLACE_MASK32(32, 63, _field)) |		\
 		    EFX_INSERT_FIELD32(32, 63, _field, _value));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_DWORD_FIELD(_dword, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_dword).ed_u32[0] = (((_dword).ed_u32[0] &		\
 		    ~EFX_INPLACE_MASK32(0, 31, _field)) |		\
 		    EFX_INSERT_FIELD32(0, 31, _field, _value));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_WORD_FIELD(_word, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_word).ew_u16[0] = (((_word).ew_u16[0] &		\
 		    ~EFX_INPLACE_MASK16(0, 15, _field)) |		\
 		    EFX_INSERT_FIELD16(0, 15, _field, _value));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_BYTE_FIELD(_byte, _field, _value)			\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_byte).eb_u8[0] = (((_byte).eb_u8[0] &			\
 		    ~EFX_INPLACE_MASK8(0, 7, _field)) |			\
 		    EFX_INSERT_FIELD8(0, 7, _field, _value));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 /*
@@ -1333,17 +1333,17 @@ extern int fix_lint;
 
 #define	EFX_SET_OWORD_BIT64(_oword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[0] |=					\
 		    __CPU_TO_LE_64(EFX_SHIFT64(_bit, FIX_LINT(0)));	\
 		(_oword).eo_u64[1] |=					\
 		    __CPU_TO_LE_64(EFX_SHIFT64(_bit, FIX_LINT(64)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_OWORD_BIT32(_oword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[0] |=					\
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(0)));	\
 		(_oword).eo_u32[1] |=					\
@@ -1352,22 +1352,22 @@ extern int fix_lint;
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(64)));	\
 		(_oword).eo_u32[3] |=					\
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(96)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_OWORD_BIT64(_oword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u64[0] &=					\
 		    __CPU_TO_LE_64(~EFX_SHIFT64(_bit, FIX_LINT(0)));	\
 		(_oword).eo_u64[1] &=					\
 		    __CPU_TO_LE_64(~EFX_SHIFT64(_bit, FIX_LINT(64)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_OWORD_BIT32(_oword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_oword).eo_u32[0] &=					\
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(0)));	\
 		(_oword).eo_u32[1] &=					\
@@ -1376,7 +1376,7 @@ extern int fix_lint;
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(64)));	\
 		(_oword).eo_u32[3] &=					\
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(96)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_TEST_OWORD_BIT64(_oword, _bit)				\
@@ -1398,38 +1398,38 @@ extern int fix_lint;
 
 #define	EFX_SET_QWORD_BIT64(_qword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u64[0] |=					\
 		    __CPU_TO_LE_64(EFX_SHIFT64(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_SET_QWORD_BIT32(_qword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[0] |=					\
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(0)));	\
 		(_qword).eq_u32[1] |=					\
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(32)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_QWORD_BIT64(_qword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u64[0] &=					\
 		    __CPU_TO_LE_64(~EFX_SHIFT64(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_QWORD_BIT32(_qword, _bit)				\
 	do {								\
-		_NOTE(CONSTANTCONDITION) 				\
+		_NOTE(CONSTANTCONDITION)				\
 		(_qword).eq_u32[0] &=					\
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(0)));	\
 		(_qword).eq_u32[1] &=					\
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(32)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_TEST_QWORD_BIT64(_qword, _bit)				\
@@ -1447,14 +1447,14 @@ extern int fix_lint;
 	do {								\
 		(_dword).ed_u32[0] |=					\
 		    __CPU_TO_LE_32(EFX_SHIFT32(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_DWORD_BIT(_dword, _bit)				\
 	do {								\
 		(_dword).ed_u32[0] &=					\
 		    __CPU_TO_LE_32(~EFX_SHIFT32(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_TEST_DWORD_BIT(_dword, _bit)				\
@@ -1466,14 +1466,14 @@ extern int fix_lint;
 	do {								\
 		(_word).ew_u16[0] |=					\
 		    __CPU_TO_LE_16(EFX_SHIFT16(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_WORD_BIT(_word, _bit)					\
 	do {								\
 		(_word).ew_u32[0] &=					\
 		    __CPU_TO_LE_16(~EFX_SHIFT16(_bit, FIX_LINT(0)));	\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_TEST_WORD_BIT(_word, _bit)					\
@@ -1485,14 +1485,14 @@ extern int fix_lint;
 	do {								\
 		(_byte).eb_u8[0] |=					\
 		    __NATIVE_8(EFX_SHIFT8(_bit, FIX_LINT(0)));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_CLEAR_BYTE_BIT(_byte, _bit)					\
 	do {								\
 		(_byte).eb_u8[0] &=					\
 		    __NATIVE_8(~EFX_SHIFT8(_bit, FIX_LINT(0)));		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_TEST_BYTE_BIT(_byte, _bit)					\
@@ -1504,7 +1504,7 @@ extern int fix_lint;
 	do {								\
 		(_oword1).eo_u64[0] |= (_oword2).eo_u64[0];		\
 		(_oword1).eo_u64[1] |= (_oword2).eo_u64[1];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_OWORD32(_oword1, _oword2)				\
@@ -1513,14 +1513,14 @@ extern int fix_lint;
 		(_oword1).eo_u32[1] |= (_oword2).eo_u32[1];		\
 		(_oword1).eo_u32[2] |= (_oword2).eo_u32[2];		\
 		(_oword1).eo_u32[3] |= (_oword2).eo_u32[3];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_OWORD64(_oword1, _oword2)				\
 	do {								\
 		(_oword1).eo_u64[0] &= (_oword2).eo_u64[0];		\
 		(_oword1).eo_u64[1] &= (_oword2).eo_u64[1];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_OWORD32(_oword1, _oword2)				\
@@ -1529,69 +1529,69 @@ extern int fix_lint;
 		(_oword1).eo_u32[1] &= (_oword2).eo_u32[1];		\
 		(_oword1).eo_u32[2] &= (_oword2).eo_u32[2];		\
 		(_oword1).eo_u32[3] &= (_oword2).eo_u32[3];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_QWORD64(_qword1, _qword2)				\
 	do {								\
 		(_qword1).eq_u64[0] |= (_qword2).eq_u64[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_QWORD32(_qword1, _qword2)				\
 	do {								\
 		(_qword1).eq_u32[0] |= (_qword2).eq_u32[0];		\
 		(_qword1).eq_u32[1] |= (_qword2).eq_u32[1];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_QWORD64(_qword1, _qword2)				\
 	do {								\
 		(_qword1).eq_u64[0] &= (_qword2).eq_u64[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_QWORD32(_qword1, _qword2)				\
 	do {								\
 		(_qword1).eq_u32[0] &= (_qword2).eq_u32[0];		\
 		(_qword1).eq_u32[1] &= (_qword2).eq_u32[1];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_DWORD(_dword1, _dword2)					\
 	do {								\
 		(_dword1).ed_u32[0] |= (_dword2).ed_u32[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_DWORD(_dword1, _dword2)					\
 	do {								\
 		(_dword1).ed_u32[0] &= (_dword2).ed_u32[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_WORD(_word1, _word2)					\
 	do {								\
 		(_word1).ew_u16[0] |= (_word2).ew_u16[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_WORD(_word1, _word2)					\
 	do {								\
 		(_word1).ew_u16[0] &= (_word2).ew_u16[0];		\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_OR_BYTE(_byte1, _byte2)					\
 	do {								\
 		(_byte1).eb_u8[0] |= (_byte2).eb_u8[0];			\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #define	EFX_AND_BYTE(_byte1, _byte2)					\
 	do {								\
 		(_byte1).eb_u8[0] &= (_byte2).eb_u8[0];			\
-	_NOTE(CONSTANTCONDITION) 					\
+	_NOTE(CONSTANTCONDITION)					\
 	} while (B_FALSE)
 
 #if EFSYS_USE_UINT64

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:04:38 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 15D58C94BED;
 Wed, 28 Dec 2016 11:04:38 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id CABC91EEA;
 Wed, 28 Dec 2016 11:04:37 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSB4b9K052872;
 Wed, 28 Dec 2016 11:04:37 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSB4aik052868;
 Wed, 28 Dec 2016 11:04:36 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281104.uBSB4aik052868@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:04:36 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310689 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:04:38 -0000

Author: arybchik
Date: Wed Dec 28 11:04:36 2016
New Revision: 310689
URL: https://svnweb.freebsd.org/changeset/base/310689

Log:
  sfxge(4): cleanup: avoid spaces before TAB
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx.h
  head/sys/dev/sfxge/common/efx_impl.h
  head/sys/dev/sfxge/common/efx_types.h
  head/sys/dev/sfxge/common/siena_phy.c

Modified: head/sys/dev/sfxge/common/efx.h
==============================================================================
--- head/sys/dev/sfxge/common/efx.h	Wed Dec 28 11:03:06 2016	(r310688)
+++ head/sys/dev/sfxge/common/efx.h	Wed Dec 28 11:04:36 2016	(r310689)
@@ -169,7 +169,7 @@ extern		void
 efx_nic_unprobe(
 	__in		efx_nic_t *enp);
 
-extern 		void
+extern		void
 efx_nic_destroy(
 	__in	efx_nic_t *enp);
 
@@ -286,21 +286,21 @@ efx_intr_init(
 	__in		efx_intr_type_t type,
 	__in		efsys_mem_t *esmp);
 
-extern 			void
+extern			void
 efx_intr_enable(
 	__in		efx_nic_t *enp);
 
-extern 			void
+extern			void
 efx_intr_disable(
 	__in		efx_nic_t *enp);
 
-extern 			void
+extern			void
 efx_intr_disable_unlocked(
 	__in		efx_nic_t *enp);
 
 #define	EFX_INTR_NEVQS	32
 
-extern __checkReturn	efx_rc_t
+extern	__checkReturn	efx_rc_t
 efx_intr_trigger(
 	__in		efx_nic_t *enp,
 	__in		unsigned int level);
@@ -819,7 +819,7 @@ efx_port_poll(
 	__in		efx_nic_t *enp,
 	__out_opt	efx_link_mode_t	*link_modep);
 
-extern 		void
+extern		void
 efx_port_fini(
 	__in	efx_nic_t *enp);
 
@@ -1253,7 +1253,7 @@ efx_vpd_verify(
 	__in_bcount(size)	caddr_t data,
 	__in			size_t size);
 
-extern  __checkReturn		efx_rc_t
+extern	__checkReturn		efx_rc_t
 efx_vpd_reinit(
 	__in			efx_nic_t *enp,
 	__in_bcount(size)	caddr_t data,
@@ -1281,7 +1281,7 @@ efx_vpd_next(
 	__out			efx_vpd_value_t *evvp,
 	__inout			unsigned int *contp);
 
-extern __checkReturn		efx_rc_t
+extern	__checkReturn		efx_rc_t
 efx_vpd_write(
 	__in			efx_nic_t *enp,
 	__in_bcount(size)	caddr_t data,
@@ -1499,7 +1499,7 @@ typedef enum efx_pattern_type_t {
 	EFX_PATTERN_NTYPES
 } efx_pattern_type_t;
 
-typedef 		void
+typedef			void
 (*efx_sram_pattern_fn_t)(
 	__in		size_t row,
 	__in		boolean_t negate,

Modified: head/sys/dev/sfxge/common/efx_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 11:03:06 2016	(r310688)
+++ head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 11:04:36 2016	(r310689)
@@ -913,7 +913,7 @@ struct efx_txq_s {
 		    uint32_t, (_edp)->ed_u32[0]);			\
 		EFSYS_BAR_WRITED((_enp)->en_esbp,			\
 		    (_reg ## _OFST +					\
-		    (2 * sizeof (efx_dword_t)) + 			\
+		    (2 * sizeof (efx_dword_t)) +			\
 		    ((_index) * _reg ## _STEP)),			\
 		    (_edp), (_lock));					\
 	_NOTE(CONSTANTCONDITION)					\
@@ -928,7 +928,7 @@ struct efx_txq_s {
 		    uint32_t, (_edp)->ed_u32[0]);			\
 		EFSYS_BAR_WRITED((_enp)->en_esbp,			\
 		    (_reg ## _OFST +					\
-		    (3 * sizeof (efx_dword_t)) + 			\
+		    (3 * sizeof (efx_dword_t)) +			\
 		    ((_index) * _reg ## _STEP)),			\
 		    (_edp), (_lock));					\
 	_NOTE(CONSTANTCONDITION)					\

Modified: head/sys/dev/sfxge/common/efx_types.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:03:06 2016	(r310688)
+++ head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:04:36 2016	(r310689)
@@ -246,7 +246,7 @@ typedef union efx_oword_u {
 
 #pragma pack()
 
-#define	__SWAP16(_x) 				\
+#define	__SWAP16(_x)				\
 	((((_x) & 0xff) << 8) |			\
 	(((_x) >> 8) & 0xff))
 
@@ -1212,16 +1212,16 @@ extern int fix_lint;
 #define	EFX_INSERT_FIELD8(_min, _max, _field, _value)			\
 	__NATIVE_8(EFX_INSERT_FIELD_NATIVE8(_min, _max, _field, _value))
 
-#define	EFX_INPLACE_MASK64(_min, _max, _field)			       	\
+#define	EFX_INPLACE_MASK64(_min, _max, _field)				\
 	EFX_INSERT_FIELD64(_min, _max, _field, EFX_MASK64(_field))
 
-#define	EFX_INPLACE_MASK32(_min, _max, _field)			       	\
+#define	EFX_INPLACE_MASK32(_min, _max, _field)				\
 	EFX_INSERT_FIELD32(_min, _max, _field, EFX_MASK32(_field))
 
-#define	EFX_INPLACE_MASK16(_min, _max, _field)			       	\
+#define	EFX_INPLACE_MASK16(_min, _max, _field)				\
 	EFX_INSERT_FIELD16(_min, _max, _field, EFX_MASK16(_field))
 
-#define	EFX_INPLACE_MASK8(_min, _max, _field)			       	\
+#define	EFX_INPLACE_MASK8(_min, _max, _field)				\
 	EFX_INSERT_FIELD8(_min, _max, _field, EFX_MASK8(_field))
 
 #define	EFX_SET_OWORD_FIELD64(_oword, _field, _value)			\

Modified: head/sys/dev/sfxge/common/siena_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_phy.c	Wed Dec 28 11:03:06 2016	(r310688)
+++ head/sys/dev/sfxge/common/siena_phy.c	Wed Dec 28 11:04:36 2016	(r310689)
@@ -455,7 +455,7 @@ siena_phy_oui_get(
 	}
 
 #define	SIENA_SIMPLE_STAT_SET2(_vmask, _esmp, _smask, _stat, _record)	\
-	SIENA_SIMPLE_STAT_SET(_vmask, _esmp, _smask, _stat, 		\
+	SIENA_SIMPLE_STAT_SET(_vmask, _esmp, _smask, _stat,		\
 			    MC_CMD_ ## _record,				\
 			    EFX_PHY_STAT_ ## _record)
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:07:36 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3A04DC94C66;
 Wed, 28 Dec 2016 11:07:36 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 14C221099;
 Wed, 28 Dec 2016 11:07:36 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSB7Zb5053112;
 Wed, 28 Dec 2016 11:07:35 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSB7Yab053021;
 Wed, 28 Dec 2016 11:07:34 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281107.uBSB7Yab053021@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:07:34 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310690 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:07:36 -0000

Author: arybchik
Date: Wed Dec 28 11:07:34 2016
New Revision: 310690
URL: https://svnweb.freebsd.org/changeset/base/310690

Log:
  sfxge(4): cleanup: add const qualifier to const array pointer
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_ev.c
  head/sys/dev/sfxge/common/efx_mac.c
  head/sys/dev/sfxge/common/efx_mon.c
  head/sys/dev/sfxge/common/efx_phy.c
  head/sys/dev/sfxge/common/efx_tx.c

Modified: head/sys/dev/sfxge/common/efx_ev.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_ev.c	Wed Dec 28 11:04:36 2016	(r310689)
+++ head/sys/dev/sfxge/common/efx_ev.c	Wed Dec 28 11:07:34 2016	(r310690)
@@ -1357,8 +1357,8 @@ fail1:
 
 #if EFSYS_OPT_QSTATS
 #if EFSYS_OPT_NAMES
-/* START MKCONFIG GENERATED EfxEventQueueStatNamesBlock b693ddf85aee1bfd */
-static const char 	*__efx_ev_qstat_name[] = {
+/* START MKCONFIG GENERATED EfxEventQueueStatNamesBlock c0f3bc5083b40532 */
+static const char * const __efx_ev_qstat_name[] = {
 	"all",
 	"rx",
 	"rx_ok",

Modified: head/sys/dev/sfxge/common/efx_mac.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mac.c	Wed Dec 28 11:04:36 2016	(r310689)
+++ head/sys/dev/sfxge/common/efx_mac.c	Wed Dec 28 11:07:34 2016	(r310690)
@@ -515,8 +515,8 @@ efx_mac_filter_default_rxq_clear(
 
 #if EFSYS_OPT_NAMES
 
-/* START MKCONFIG GENERATED EfxMacStatNamesBlock 054d43a31d2d7a45 */
-static const char 	*__efx_mac_stat_name[] = {
+/* START MKCONFIG GENERATED EfxMacStatNamesBlock c11b91b42f922516 */
+static const char * const __efx_mac_stat_name[] = {
 	"rx_octets",
 	"rx_pkts",
 	"rx_unicst_pkts",

Modified: head/sys/dev/sfxge/common/efx_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mon.c	Wed Dec 28 11:04:36 2016	(r310689)
+++ head/sys/dev/sfxge/common/efx_mon.c	Wed Dec 28 11:07:34 2016	(r310690)
@@ -126,8 +126,8 @@ fail1:
 
 #if EFSYS_OPT_NAMES
 
-/* START MKCONFIG GENERATED MonitorStatNamesBlock 31f437eafb0b0437 */
-static const char 	*__mon_stat_name[] = {
+/* START MKCONFIG GENERATED MonitorStatNamesBlock 5daa2a5725ba734b */
+static const char * const __mon_stat_name[] = {
 	"value_2_5v",
 	"value_vccp1",
 	"value_vcc",

Modified: head/sys/dev/sfxge/common/efx_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 11:04:36 2016	(r310689)
+++ head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 11:07:34 2016	(r310690)
@@ -336,8 +336,8 @@ fail1:
 
 #if EFSYS_OPT_NAMES
 
-/* START MKCONFIG GENERATED PhyStatNamesBlock d5f79b4bc2c050fe */
-static const char 	*__efx_phy_stat_name[] = {
+/* START MKCONFIG GENERATED PhyStatNamesBlock af9ffa24da3bc100 */
+static const char * const __efx_phy_stat_name[] = {
 	"oui",
 	"pma_pmd_link_up",
 	"pma_pmd_rx_fault",

Modified: head/sys/dev/sfxge/common/efx_tx.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_tx.c	Wed Dec 28 11:04:36 2016	(r310689)
+++ head/sys/dev/sfxge/common/efx_tx.c	Wed Dec 28 11:07:34 2016	(r310690)
@@ -1029,8 +1029,8 @@ siena_tx_qdesc_dma_create(
 
 #if EFSYS_OPT_QSTATS
 #if EFSYS_OPT_NAMES
-/* START MKCONFIG GENERATED EfxTransmitQueueStatNamesBlock 9d8d26a0a5e2c453 */
-static const char 	*__efx_tx_qstat_name[] = {
+/* START MKCONFIG GENERATED EfxTransmitQueueStatNamesBlock 2866874ecd7a363b */
+static const char * const __efx_tx_qstat_name[] = {
 	"post",
 	"post_pio",
 };

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:09:47 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 23A6AC94D9E;
 Wed, 28 Dec 2016 11:09:47 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E63221359;
 Wed, 28 Dec 2016 11:09:46 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSB9kqO053326;
 Wed, 28 Dec 2016 11:09:46 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSB9kYU053324;
 Wed, 28 Dec 2016 11:09:46 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281109.uBSB9kYU053324@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:09:46 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310691 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:09:47 -0000

Author: arybchik
Date: Wed Dec 28 11:09:45 2016
New Revision: 310691
URL: https://svnweb.freebsd.org/changeset/base/310691

Log:
  sfxge(4): make strings array pointer itself immutable
  
  Found by DPDK checkpatches.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_mon.c
  head/sys/dev/sfxge/common/efx_port.c

Modified: head/sys/dev/sfxge/common/efx_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mon.c	Wed Dec 28 11:07:34 2016	(r310690)
+++ head/sys/dev/sfxge/common/efx_mon.c	Wed Dec 28 11:09:45 2016	(r310691)
@@ -40,7 +40,7 @@ __FBSDID("$FreeBSD$");
 
 #if EFSYS_OPT_NAMES
 
-static const char	*__efx_mon_name[] = {
+static const char * const __efx_mon_name[] = {
 	"",
 	"sfx90x0",
 	"sfx91x0",

Modified: head/sys/dev/sfxge/common/efx_port.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_port.c	Wed Dec 28 11:07:34 2016	(r310690)
+++ head/sys/dev/sfxge/common/efx_port.c	Wed Dec 28 11:09:45 2016	(r310691)
@@ -172,7 +172,7 @@ fail1:
 
 #if EFSYS_OPT_NAMES
 
-static const char 	*__efx_loopback_type_name[] = {
+static const char * const __efx_loopback_type_name[] = {
 	"OFF",
 	"DATA",
 	"GMAC",

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:11:16 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id DEE68C94F09;
 Wed, 28 Dec 2016 11:11:16 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id B95081815;
 Wed, 28 Dec 2016 11:11:16 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSBBFYM054442;
 Wed, 28 Dec 2016 11:11:15 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSBBFD4054439;
 Wed, 28 Dec 2016 11:11:15 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281111.uBSBBFD4054439@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:11:15 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310692 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:11:17 -0000

Author: arybchik
Date: Wed Dec 28 11:11:15 2016
New Revision: 310692
URL: https://svnweb.freebsd.org/changeset/base/310692

Log:
  sfxge(4): enclose macro complex value in parenthesis
  
  Found by DPDK checkpatches.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_bootcfg.c
  head/sys/dev/sfxge/common/efx_types.h
  head/sys/dev/sfxge/common/mcdi_mon.c

Modified: head/sys/dev/sfxge/common/efx_bootcfg.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_bootcfg.c	Wed Dec 28 11:09:45 2016	(r310691)
+++ head/sys/dev/sfxge/common/efx_bootcfg.c	Wed Dec 28 11:11:15 2016	(r310692)
@@ -43,8 +43,8 @@ __FBSDID("$FreeBSD$");
  */
 #define	BOOTCFG_MAX_SIZE 0x1000
 
-#define	DHCP_END (uint8_t)0xff
-#define	DHCP_PAD (uint8_t)0
+#define	DHCP_END ((uint8_t)0xff)
+#define	DHCP_PAD ((uint8_t)0)
 
 static	__checkReturn		uint8_t
 efx_bootcfg_csum(

Modified: head/sys/dev/sfxge/common/efx_types.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:09:45 2016	(r310691)
+++ head/sys/dev/sfxge/common/efx_types.h	Wed Dec 28 11:11:15 2016	(r310692)
@@ -264,37 +264,37 @@ typedef union efx_oword_u {
 
 #if EFSYS_IS_BIG_ENDIAN
 
-#define	__CPU_TO_LE_16(_x)	(uint16_t)__SWAP16(_x)
-#define	__LE_TO_CPU_16(_x)	(uint16_t)__SWAP16(_x)
-#define	__CPU_TO_BE_16(_x)	(uint16_t)__NOSWAP16(_x)
-#define	__BE_TO_CPU_16(_x)	(uint16_t)__NOSWAP16(_x)
-
-#define	__CPU_TO_LE_32(_x)	(uint32_t)__SWAP32(_x)
-#define	__LE_TO_CPU_32(_x)	(uint32_t)__SWAP32(_x)
-#define	__CPU_TO_BE_32(_x)	(uint32_t)__NOSWAP32(_x)
-#define	__BE_TO_CPU_32(_x)	(uint32_t)__NOSWAP32(_x)
-
-#define	__CPU_TO_LE_64(_x)	(uint64_t)__SWAP64(_x)
-#define	__LE_TO_CPU_64(_x)	(uint64_t)__SWAP64(_x)
-#define	__CPU_TO_BE_64(_x)	(uint64_t)__NOSWAP64(_x)
-#define	__BE_TO_CPU_64(_x)	(uint64_t)__NOSWAP64(_x)
+#define	__CPU_TO_LE_16(_x)	((uint16_t)__SWAP16(_x))
+#define	__LE_TO_CPU_16(_x)	((uint16_t)__SWAP16(_x))
+#define	__CPU_TO_BE_16(_x)	((uint16_t)__NOSWAP16(_x))
+#define	__BE_TO_CPU_16(_x)	((uint16_t)__NOSWAP16(_x))
+
+#define	__CPU_TO_LE_32(_x)	((uint32_t)__SWAP32(_x))
+#define	__LE_TO_CPU_32(_x)	((uint32_t)__SWAP32(_x))
+#define	__CPU_TO_BE_32(_x)	((uint32_t)__NOSWAP32(_x))
+#define	__BE_TO_CPU_32(_x)	((uint32_t)__NOSWAP32(_x))
+
+#define	__CPU_TO_LE_64(_x)	((uint64_t)__SWAP64(_x))
+#define	__LE_TO_CPU_64(_x)	((uint64_t)__SWAP64(_x))
+#define	__CPU_TO_BE_64(_x)	((uint64_t)__NOSWAP64(_x))
+#define	__BE_TO_CPU_64(_x)	((uint64_t)__NOSWAP64(_x))
 
 #elif EFSYS_IS_LITTLE_ENDIAN
 
-#define	__CPU_TO_LE_16(_x)	(uint16_t)__NOSWAP16(_x)
-#define	__LE_TO_CPU_16(_x)	(uint16_t)__NOSWAP16(_x)
-#define	__CPU_TO_BE_16(_x)	(uint16_t)__SWAP16(_x)
-#define	__BE_TO_CPU_16(_x)	(uint16_t)__SWAP16(_x)
-
-#define	__CPU_TO_LE_32(_x)	(uint32_t)__NOSWAP32(_x)
-#define	__LE_TO_CPU_32(_x)	(uint32_t)__NOSWAP32(_x)
-#define	__CPU_TO_BE_32(_x)	(uint32_t)__SWAP32(_x)
-#define	__BE_TO_CPU_32(_x)	(uint32_t)__SWAP32(_x)
-
-#define	__CPU_TO_LE_64(_x)	(uint64_t)__NOSWAP64(_x)
-#define	__LE_TO_CPU_64(_x)	(uint64_t)__NOSWAP64(_x)
-#define	__CPU_TO_BE_64(_x)	(uint64_t)__SWAP64(_x)
-#define	__BE_TO_CPU_64(_x)	(uint64_t)__SWAP64(_x)
+#define	__CPU_TO_LE_16(_x)	((uint16_t)__NOSWAP16(_x))
+#define	__LE_TO_CPU_16(_x)	((uint16_t)__NOSWAP16(_x))
+#define	__CPU_TO_BE_16(_x)	((uint16_t)__SWAP16(_x))
+#define	__BE_TO_CPU_16(_x)	((uint16_t)__SWAP16(_x))
+
+#define	__CPU_TO_LE_32(_x)	((uint32_t)__NOSWAP32(_x))
+#define	__LE_TO_CPU_32(_x)	((uint32_t)__NOSWAP32(_x))
+#define	__CPU_TO_BE_32(_x)	((uint32_t)__SWAP32(_x))
+#define	__BE_TO_CPU_32(_x)	((uint32_t)__SWAP32(_x))
+
+#define	__CPU_TO_LE_64(_x)	((uint64_t)__NOSWAP64(_x))
+#define	__LE_TO_CPU_64(_x)	((uint64_t)__NOSWAP64(_x))
+#define	__CPU_TO_BE_64(_x)	((uint64_t)__SWAP64(_x))
+#define	__BE_TO_CPU_64(_x)	((uint64_t)__SWAP64(_x))
 
 #else
 

Modified: head/sys/dev/sfxge/common/mcdi_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/mcdi_mon.c	Wed Dec 28 11:09:45 2016	(r310691)
+++ head/sys/dev/sfxge/common/mcdi_mon.c	Wed Dec 28 11:11:15 2016	(r310692)
@@ -38,8 +38,8 @@ __FBSDID("$FreeBSD$");
 
 #if EFSYS_OPT_MON_STATS
 
-#define	MCDI_MON_NEXT_PAGE  (uint16_t)0xfffe
-#define	MCDI_MON_INVALID_SENSOR (uint16_t)0xfffd
+#define	MCDI_MON_NEXT_PAGE  ((uint16_t)0xfffe)
+#define	MCDI_MON_INVALID_SENSOR ((uint16_t)0xfffd)
 #define	MCDI_MON_PAGE_SIZE 0x20
 
 /* Bitmasks of valid port(s) for each sensor */

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:19:56 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26A03C94161;
 Wed, 28 Dec 2016 11:19:56 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id EA3CF1AE6;
 Wed, 28 Dec 2016 11:19:55 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSBJtlE057552;
 Wed, 28 Dec 2016 11:19:55 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSBJsDp057546;
 Wed, 28 Dec 2016 11:19:54 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281119.uBSBJsDp057546@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:19:54 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310693 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:19:56 -0000

Author: arybchik
Date: Wed Dec 28 11:19:54 2016
New Revision: 310693
URL: https://svnweb.freebsd.org/changeset/base/310693

Log:
  sfxge(4): cleanup: avoid unspecified unsigned
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/ef10_ev.c
  head/sys/dev/sfxge/common/ef10_filter.c
  head/sys/dev/sfxge/common/ef10_nvram.c
  head/sys/dev/sfxge/common/efx_ev.c
  head/sys/dev/sfxge/common/efx_filter.c
  head/sys/dev/sfxge/common/siena_vpd.c

Modified: head/sys/dev/sfxge/common/ef10_ev.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_ev.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/ef10_ev.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -990,7 +990,7 @@ ef10_ev_mcdi(
 	__in_opt	void *arg)
 {
 	efx_nic_t *enp = eep->ee_enp;
-	unsigned code;
+	unsigned int code;
 	boolean_t should_abort = B_FALSE;
 
 	EFX_EV_QSTAT_INCR(eep, EV_MCDI_RESPONSE);

Modified: head/sys/dev/sfxge/common/ef10_filter.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_filter.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/ef10_filter.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -1246,7 +1246,7 @@ ef10_filter_reconfigure(
 	efx_nic_cfg_t *encp = &enp->en_nic_cfg;
 	ef10_filter_table_t *table = enp->en_filter.ef_ef10_filter_table;
 	efx_filter_flag_t filter_flags;
-	unsigned i;
+	unsigned int i;
 	efx_rc_t all_unicst_rc = 0;
 	efx_rc_t all_mulcst_rc = 0;
 	efx_rc_t rc;

Modified: head/sys/dev/sfxge/common/ef10_nvram.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_nvram.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/ef10_nvram.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -772,7 +772,7 @@ ef10_nvram_buffer_create(
 	struct tlv_partition_header header;
 	struct tlv_partition_trailer trailer;
 
-	unsigned min_buf_size = sizeof (struct tlv_partition_header) +
+	unsigned int min_buf_size = sizeof (struct tlv_partition_header) +
 	    sizeof (struct tlv_partition_trailer);
 	if (partn_size < min_buf_size) {
 		rc = EINVAL;

Modified: head/sys/dev/sfxge/common/efx_ev.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_ev.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/efx_ev.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -953,7 +953,7 @@ siena_ev_mcdi(
 	__in_opt	void *arg)
 {
 	efx_nic_t *enp = eep->ee_enp;
-	unsigned code;
+	unsigned int code;
 	boolean_t should_abort = B_FALSE;
 
 	EFSYS_ASSERT3U(enp->en_family, ==, EFX_FAMILY_SIENA);

Modified: head/sys/dev/sfxge/common/efx_filter.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_filter.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/efx_filter.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -970,7 +970,7 @@ siena_filter_search(
 	__out		int *filter_index,
 	__out		unsigned int *depth_required)
 {
-	unsigned hash, incr, filter_idx, depth;
+	unsigned int hash, incr, filter_idx, depth;
 
 	hash = siena_filter_tbl_hash(key);
 	incr = siena_filter_tbl_increment(key);

Modified: head/sys/dev/sfxge/common/siena_vpd.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_vpd.c	Wed Dec 28 11:11:15 2016	(r310692)
+++ head/sys/dev/sfxge/common/siena_vpd.c	Wed Dec 28 11:19:54 2016	(r310693)
@@ -160,7 +160,7 @@ siena_vpd_init(
 {
 	efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
 	caddr_t svpd = NULL;
-	unsigned partn;
+	unsigned int partn;
 	size_t size = 0;
 	efx_rc_t rc;
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:25:19 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 36FAAC94398;
 Wed, 28 Dec 2016 11:25:19 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E238D101F;
 Wed, 28 Dec 2016 11:25:18 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSBPIC4061553;
 Wed, 28 Dec 2016 11:25:18 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSBPHYt061550;
 Wed, 28 Dec 2016 11:25:17 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281125.uBSBPHYt061550@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:25:17 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310694 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:25:19 -0000

Author: arybchik
Date: Wed Dec 28 11:25:17 2016
New Revision: 310694
URL: https://svnweb.freebsd.org/changeset/base/310694

Log:
  sfxge(4): cleanup: add missing spaces
  
  Found by DPDK checkpatch.sh
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_impl.h
  head/sys/dev/sfxge/common/efx_mcdi.c
  head/sys/dev/sfxge/common/medford_nic.c

Modified: head/sys/dev/sfxge/common/efx_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 11:19:54 2016	(r310693)
+++ head/sys/dev/sfxge/common/efx_impl.h	Wed Dec 28 11:25:17 2016	(r310694)
@@ -124,7 +124,7 @@ typedef struct efx_tx_ops_s {
 	void		(*etxo_qenable)(efx_txq_t *);
 	efx_rc_t	(*etxo_qpio_enable)(efx_txq_t *);
 	void		(*etxo_qpio_disable)(efx_txq_t *);
-	efx_rc_t	(*etxo_qpio_write)(efx_txq_t *,uint8_t *, size_t,
+	efx_rc_t	(*etxo_qpio_write)(efx_txq_t *, uint8_t *, size_t,
 					   size_t);
 	efx_rc_t	(*etxo_qpio_post)(efx_txq_t *, size_t, unsigned int,
 					   unsigned int *);
@@ -801,7 +801,7 @@ struct efx_txq_s {
 #else
 #define	EFX_CHECK_REG(_enp, _reg) do {					\
 	_NOTE(CONSTANTCONDITION)					\
-	} while(B_FALSE)
+	} while (B_FALSE)
 #endif
 
 #define	EFX_BAR_READD(_enp, _reg, _edp, _lock)				\

Modified: head/sys/dev/sfxge/common/efx_mcdi.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mcdi.c	Wed Dec 28 11:19:54 2016	(r310693)
+++ head/sys/dev/sfxge/common/efx_mcdi.c	Wed Dec 28 11:25:17 2016	(r310694)
@@ -1765,7 +1765,7 @@ efx_mcdi_mac_stats(
 	    MAC_STATS_IN_PERIODIC_CHANGE, enable | events | disable,
 	    MAC_STATS_IN_PERIODIC_ENABLE, enable | events,
 	    MAC_STATS_IN_PERIODIC_NOEVENT, !events,
-	    MAC_STATS_IN_PERIOD_MS, (enable | events) ? 1000: 0);
+	    MAC_STATS_IN_PERIOD_MS, (enable | events) ? 1000 : 0);
 
 	if (esmp != NULL) {
 		int bytes = MC_CMD_MAC_NSTATS * sizeof (uint64_t);

Modified: head/sys/dev/sfxge/common/medford_nic.c
==============================================================================
--- head/sys/dev/sfxge/common/medford_nic.c	Wed Dec 28 11:19:54 2016	(r310693)
+++ head/sys/dev/sfxge/common/medford_nic.c	Wed Dec 28 11:25:17 2016	(r310694)
@@ -66,7 +66,7 @@ efx_mcdi_get_rxdp_config(
 		/* RX DMA end padding is disabled */
 		end_padding = 0;
 	} else {
-		switch(MCDI_OUT_DWORD_FIELD(req, GET_RXDP_CONFIG_OUT_DATA,
+		switch (MCDI_OUT_DWORD_FIELD(req, GET_RXDP_CONFIG_OUT_DATA,
 					    GET_RXDP_CONFIG_OUT_PAD_HOST_LEN)) {
 		case MC_CMD_SET_RXDP_CONFIG_IN_PAD_HOST_64:
 			end_padding = 64;

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:28:18 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 02DBBC94461;
 Wed, 28 Dec 2016 11:28:18 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id C690911E7;
 Wed, 28 Dec 2016 11:28:17 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSBSGAj061685;
 Wed, 28 Dec 2016 11:28:16 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSBSG2o061684;
 Wed, 28 Dec 2016 11:28:16 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281128.uBSBSG2o061684@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:28:16 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310695 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:28:18 -0000

Author: arybchik
Date: Wed Dec 28 11:28:16 2016
New Revision: 310695
URL: https://svnweb.freebsd.org/changeset/base/310695

Log:
  sfxge(4): fix defined-but-not-used warning if neither VPD nor NVRAM opt enabled
  
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/siena_nic.c

Modified: head/sys/dev/sfxge/common/siena_nic.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_nic.c	Wed Dec 28 11:25:17 2016	(r310694)
+++ head/sys/dev/sfxge/common/siena_nic.c	Wed Dec 28 11:28:16 2016	(r310695)
@@ -37,6 +37,8 @@ __FBSDID("$FreeBSD$");
 
 #if EFSYS_OPT_SIENA
 
+#if EFSYS_OPT_VPD || EFSYS_OPT_NVRAM
+
 static	__checkReturn		efx_rc_t
 siena_nic_get_partn_mask(
 	__in			efx_nic_t *enp,
@@ -78,6 +80,8 @@ fail1:
 	return (rc);
 }
 
+#endif /* EFSYS_OPT_VPD || EFSYS_OPT_NVRAM */
+
 static	__checkReturn	efx_rc_t
 siena_board_cfg(
 	__in		efx_nic_t *enp)

From owner-svn-src-all@freebsd.org  Wed Dec 28 11:43:12 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id C1E09C948FF;
 Wed, 28 Dec 2016 11:43:12 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 823121B49;
 Wed, 28 Dec 2016 11:43:12 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSBhBrW069638;
 Wed, 28 Dec 2016 11:43:11 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSBhBPo069634;
 Wed, 28 Dec 2016 11:43:11 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281143.uBSBhBPo069634@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 11:43:11 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310696 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 11:43:12 -0000

Author: arybchik
Date: Wed Dec 28 11:43:11 2016
New Revision: 310696
URL: https://svnweb.freebsd.org/changeset/base/310696

Log:
  sfxge(4): cleanup: improve prefast annotations
  
  Submitted by:   Andy Moreton <amoreton at solarflare.com>
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/ef10_impl.h
  head/sys/dev/sfxge/common/ef10_mcdi.c
  head/sys/dev/sfxge/common/siena_impl.h
  head/sys/dev/sfxge/common/siena_mcdi.c

Modified: head/sys/dev/sfxge/common/ef10_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/ef10_impl.h	Wed Dec 28 11:28:16 2016	(r310695)
+++ head/sys/dev/sfxge/common/ef10_impl.h	Wed Dec 28 11:43:11 2016	(r310696)
@@ -296,11 +296,11 @@ ef10_mcdi_fini(
 
 extern			void
 ef10_mcdi_send_request(
-	__in		efx_nic_t *enp,
-	__in		void *hdrp,
-	__in		size_t hdr_len,
-	__in		void *sdup,
-	__in		size_t sdu_len);
+	__in			efx_nic_t *enp,
+	__in_bcount(hdr_len)	void *hdrp,
+	__in			size_t hdr_len,
+	__in_bcount(sdu_len)	void *sdup,
+	__in			size_t sdu_len);
 
 extern	__checkReturn	boolean_t
 ef10_mcdi_poll_response(

Modified: head/sys/dev/sfxge/common/ef10_mcdi.c
==============================================================================
--- head/sys/dev/sfxge/common/ef10_mcdi.c	Wed Dec 28 11:28:16 2016	(r310695)
+++ head/sys/dev/sfxge/common/ef10_mcdi.c	Wed Dec 28 11:43:11 2016	(r310696)
@@ -110,11 +110,11 @@ ef10_mcdi_fini(
 
 			void
 ef10_mcdi_send_request(
-	__in		efx_nic_t *enp,
-	__in		void *hdrp,
-	__in		size_t hdr_len,
-	__in		void *sdup,
-	__in		size_t sdu_len)
+	__in			efx_nic_t *enp,
+	__in_bcount(hdr_len)	void *hdrp,
+	__in			size_t hdr_len,
+	__in_bcount(sdu_len)	void *sdup,
+	__in			size_t sdu_len)
 {
 	const efx_mcdi_transport_t *emtp = enp->en_mcdi.em_emtp;
 	efsys_mem_t *esmp = emtp->emt_dma_mem;

Modified: head/sys/dev/sfxge/common/siena_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/siena_impl.h	Wed Dec 28 11:28:16 2016	(r310695)
+++ head/sys/dev/sfxge/common/siena_impl.h	Wed Dec 28 11:43:11 2016	(r310696)
@@ -96,11 +96,11 @@ siena_mcdi_init(
 
 extern			void
 siena_mcdi_send_request(
-	__in		efx_nic_t *enp,
-	__in		void *hdrp,
-	__in		size_t hdr_len,
-	__in		void *sdup,
-	__in		size_t sdu_len);
+	__in			efx_nic_t *enp,
+	__in_bcount(hdr_len)	void *hdrp,
+	__in			size_t hdr_len,
+	__in_bcount(sdu_len)	void *sdup,
+	__in			size_t sdu_len);
 
 extern	__checkReturn	boolean_t
 siena_mcdi_poll_response(

Modified: head/sys/dev/sfxge/common/siena_mcdi.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_mcdi.c	Wed Dec 28 11:28:16 2016	(r310695)
+++ head/sys/dev/sfxge/common/siena_mcdi.c	Wed Dec 28 11:43:11 2016	(r310696)
@@ -54,11 +54,11 @@ __FBSDID("$FreeBSD$");
 
 			void
 siena_mcdi_send_request(
-	__in		efx_nic_t *enp,
-	__in		void *hdrp,
-	__in		size_t hdr_len,
-	__in		void *sdup,
-	__in		size_t sdu_len)
+	__in			efx_nic_t *enp,
+	__in_bcount(hdr_len)	void *hdrp,
+	__in			size_t hdr_len,
+	__in_bcount(sdu_len)	void *sdup,
+	__in			size_t sdu_len)
 {
 	efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
 	efx_dword_t dword;

From owner-svn-src-all@freebsd.org  Wed Dec 28 13:11:23 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id D3E20C947E2;
 Wed, 28 Dec 2016 13:11:23 +0000 (UTC)
 (envelope-from araujo@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 9D5BD123E;
 Wed, 28 Dec 2016 13:11:23 +0000 (UTC)
 (envelope-from araujo@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSDBMnH003557;
 Wed, 28 Dec 2016 13:11:22 GMT (envelope-from araujo@FreeBSD.org)
Received: (from araujo@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSDBMIa003556;
 Wed, 28 Dec 2016 13:11:22 GMT (envelope-from araujo@FreeBSD.org)
Message-Id: <201612281311.uBSDBMIa003556@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: araujo set sender to
 araujo@FreeBSD.org using -f
From: Marcelo Araujo <araujo@FreeBSD.org>
Date: Wed, 28 Dec 2016 13:11:22 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310698 - head/usr.bin/netstat
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 13:11:23 -0000

Author: araujo
Date: Wed Dec 28 13:11:22 2016
New Revision: 310698
URL: https://svnweb.freebsd.org/changeset/base/310698

Log:
  Print hostcache usage counts with TCP statistics.
  
  PR:		196252
  Submitted by:	Anton Yuzhaninov <citrin+pr@citrin.ru>
  MFC after:	3 weeks.

Modified:
  head/usr.bin/netstat/inet.c

Modified: head/usr.bin/netstat/inet.c
==============================================================================
--- head/usr.bin/netstat/inet.c	Wed Dec 28 12:23:16 2016	(r310697)
+++ head/usr.bin/netstat/inet.c	Wed Dec 28 13:11:22 2016	(r310698)
@@ -751,6 +751,12 @@ tcp_stats(u_long off, const char *name, 
 	    "{N:/ignored RSTs in the window%s}\n");
 	p(tcps_connects, "\t{:connections-established/%ju} "
 	    "{N:/connection%s established (including accepts)}\n");
+	p(tcps_usedrtt, "\t\t{:connections-hostcache-rtt/%ju} "
+	    "{N:/time%s used RTT from hostcache}\n");
+	p(tcps_usedrttvar, "\t\t{:connections-hostcache-rttvar/%ju} "
+	    "{N:/time%s used RTT variance from hostcache}\n");
+	p(tcps_usedssthresh, "\t\t{:connections-hostcache-ssthresh/%ju} "
+	    "{N:/time%s used slow-start threshold from hostcache}\n");
 	p2(tcps_closed, tcps_drops, "\t{:connections-closed/%ju} "
 	    "{N:/connection%s closed (including} "
 	    "{:connection-drops/%ju} {N:/drop%s})\n");

From owner-svn-src-all@freebsd.org  Wed Dec 28 13:28:45 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 69DCCC94D43;
 Wed, 28 Dec 2016 13:28:45 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org (repo.freebsd.org
 [IPv6:2610:1c1:1:6068::e6a:0])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id 449B41F0C;
 Wed, 28 Dec 2016 13:28:45 +0000 (UTC)
 (envelope-from arybchik@FreeBSD.org)
Received: from repo.freebsd.org ([127.0.1.37])
 by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBSDSivl011645;
 Wed, 28 Dec 2016 13:28:44 GMT (envelope-from arybchik@FreeBSD.org)
Received: (from arybchik@localhost)
 by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBSDSiZr011642;
 Wed, 28 Dec 2016 13:28:44 GMT (envelope-from arybchik@FreeBSD.org)
Message-Id: <201612281328.uBSDSiZr011642@repo.freebsd.org>
X-Authentication-Warning: repo.freebsd.org: arybchik set sender to
 arybchik@FreeBSD.org using -f
From: Andrew Rybchenko <arybchik@FreeBSD.org>
Date: Wed, 28 Dec 2016 13:28:44 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
 svn-src-head@freebsd.org
Subject: svn commit: r310699 - head/sys/dev/sfxge/common
X-SVN-Group: head
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 13:28:45 -0000

Author: arybchik
Date: Wed Dec 28 13:28:44 2016
New Revision: 310699
URL: https://svnweb.freebsd.org/changeset/base/310699

Log:
  sfxge(4): rename hunt_bist_* methods to ef10_bist_*
  
  Submitted by:   Mark Spender <mspender at solarflare.com>
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      2 days

Modified:
  head/sys/dev/sfxge/common/efx_phy.c
  head/sys/dev/sfxge/common/hunt_impl.h
  head/sys/dev/sfxge/common/hunt_phy.c

Modified: head/sys/dev/sfxge/common/efx_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 13:11:22 2016	(r310698)
+++ head/sys/dev/sfxge/common/efx_phy.c	Wed Dec 28 13:28:44 2016	(r310699)
@@ -65,11 +65,10 @@ static const efx_phy_ops_t	__efx_phy_ef1
 	ef10_phy_stats_update,		/* epo_stats_update */
 #endif	/* EFSYS_OPT_PHY_STATS */
 #if EFSYS_OPT_BIST
-	/* FIXME: Are these BIST methods appropriate for Medford? */
-	hunt_bist_enable_offline,	/* epo_bist_enable_offline */
-	hunt_bist_start,		/* epo_bist_start */
-	hunt_bist_poll,			/* epo_bist_poll */
-	hunt_bist_stop,			/* epo_bist_stop */
+	ef10_bist_enable_offline,	/* epo_bist_enable_offline */
+	ef10_bist_start,		/* epo_bist_start */
+	ef10_bist_poll,			/* epo_bist_poll */
+	ef10_bist_stop,			/* epo_bist_stop */
 #endif	/* EFSYS_OPT_BIST */
 };
 #endif	/* EFSYS_OPT_HUNTINGTON || EFSYS_OPT_MEDFORD */

Modified: head/sys/dev/sfxge/common/hunt_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/hunt_impl.h	Wed Dec 28 13:11:22 2016	(r310698)
+++ head/sys/dev/sfxge/common/hunt_impl.h	Wed Dec 28 13:28:44 2016	(r310699)
@@ -75,16 +75,16 @@ hunt_board_cfg(
 #if EFSYS_OPT_BIST
 
 extern	__checkReturn		efx_rc_t
-hunt_bist_enable_offline(
+ef10_bist_enable_offline(
 	__in			efx_nic_t *enp);
 
 extern	__checkReturn		efx_rc_t
-hunt_bist_start(
+ef10_bist_start(
 	__in			efx_nic_t *enp,
 	__in			efx_bist_type_t type);
 
 extern	__checkReturn		efx_rc_t
-hunt_bist_poll(
+ef10_bist_poll(
 	__in			efx_nic_t *enp,
 	__in			efx_bist_type_t type,
 	__out			efx_bist_result_t *resultp,
@@ -95,7 +95,7 @@ hunt_bist_poll(
 	__in			size_t count);
 
 extern				void
-hunt_bist_stop(
+ef10_bist_stop(
 	__in			efx_nic_t *enp,
 	__in			efx_bist_type_t type);
 

Modified: head/sys/dev/sfxge/common/hunt_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/hunt_phy.c	Wed Dec 28 13:11:22 2016	(r310698)
+++ head/sys/dev/sfxge/common/hunt_phy.c	Wed Dec 28 13:28:44 2016	(r310699)
@@ -39,7 +39,7 @@ __FBSDID("$FreeBSD$");
 #if EFSYS_OPT_BIST
 
 	__checkReturn		efx_rc_t
-hunt_bist_enable_offline(
+ef10_bist_enable_offline(
 	__in			efx_nic_t *enp)
 {
 	efx_rc_t rc;
@@ -56,7 +56,7 @@ fail1:
 }
 
 	__checkReturn		efx_rc_t
-hunt_bist_start(
+ef10_bist_start(
 	__in			efx_nic_t *enp,
 	__in			efx_bist_type_t type)
 {
@@ -74,7 +74,7 @@ fail1:
 }
 
 	__checkReturn		efx_rc_t
-hunt_bist_poll(
+ef10_bist_poll(
 	__in			efx_nic_t *enp,
 	__in			efx_bist_type_t type,
 	__out			efx_bist_result_t *resultp,
@@ -179,11 +179,11 @@ fail1:
 }
 
 			void
-hunt_bist_stop(
+ef10_bist_stop(
 	__in		efx_nic_t *enp,
 	__in		efx_bist_type_t type)
 {
-	/* There is no way to stop BIST on Huntinton. */
+	/* There is no way to stop BIST on EF10. */
 	_NOTE(ARGUNUSED(enp, type))
 }
 

From owner-svn-src-all@freebsd.org  Wed Dec 28 13:47:03 2016
Return-Path: <owner-svn-src-all@freebsd.org>
Delivered-To: svn-src-all@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id E646AC4F53D;
 Wed, 28 Dec 2016 13:47:03 +0000 (UTC)
 (envelope-from kabaev@gmail.com)
Received: from mail-qk0-x242.google.com (mail-qk0-x242.google.com
 [IPv6:2607:f8b0:400d:c09::242])
 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
 (Client CN "smtp.gmail.com",
 Issuer "Google Internet Authority G2" (verified OK))
 by mx1.freebsd.org (Postfix) with ESMTPS id 9D8DA1D74;
 Wed, 28 Dec 2016 13:47:03 +0000 (UTC)
 (envelope-from kabaev@gmail.com)
Received: by mail-qk0-x242.google.com with SMTP id t184so32182583qkd.1;
 Wed, 28 Dec 2016 05:47:03 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=date:from:to:cc:subject:message-id:in-reply-to:references
 :mime-version; bh=zQZDIPvTWblW6andBDHU5gLMBM8ZL1HkY5OdVOPUHOg=;
 b=ID2D8osL2JPLGnZ7U+tUck2BvS8PyWCBylQRe5innN2wiR0Ce4YXz+fOP57PW2vN47
 atb/Zmep2l25cLUFMiDBxoCIISVe+Xz1ZfAmMLWtLny1UvnJBwqL3XpJef3BisG5E26D
 2vUUm8Eh5edXGJldUtWGmg8YmBZGJHdstMY88wQPdxP3Wp8feo0UoS0JEk7r2n7+Yuno
 vX6tsDaKs8IIfcpHGfzZsJB2dqDGz7nbbhB2JDC9+DNLQXa0yF7HoQqGJmTVBEE8+J5b
 CcGT8vlPoYhTZaaIP6vu399wgqRbpjEzrQFKdND2DcsZE0UKZ/e+gScZe1hExNKxcABQ
 3eLg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to
 :references:mime-version;
 bh=zQZDIPvTWblW6andBDHU5gLMBM8ZL1HkY5OdVOPUHOg=;
 b=dksosO451doLRz0bQ0nbNYqBN7492ErJTWCp/MM1RXewp0iPdkAAdbXWcctj/EWBxh
 Q7MQIX0Lpw3jj9Ydc1RGNixi7P2B88WiAiOpIXRFAGnc7J2hVfYAQGe87ht6sNfsXSxB
 Eeo4JqYoK3PBi9RuVrw6BNUNLxnt/cscBtScUklxHDQrM0xMOTJfk+ZFoe5p2sa1d6i7
 THv6zkV6bvWa8bVcoPS7mHPb4QcA7FM4A/P27wsKwyAdblRtg/O9h6cbaAhciTqOiV1T
 jM9Bg24bRBSY48mBcN0jdxddU6U3zlTVFUl9OAECwlSrdt9GDR6Ti+RSvXVJY/e6ZvsC
 UhnQ==
X-Gm-Message-State: AIkVDXIEzjjSrrYyB4tHYYiEFhXtdL5N++MzGfu3mX1Sl5Rpgptb/dcQGcW/726TA4RYaQ==
X-Received: by 10.55.95.1 with SMTP id t1mr34991611qkb.277.1482932822847;
 Wed, 28 Dec 2016 05:47:02 -0800 (PST)
Received: from kan ([2601:18f:802:4680:226:18ff:fe00:232e])
 by smtp.gmail.com with ESMTPSA id p19sm30820689qtp.4.2016.12.28.05.47.01
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Wed, 28 Dec 2016 05:47:02 -0800 (PST)
Date: Wed, 28 Dec 2016 08:46:53 -0500
From: Alexander Kabaev <kabaev@gmail.com>
To: Adrian Chadd <adrian.chadd@gmail.com>
Cc: Alexander Kabaev <kan@freebsd.org>, "src-committers@freebsd.org"
 <src-committers@freebsd.org>, "svn-src-all@freebsd.org"
 <svn-src-all@freebsd.org>, "svn-src-head@freebsd.org"
 <svn-src-head@freebsd.org>
Subject: Re: svn commit: r310650 - in head/sys/mips: include mips
Message-ID: <20161228084653.0326caa4@kan>
In-Reply-To: <CAJ-Vmo=bMUNbfgaTdUC8ToN9yLZuyqN5ws79vmwP8OJcRfR1ag@mail.gmail.com>
References: <201612280255.uBS2tQeR045512@repo.freebsd.org>
 <CAJ-Vmo=bMUNbfgaTdUC8ToN9yLZuyqN5ws79vmwP8OJcRfR1ag@mail.gmail.com>
X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.29; amd64-portbld-freebsd12.0)
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
 boundary="Sig_/y/NNRm+pci6OV9c.3sVTdHg"; protocol="application/pgp-signature"
X-BeenThere: svn-src-all@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "SVN commit messages for the entire src tree \(except for &quot;
 user&quot; and &quot; projects&quot; \)" <svn-src-all.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/svn-src-all/>
List-Post: <mailto:svn-src-all@freebsd.org>
List-Help: <mailto:svn-src-all-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/svn-src-all>,
 <mailto:svn-src-all-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Wed, 28 Dec 2016 13:47:04 -0000

--Sig_/y/NNRm+pci6OV9c.3sVTdHg
Content-Type: text/plain; charset=KOI8-R
Content-Transfer-Encoding: quoted-printable

On Tue, 27 Dec 2016 21:50:32 -0800
Adrian Chadd <adrian.chadd@gmail.com> wrote:

> hiya,
>=20
> so I dug into the mips24k definition of this. It says this:
>=20
> "
> 3.4.3 Uncached accelerated writes
> The 24K core permits memory regions to be marked as "uncached
> accelerated". This type of region is useful to hard-
> ware which is "write only" - perhaps video frame buffers, or some
> other hardware stream. Sequential word stores in
> such regions are gathered into cache-line-sized chunks, before being
> written with a single burst cycle on the CPU
> interface.
> Such regions are uncached for read, and partial-word or
> out-of-sequence writes have "unpredictable" effects - don't
> do them. The burst write is normally performed when software writes to
> the last location in the memory block or does
> an uncached-accelerated write to some other block; but it can also be
> triggered by a
> sync instruction, a pref nudge, a matching load or any exception. If
> the block is not completely written by the