DF-1686 / fix.diff
--- a/sys/dev/agp/agp.c +++ b/sys/dev/agp/agp.c @@ -857,7 +857,7 @@ device_t dev = kdev->si_drv1; struct agp_softc *sc = device_get_softc(dev); - if (ap->a_offset > AGP_GET_APERTURE(dev)) + if (ap->a_offset + PAGE_SIZE > AGP_GET_APERTURE(dev) + 1) return EINVAL; ap->a_result = atop(rman_get_start(sc->as_aperture) + ap->a_offset); return 0; |