Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Jan 2016 18:25:47 +0100
From:      =?UTF-8?Q?Jean-S=c3=a9bastien_P=c3=a9dron?= <jean-sebastien.pedron@dumbbell.fr>
To:        Nikola Pajkovsky <n.pajkovsky@gmail.com>
Cc:        freebsd-x11@freebsd.org
Subject:   Re: build-able drm-i915-update-38
Message-ID:  <56992B9B.4010405@dumbbell.fr>
In-Reply-To: <87twmfxhka.fsf@gooddata.com>
References:  <87oacpdguk.fsf@gooddata.com> <5696A19A.2030009@dumbbell.fr> <864mehduk6.fsf@freebsd.lan> <5698AB9C.9070005@dumbbell.fr> <87twmfxhka.fsf@gooddata.com>

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

On 15/01/2016 11:28, Nikola Pajkovsky wrote:
> BUG_ON() is defined in linux.git/include/asm-generic/bug.h as
>=20
>    #ifndef HAVE_ARCH_BUG
>    #define BUG() do { \
>    	printk("BUG: failure at %s:%d/%s()!\n", __FILE__, __LINE__, __func_=
_); \
>    	panic("BUG!"); \
>    } while (0)
>    #endif
>=20
>    #ifndef HAVE_ARCH_BUG_ON
>    #define BUG_ON(condition) do { if (unlikely(condition)) BUG(); } whi=
le(0)
>    #endif
>=20
> and HAVE_ARCH_BUG is defined for x86, hence, BUG_ON must be *on* always=
,
> even in kernel w/o debugging options.

For now in FreeBSD, I defined BUG_ON() to be the same as KASSERT(). I
now see that for BUG(), I defined it as panic(), so it's still effective
on a non-debug kernel. Therefore, both definitions are inconsistents...

In your pull request, feel free to change how BUG() and BUG_ON() are
defined so they are always active and consistent.

--=20
Jean-S=C3=A9bastien P=C3=A9dron


--bQ15ASsn89BvDB81FXWIAmS9kjTocaU2N
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

iQJ8BAEBCgBmBQJWmSugXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz
OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMH3oP/1zz5psi6a8ft0Za4M16SS6R
IfdnnQ+RQJNhu4ygunAOyHDKUepl3eUUx9FVMdfHc0KqMenlnNVQhh7EKlnBRgF/
3zya8F+nTji238nX2eDN/xVuWZNZJao0zf7/+QtmKQ/QXF6rir3DnmZPOOn8dscA
4LJ6KYM6YWW8di/6+iLKpgtBdoIvKBdAF84LlYBMNKqwC696THazOnuU5M6tB4nb
zy3kGtAMS0wWT+6lVSqmm9LB3g6ACEMK+lcxykFGyXFMjUyP/HkFB1kp2K3AFohz
BT25GWDYu6Rd/5DQcmKqj/FxSTi9l8Y0QGAgu1s20vxsMgolVE8LLL5bZKlLbpqn
qEferSeCg0QOo7jzC2KgT5hiaQZw1hmD1v4ohYBUAnZDK9/3HlPwUZgFY7U8oJDJ
IKRQSKIomB6WEpOqvvHZE60OmnYB8TU5Aevj6oF3ZUBLlFlRg7xW5DVuiQjJUacr
yED5qhsgdlY/vUC0CYOslMGKvI/vTjCpA0MiTLDuHTYq4ylNjSTerhCgCTeNC9OA
pKE+zLI/1mclPyoWev5DUsAi58LQkkl2j7ixil5onClE21qaMucbiv8k5VYe/xCI
baaP1Y0iS3tKg46TkgTEH+pT7Xewe3kHACbxNI3Jf5LosrrG4eGVp4nQs8OzWaZ6
uiDUJsxQX9CH9e3uC18n
=td4u
-----END PGP SIGNATURE-----

--bQ15ASsn89BvDB81FXWIAmS9kjTocaU2N--



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