mirror of
https://github.com/team-infusion-developers/android_kernel_samsung_msm8976.git
synced 2024-09-21 20:04:01 +00:00
UPSTREAM: zram: use proper type to update max_used_pages
(cherry-pick from commit 2ea55a2caee016daee511431217861fb04767b27) max_used_pages is defined as atomic_long_t so we need to use unsigned long to keep temporary value for it rather than int which is smaller than unsigned long in a 64 bit system. Bug: 25951511 Change-Id: Iacae8b3edd074247d8416db9e47b5f3b4d80fb9f Signed-off-by: Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Minchan Kim <minchan@kernel.org> Cc: Jerome Marchand <jmarchan@redhat.com> Cc: Nitin Gupta <ngupta@vflare.org> Cc: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
9b71df804c
commit
4230a7b840
1 changed files with 1 additions and 1 deletions
|
@ -577,7 +577,7 @@ out_cleanup:
|
|||
static inline void update_used_max(struct zram *zram,
|
||||
const unsigned long pages)
|
||||
{
|
||||
int old_max, cur_max;
|
||||
unsigned long old_max, cur_max;
|
||||
|
||||
old_max = atomic_long_read(&zram->stats.max_used_pages);
|
||||
|
||||
|
|
Loading…
Reference in a new issue