Commit 7caf463d authored by Sudip Mukherjee's avatar Sudip Mukherjee Committed by Greg Kroah-Hartman

staging: sm7xxfb: remove numvgamodes

numvgamodes was only used in one place, so remove the #define
and use its defined value.
Signed-off-by: default avatarSudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9d91928c
...@@ -775,5 +775,3 @@ static struct ModeInit vgamode[] = { ...@@ -775,5 +775,3 @@ static struct ModeInit vgamode[] = {
}, },
}, },
}; };
#define numvgamodes ARRAY_SIZE(vgamode)
...@@ -477,7 +477,7 @@ static void sm7xx_set_timing(struct smtcfb_info *sfb) ...@@ -477,7 +477,7 @@ static void sm7xx_set_timing(struct smtcfb_info *sfb)
"sfb->width=%d sfb->height=%d sfb->fb->var.bits_per_pixel=%d sfb->hz=%d\n", "sfb->width=%d sfb->height=%d sfb->fb->var.bits_per_pixel=%d sfb->hz=%d\n",
sfb->width, sfb->height, sfb->fb->var.bits_per_pixel, sfb->hz); sfb->width, sfb->height, sfb->fb->var.bits_per_pixel, sfb->hz);
for (j = 0; j < numvgamodes; j++) { for (j = 0; j < ARRAY_SIZE(vgamode); j++) {
if (vgamode[j].mmsizex == sfb->width && if (vgamode[j].mmsizex == sfb->width &&
vgamode[j].mmsizey == sfb->height && vgamode[j].mmsizey == sfb->height &&
vgamode[j].bpp == sfb->fb->var.bits_per_pixel && vgamode[j].bpp == sfb->fb->var.bits_per_pixel &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment