Date: Sun, 26 Mar 2017 01:36:32 +0200 From: Konstantin Belousov <kostikbel@gmail.com> To: Dmitry Chagin <dchagin@FreeBSD.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315957 - in head/sys: amd64/linux amd64/linux32 compat/linux i386/linux Message-ID: <20170325233632.GI43712@kib.kiev.ua> In-Reply-To: <201703251547.v2PFlUpf056924@repo.freebsd.org> References: <201703251547.v2PFlUpf056924@repo.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Mar 25, 2017 at 03:47:30PM +0000, Dmitry Chagin wrote: > Author: dchagin > Date: Sat Mar 25 15:47:29 2017 > New Revision: 315957 > URL: https://svnweb.freebsd.org/changeset/base/315957 > > Log: > Implement Linux mincore() system call. > This is necessary for the upcoming drm-next. > +int > +linux_mincore(struct thread *td, struct linux_mincore_args *args) > +{ > + struct mincore_args bsd_args; > + > + /* Needs to be page-aligned */ > + if (args->start & PAGE_MASK) > + return (EINVAL); > + bsd_args.addr = PTRIN(args->start); > + bsd_args.len = args->len; > + bsd_args.vec = args->vec; > + return (sys_mincore(td, &bsd_args)); > +} Almost all syscalls implementations in vm/vm_mmap.c got the kern_* helpers, sys_mincore() did not because it was not called outside the file. Please add kern_mincore() and use it, instead of abusing syscall entry.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20170325233632.GI43712>