Re: [PATCH 5/6 v3] staging: unisys: move parahotplug to sysfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jul 24, 2014 at 02:08:46PM -0400, Benjamin Romer wrote:
> +	if (kstrtouint(buf, 10, &id) != 1)
>  		return -EINVAL;

Obviously this doesn't work.  Btw, you should update your test suite to
prevent this kind of embarassing typo in the future.  ;)

Also I was reviewing enable_ints_write() earlier today and it does:

	ret = kstrtouint(buf, 10, &new_value);
	if (ret != 0)
		return ret;

Don't do the "!= 0", it's a double negative and it doesn't contribute
anything.  Just do "if (ret) ".

regards,
dan carpenter


_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux