diff options
author | Rupesh Gujare <rupesh.gujare@atmel.com> | 2013-08-13 18:29:24 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-08-14 14:15:40 -0700 |
commit | a15e042e262bb62cd8dd9a7ccda9137c9e65cedc (patch) | |
tree | a010fd21769aa15888ad40aa4afd846c3894f4d5 /drivers/staging/ozwpan | |
parent | 25403813148a49492726b9b062af4c58c6b240db (diff) |
staging: ozwpan: Remove unneeded initializers
Remove variable initialization wherever it is not required.
Signed-off-by: Rupesh Gujare <rupesh.gujare@atmel.com>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/ozwpan')
-rw-r--r-- | drivers/staging/ozwpan/ozeltbuf.c | 2 | ||||
-rw-r--r-- | drivers/staging/ozwpan/ozhcd.c | 18 | ||||
-rw-r--r-- | drivers/staging/ozwpan/ozpd.c | 4 |
3 files changed, 12 insertions, 12 deletions
diff --git a/drivers/staging/ozwpan/ozeltbuf.c b/drivers/staging/ozwpan/ozeltbuf.c index 4844d9f3cfe..cfc0f3996b4 100644 --- a/drivers/staging/ozwpan/ozeltbuf.c +++ b/drivers/staging/ozwpan/ozeltbuf.c @@ -67,7 +67,7 @@ void oz_elt_buf_term(struct oz_elt_buf *buf) */ struct oz_elt_info *oz_elt_info_alloc(struct oz_elt_buf *buf) { - struct oz_elt_info *ei = NULL; + struct oz_elt_info *ei; spin_lock_bh(&buf->lock); if (buf->free_elts && buf->elt_pool) { diff --git a/drivers/staging/ozwpan/ozhcd.c b/drivers/staging/ozwpan/ozhcd.c index ed3ffeba12a..0fd3feaa3f2 100644 --- a/drivers/staging/ozwpan/ozhcd.c +++ b/drivers/staging/ozwpan/ozhcd.c @@ -373,7 +373,7 @@ static void oz_complete_urb(struct usb_hcd *hcd, struct urb *urb, { struct oz_hcd *ozhcd = oz_hcd_private(hcd); unsigned long irq_state; - struct oz_urb_link *cancel_urbl = NULL; + struct oz_urb_link *cancel_urbl; spin_lock_irqsave(&g_tasklet_lock, irq_state); usb_hcd_unlink_urb_from_ep(hcd, urb); @@ -585,7 +585,7 @@ static struct urb *oz_find_urb_by_id(struct oz_port *port, int ep_ix, { struct oz_hcd *ozhcd = port->ozhcd; struct urb *urb = NULL; - struct oz_urb_link *urbl = NULL; + struct oz_urb_link *urbl; struct oz_endpoint *ep; spin_lock_bh(&ozhcd->hcd_lock); @@ -664,7 +664,7 @@ struct oz_port *oz_hcd_pd_arrived(void *hpd) { int i; struct oz_port *hport = NULL; - struct oz_hcd *ozhcd = NULL; + struct oz_hcd *ozhcd; struct oz_endpoint *ep; ozhcd = oz_hcd_claim(); @@ -1423,7 +1423,7 @@ static void oz_clean_endpoints_for_config(struct usb_hcd *hcd, */ static void *oz_claim_hpd(struct oz_port *port) { - void *hpd = NULL; + void *hpd; struct oz_hcd *ozhcd = port->ozhcd; spin_lock_bh(&ozhcd->hcd_lock); @@ -1444,7 +1444,7 @@ static void oz_process_ep0_urb(struct oz_hcd *ozhcd, struct urb *urb, unsigned windex; unsigned wvalue; unsigned wlength; - void *hpd = NULL; + void *hpd; u8 req_id; int rc = 0; unsigned complete = 0; @@ -1798,7 +1798,7 @@ static int oz_hcd_urb_enqueue(struct usb_hcd *hcd, struct urb *urb, gfp_t mem_flags) { struct oz_hcd *ozhcd = oz_hcd_private(hcd); - int rc = 0; + int rc; int port_ix; struct oz_port *port; unsigned long irq_state; @@ -1851,7 +1851,7 @@ static int oz_hcd_urb_enqueue(struct usb_hcd *hcd, struct urb *urb, static struct oz_urb_link *oz_remove_urb(struct oz_endpoint *ep, struct urb *urb) { - struct oz_urb_link *urbl = NULL; + struct oz_urb_link *urbl; struct list_head *e; if (unlikely(ep == NULL)) @@ -1878,7 +1878,7 @@ static struct oz_urb_link *oz_remove_urb(struct oz_endpoint *ep, static int oz_hcd_urb_dequeue(struct usb_hcd *hcd, struct urb *urb, int status) { struct oz_hcd *ozhcd = oz_hcd_private(hcd); - struct oz_urb_link *urbl = NULL; + struct oz_urb_link *urbl; int rc; unsigned long irq_state; @@ -2141,7 +2141,7 @@ static int oz_clear_port_feature(struct usb_hcd *hcd, u16 wvalue, u16 windex) static int oz_get_port_status(struct usb_hcd *hcd, u16 windex, char *buf) { struct oz_hcd *ozhcd; - u32 status = 0; + u32 status; if ((windex < 1) || (windex > OZ_NB_PORTS)) return -EPIPE; diff --git a/drivers/staging/ozwpan/ozpd.c b/drivers/staging/ozwpan/ozpd.c index 95109fd7f45..2514d79a8ff 100644 --- a/drivers/staging/ozwpan/ozpd.c +++ b/drivers/staging/ozwpan/ozpd.c @@ -337,7 +337,7 @@ void oz_pd_heartbeat(struct oz_pd *pd, u16 apps) */ void oz_pd_stop(struct oz_pd *pd) { - u16 stop_apps = 0; + u16 stop_apps; oz_dbg(ON, "oz_pd_stop() State = 0x%x\n", pd->state); oz_pd_indicate_farewells(pd); @@ -362,7 +362,7 @@ void oz_pd_stop(struct oz_pd *pd) int oz_pd_sleep(struct oz_pd *pd) { int do_stop = 0; - u16 stop_apps = 0; + u16 stop_apps; oz_polling_lock_bh(); if (pd->state & (OZ_PD_S_SLEEP | OZ_PD_S_STOPPED)) { |