17c478bd9Sstevel@tonic-gate /* 27c478bd9Sstevel@tonic-gate * CDDL HEADER START 37c478bd9Sstevel@tonic-gate * 47c478bd9Sstevel@tonic-gate * The contents of this file are subject to the terms of the 51e2e7a75Shuah * Common Development and Distribution License (the "License"). 61e2e7a75Shuah * You may not use this file except in compliance with the License. 77c478bd9Sstevel@tonic-gate * 87c478bd9Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 97c478bd9Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 107c478bd9Sstevel@tonic-gate * See the License for the specific language governing permissions 117c478bd9Sstevel@tonic-gate * and limitations under the License. 127c478bd9Sstevel@tonic-gate * 137c478bd9Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 147c478bd9Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 157c478bd9Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 167c478bd9Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 177c478bd9Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 187c478bd9Sstevel@tonic-gate * 197c478bd9Sstevel@tonic-gate * CDDL HEADER END 207c478bd9Sstevel@tonic-gate */ 217c478bd9Sstevel@tonic-gate /* 22b9e93c10SJonathan Haslam * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 237c478bd9Sstevel@tonic-gate * Use is subject to license terms. 247c478bd9Sstevel@tonic-gate */ 257c478bd9Sstevel@tonic-gate 267c478bd9Sstevel@tonic-gate #include <sys/cpu_module.h> 277c478bd9Sstevel@tonic-gate #include <sys/lockstat.h> 287c478bd9Sstevel@tonic-gate 297c478bd9Sstevel@tonic-gate /* 307c478bd9Sstevel@tonic-gate * This is a dummy file that provides the default cpu module 317c478bd9Sstevel@tonic-gate * that is linked to unix. 327c478bd9Sstevel@tonic-gate */ 337c478bd9Sstevel@tonic-gate 347c478bd9Sstevel@tonic-gate uint_t root_phys_addr_lo_mask; 357c478bd9Sstevel@tonic-gate int64_t timedelta; 367c478bd9Sstevel@tonic-gate hrtime_t hres_last_tick; 37b5b48cc1Ssudheer volatile timestruc_t hrestime; 387c478bd9Sstevel@tonic-gate int64_t hrestime_adj; 39b5b48cc1Ssudheer volatile int hres_lock; 407c478bd9Sstevel@tonic-gate uint_t nsec_scale; 417c478bd9Sstevel@tonic-gate uint_t nsec_shift; 427c478bd9Sstevel@tonic-gate uint_t adj_shift; 437c478bd9Sstevel@tonic-gate hrtime_t hrtime_base; 447c478bd9Sstevel@tonic-gate int traptrace_use_stick; 451e2e7a75Shuah uint_t cpu_impl_dual_pgsz; 46*023e71deSHaik Aftandilian uint64_t native_tick_offset; 47*023e71deSHaik Aftandilian uint64_t native_stick_offset; 487c478bd9Sstevel@tonic-gate 497c478bd9Sstevel@tonic-gate void 507c478bd9Sstevel@tonic-gate cpu_setup(void) 517c478bd9Sstevel@tonic-gate {} 527c478bd9Sstevel@tonic-gate 537c478bd9Sstevel@tonic-gate void 547c478bd9Sstevel@tonic-gate cpu_init_tick_freq(void) 557c478bd9Sstevel@tonic-gate {} 567c478bd9Sstevel@tonic-gate 577c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 587c478bd9Sstevel@tonic-gate void 591e2e7a75Shuah vtag_flushpage(caddr_t addr, uint64_t sfmmup) 607c478bd9Sstevel@tonic-gate {} 617c478bd9Sstevel@tonic-gate 627c478bd9Sstevel@tonic-gate void 637c478bd9Sstevel@tonic-gate vtag_flushall(void) 647c478bd9Sstevel@tonic-gate {} 657c478bd9Sstevel@tonic-gate 667c478bd9Sstevel@tonic-gate void 671e2e7a75Shuah vtag_flushall_uctxs(void) 687c478bd9Sstevel@tonic-gate {} 697c478bd9Sstevel@tonic-gate 707c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 717c478bd9Sstevel@tonic-gate void 721e2e7a75Shuah vtag_flushpage_tl1(uint64_t addr, uint64_t sfmmup) 737c478bd9Sstevel@tonic-gate {} 747c478bd9Sstevel@tonic-gate 757c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 767c478bd9Sstevel@tonic-gate void 771e2e7a75Shuah vtag_flush_pgcnt_tl1(uint64_t addr, uint64_t sfmmup_pgcnt) 787c478bd9Sstevel@tonic-gate {} 797c478bd9Sstevel@tonic-gate 807c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 817c478bd9Sstevel@tonic-gate void 827c478bd9Sstevel@tonic-gate vtag_flushall_tl1(uint64_t dummy1, uint64_t dummy2) 837c478bd9Sstevel@tonic-gate {} 847c478bd9Sstevel@tonic-gate 857c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 867c478bd9Sstevel@tonic-gate void 879853d9e8SJason Beloro vtag_unmap_perm_tl1(uint64_t addr, uint64_t ctx) 889853d9e8SJason Beloro {} 899853d9e8SJason Beloro 909853d9e8SJason Beloro /*ARGSUSED*/ 919853d9e8SJason Beloro void 927c478bd9Sstevel@tonic-gate vac_flushpage(pfn_t pf, int color) 937c478bd9Sstevel@tonic-gate {} 947c478bd9Sstevel@tonic-gate 957c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 967c478bd9Sstevel@tonic-gate void 977c478bd9Sstevel@tonic-gate vac_flushpage_tl1(uint64_t pf, uint64_t color) 987c478bd9Sstevel@tonic-gate {} 997c478bd9Sstevel@tonic-gate 1007c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1017c478bd9Sstevel@tonic-gate void 1027c478bd9Sstevel@tonic-gate vac_flushcolor(int color, pfn_t pf) 1037c478bd9Sstevel@tonic-gate {} 1047c478bd9Sstevel@tonic-gate 1057c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1067c478bd9Sstevel@tonic-gate void 1077c478bd9Sstevel@tonic-gate vac_flushcolor_tl1(uint64_t color, uint64_t dummy) 1087c478bd9Sstevel@tonic-gate {} 1097c478bd9Sstevel@tonic-gate 1107c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1117c478bd9Sstevel@tonic-gate void 1127c478bd9Sstevel@tonic-gate init_mondo(xcfunc_t func, uint64_t arg1, uint64_t arg2) 1137c478bd9Sstevel@tonic-gate {} 1147c478bd9Sstevel@tonic-gate 1157c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1167c478bd9Sstevel@tonic-gate void 1177c478bd9Sstevel@tonic-gate send_one_mondo(int cpuid) 1187c478bd9Sstevel@tonic-gate {} 1197c478bd9Sstevel@tonic-gate 1207c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1217c478bd9Sstevel@tonic-gate void 1227c478bd9Sstevel@tonic-gate send_mondo_set(cpuset_t set) 1237c478bd9Sstevel@tonic-gate {} 1247c478bd9Sstevel@tonic-gate 1257c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1267c478bd9Sstevel@tonic-gate void 1277c478bd9Sstevel@tonic-gate flush_instr_mem(caddr_t addr, size_t len) 1287c478bd9Sstevel@tonic-gate {} 1297c478bd9Sstevel@tonic-gate 1307c478bd9Sstevel@tonic-gate void 1317c478bd9Sstevel@tonic-gate syncfpu(void) 1327c478bd9Sstevel@tonic-gate {} 1337c478bd9Sstevel@tonic-gate 1347c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1357c478bd9Sstevel@tonic-gate void 1367c478bd9Sstevel@tonic-gate cpu_change_speed(uint64_t divisor, uint64_t arg2) 1377c478bd9Sstevel@tonic-gate {} 1387c478bd9Sstevel@tonic-gate 1397c478bd9Sstevel@tonic-gate u_longlong_t 1407c478bd9Sstevel@tonic-gate gettick(void) 1417c478bd9Sstevel@tonic-gate { return (0); } 1427c478bd9Sstevel@tonic-gate 1437c478bd9Sstevel@tonic-gate uint64_t 1447c478bd9Sstevel@tonic-gate gettick_counter(void) 1457c478bd9Sstevel@tonic-gate { return (0); } 1467c478bd9Sstevel@tonic-gate 1477c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1487c478bd9Sstevel@tonic-gate void 1497c478bd9Sstevel@tonic-gate gethrestime(timespec_t *tp) 1507c478bd9Sstevel@tonic-gate {} 1517c478bd9Sstevel@tonic-gate 1527c478bd9Sstevel@tonic-gate time_t 1537c478bd9Sstevel@tonic-gate gethrestime_sec(void) 1547c478bd9Sstevel@tonic-gate { return (0); } 1557c478bd9Sstevel@tonic-gate 1567c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1577c478bd9Sstevel@tonic-gate void 1587c478bd9Sstevel@tonic-gate gethrestime_lasttick(timespec_t *tp) 1597c478bd9Sstevel@tonic-gate {} 1607c478bd9Sstevel@tonic-gate 1617c478bd9Sstevel@tonic-gate hrtime_t 1627c478bd9Sstevel@tonic-gate gethrtime(void) 1637c478bd9Sstevel@tonic-gate { return (0); } 1647c478bd9Sstevel@tonic-gate 1657c478bd9Sstevel@tonic-gate hrtime_t 1667c478bd9Sstevel@tonic-gate gethrtime_unscaled(void) 1677c478bd9Sstevel@tonic-gate { return (0); } 1687c478bd9Sstevel@tonic-gate 1697c478bd9Sstevel@tonic-gate hrtime_t 1707c478bd9Sstevel@tonic-gate gethrtime_waitfree(void) 1717c478bd9Sstevel@tonic-gate { return (0); } 1727c478bd9Sstevel@tonic-gate 1737c478bd9Sstevel@tonic-gate hrtime_t 1747c478bd9Sstevel@tonic-gate dtrace_gethrtime(void) 1757c478bd9Sstevel@tonic-gate { return (0); } 1767c478bd9Sstevel@tonic-gate 1777c478bd9Sstevel@tonic-gate uint_t 1787c478bd9Sstevel@tonic-gate get_impl(void) 1797c478bd9Sstevel@tonic-gate { return (0); } 1807c478bd9Sstevel@tonic-gate 1817c478bd9Sstevel@tonic-gate hrtime_t 1827c478bd9Sstevel@tonic-gate get_hrestime(void) 1837c478bd9Sstevel@tonic-gate { return (0); } 1847c478bd9Sstevel@tonic-gate 1857c478bd9Sstevel@tonic-gate ulong_t 1867c478bd9Sstevel@tonic-gate get_timestamp(void) 1877c478bd9Sstevel@tonic-gate { return (0); } 1887c478bd9Sstevel@tonic-gate 1897c478bd9Sstevel@tonic-gate ulong_t 1907c478bd9Sstevel@tonic-gate get_virtime(void) 1917c478bd9Sstevel@tonic-gate { return (0); } 1927c478bd9Sstevel@tonic-gate 1937c478bd9Sstevel@tonic-gate hrtime_t 1947c478bd9Sstevel@tonic-gate gethrtime_max(void) 1957c478bd9Sstevel@tonic-gate { return (0); } 1967c478bd9Sstevel@tonic-gate 1977c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 1987c478bd9Sstevel@tonic-gate void 1997c478bd9Sstevel@tonic-gate scalehrtime(hrtime_t *hrt) 2007c478bd9Sstevel@tonic-gate {} 2017c478bd9Sstevel@tonic-gate 2027c478bd9Sstevel@tonic-gate void 2037c478bd9Sstevel@tonic-gate hres_tick(void) 2047c478bd9Sstevel@tonic-gate {} 2057c478bd9Sstevel@tonic-gate 2067c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2077c478bd9Sstevel@tonic-gate void 2087c478bd9Sstevel@tonic-gate tickcmpr_set(uint64_t clock_cycles) 2097c478bd9Sstevel@tonic-gate {} 2107c478bd9Sstevel@tonic-gate 2117c478bd9Sstevel@tonic-gate void 2127c478bd9Sstevel@tonic-gate tickcmpr_disable(void) 2137c478bd9Sstevel@tonic-gate {} 2147c478bd9Sstevel@tonic-gate 2157c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2167c478bd9Sstevel@tonic-gate void 2177c478bd9Sstevel@tonic-gate tick_write_delta(uint64_t delta) 2187c478bd9Sstevel@tonic-gate {} 2197c478bd9Sstevel@tonic-gate 2207c478bd9Sstevel@tonic-gate int 2217c478bd9Sstevel@tonic-gate tickcmpr_disabled(void) 2227c478bd9Sstevel@tonic-gate { return (0); } 2237c478bd9Sstevel@tonic-gate 2247c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2257c478bd9Sstevel@tonic-gate void 2267c478bd9Sstevel@tonic-gate drv_usecwait(clock_t n) 2277c478bd9Sstevel@tonic-gate {} 2287c478bd9Sstevel@tonic-gate 2297c478bd9Sstevel@tonic-gate /* 2307c478bd9Sstevel@tonic-gate * Processor-optimized memory routines 2317c478bd9Sstevel@tonic-gate */ 2327c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2337c478bd9Sstevel@tonic-gate int 2347c478bd9Sstevel@tonic-gate kcopy(const void *from, void *to, size_t count) 2357c478bd9Sstevel@tonic-gate { return (0); } 2367c478bd9Sstevel@tonic-gate 2377c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2387c478bd9Sstevel@tonic-gate int 2397c478bd9Sstevel@tonic-gate kcopy_nta(const void *from, void *to, size_t count, int dummy) 2407c478bd9Sstevel@tonic-gate { return (0); } 2417c478bd9Sstevel@tonic-gate 2427c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2437c478bd9Sstevel@tonic-gate void 2447c478bd9Sstevel@tonic-gate bcopy(const void *from, void *to, size_t count) 2457c478bd9Sstevel@tonic-gate {} 2467c478bd9Sstevel@tonic-gate 2477c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2487c478bd9Sstevel@tonic-gate void 2497c478bd9Sstevel@tonic-gate ovbcopy(const void *from, void *to, size_t count) 2507c478bd9Sstevel@tonic-gate {} 2517c478bd9Sstevel@tonic-gate 2527c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2537c478bd9Sstevel@tonic-gate int 2547c478bd9Sstevel@tonic-gate copyin(const void *uaddr, void *kaddr, size_t count) 2557c478bd9Sstevel@tonic-gate { return (0); } 2567c478bd9Sstevel@tonic-gate 2577c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2587c478bd9Sstevel@tonic-gate int 2597c478bd9Sstevel@tonic-gate xcopyin(const void *uaddr, void *kaddr, size_t count) 2607c478bd9Sstevel@tonic-gate { return (0); } 2617c478bd9Sstevel@tonic-gate 2627c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2637c478bd9Sstevel@tonic-gate int 2647c478bd9Sstevel@tonic-gate xcopyin_nta(const void *uaddr, void *kaddr, size_t count, int dummy) 2657c478bd9Sstevel@tonic-gate { return (0); } 2667c478bd9Sstevel@tonic-gate 2677c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2687c478bd9Sstevel@tonic-gate int 2697c478bd9Sstevel@tonic-gate copyout(const void *kaddr, void *uaddr, size_t count) 2707c478bd9Sstevel@tonic-gate { return (0); } 2717c478bd9Sstevel@tonic-gate 2727c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2737c478bd9Sstevel@tonic-gate int 2747c478bd9Sstevel@tonic-gate xcopyout(const void *kaddr, void *uaddr, size_t count) 2757c478bd9Sstevel@tonic-gate { return (0); } 2767c478bd9Sstevel@tonic-gate 2777c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2787c478bd9Sstevel@tonic-gate int 2797c478bd9Sstevel@tonic-gate xcopyout_nta(const void *kaddr, void *uaddr, size_t count, int dummy) 2807c478bd9Sstevel@tonic-gate { return (0); } 2817c478bd9Sstevel@tonic-gate 2827c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2837c478bd9Sstevel@tonic-gate void 2847c478bd9Sstevel@tonic-gate copyout_noerr(const void *kfrom, void *uto, size_t count) 2857c478bd9Sstevel@tonic-gate {} 2867c478bd9Sstevel@tonic-gate 2877c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2887c478bd9Sstevel@tonic-gate void 2897c478bd9Sstevel@tonic-gate copyin_noerr(const void *kfrom, void *uto, size_t count) 2907c478bd9Sstevel@tonic-gate {} 2917c478bd9Sstevel@tonic-gate 2927c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2937c478bd9Sstevel@tonic-gate int 2947c478bd9Sstevel@tonic-gate xcopyin_little(const void *uaddr, void *kaddr, size_t count) 2957c478bd9Sstevel@tonic-gate { return (0); } 2967c478bd9Sstevel@tonic-gate 2977c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 2987c478bd9Sstevel@tonic-gate int 2997c478bd9Sstevel@tonic-gate xcopyout_little(const void *kaddr, void *uaddr, size_t count) 3007c478bd9Sstevel@tonic-gate { return (0); } 3017c478bd9Sstevel@tonic-gate 3027c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 3037c478bd9Sstevel@tonic-gate void 3047c478bd9Sstevel@tonic-gate hwblkpagecopy(const void *src, void *dst) 3057c478bd9Sstevel@tonic-gate {} 3067c478bd9Sstevel@tonic-gate 3077c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 3087c478bd9Sstevel@tonic-gate void 3097c478bd9Sstevel@tonic-gate hw_pa_bcopy32(uint64_t src, uint64_t dst) 3107c478bd9Sstevel@tonic-gate {} 3117c478bd9Sstevel@tonic-gate 3127c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 3137c478bd9Sstevel@tonic-gate int 3147c478bd9Sstevel@tonic-gate hwblkclr(void *addr, size_t len) 3157c478bd9Sstevel@tonic-gate { return (0); } 3167c478bd9Sstevel@tonic-gate 3177c478bd9Sstevel@tonic-gate int use_hw_bzero; 3187c478bd9Sstevel@tonic-gate int use_hw_bcopy; 3197c478bd9Sstevel@tonic-gate uint_t hw_copy_limit_1; 3207c478bd9Sstevel@tonic-gate uint_t hw_copy_limit_2; 3217c478bd9Sstevel@tonic-gate uint_t hw_copy_limit_4; 3227c478bd9Sstevel@tonic-gate uint_t hw_copy_limit_8; 3237c478bd9Sstevel@tonic-gate 3247c478bd9Sstevel@tonic-gate /* 3257c478bd9Sstevel@tonic-gate * tick operations 3267c478bd9Sstevel@tonic-gate */ 3277c478bd9Sstevel@tonic-gate 3287c478bd9Sstevel@tonic-gate void 3297c478bd9Sstevel@tonic-gate tick_rtt(void) 3307c478bd9Sstevel@tonic-gate { } 3317c478bd9Sstevel@tonic-gate 3327c478bd9Sstevel@tonic-gate void 3337c478bd9Sstevel@tonic-gate pil14_interrupt(void) 3347c478bd9Sstevel@tonic-gate { } 3357c478bd9Sstevel@tonic-gate 336b9e93c10SJonathan Haslam void 337b9e93c10SJonathan Haslam pil15_interrupt(void) 338b9e93c10SJonathan Haslam { } 339b9e93c10SJonathan Haslam 3407c478bd9Sstevel@tonic-gate /* ARGSUSED */ 3417c478bd9Sstevel@tonic-gate void 3427c478bd9Sstevel@tonic-gate cpu_init_private(struct cpu *cp) 3437c478bd9Sstevel@tonic-gate {} 3447c478bd9Sstevel@tonic-gate 3457c478bd9Sstevel@tonic-gate /* ARGSUSED */ 3467c478bd9Sstevel@tonic-gate void 3477c478bd9Sstevel@tonic-gate cpu_uninit_private(struct cpu *cp) 3487c478bd9Sstevel@tonic-gate {} 3497c478bd9Sstevel@tonic-gate 3507c478bd9Sstevel@tonic-gate void 3517c478bd9Sstevel@tonic-gate sticksync_slave(void) 3527c478bd9Sstevel@tonic-gate {} 3537c478bd9Sstevel@tonic-gate 3547c478bd9Sstevel@tonic-gate void 3557c478bd9Sstevel@tonic-gate sticksync_master(void) 3567c478bd9Sstevel@tonic-gate {} 3577c478bd9Sstevel@tonic-gate 3587c478bd9Sstevel@tonic-gate /*ARGSUSED*/ 3597c478bd9Sstevel@tonic-gate int 3607c478bd9Sstevel@tonic-gate dtrace_blksuword32(uintptr_t addr, uint32_t *data, int tryagain) 3617c478bd9Sstevel@tonic-gate { return (-1); } 362