Merge tag 'lsk-v3.10-android-14.12'
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / arm / mali400 / mali / linux / mali_osk_math.c
1 /*
2  * This confidential and proprietary software may be used only as
3  * authorised by a licensing agreement from ARM Limited
4  * (C) COPYRIGHT 2008-2010, 2013-2014 ARM Limited
5  * ALL RIGHTS RESERVED
6  * The entire notice above must be reproduced on all authorised
7  * copies and copies may only be made to the extent permitted
8  * by a licensing agreement from ARM Limited.
9  */
10
11 /**
12  * @file mali_osk_math.c
13  * Implementation of the OS abstraction layer for the kernel device driver
14  */
15
16 #include "mali_osk.h"
17 #include <linux/bitops.h>
18
19 u32 _mali_osk_clz(u32 input)
20 {
21         return 32 - fls(input);
22 }
23
24 u32 _mali_osk_fls(u32 input)
25 {
26         return fls(input);
27 }