Created
March 28, 2012 17:24
-
-
Save jbclements/2228419 to your computer and use it in GitHub Desktop.
devres.c only better....
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(with-handlers | |
([cant-alloc -> NULL] | |
[cant-remap -> (devres-free the-box) NULL]) | |
(define the-box (devres-alloc devm-ioremap-release, GFP_KERNEL)) | |
(define remapped (ioremap-prot offset size flags)) | |
(set-box! the-box remapped) | |
(devres-add dev the-box) | |
addr) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment