Author: kib
Date: Sun Dec  2 13:29:13 2018
New Revision: 341400
URL: https://svnweb.freebsd.org/changeset/base/341400

Log:
  Add a comment noting that the additional range checks are not needed.
  
  The object size is set in the dsp_mmap_single() which provides the
  range limit by vm_fault().
  
  Reported by:  C Turt <ect...@gmail.com>
  Reviewed by:  alc, markj
  admbug:               781
  MFC after:    2 weeks
  Sponsored by: The FreeBSD Foundation

Modified:
  head/sys/dev/sound/pcm/dsp.c

Modified: head/sys/dev/sound/pcm/dsp.c
==============================================================================
--- head/sys/dev/sound/pcm/dsp.c        Sun Dec  2 13:27:36 2018        
(r341399)
+++ head/sys/dev/sound/pcm/dsp.c        Sun Dec  2 13:29:13 2018        
(r341400)
@@ -2205,7 +2205,10 @@ dsp_mmap(struct cdev *i_dev, vm_ooffset_t offset, vm_p
     int nprot, vm_memattr_t *memattr)
 {
 
-       /* XXX memattr is not honored */
+       /*
+        * offset is in range due to checks in dsp_mmap_single().
+        * XXX memattr is not honored.
+        */
        *paddr = vtophys(offset);
        return (0);
 }
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to