Date: Fri, 2 Jun 2006 06:49:16 GMT From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 98317 for review Message-ID: <200606020649.k526nG1b045633@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=98317 Change 98317 by imp@imp_lighthouse on 2006/06/02 06:49:01 Implement resource activation. Affected files ... .. //depot/projects/arm/src/sys/dev/sdhc/sdhc_pci.c#5 edit Differences ... ==== //depot/projects/arm/src/sys/dev/sdhc/sdhc_pci.c#5 (text+ko) ==== @@ -116,17 +116,22 @@ } static int -sdhc_activate_resource(device_t brdev, device_t child, int type, int rid, +sdhc_activate_resource(device_t dev, device_t child, int type, int rid, struct resource *r) { - return (EIO); + if (rid != 0 || type != SYS_RES_MEMORY || + device_get_parent(child) != dev || rman_get_device(r) != dev) + return (EINVAL); + rman_set_device(r, child); + return (0); } static int -sdhc_deactivate_resource(device_t brdev, device_t child, int type, +sdhc_deactivate_resource(device_t dev, device_t child, int type, int rid, struct resource *r) { - return (EIO); + rman_set_device(r, dev); + return (0); } static void
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200606020649.k526nG1b045633>