Commit e54c2b0a authored by Bhagyashri Dighole's avatar Bhagyashri Dighole Committed by Greg Kroah-Hartman

staging: fbtft: ternary statement to if statement.

Convert a ternary statement into a if statement which is detected while
resolving "WARNING: line over 80 characters". Use BIT() macro instead
manually left shifting.
Signed-off-by: default avatarBhagyashri Dighole <digholebhagyashri@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 7945e278
......@@ -184,7 +184,8 @@ static int write_vmem(struct fbtft_par *par, size_t offset, size_t len)
for (y = 0; y < yres / 8; y++) {
*buf = 0x00;
for (i = 0; i < 8; i++)
*buf |= (vmem16[(y * 8 + i) * xres + x] ? 1 : 0) << i;
if (vmem16[(y * 8 + i) * xres + x])
*buf |= BIT(i);
buf++;
}
}
......
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