Merge tag 'v3.10.79' into update
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / drivers / misc / mediatek / gpu / mt8127 / mali / ump / linux / ump_osk_atomics.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 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 ump_osk_atomics.c
13 * Implementation of the OS abstraction layer for the UMP kernel device driver
14 */
15
16 #include "ump_osk.h"
17 #include <asm/atomic.h>
18
19 int _ump_osk_atomic_dec_and_read( _mali_osk_atomic_t *atom )
20 {
21 return atomic_dec_return((atomic_t *)&atom->u.val);
22 }
23
24 int _ump_osk_atomic_inc_and_read( _mali_osk_atomic_t *atom )
25 {
26 return atomic_inc_return((atomic_t *)&atom->u.val);
27 }