From owner-svn-src-all@freebsd.org Fri May 27 21:01:55 2016 Return-Path: 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 8421EB4DA31; Fri, 27 May 2016 21:01:55 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (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 154DF10F7; Fri, 27 May 2016 21:01:54 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id u4RL1mCk096663 (version=TLSv1 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Sat, 28 May 2016 00:01:48 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua u4RL1mCk096663 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id u4RL1mEI096662; Sat, 28 May 2016 00:01:48 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sat, 28 May 2016 00:01:48 +0300 From: Konstantin Belousov To: Ivan Klymenko Cc: Alan Cox , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r300865 - in head/sys: sys vm Message-ID: <20160527210148.GR38613@kib.kiev.ua> References: <201605271915.u4RJFkEl013139@repo.freebsd.org> <20160527225103.67ae3547@nonamehost.local> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160527225103.67ae3547@nonamehost.local> User-Agent: Mutt/1.6.1 (2016-04-27) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 May 2016 21:01:55 -0000 On Fri, May 27, 2016 at 10:51:03PM +0300, Ivan Klymenko wrote: > On Fri, 27 May 2016 19:15:46 +0000 (UTC) > Alan Cox wrote: > > > Author: alc > > Date: Fri May 27 19:15:45 2016 > > New Revision: 300865 > > URL: https://svnweb.freebsd.org/changeset/base/300865 > > > > Log: > > The flag "vm_pages_needed" has long served two distinct purposes: > > (1) to indicate that threads are waiting for free pages to become > > available and (2) to indicate whether a wakeup call has been sent to > > the page daemon. The trouble is that a single flag cannot really > > serve both purposes, because we have two distinct targets for when to > > wakeup threads waiting for free pages versus when the page daemon has > > completed its work. In particular, the flag will be cleared by > > vm_page_free() before the page daemon has met its target, and this > > can lead to the OOM killer being invoked prematurely. To address this > > problem, a new flag "vm_pageout_wanted" is introduced. > > Discussed with: jeff > > Reviewed by: kib, markj > > Tested by: markj > > Sponsored by: EMC / Isilon Storage Division > > > > Modified: > > head/sys/sys/vmmeter.h > > head/sys/vm/vm_page.c > > head/sys/vm/vm_pageout.c > > head/sys/vm/vm_pageout.h > > > > Modified: head/sys/vm/vm_pageout.h > > ============================================================================== > > --- head/sys/vm/vm_pageout.h Fri May 27 18:52:58 2016 > > (r300864) +++ head/sys/vm/vm_pageout.h Fri May 27 19:15:45 > > 2016 (r300865) @@ -72,9 +72,10 @@ > > */ > > > > extern int vm_page_max_wired; > > -extern int vm_pages_needed; /* should be some "event" > > structure */ extern int vm_pageout_deficit; > > extern int vm_pageout_page_count; > > +extern bool vm_pageout_wanted; > > +extern bool vm_pages_needed; > > > > /* > > * Swap out requests > > _______________________________________________ > > svn-src-all@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/svn-src-all > > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" > > ... > ===> lib/libalias/modules/smedia (obj) > --- cddl/lib__L --- > In file included > from /usr/src/cddl/lib/libzpool/../../../sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c:143: /media/da0s1/obj/usr/src/tmp/usr/include/vm/vm_pageout.h:77:8: > error: unknown type name 'bool' extern bool vm_pageout_wanted; > ^ > /media/da0s1/obj/usr/src/tmp/usr/include/vm/vm_pageout.h:78:8: error: > unknown type name 'bool' extern bool vm_pages_needed; > ^ > 2 errors generated. > *** [arc.So] Error code 1 Does it compile if you just remove the #include line from arc.c and possibly zfs_vnops.c ? If not, try bracing the line with #ifdef _KERNEL, like this: diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c index c1a254a..74193d1 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c @@ -140,7 +140,9 @@ #include #include +#ifdef _KERNEL #include +#endif #include #ifdef illumos diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c index 6b25d39..c39e6a0 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c @@ -75,7 +75,9 @@ #include #include #include +#ifdef _KERNEL #include +#endif /* * Programming rules.