diff options
author | Joe Perches <joe@perches.com> | 2013-10-23 15:14:51 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-07 05:01:42 -0500 |
commit | da4a733946aa360e2219ce2d33b8d25ce4aa1959 (patch) | |
tree | b023fd537a41580694d5b6c66311a18e9eadf258 | |
parent | 12d1ee1f2df0ee56441a76a0ad0984936b046aa8 (diff) |
[media] media: Remove OOM message after input_allocate_device
Emitting an OOM message isn't necessary after input_allocate_device
as there's a generic OOM and a dump_stack already done.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r-- | drivers/media/rc/imon.c | 8 | ||||
-rw-r--r-- | drivers/media/usb/em28xx/em28xx-input.c | 4 | ||||
-rw-r--r-- | drivers/media/usb/pwc/pwc-if.c | 1 |
3 files changed, 3 insertions, 10 deletions
diff --git a/drivers/media/rc/imon.c b/drivers/media/rc/imon.c index f329485c6629..822b9f47ca72 100644 --- a/drivers/media/rc/imon.c +++ b/drivers/media/rc/imon.c | |||
@@ -1909,10 +1909,8 @@ static struct input_dev *imon_init_idev(struct imon_context *ictx) | |||
1909 | int ret, i; | 1909 | int ret, i; |
1910 | 1910 | ||
1911 | idev = input_allocate_device(); | 1911 | idev = input_allocate_device(); |
1912 | if (!idev) { | 1912 | if (!idev) |
1913 | dev_err(ictx->dev, "input dev allocation failed\n"); | ||
1914 | goto out; | 1913 | goto out; |
1915 | } | ||
1916 | 1914 | ||
1917 | snprintf(ictx->name_idev, sizeof(ictx->name_idev), | 1915 | snprintf(ictx->name_idev, sizeof(ictx->name_idev), |
1918 | "iMON Panel, Knob and Mouse(%04x:%04x)", | 1916 | "iMON Panel, Knob and Mouse(%04x:%04x)", |
@@ -1960,10 +1958,8 @@ static struct input_dev *imon_init_touch(struct imon_context *ictx) | |||
1960 | int ret; | 1958 | int ret; |
1961 | 1959 | ||
1962 | touch = input_allocate_device(); | 1960 | touch = input_allocate_device(); |
1963 | if (!touch) { | 1961 | if (!touch) |
1964 | dev_err(ictx->dev, "touchscreen input dev allocation failed\n"); | ||
1965 | goto touch_alloc_failed; | 1962 | goto touch_alloc_failed; |
1966 | } | ||
1967 | 1963 | ||
1968 | snprintf(ictx->name_touch, sizeof(ictx->name_touch), | 1964 | snprintf(ictx->name_touch, sizeof(ictx->name_touch), |
1969 | "iMON USB Touchscreen (%04x:%04x)", | 1965 | "iMON USB Touchscreen (%04x:%04x)", |
diff --git a/drivers/media/usb/em28xx/em28xx-input.c b/drivers/media/usb/em28xx/em28xx-input.c index 9a5dad96ff08..61c061f3a476 100644 --- a/drivers/media/usb/em28xx/em28xx-input.c +++ b/drivers/media/usb/em28xx/em28xx-input.c | |||
@@ -557,10 +557,8 @@ static int em28xx_register_snapshot_button(struct em28xx *dev) | |||
557 | 557 | ||
558 | em28xx_info("Registering snapshot button...\n"); | 558 | em28xx_info("Registering snapshot button...\n"); |
559 | input_dev = input_allocate_device(); | 559 | input_dev = input_allocate_device(); |
560 | if (!input_dev) { | 560 | if (!input_dev) |
561 | em28xx_errdev("input_allocate_device failed\n"); | ||
562 | return -ENOMEM; | 561 | return -ENOMEM; |
563 | } | ||
564 | 562 | ||
565 | usb_make_path(dev->udev, dev->snapshot_button_path, | 563 | usb_make_path(dev->udev, dev->snapshot_button_path, |
566 | sizeof(dev->snapshot_button_path)); | 564 | sizeof(dev->snapshot_button_path)); |
diff --git a/drivers/media/usb/pwc/pwc-if.c b/drivers/media/usb/pwc/pwc-if.c index 78c9bc8e7f56..abf365ab025d 100644 --- a/drivers/media/usb/pwc/pwc-if.c +++ b/drivers/media/usb/pwc/pwc-if.c | |||
@@ -1078,7 +1078,6 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_id | |||
1078 | /* register webcam snapshot button input device */ | 1078 | /* register webcam snapshot button input device */ |
1079 | pdev->button_dev = input_allocate_device(); | 1079 | pdev->button_dev = input_allocate_device(); |
1080 | if (!pdev->button_dev) { | 1080 | if (!pdev->button_dev) { |
1081 | PWC_ERROR("Err, insufficient memory for webcam snapshot button device."); | ||
1082 | rc = -ENOMEM; | 1081 | rc = -ENOMEM; |
1083 | goto err_video_unreg; | 1082 | goto err_video_unreg; |
1084 | } | 1083 | } |