centaur.c (498495dba268b20e8eadd7fe93c140c68b6cc9d2) centaur.c (f8bd9f25c9815161a39886fdd96d110b536a6074)
1// SPDX-License-Identifier: GPL-2.0
2#include <linux/init.h>
3#include <linux/mm.h>
4
5#include <asm/mtrr.h>
6#include <asm/msr.h>
7
8#include "mtrr.h"

--- 97 unchanged lines hidden (view full) ---

106 (centaur_mcr_type == 0 || type != MTRR_TYPE_UNCACHABLE)) {
107 pr_warn("mtrr: only write-combining%s supported\n",
108 centaur_mcr_type ? " and uncacheable are" : " is");
109 return -EINVAL;
110 }
111 return 0;
112}
113
1// SPDX-License-Identifier: GPL-2.0
2#include <linux/init.h>
3#include <linux/mm.h>
4
5#include <asm/mtrr.h>
6#include <asm/msr.h>
7
8#include "mtrr.h"

--- 97 unchanged lines hidden (view full) ---

106 (centaur_mcr_type == 0 || type != MTRR_TYPE_UNCACHABLE)) {
107 pr_warn("mtrr: only write-combining%s supported\n",
108 centaur_mcr_type ? " and uncacheable are" : " is");
109 return -EINVAL;
110 }
111 return 0;
112}
113
114static const struct mtrr_ops centaur_mtrr_ops = {
114const struct mtrr_ops centaur_mtrr_ops = {
115 .vendor = X86_VENDOR_CENTAUR,
116 .set = centaur_set_mcr,
117 .get = centaur_get_mcr,
118 .get_free_region = centaur_get_free_region,
119 .validate_add_page = centaur_validate_add_page,
120 .have_wrcomb = positive_have_wrcomb,
121};
115 .vendor = X86_VENDOR_CENTAUR,
116 .set = centaur_set_mcr,
117 .get = centaur_get_mcr,
118 .get_free_region = centaur_get_free_region,
119 .validate_add_page = centaur_validate_add_page,
120 .have_wrcomb = positive_have_wrcomb,
121};
122
123int __init centaur_init_mtrr(void)
124{
125 set_mtrr_ops(&centaur_mtrr_ops);
126 return 0;
127}