4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
22 * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
25 #include <sys/cpu_module.h>
26 #include <sys/lockstat.h>
29 * This is a dummy file that provides the default cpu module
30 * that is linked to unix.
33 uint_t root_phys_addr_lo_mask
;
35 hrtime_t hres_last_tick
;
36 volatile timestruc_t hrestime
;
38 volatile int hres_lock
;
43 int traptrace_use_stick
;
44 uint_t cpu_impl_dual_pgsz
;
45 uint64_t native_tick_offset
;
46 uint64_t native_stick_offset
;
53 cpu_init_tick_freq(void)
58 vtag_flushpage(caddr_t addr
, uint64_t sfmmup
)
66 vtag_flushall_uctxs(void)
71 vtag_flushpage_tl1(uint64_t addr
, uint64_t sfmmup
)
76 vtag_flush_pgcnt_tl1(uint64_t addr
, uint64_t sfmmup_pgcnt
)
81 vtag_flushall_tl1(uint64_t dummy1
, uint64_t dummy2
)
86 vtag_unmap_perm_tl1(uint64_t addr
, uint64_t ctx
)
91 vac_flushpage(pfn_t pf
, int color
)
96 vac_flushpage_tl1(uint64_t pf
, uint64_t color
)
101 vac_flushcolor(int color
, pfn_t pf
)
106 vac_flushcolor_tl1(uint64_t color
, uint64_t dummy
)
111 init_mondo(xcfunc_t func
, uint64_t arg1
, uint64_t arg2
)
116 send_one_mondo(int cpuid
)
121 send_mondo_set(cpuset_t set
)
126 flush_instr_mem(caddr_t addr
, size_t len
)
135 cpu_change_speed(uint64_t divisor
, uint64_t arg2
)
147 gettick_counter(void)
152 gethrestime(timespec_t
*tp
)
156 gethrestime_sec(void)
161 gethrestime_lasttick(timespec_t
*tp
)
169 gethrtime_unscaled(void)
173 gethrtime_waitfree(void)
177 dtrace_gethrtime(void)
202 scalehrtime(hrtime_t
*hrt
)
211 tickcmpr_set(uint64_t clock_cycles
)
215 tickcmpr_disable(void)
220 tick_write_delta(uint64_t delta
)
224 tickcmpr_disabled(void)
229 drv_usecwait(clock_t n
)
233 * Processor-optimized memory routines
237 kcopy(const void *from
, void *to
, size_t count
)
242 kcopy_nta(const void *from
, void *to
, size_t count
, int dummy
)
247 bcopy(const void *from
, void *to
, size_t count
)
252 ovbcopy(const void *from
, void *to
, size_t count
)
257 copyin(const void *uaddr
, void *kaddr
, size_t count
)
262 xcopyin(const void *uaddr
, void *kaddr
, size_t count
)
267 xcopyin_nta(const void *uaddr
, void *kaddr
, size_t count
, int dummy
)
272 copyout(const void *kaddr
, void *uaddr
, size_t count
)
277 xcopyout(const void *kaddr
, void *uaddr
, size_t count
)
282 xcopyout_nta(const void *kaddr
, void *uaddr
, size_t count
, int dummy
)
287 copyout_noerr(const void *kfrom
, void *uto
, size_t count
)
292 copyin_noerr(const void *kfrom
, void *uto
, size_t count
)
297 xcopyin_little(const void *uaddr
, void *kaddr
, size_t count
)
302 xcopyout_little(const void *kaddr
, void *uaddr
, size_t count
)
307 hwblkpagecopy(const void *src
, void *dst
)
312 hw_pa_bcopy32(uint64_t src
, uint64_t dst
)
317 hwblkclr(void *addr
, size_t len
)
322 uint_t hw_copy_limit_1
;
323 uint_t hw_copy_limit_2
;
324 uint_t hw_copy_limit_4
;
325 uint_t hw_copy_limit_8
;
336 pil14_interrupt(void)
340 pil15_interrupt(void)
345 cpu_init_private(struct cpu
*cp
)
350 cpu_uninit_private(struct cpu
*cp
)
354 sticksync_slave(void)
358 sticksync_master(void)
363 dtrace_blksuword32(uintptr_t addr
, uint32_t *data
, int tryagain
)