Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Oct 2015 18:08:32 +0200
From:      =?UTF-8?Q?Jean-S=c3=a9bastien_P=c3=a9dron?= <jean-sebastien.pedron@dumbbell.fr>
To:        Hans Petter Selasky <hps@selasky.org>, Konstantin Belousov <kostikbel@gmail.com>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r289565 - head/sys/ofed/include/linux
Message-ID:  <56251580.10907@dumbbell.fr>
In-Reply-To: <56250752.5030007@selasky.org>
References:  <201510191056.t9JAuWhF052021@repo.freebsd.org> <20151019150130.GK2257@kib.kiev.ua> <56250752.5030007@selasky.org>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--JpK9XquJoTafJjUEawQBni4UISTFCFgGD
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

On 19.10.2015 17:08, Hans Petter Selasky wrote:
> On 10/19/15 17:01, Konstantin Belousov wrote:
>> This is wrong on many counts.  First, we already provide the wrappers =
to
>> implement the nofaulting behaviour, see vm_fault_disable_pagefaults()
>> and vm_fault_enable_pagefaults().
>>
>> Second, your implementation ignores possible recursion on the
>> state, unconditionally re-enabling faulting, and more seriously, it
>> unconditionally obliterates the spurious faults tracker.
>>
>> The return value from vm_fault_disable_pagefaults() is there for the
>> reason,
>> and if Linux KPI does not have a place to store the state, some
>> replacement
>> must be implemented instead of silently corrupting the flags on enable=
=2E
>=20
> Hi Konstantin,
>=20
> Thank you for you input. I'll update these functions according to your
> suggestion. We can have a return value, even if Linux doesn't. It
> doesn't have to be exactly the same and then I can set a compiler
> attribute that the return value must be checked.

Hi!

I believe we should not try to completely "hide" FreeBSD at all cost
when both KPIs do not match. If we can't implement the Linux behaviour,
I think we should not modify the Linux KPI but instead use the native
FreeBSD function. If we change the Linux KPI in a way which requires a
change in the consumers, consumers will have a diff with Linux original
code anyway, so let's use the native function and make the difference in
KPI/behaviour explicit.

To me, the goal of this shim is to reduce the diff with Linux in
consumers, not eliminate it.

--=20
Jean-S=E9bastien P=E9dron


--JpK9XquJoTafJjUEawQBni4UISTFCFgGD
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

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

iQJ8BAEBCgBmBQJWJRWFXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz
OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTM6aYQAKZkM2ik6SDXHn6++oHtih77
92iGj7qA3PXwH4T7yInGJwX1RMyP5KhuEDLepEG9pSqS0Cc01/le3SZpj0t5yaOK
qU071Ih23ICtREEos7Rq5l61D+QPAD76vXw5w5p5VTkIj2LAY3vDGXLDqN3eCzf5
gBhedlTLV2t4l0o/XO+Dv2ln3rE/WnrWeaX0worVuGk33TB8faPdPs0dNiqQg5t4
m7OOpOTgmc9gktVmIrKVSuZg5iGRVCS7CD6SEmL/ajxaCvA1zn0ua8+7uRs794q1
iTKMK/xxBufm3278VwkvwDDE1+9ajHybuyB+PBb10GcUJEfWy4u6FP9f42rIhDvx
rNXN9lb51adbjlCRohiKkoAvtLP3SQ/w3Am/up6gfFJ3AcXMhotAb8AdrRyeO0BV
VbgXnxnzjkGpH3WHSluHHwbUgkG5/G/cbxc0SsU/yemMBObSpJUHMCuEuFGgUDU5
iNC2Y9tKs9OPG8vuWeffjcsr8JR1d36VHqqNPrWBODcP0stUggK4xOSQcQS6ZKN1
/josVTGmdxb0ZK6dAiRzYtFMoWlW1odEO5rjP+PiXgP80ABAsWrMr3M4q/rma8JY
qOhQA1Q3qhhvxNvu9yK61Y/67HiV9ZVjJh9hAxvqTQB3UfNuq3AH67SM8L33PIar
wJ4BHL3jmadYPYOnJRZF
=bFUl
-----END PGP SIGNATURE-----

--JpK9XquJoTafJjUEawQBni4UISTFCFgGD--



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