lkml.org 
[lkml]   [2018]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v3 4/4] zram: introduce zram memory tracking
Hi Minchan,

On (04/09/18 14:54), Minchan Kim wrote:
> +static long long ns2usecs(u64 nsec)
> +{
> + nsec += 500;
> + do_div(nsec, 1000);
> + return nsec;
> +}

Sorry, I don't quite understand "nsec += 500".

> +static ssize_t read_block_state(struct file *file, char __user *buf,
> + size_t count, loff_t *ppos)
> +{
[..]
> +
> + up_read(&zram->init_lock);
> + copy_to_user(buf, kbuf, written);

drivers/block/zram/zram_drv.c: In function ‘read_block_state’:
drivers/block/zram/zram_drv.c:701:2: warning: ignoring return value of ‘copy_to_user’, declared with attribute warn_unused_result [-Wunused-result]
copy_to_user(buf, kbuf, written);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

[..]
> @@ -61,7 +61,9 @@ struct zram_table_entry {
> unsigned long element;
> };
> unsigned long value;
> +#ifdef CONFIG_ZRAM_MEMORY_TRACKING

A silly nitpick, but since you are going to resend this one, could you
remove TAB between ifdef and CONFIG_ZRAM_MEMORY_TRACKING?

-ss

\
 
 \ /
  Last update: 2018-04-10 02:03    [W:1.945 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site