Re: [PATCH] Staging: vme: fix a wrong waring in vme_user_probe()

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

 



On Wed, Aug 05, 2015 at 01:24:52PM +0800, Navy Cheng wrote:
> The waring message will mislead developers and users. This will cause a
> potential damage. Fix the waring message to give developers and users the
> correct guidance.

"waring"?



> 
> Signed-off-by: Navy Cheng <navych@xxxxxxx>
> ---
>  drivers/staging/vme/devices/vme_user.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/vme/devices/vme_user.c b/drivers/staging/vme/devices/vme_user.c
> index 19ba749..40097fe 100644
> --- a/drivers/staging/vme/devices/vme_user.c
> +++ b/drivers/staging/vme/devices/vme_user.c
> @@ -785,7 +785,7 @@ static int vme_user_probe(struct vme_dev *vdev)
>  	vme_user_cdev->owner = THIS_MODULE;
>  	err = cdev_add(vme_user_cdev, MKDEV(VME_MAJOR, 0), VME_DEVS);
>  	if (err) {
> -		dev_warn(&vdev->dev, "cdev_all failed\n");
> +		dev_warn(&vdev->dev, "cdev_add failed\n");

The only way this can fail is if we don't have enough memory, and a
message will be printed out there, so might as well just remove this
message entirely as well.

thanks,

greg k-h
_______________________________________________
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