All of lore.kernel.org
 help / color / mirror / Atom feed
* [watchdog-next] watchdog: pcwd_usb: fix compilation warning
@ 2016-01-19 13:51 Tomas Winkler
  2016-01-19 14:18 ` Guenter Roeck
  0 siblings, 1 reply; 2+ messages in thread
From: Tomas Winkler @ 2016-01-19 13:51 UTC (permalink / raw)
  To: Wim Van Sebroeck, Guenter Roeck; +Cc: linux-watchdog, Tomas Winkler

In function ‘usb_pcwd_probe’:
drivers/watchdog/pcwd_usb.c:611:12: warning: variable ‘maxp’ set but not
used [-Wunused-but-set-variable]
  int pipe, maxp;

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
 drivers/watchdog/pcwd_usb.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/watchdog/pcwd_usb.c b/drivers/watchdog/pcwd_usb.c
index 1a11aedc4fe8..68952d9ccf83 100644
--- a/drivers/watchdog/pcwd_usb.c
+++ b/drivers/watchdog/pcwd_usb.c
@@ -608,7 +608,7 @@ static int usb_pcwd_probe(struct usb_interface *interface,
 	struct usb_host_interface *iface_desc;
 	struct usb_endpoint_descriptor *endpoint;
 	struct usb_pcwd_private *usb_pcwd = NULL;
-	int pipe, maxp;
+	int pipe;
 	int retval = -ENOMEM;
 	int got_fw_rev;
 	unsigned char fw_rev_major, fw_rev_minor;
@@ -641,7 +641,6 @@ static int usb_pcwd_probe(struct usb_interface *interface,
 
 	/* get a handle to the interrupt data pipe */
 	pipe = usb_rcvintpipe(udev, endpoint->bEndpointAddress);
-	maxp = usb_maxpacket(udev, pipe, usb_pipeout(pipe));
 
 	/* allocate memory for our device and initialize it */
 	usb_pcwd = kzalloc(sizeof(struct usb_pcwd_private), GFP_KERNEL);
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [watchdog-next] watchdog: pcwd_usb: fix compilation warning
  2016-01-19 13:51 [watchdog-next] watchdog: pcwd_usb: fix compilation warning Tomas Winkler
@ 2016-01-19 14:18 ` Guenter Roeck
  0 siblings, 0 replies; 2+ messages in thread
From: Guenter Roeck @ 2016-01-19 14:18 UTC (permalink / raw)
  To: Tomas Winkler, Wim Van Sebroeck; +Cc: linux-watchdog

On 01/19/2016 05:51 AM, Tomas Winkler wrote:
> In function ‘usb_pcwd_probe’:
> drivers/watchdog/pcwd_usb.c:611:12: warning: variable ‘maxp’ set but not
> used [-Wunused-but-set-variable]
>    int pipe, maxp;
>
> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>

Reviewed-by: Guenter Roeck <linux@roeck-us.net>

> ---
>   drivers/watchdog/pcwd_usb.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/watchdog/pcwd_usb.c b/drivers/watchdog/pcwd_usb.c
> index 1a11aedc4fe8..68952d9ccf83 100644
> --- a/drivers/watchdog/pcwd_usb.c
> +++ b/drivers/watchdog/pcwd_usb.c
> @@ -608,7 +608,7 @@ static int usb_pcwd_probe(struct usb_interface *interface,
>   	struct usb_host_interface *iface_desc;
>   	struct usb_endpoint_descriptor *endpoint;
>   	struct usb_pcwd_private *usb_pcwd = NULL;
> -	int pipe, maxp;
> +	int pipe;
>   	int retval = -ENOMEM;
>   	int got_fw_rev;
>   	unsigned char fw_rev_major, fw_rev_minor;
> @@ -641,7 +641,6 @@ static int usb_pcwd_probe(struct usb_interface *interface,
>
>   	/* get a handle to the interrupt data pipe */
>   	pipe = usb_rcvintpipe(udev, endpoint->bEndpointAddress);
> -	maxp = usb_maxpacket(udev, pipe, usb_pipeout(pipe));
>
>   	/* allocate memory for our device and initialize it */
>   	usb_pcwd = kzalloc(sizeof(struct usb_pcwd_private), GFP_KERNEL);
>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-01-19 14:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-19 13:51 [watchdog-next] watchdog: pcwd_usb: fix compilation warning Tomas Winkler
2016-01-19 14:18 ` Guenter Roeck

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.