i915: allocate devname at init time
Since it'll be freed at unload time, we should alloc devname rather than pointing to the DRIVER_NAME string.main
parent
b57e1f7efd
commit
8dc4d4fa1f
|
@ -265,7 +265,10 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
|
|||
drm_mm_print(&dev->bm.man[DRM_BO_MEM_VRAM].manager, "VRAM");
|
||||
drm_mm_print(&dev->bm.man[DRM_BO_MEM_TT].manager, "TT");
|
||||
|
||||
dev->devname = DRIVER_NAME;
|
||||
dev->devname = kstrdup(DRIVER_NAME, GFP_KERNEL);
|
||||
if (!dev->devname)
|
||||
return -ENOMEM;
|
||||
|
||||
drm_irq_install(dev);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue