lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 5 Mar 2015 09:09:16 +0900
From:	Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
	Minchan Kim <minchan@...nel.org>,
	Nitin Gupta <ngupta@...are.org>, linux-kernel@...r.kernel.org,
	Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
Subject: Re: [PATCH 2/2] zram: introduce automatic device_id generation

On (03/04/15 14:13), Andrew Morton wrote:
> > +static ssize_t zram_add_show(struct class *class,
> > +			struct class_attribute *attr,
> > +			char *buf)
> > +{
> > +	int ret;
> > +
> > +	mutex_lock(&zram_index_mutex);
> > +	/* read operation on zram_add is - pick up device_id
> > +	 * automatically, add corresponding device and return
> > +	 * that device_id back to user */
> > +	ret = zram_add(-1);
> > +	mutex_unlock(&zram_index_mutex);
> > +
> > +	if (ret < 0)
> > +		return ret;
> > +	return scnprintf(buf, PAGE_SIZE, "%d\n", ret);
> > +}
> 
> Please don't invent new commenting styles.  Because doing so inevitably
> creates a mixed-up mess, which is what we now have.
> 

sorry. sure, will take care of that next time. thanks for pointing that
out.

	-ss

> --- a/drivers/block/zram/zram_drv.c~zram-introduce-automatic-device_id-generation-fix
> +++ a/drivers/block/zram/zram_drv.c
> @@ -1281,9 +1281,10 @@ static ssize_t zram_add_show(struct clas
>  	int ret;
>  
>  	mutex_lock(&zram_index_mutex);
> -	/* read operation on zram_add is - pick up device_id
> -	 * automatically, add corresponding device and return
> -	 * that device_id back to user */
> +	/*
> +	 * read operation on zram_add is - pick up device_id automatically, add
> +	 * corresponding device and return that device_id back to user
> +	 */
>  	ret = zram_add(-1);
>  	mutex_unlock(&zram_index_mutex);
>  
> _
> 
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ