[PATCH] staging: rtl8188eu: core: switch with redundant cases

Dan Carpenter dan.carpenter at oracle.com
Wed Feb 4 11:42:13 UTC 2015


On Wed, Feb 04, 2015 at 06:04:38AM -0500, Nicholas Mc Guire wrote:
> A few redundant switch cases as well as a redundant if/else
> within one of the cases was consolidated to a single call.
> The cases are intentionally retained for documentation purposes.

This statement is not clear.  It obviously causes a bug if you just
start deleting case statements.

> 
> Signed-off-by: Nicholas Mc Guire <hofrat at osadl.org>
> ---
> case WIFI_REASSOCREQ,WIFI_PROBEREQ,WIFI_BEACON,WIFI_ACTION all
> have the same effect - notably the also for WIFI_PROBEREQ where
> the if/else is executing the same function. 
> 
> These redundant cases could all be dropped and consolidated into
> the default but probably it is better for documentation/readability
> to leave them in the switch/case explicitly.

Oh.  This explains what you meant.  Stop putting this information below
the cut off, it's annoying.

regards,
dan carpenter



More information about the devel mailing list