drivers/usbdev/usbmsc.c: Run nxstyle; fix complaints.

This commit is contained in:
Gregory Nutt 2020-04-15 08:41:49 -06:00 committed by Alan Carvalho de Assis
parent c2ecdaecf7
commit 6548b41cab

View File

@ -73,10 +73,6 @@
# include "composite.h"
#endif
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
/****************************************************************************
* Private Types
****************************************************************************/
@ -146,14 +142,12 @@ static struct usbdevclass_driverops_s g_driverops =
NULL /* resume */
};
/* Used to hand-off the state structure when the SCSI worker thread is started */
/* Used to hand-off the state structure when the SCSI worker thread is
* started.
*/
FAR struct usbmsc_dev_s *g_usbmsc_handoff;
/****************************************************************************
* Public Data
****************************************************************************/
/****************************************************************************
* Private Functions
****************************************************************************/
@ -226,10 +220,6 @@ static void usbmsc_freereq(FAR struct usbdev_ep_s *ep,
}
}
/****************************************************************************
* Class Driver Interfaces
****************************************************************************/
/****************************************************************************
* Name: usbmsc_bind
*
@ -358,7 +348,9 @@ static int usbmsc_bind(FAR struct usbdevclass_driver_s *driver,
leave_critical_section(flags);
}
/* Report if we are selfpowered (unless we are part of a composite device) */
/* Report if we are selfpowered (unless we are part of a composite
* device).
*/
#ifndef CONFIG_USBMSC_COMPOSITE
#ifdef CONFIG_USBDEV_SELFPOWERED
@ -895,10 +887,6 @@ static void usbmsc_disconnect(FAR struct usbdevclass_driver_s *driver,
#endif
}
/****************************************************************************
* Initialization/Un-Initialization
****************************************************************************/
/****************************************************************************
* Name: usbmsc_lununinitialize
****************************************************************************/
@ -921,10 +909,6 @@ static void usbmsc_lununinitialize(struct usbmsc_lun_s *lun)
* Public Functions
****************************************************************************/
/****************************************************************************
* Internal Interfaces
****************************************************************************/
/****************************************************************************
* Name: usbmsc_setconfig
*
@ -1170,7 +1154,9 @@ void usbmsc_rdcomplete(FAR struct usbdev_ep_s *ep,
sq_addlast((FAR sq_entry_t *)privreq, &priv->rdreqlist);
leave_critical_section(flags);
/* Signal the worker thread that there is received data to be processed */
/* Signal the worker thread that there is received data to be
* processed.
*/
priv->theventset |= USBMSC_EVENT_RDCOMPLETE;
usbmsc_scsi_signal(priv);
@ -1287,10 +1273,6 @@ static int usbmsc_sync_wait(FAR struct usbmsc_dev_s *priv)
return nxsem_wait_uninterruptible(&priv->thsynch);
}
/****************************************************************************
* User Interfaces
****************************************************************************/
/****************************************************************************
* Name: usbmsc_configure
*
@ -1562,7 +1544,9 @@ int usbmsc_bindlun(FAR void *handle, FAR const char *drvrpath,
lun->sectorsize = geo.geo_sectorsize;
lun->readonly = readonly;
/* If the driver does not support the write method, then this is read-only */
/* If the driver does not support the write method, then this is read-
* only.
*/
if (!inode->u.i_bops->write)
{
@ -1724,7 +1708,9 @@ int usbmsc_exportluns(FAR void *handle)
DEBUGASSERT(g_usbmsc_handoff == NULL);
/* Register the USB storage class driver (unless we are part of a composite device) */
/* Register the USB storage class driver (unless we are part of a composite
* device).
*/
#ifndef CONFIG_USBMSC_COMPOSITE
ret = usbdev_register(&drvr->drvr);