mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-28 11:18:45 +07:00
2874c5fd28
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation either version 2 of the license or at your option any later version extracted by the scancode license scanner the SPDX license identifier GPL-2.0-or-later has been chosen to replace the boilerplate/reference in 3029 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
52 lines
1013 B
C
52 lines
1013 B
C
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
/*
|
|
* Copyright (C) 2007 Lemote Inc. & Institute of Computing Technology
|
|
* Author: Fuxin Zhang, zhangfx@lemote.com
|
|
*/
|
|
#include <linux/export.h>
|
|
#include <linux/init.h>
|
|
|
|
#include <asm/wbflush.h>
|
|
#include <asm/bootinfo.h>
|
|
|
|
#include <loongson.h>
|
|
|
|
#ifdef CONFIG_VT
|
|
#include <linux/console.h>
|
|
#include <linux/screen_info.h>
|
|
#endif
|
|
|
|
static void wbflush_loongson(void)
|
|
{
|
|
asm(".set\tpush\n\t"
|
|
".set\tnoreorder\n\t"
|
|
".set mips3\n\t"
|
|
"sync\n\t"
|
|
"nop\n\t"
|
|
".set\tpop\n\t"
|
|
".set mips0\n\t");
|
|
}
|
|
|
|
void (*__wbflush)(void) = wbflush_loongson;
|
|
EXPORT_SYMBOL(__wbflush);
|
|
|
|
void __init plat_mem_setup(void)
|
|
{
|
|
#ifdef CONFIG_VT
|
|
#if defined(CONFIG_VGA_CONSOLE)
|
|
conswitchp = &vga_con;
|
|
|
|
screen_info = (struct screen_info) {
|
|
.orig_x = 0,
|
|
.orig_y = 25,
|
|
.orig_video_cols = 80,
|
|
.orig_video_lines = 25,
|
|
.orig_video_isVGA = VIDEO_TYPE_VGAC,
|
|
.orig_video_points = 16,
|
|
};
|
|
#elif defined(CONFIG_DUMMY_CONSOLE)
|
|
conswitchp = &dummy_con;
|
|
#endif
|
|
#endif
|
|
}
|