Re: [PATCH 0/5] DRM device-alloc cleanup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 9, 2013 at 3:31 PM, Dave Airlie <airlied@xxxxxxxxx> wrote:
> On Wed, Oct 2, 2013 at 7:23 PM, David Herrmann <dh.herrmann@xxxxxxxxx> wrote:
>> Hi
>>
>> This cleans up the bus drivers in DRM. Instead of copying the device alloc/free
>> semantics into each bus driver (drm_{pci,platform,usb}.c) we now have a central
>> place in drm_stub.c.
>>
>> This introduces drm_dev_{alloc,free,register,unregister}(). They have the same
>> semantics as most other kernel subsystems. *_alloc() allocates a new device and
>> populates the static fields and sub-objects. *_free() frees an unregistered
>> object allocated via *_alloc(). *_register() registers a DRM device and
>> *_unregister() obviously unregisters a DRM device. A *_free() is still needed
>> after calling *_unregister() (same as for "struct device"). No ref-counting is
>> added as it is not required by any driver.
>>
>> Note that the bus drivers are modified to use the new helpers directly. However,
>> I didn't modify the drivers to use *_unregister() and *_free() directly.
>> Instead, the drm_put_dev() helper was modified to use these. Reason for that is
>> that I have pending patches to make device hotplugging safer regarding mmaps.
>> But these aren't ready, yet. Hopefully I can get them ready for rc5 or rc6.
>>
>> Tested on nouveau.
>>
>
> Okay I've merged this series, a follow-on to fix the AGP bits like
> Daniel suggested would be good.

Actually this oopses i915 on startup, I fixed up the lack of passing
flags into drm_dev_register,
so it can be passed to load, and it seems to work now, I've squashed
my fix into the series in my tree

please read/review the series for your learning pleasure.

Dave.
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux