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] [day] [month] [year] [list]
Date:	Tue, 24 Mar 2015 11:57:50 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	Sudip Mukherjee <sudipm.mukherjee@...il.com>
Cc:	devel@...verdev.osuosl.org,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	sparmaintainer@...sys.com, linux-kernel@...r.kernel.org,
	Benjamin Romer <benjamin.romer@...sys.com>,
	David Kershner <david.kershner@...sys.com>
Subject: Re: [PATCH] staging: unisys: handle major number properly

On Tue, Mar 24, 2015 at 02:13:16PM +0530, Sudip Mukherjee wrote:
> On Tue, Mar 24, 2015 at 11:32:47AM +0300, Dan Carpenter wrote:
> <snip>
> > >  	}
> > > -	rc = cdev_add(&file_cdev, MKDEV(MAJOR(majordev), 0), 1);
> > > +	rc = cdev_add(&file_cdev, MKDEV(major, 0), 1);
> > 
> > This should just be:
> > 
> > 	rc = cdev_add(&file_cdev, majordev, 1);
> > 
> > So here is my suggestion:
> > 
> > [patch 1] delete dead code I mentioned in my previous email.
> > 	This deletes "registered" and the (MAJOR(majordev) >= 0) check.
> 
> that was initially my first patch.

Yes, but the patch description wasn't clear.  You were talking saying
the condition was always true because of the types and I am saying the
condition is always true because of the order the functions are called.

> 
> > 
> > [patch 2] pass majordev to visorchipset_file_cleanup()
> > 	This lets you delete the "majordev" global.
> > 
> > [patch 3] small cleanup in visorchipset_file_init()
> > 
> > -	rc = cdev_add(&file_cdev, MKDEV(MAJOR(majordev), 0), 1);
> > +	rc = cdev_add(&file_cdev, majordev, 1);
> 
> and i can also include the removal of that global variable in this
> 3rd patch.
> thanks.. after Greg's review i was thinking i understood the code wrong.
> but then will this be a v2 or a whole new series?

I'm pretty sure we're up to v3 at least now.  This means redoing the
whole series, yes.

regards,
dan carpenter

--
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