diff options
author | Alexandre Courbot <acourbot@nvidia.com> | 2016-09-16 18:09:12 +0900 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2016-11-04 17:17:05 +1000 |
commit | 26735c44da7a2de18d66fe63507a9c4863ebd719 (patch) | |
tree | a46cd8fc94d567b8b264fa6e713fe14a43d6a66d /lib | |
parent | 6fa1704bb55f7e9bc31a46989791c56a3c9f76e6 (diff) | |
download | nouveau-26735c44da7a2de18d66fe63507a9c4863ebd719.tar.gz |
volt: use kernel's 64-bit signed division function
Doing direct 64 bit divisions in kernel code leads to references to
undefined symbols on 32 bit architectures. Replace such divisions with
calls to div64_s64 to make the module usable on 32 bit archs.
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
Reviewed-by: Karol Herbst <karolherbst@gmail.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/include/nvif/os.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/include/nvif/os.h b/lib/include/nvif/os.h index 2f34c5a28..c10c29f33 100644 --- a/lib/include/nvif/os.h +++ b/lib/include/nvif/os.h @@ -88,6 +88,7 @@ typedef dma_addr_t resource_size_t; ) #define do_div(a,b) (a) = (a) / (b) #define div_u64(a,b) (a) / (b) +#define div64_s64(a,b) (a) / (b) #define likely(a) (a) #define unlikely(a) (a) #define BIT(a) (1UL << (a)) |