Message ID | 1453199177-21085-3-git-send-email-chaehyun.lim@gmail.com (mailing list archive) |
---|---|
State | Not Applicable |
Delegated to: | Kalle Valo |
Headers | show |
On Tue, Jan 19, 2016 at 07:26:17PM +0900, Chaehyun Lim wrote: > counter is used as for-loop control variable and indicating index of > struct wid array so that it is better to use int type. > There is no need to set to 0 when it is declared at the top of this > function. counter is initialized as 0 in for-loop statement. > > Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> > --- > drivers/staging/wilc1000/coreconfigurator.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/wilc1000/coreconfigurator.c b/drivers/staging/wilc1000/coreconfigurator.c > index 86dfe77..7e8e423 100644 > --- a/drivers/staging/wilc1000/coreconfigurator.c > +++ b/drivers/staging/wilc1000/coreconfigurator.c > @@ -591,7 +591,7 @@ s32 wilc_dealloc_assoc_resp_info(tstrConnectRespInfo *pstrConnectRespInfo) > int wilc_send_config_pkt(struct wilc *wilc, u8 mode, struct wid *wids, > u32 count, u32 drv) > { > - s32 counter = 0; > + int counter; rename it to "i" as well. "int i;" regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/staging/wilc1000/coreconfigurator.c b/drivers/staging/wilc1000/coreconfigurator.c index 86dfe77..7e8e423 100644 --- a/drivers/staging/wilc1000/coreconfigurator.c +++ b/drivers/staging/wilc1000/coreconfigurator.c @@ -591,7 +591,7 @@ s32 wilc_dealloc_assoc_resp_info(tstrConnectRespInfo *pstrConnectRespInfo) int wilc_send_config_pkt(struct wilc *wilc, u8 mode, struct wid *wids, u32 count, u32 drv) { - s32 counter = 0; + int counter; int ret = 0; if (mode == GET_CFG) {
counter is used as for-loop control variable and indicating index of struct wid array so that it is better to use int type. There is no need to set to 0 when it is declared at the top of this function. counter is initialized as 0 in for-loop statement. Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com> --- drivers/staging/wilc1000/coreconfigurator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)