Date: Mon, 1 Oct 2018 18:51:39 +0000 (UTC) From: Mark Johnston <markj@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r339075 - in head/sys: sys vm Message-ID: <201810011851.w91IpddE024174@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: markj Date: Mon Oct 1 18:51:39 2018 New Revision: 339075 URL: https://svnweb.freebsd.org/changeset/base/339075 Log: Use an unsigned iterator for domain sets. Otherwise (iter % ds->ds_cnt) is not guaranteed to lie in the range [0, MAXMEMDOM). Reported by: pho Reviewed by: kib Approved by: re (rgrimes) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D17374 Modified: head/sys/sys/_domainset.h head/sys/vm/vm_domainset.h Modified: head/sys/sys/_domainset.h ============================================================================== --- head/sys/sys/_domainset.h Mon Oct 1 18:51:08 2018 (r339074) +++ head/sys/sys/_domainset.h Mon Oct 1 18:51:39 2018 (r339075) @@ -54,7 +54,7 @@ typedef struct _domainset domainset_t; struct domainset; struct domainset_ref { struct domainset * volatile dr_policy; - int dr_iterator; + unsigned int dr_iterator; }; #endif /* !_SYS__DOMAINSET_H_ */ Modified: head/sys/vm/vm_domainset.h ============================================================================== --- head/sys/vm/vm_domainset.h Mon Oct 1 18:51:08 2018 (r339074) +++ head/sys/vm/vm_domainset.h Mon Oct 1 18:51:39 2018 (r339075) @@ -32,7 +32,7 @@ struct vm_domainset_iter { struct domainset *di_domain; - int *di_iter; + unsigned int *di_iter; vm_pindex_t di_offset; int di_flags; uint16_t di_policy;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201810011851.w91IpddE024174>