On 2022/06/21 16:39, Jonathan Gray wrote:
> chromium loads vulkan when going to chrome://gpu
> on Intel Mesa uses HW_USERMEM64
> 
> chrome(44801): pledge sysctl 2: 6 20
> chrome[44801]: pledge "", syscall 202

ok with me, it's read-only and low-risk for the new functionality it
allows to other programmes using pledge sysctl already, and there seems
no reason not to have it when HW_PHYSMEM64 is available.

> Index: sys/kern/kern_pledge.c
> ===================================================================
> RCS file: /cvs/src/sys/kern/kern_pledge.c,v
> retrieving revision 1.281
> diff -u -p -r1.281 kern_pledge.c
> --- sys/kern/kern_pledge.c    25 Mar 2022 17:40:59 -0000      1.281
> +++ sys/kern/kern_pledge.c    21 Jun 2022 06:23:09 -0000
> @@ -977,6 +977,7 @@ pledge_sysctl(struct proc *p, int miblen
>                       case HW_PHYSMEM64:      /* hw.physmem */
>                       case HW_NCPU:           /* hw.ncpu */
>                       case HW_NCPUONLINE:     /* hw.ncpuonline */
> +                     case HW_USERMEM64:      /* hw.usermem */
>                               return (0);
>                       }
>                       break;
> 

Reply via email to