Replace the open coded width height swap with the standard macro.
Signed-off-by: Tvrtko Ursulin <[email protected]>
Suggested-by: Thomas Zimmermann <[email protected]>
Cc: Thomas Zimmermann <[email protected]>
Cc: Ard Biesheuvel <[email protected]>
Cc: Melissa Wen <[email protected]>
Cc: [email protected]
Reviewed-by: Thomas Zimmermann <[email protected]>
Tested-by: Melissa Wen <[email protected]> # v3
---
drivers/firmware/efi/sysfb_efi.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/firmware/efi/sysfb_efi.c b/drivers/firmware/efi/sysfb_efi.c
index 1e509595ac03..1d8b6966731c 100644
--- a/drivers/firmware/efi/sysfb_efi.c
+++ b/drivers/firmware/efi/sysfb_efi.c
@@ -357,10 +357,7 @@ __init void sysfb_apply_efi_quirks(void)
if (screen_info.orig_video_isVGA == VIDEO_TYPE_EFI &&
dmi_check_system(efifb_dmi_swap_width_height)) {
- u16 temp = screen_info.lfb_width;
-
- screen_info.lfb_width = screen_info.lfb_height;
- screen_info.lfb_height = temp;
+ swap(screen_info.lfb_width, screen_info.lfb_height);
screen_info.lfb_linelength = 4 * screen_info.lfb_width;
}
}
--
2.51.1