Deleted Added
full compact
bcm2835_cpufreq.c (290667) bcm2835_cpufreq.c (300421)
1/*-
2 * Copyright (C) 2013-2015 Daisuke Aoyama <aoyama@peach.ne.jp>
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

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

21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 */
27
28#include <sys/cdefs.h>
1/*-
2 * Copyright (C) 2013-2015 Daisuke Aoyama <aoyama@peach.ne.jp>
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

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

21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 */
27
28#include <sys/cdefs.h>
29__FBSDID("$FreeBSD: head/sys/arm/broadcom/bcm2835/bcm2835_cpufreq.c 290667 2015-11-11 00:45:41Z gonzo $");
29__FBSDID("$FreeBSD: head/sys/arm/broadcom/bcm2835/bcm2835_cpufreq.c 300421 2016-05-22 13:58:32Z loos $");
30
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/bus.h>
34#include <sys/cpu.h>
35#include <sys/kernel.h>
36#include <sys/lock.h>
37#include <sys/malloc.h>

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

77#define DEFAULT_CORE_FREQUENCY 250
78#define DEFAULT_SDRAM_FREQUENCY 400
79#define TRANSITION_LATENCY 1000
80#define MIN_OVER_VOLTAGE -16
81#define MAX_OVER_VOLTAGE 6
82#define MSG_ERROR -999999999
83#define MHZSTEP 100
84#define HZSTEP (MHZ2HZ(MHZSTEP))
30
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/bus.h>
34#include <sys/cpu.h>
35#include <sys/kernel.h>
36#include <sys/lock.h>
37#include <sys/malloc.h>

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

77#define DEFAULT_CORE_FREQUENCY 250
78#define DEFAULT_SDRAM_FREQUENCY 400
79#define TRANSITION_LATENCY 1000
80#define MIN_OVER_VOLTAGE -16
81#define MAX_OVER_VOLTAGE 6
82#define MSG_ERROR -999999999
83#define MHZSTEP 100
84#define HZSTEP (MHZ2HZ(MHZSTEP))
85#define TZ_ZEROC 2732
85#define TZ_ZEROC 2731
86
87#define VC_LOCK(sc) do { \
88 sema_wait(&vc_sema); \
89 } while (0)
90#define VC_UNLOCK(sc) do { \
91 sema_post(&vc_sema); \
92 } while (0)
93

--- 1526 unchanged lines hidden ---
86
87#define VC_LOCK(sc) do { \
88 sema_wait(&vc_sema); \
89 } while (0)
90#define VC_UNLOCK(sc) do { \
91 sema_post(&vc_sema); \
92 } while (0)
93

--- 1526 unchanged lines hidden ---