Deleted Added
full compact
coretemp.c (246951) coretemp.c (300421)
1/*-
2 * Copyright (c) 2007, 2008 Rui Paulo <rpaulo@FreeBSD.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

25 */
26
27/*
28 * Device driver for Intel's On Die thermal sensor via MSR.
29 * First introduced in Intel's Core line of processors.
30 */
31
32#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2007, 2008 Rui Paulo <rpaulo@FreeBSD.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

25 */
26
27/*
28 * Device driver for Intel's On Die thermal sensor via MSR.
29 * First introduced in Intel's Core line of processors.
30 */
31
32#include <sys/cdefs.h>
33__FBSDID("$FreeBSD: head/sys/dev/coretemp/coretemp.c 246951 2013-02-18 22:47:16Z markj $");
33__FBSDID("$FreeBSD: head/sys/dev/coretemp/coretemp.c 300421 2016-05-22 13:58:32Z loos $");
34
35#include <sys/param.h>
36#include <sys/bus.h>
37#include <sys/systm.h>
38#include <sys/types.h>
39#include <sys/module.h>
40#include <sys/conf.h>
41#include <sys/kernel.h>
42#include <sys/sysctl.h>
43#include <sys/proc.h> /* for curthread */
44#include <sys/sched.h>
45
46#include <machine/specialreg.h>
47#include <machine/cpufunc.h>
48#include <machine/cputypes.h>
49#include <machine/md_var.h>
50
34
35#include <sys/param.h>
36#include <sys/bus.h>
37#include <sys/systm.h>
38#include <sys/types.h>
39#include <sys/module.h>
40#include <sys/conf.h>
41#include <sys/kernel.h>
42#include <sys/sysctl.h>
43#include <sys/proc.h> /* for curthread */
44#include <sys/sched.h>
45
46#include <machine/specialreg.h>
47#include <machine/cpufunc.h>
48#include <machine/cputypes.h>
49#include <machine/md_var.h>
50
51#define TZ_ZEROC 2732
51#define TZ_ZEROC 2731
52
53#define THERM_STATUS_LOG 0x02
54#define THERM_STATUS 0x01
55#define THERM_STATUS_TEMP_SHIFT 16
56#define THERM_STATUS_TEMP_MASK 0x7f
57#define THERM_STATUS_RES_SHIFT 27
58#define THERM_STATUS_RES_MASK 0x0f
59#define THERM_STATUS_VALID_SHIFT 31

--- 387 unchanged lines hidden ---
52
53#define THERM_STATUS_LOG 0x02
54#define THERM_STATUS 0x01
55#define THERM_STATUS_TEMP_SHIFT 16
56#define THERM_STATUS_TEMP_MASK 0x7f
57#define THERM_STATUS_RES_SHIFT 27
58#define THERM_STATUS_RES_MASK 0x0f
59#define THERM_STATUS_VALID_SHIFT 31

--- 387 unchanged lines hidden ---