Date: Sat, 27 Jun 2026 09:55:59 +0000 From: Christos Margiolis <christos@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: f3d461cf3220 - stable/15 - sound: Re-arrange a calculation in dsp_mmap_single() Message-ID: <6a3f9e2f.31e91.5fb523ff@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch stable/15 has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=f3d461cf322000f7784eb42be92282a14d148cfa commit f3d461cf322000f7784eb42be92282a14d148cfa Author: Christos Margiolis <christos@FreeBSD.org> AuthorDate: 2026-06-12 06:14:57 +0000 Commit: Christos Margiolis <christos@FreeBSD.org> CommitDate: 2026-06-27 09:55:21 +0000 sound: Re-arrange a calculation in dsp_mmap_single() This makes it easier to read. No functional change intended. Sponsored by: The FreeBSD Foundation MFC after: 1 week Reviewed by: markj, kib Pull-Request: https://ron-dev.freebsd.org/FreeBSD/src/pulls/30 (cherry picked from commit 0c8147ae3bc1c7db95098fcc92fc2e86111f59d3) --- sys/dev/sound/pcm/dsp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c index 31d28245d7a8..3f0c5d622f99 100644 --- a/sys/dev/sound/pcm/dsp.c +++ b/sys/dev/sound/pcm/dsp.c @@ -1993,7 +1993,7 @@ dsp_mmap_single(struct cdev *cdev, vm_ooffset_t *offset, CHN_LOCK(c); if ((c->flags & CHN_F_MMAP_INVALID) || - *offset + size > c->bufsoft->allocsize) { + c->bufsoft->allocsize < *offset + size) { CHN_UNLOCK(c); PCM_GIANT_EXIT(d); return (EINVAL);home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a3f9e2f.31e91.5fb523ff>
