Re: [RFC v2 1/4] drm: Add support to find drm_panel by name

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

 



On 01/13/2015 12:08 AM, Daniel Vetter wrote:
> On Fri, Jan 9, 2015 at 1:50 PM, Jani Nikula <jani.nikula@xxxxxxxxx> wrote:
>> I have a slightly uneasy feeling about handing out drm_panel pointers
>> (both from here and of_drm_find_panel) without refcounting. If the panel
>> driver gets removed, whoever called the find functions will have a
>> dangling pointer. I supposed this will be discussed on drm-devel.

refcounting does not seems to me a good solution, drm_panel is
exposed by device driver and device driver can be unbound unconditionally
at any time. This problem affects many frameworks not only drm_panel.

I work on resource tracking framework which tries to solve the problem
in a generic way[1].

[1]: https://lkml.org/lkml/2014/12/10/342

Regards
Andrzej


> There's been some discussion already about exactly this problem (but
> with drm bridges) with Thierry and some other people. Cc'ed them all
> hopefully. Especially when the panel/bridge is a separate driver
> there's imo indeed an issue.
> -Daniel

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux