Skip to content

Commit

Permalink
fsl_usb2_udc: Remove check for udc == NULL in dr_controller_setup.
Browse files Browse the repository at this point in the history
Remove check for udc == NULL in dr_controller_setup. All callers of
this function have already dereferenced udc at some point.

Signed-off-by: Will Newton <will.newton@gmail.com>
Acked-by: Li Yang <leoli@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Will Newton authored and Greg Kroah-Hartman committed Oct 17, 2008
1 parent 9c94155 commit f6e4411
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions drivers/usb/gadget/fsl_usb2_udc.c
Original file line number Diff line number Diff line change
Expand Up @@ -185,10 +185,6 @@ static int dr_controller_setup(struct fsl_udc *udc)
unsigned long timeout;
#define FSL_UDC_RESET_TIMEOUT 1000

/* before here, make sure dr_regs has been initialized */
if (!udc)
return -EINVAL;

/* Stop and reset the usb controller */
tmp = fsl_readl(&dr_regs->usbcmd);
tmp &= ~USB_CMD_RUN_STOP;
Expand Down

0 comments on commit f6e4411

Please sign in to comment.