aboutsummaryrefslogtreecommitdiff
path: root/bsd-core/radeon_drv.c
diff options
context:
space:
mode:
authorRobert Noland <rnoland@2hip.net>2008-10-03 14:05:45 -0400
committerRobert Noland <rnoland@2hip.net>2008-10-03 14:05:45 -0400
commit9c0ce38df3d9026785155d06fc62bdd7acaf8bf0 (patch)
treedb627d17b973fb57cca446d17809369a2c77fda2 /bsd-core/radeon_drv.c
parent4c92abfa8d0b9f2ab14e6b915bdffd47fd2e2474 (diff)
[FreeBSD] Use M_WAITOK when allocating driver memory.
We don't explicitly check for error here and M_WAITOK will just put the process to sleep waiting on resources to become available. Suggested by John Baldwin
Diffstat (limited to 'bsd-core/radeon_drv.c')
-rw-r--r--bsd-core/radeon_drv.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/bsd-core/radeon_drv.c b/bsd-core/radeon_drv.c
index 8ab3e995..6b90dd69 100644
--- a/bsd-core/radeon_drv.c
+++ b/bsd-core/radeon_drv.c
@@ -89,7 +89,9 @@ radeon_attach(device_t nbdev)
bzero(dev, sizeof(struct drm_device));
- dev->driver = malloc(sizeof(struct drm_driver_info), M_DRM, M_NOWAIT | M_ZERO);
+ dev->driver = malloc(sizeof(struct drm_driver_info), M_DRM,
+ M_WAITOK | M_ZERO);
+
radeon_configure(dev);
return drm_attach(nbdev, radeon_pciidlist);