Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 May 2013 07:36:06 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        John Baldwin <jhb@freebsd.org>
Cc:        arch@freebsd.org
Subject:   Re: Extending MADV_PROTECT
Message-ID:  <20130511043606.GE3047@kib.kiev.ua>
In-Reply-To: <201305101535.50633.jhb@freebsd.org>
References:  <201305071433.27993.jhb@freebsd.org> <201305090814.52166.jhb@freebsd.org> <20130509123147.GT3047@kib.kiev.ua> <201305101535.50633.jhb@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--ZhyQ46P6+PZKtzF3
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Fri, May 10, 2013 at 03:35:50PM -0400, John Baldwin wrote:
> Ok, here is a patch for 8 that reworks this to use a procctl().  If this looks
> reasonable I will port this to HEAD as two pieces: the first to add
> procctl() and the second to add PROCSPROTECT.

This looks fine.

Do we need the genericity of the ioctl for procctl ?
Ptrace(2) does not need the size encoded.

I mean, the call is never marshalled to some unknown driver which needs
a size of parameters unknown to the generic layer. I suppose that all
additions to procctl() would have the size of the control structures
pre-defined. Then, you could just do copyin and, if needed, copyout
discrimating on the command code, and not on the encoding of the size in
the command.

Also, command could be int and not long then, eliminating the need for
compat32 wrapper.

--ZhyQ46P6+PZKtzF3
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (FreeBSD)

iQIcBAEBAgAGBQJRjcq1AAoJEJDCuSvBvK1Ba/sP/i4BkyaYfh0CDfy0jNscG3Eh
RDp8SOWgQkowHZP6hUNJWvcnJKcyuggXszesKKSQYvcBqeQ5Y/FqVEbNhDMV7URt
qFBqMyQyCShLkzecpl7ylGOYEqhaFjtdTJp6RewXj1nCrCIna53jxSA6Z4nXbIVI
VZgaPmNhd8OwyJJyVY2nGj+PYj4/9rou6qdnhqMdwoziYePSlT1RhB6mWkXqXwn1
N100Z808I9norcWjpl19SGPt+rUQvmRSCWFLkWi9KByfkZS1d6TGnNA4krqGqKuY
FaamswCi09nF7nsD8KHe+U8HinSXbaOMJkkL5i6pvNATkcFkAja4wU8V267i8Koo
QdeiSFOFul8urwSPjyLCXia1PS6PaTwUFLhquVK1ew3uc0X/m8uh1L1oYxg2fDUS
V378U3MhMfSPUlWvKdFXTWmjE0/UeEZoGFtQtvWn6+x4N939c4ZtDKf7zpnxv1aR
wwNHaOgADLOJRQmaJNSVv7QVYQPMal4AmMKoZp/q+YiXVcy0FQFCof2TEkkOuORJ
fMQ1CtY2i3J9GZhdvjIu2fKmwVTpGkOnNn64R91OZ58HkEnuGf3snOMwU17JQbRA
fXwrtNpfGCU1ZUiLXTAuxHDkhpptNHl7JQiQrW4Ohm+v82SqxFf4P/oq1pHPtv9l
DoXly/fKRlQfnTShxaVr
=A8n/
-----END PGP SIGNATURE-----

--ZhyQ46P6+PZKtzF3--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130511043606.GE3047>