[Nouveau] [Bug 86539] [NVAC] Trying to register nv_backlight after NV96 did it

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Mon Feb 29 07:39:04 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=86539

--- Comment #11 from Hans de Goede <jwrdegoede at fedoraproject.org> ---
Hi Pierre,

Thanks for working on this. I'm not sure what the nbs suffix stands for, maybe
rename it to
bl_interface_nr ?

Chances are that nv50_backlight_init() may run twice at the same time if 2
cards are being probed simultaneously. So I would make bl_interface_nr an
atomic_t and use:

int nr = atomic_inc_return(&bl_interface_nr) - 1;

to increment it and get the _NEW_ value. Since this gives you the new value,
you should substract 1 as is done above.

Regards,

Hans

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/nouveau/attachments/20160229/02865c6d/attachment.html>


More information about the Nouveau mailing list