Page MenuHomeFreeBSD

linux: implement sched_getattr()
Needs ReviewPublic

Authored by ngie on Fri, Oct 2, 12:51 AM.
Tags
None
Referenced Files
F174391009: D60214.id188451.diff
Fri, Oct 2, 9:09 PM
F174371147: D60214.id188351.diff
Fri, Oct 2, 6:21 PM
F174368013: D60214.diff
Fri, Oct 2, 5:51 PM
F174347450: D60214.id.diff
Fri, Oct 2, 2:30 PM
F174337015: D60214.diff
Fri, Oct 2, 12:22 PM
F174305517: D60214.id188351.diff
Fri, Oct 2, 5:33 AM
F174305340: D60214.diff
Fri, Oct 2, 5:31 AM
Subscribers

Details

Reviewers
None
Group Reviewers
Linux Emulation
Summary

This change adds the necessary glue to translate Linux scheduler policy
and priority from FreeBSD so this information is available to Linux
applications.

This unbreaks using the Linux version of Chromium on FreeBSD.

This change was originally submitted via [freebsd/freebsd-src#2370][github-pr].

PR: 297468
Co-Authored-By: Enji Cooper <ngie@FreeBSD.org>
Signed-off-by: Joao Bonifacio <joaoboni017@gmail.com>

[github-pr]: https://github.com/freebsd/freebsd-src/pull/2370

Test Plan

TODO:

  • build change and test as shown in the PR (minimum bar)
  • run the relevant sched_getattr tests from LTP.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 77590
Build 74473: arc lint + arc unit

Event Timeline

ngie requested review of this revision.Fri, Oct 2, 12:51 AM
ngie added a reviewer: Linux Emulation.
  • Add additional constants.
  • Apply other logic changes I brought up in the differential.
sys/compat/linux/linux_misc.c
1421–1425
1426

The MIN call here duplicates logic on line 1401.