Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Aug 2015 09:10:46 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        Koop Mast <kwm@FreeBSD.org>
Cc:        Jan Beich <jbeich@FreeBSD.org>, svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r286524 - in head: . etc sys/dev/drm sys/dev/drm2
Message-ID:  <BFB7A491-0787-4E81-8C67-5554AF861B35@bsdimp.com>
In-Reply-To: <1439301209.4375.40.camel@FreeBSD.org>
References:  <201508091258.t79CwvGj027161@repo.freebsd.org> <bneg-f17o-wny@FreeBSD.org> <1439301209.4375.40.camel@FreeBSD.org>

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

--Apple-Mail=_18A42306-2BC7-4C21-A695-ADDAF3EC4FD6
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=utf-8


> On Aug 11, 2015, at 7:53 AM, Koop Mast <kwm@FreeBSD.org> wrote:
>=20
> On Mon, 2015-08-10 at 02:15 +0200, Jan Beich wrote:
>> Koop Mast <kwm@FreeBSD.org> writes:
>>=20
>>> Author: kwm (ports committer)
>>> Date: Sun Aug  9 12:58:56 2015
>>> New Revision: 286524
>>> URL: https://svnweb.freebsd.org/changeset/base/286524
>>>=20
>>> Log:
>>>  Add a new group named 'video' with the id of 44. And make drm
>>> create
>>>  devices in /dev/dri/ with this new group.
>>=20
>> Would 'video' group include capture devices as well? Linux seems to
>> mix
>> /dev/nvidia*, /dev/fb* and /dev/video* all under same group despite
>> all of them have different attack vectors.
>=20
> We could extend this, but the only example I had where the dri =
devices.
> Also webcamd already chmod's it's devices:
> % ll /dev/video0
> crw-rw----  1 webcamd  webcamd  0x9a Aug 10 07:35 /dev/video0
>=20
> I'm unsure if nvidia makes any /dev devices since it been ages since I
> had one in a machine of mine.
>=20
>>> Modified: head/sys/dev/drm/drmP.h
>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
>>> --- head/sys/dev/drm/drmP.h	Sun Aug  9 12:20:22 2015
>>> (r286523)
>>> +++ head/sys/dev/drm/drmP.h	Sun Aug  9 12:58:56 2015
>>> (r286524)
>>> @@ -175,7 +175,7 @@ SYSCTL_DECL(_hw_drm);
>>>=20
>>> #define DRM_DEV_MODE	(S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP)
>>> #define DRM_DEV_UID	0
>>> -#define DRM_DEV_GID	0
>>> +#define DRM_DEV_GID	44	/* "video" group */
>>=20
>> Why hardcode? Linux often uses udev(7) rules to assign a group which
>> on
>> FreeBSD can easily be translated into devd.conf(5) or devfs.rules(5).
>>=20
>> Having 'video' assigned by kernel wouldn't eliminate having to run
>> mergemaster/etcupdate + pw groupmod on upgrade.
>=20
> I find this way easier to do. However with the devd.conf(5) or
> devfs.rules(5) someone still needs to up date the /etc and pw =
groupmod.

devd.conf isn=E2=80=99t the place for this. This is pure devfs.rules.

Warner


--Apple-Mail=_18A42306-2BC7-4C21-A695-ADDAF3EC4FD6
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=signature.asc
Content-Type: application/pgp-signature;
	name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail

-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - https://gpgtools.org

iQIcBAEBCgAGBQJVyhB3AAoJEGwc0Sh9sBEAg54QAIxT7XZBAk3NT2AnsgDvOYFl
CaPGFengI9bQZ84U7yeV+IAbHmE+JgUsGnfZSrgazee+55Shl7HS5hBjP8Dmezh6
jklC3P2gdKrigwpP0jnD0wEgNW4FlRYgcGsskTGirHe1bG2x7rcVf650vdA9oBU9
gBTYzGEOB35fd0NeUj+UX6xtYdOPE5MA8jA3IFkozLSFpiWQr6FCOYczGDaYk0u7
6qmD7tKT1UX+d3GkO9FvzyFqAD2872cGJo/ljsfAKxH40AgEzbrl90oKTpmh8hiU
AzmH0vt/PIf+o1STa3VWblKR1JQGXCT0qjfRhT64WAOCyWA8zsPCSpeV2ilrgytB
HspRWqywZ4epdwQYikqIKx3X4okFsObkpGGNTzn5P0m+YJa1ynqbNHfgf8Y4PLYn
xHh/Wo1AfPvEExDvM6ePtZeubWp+mnVXLVpqQI3IzUun/qSbByBlZlG9JmzVt3Cf
tsrkOIcnNFFWwGjUuLQ9BJZXkRkwzXFaH0FPPm7ucuvIWY5X2ElFA18mE/M9gBox
grKZSiV8NVgKZP2XoMs+5EUpo88uCv0auKnlYz4FKhOsDPq1Wf5qUrj0bNiPwpUm
FLcugaCvDkc+DzGhERr4a0ng1mgsrPo4eg3YHj9cMLOLPfiIfBAgRVcdojac49CJ
BTMreEjigDuvogWNpSfD
=tus0
-----END PGP SIGNATURE-----

--Apple-Mail=_18A42306-2BC7-4C21-A695-ADDAF3EC4FD6--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BFB7A491-0787-4E81-8C67-5554AF861B35>