Simply use a typedef for refcount_t on atomic_t, this allow us
to use a nativ type and also changing struct kref to directly use
a refcount_t like Linux.
Reviewed by: bz
Sponsored by: Beckhoff Automation GmbH & Co. KG
Differential Revision: https://reviews.freebsd.org/D45207
(cherry picked from commit abb1a1340e3f0dcdbb81b5c42ad304f02c812e20)
In Linux this takes a refcount_t argument but in linuxkpi struct kref
uses an atomic_t for the refcount and code in drm directly uses this
function with a kref so use an atomic_t here.
Reviewed by: bz
Sponsored by: Beckhoff Automation GmbH & Co. KG
Differential Revision: https://reviews.freebsd.org/D36099
Implement some refcount functions needed by drm.
Just use the atomic_t struct and functions from linuxkpi for simplicity.
Sponsored-by: The FreeBSD Foundation
Reviewed by: hselsasky
Differential Revision: https://reviews.freebsd.org/D24985