aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/dgap
diff options
context:
space:
mode:
authorMark Hounschell <markh@compro.net>2014-05-23 13:45:57 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-05-24 04:40:52 +0900
commit0c24b2325598326cc7af3e93266ebe232c629fe4 (patch)
tree82c7a88e35ddb4852f09a368257331b85df49629 /drivers/staging/dgap
parentee487100ce307baec964ca3708409fdb65c58f49 (diff)
downloadlinux-stericsson-0c24b2325598326cc7af3e93266ebe232c629fe4.tar.gz
staging: dgap: Simplify get_altpin and get_useintr functions
Simplify dgap_config_get_useintr and dgap_config_get_altpin changing the case statement to an if statement. Signed-off-by: Mark Hounschell <markh@compro.net> Tested-by: Mark Hounschell <markh@compro.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/dgap')
-rw-r--r--drivers/staging/dgap/dgap.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/staging/dgap/dgap.c b/drivers/staging/dgap/dgap.c
index f811cbf5332e..a89606e1fda9 100644
--- a/drivers/staging/dgap/dgap.c
+++ b/drivers/staging/dgap/dgap.c
@@ -7310,14 +7310,11 @@ static uint dgap_config_get_useintr(struct board_t *bd)
return 0;
for (p = bd->bd_config; p; p = p->next) {
- switch (p->type) {
- case INTRNODE:
+ if (p->type == INTRNODE) {
/*
* check for pcxr types.
*/
return p->u.useintr;
- default:
- break;
}
}
@@ -7336,14 +7333,11 @@ static uint dgap_config_get_altpin(struct board_t *bd)
return 0;
for (p = bd->bd_config; p; p = p->next) {
- switch (p->type) {
- case ANODE:
+ if (p->type == ANODE) {
/*
* check for pcxr types.
*/
return p->u.altpin;
- default:
- break;
}
}