freebsd-dev/share
Ka Ho Ng 1eaa36523c fspacectl(2): Clarifies the return values
rmacklem@ spotted two things in the system call:
- Upon returning from a successful operation, vop_stddeallocate can
  update rmsr.r_offset to a value greater than file size. This behavior,
  although being harmless, can be confusing.
- The EINVAL return value for rqsr.r_offset + rqsr.r_len > OFF_MAX is
  undocumented.

This commit has the following changes:
- vop_stddeallocate and shm_deallocate to bound the the affected area
  further by the file size.
- The EINVAL case for rqsr.r_offset + rqsr.r_len > OFF_MAX is
  documented.
- The fspacectl(2), vn_deallocate(9) and VOP_DEALLOCATE(9)'s return
  len is explicitly documented the be the value 0, and the return offset
  is restricted to be the smallest of off + len and current file size
  suggested by kib@. This semantic allows callers to interact better
  with potential file size growth after the call.

Sponsored by:	The FreeBSD Foundation
Reviewed by:	imp, kib
Differential Revision:	https://reviews.freebsd.org/D31604
2021-08-24 17:08:28 +08:00
..
colldef pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
colldef_unicode pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
ctypedef localedef: unbreak WITHOUT_LOCALES 2021-08-19 12:38:17 -05:00
dict
doc pkgbase: Install atf and kyua in the tests package 2021-01-04 16:20:47 +01:00
dtrace pkgbase: Put dtrace in its own package 2021-06-19 17:49:31 +02:00
examples sound: Add an example of basic sound application 2021-08-04 18:11:54 +08:00
i18n Remove mkcsmapper_static and mkesdb_static from build-tools 2021-08-02 14:33:25 +01:00
keys
man fspacectl(2): Clarifies the return values 2021-08-24 17:08:28 +08:00
misc Add myself (diizzy) as ports committer 2021-08-11 09:58:17 +02:00
mk Mark LLDB/CLANG_BOOTSTRAP/LLD_BOOTSTRAP as broken on non-FreeBSD for now 2021-08-17 17:44:52 +01:00
monetdef pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
monetdef_unicode pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
msgdef pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
msgdef_unicode pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
numericdef pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
numericdef_unicode pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
security
sendmail
skel
snmp pkgbase: Put the mibs and defs in the bnsmp package 2021-06-19 17:50:03 +02:00
syscons syscons: scrnmaps: appease -Wmissing-variable-declarations 2021-01-01 11:53:47 -06:00
tabset
termcap termcap: add an entry for the foot terminal 2021-02-21 06:06:47 +01:00
tests
timedef pkgbase: locales: Also tag the files dir 2021-08-06 14:37:45 +02:00
vt vt/fonts: fix typo 2020-12-02 09:42:02 +00:00
zoneinfo pkgbase: Put zoneinfo file in their own package 2021-01-04 16:18:36 +01:00
Makefile locales: now that C.UTF-8 is the default locale, always install it 2021-07-23 16:58:20 +02:00
Makefile.inc