DELTA 292407 25127 1137 SVN‘t’: O \€MƒŽcM struct pcpu *pcpu; __asm __volatile("mv %0, gp" : "=&r"(pcpu)); return (pcpu); } static inline struct thread * get_curthread(void) { struct thread *td; __asm __volatile("ld %0, 0(gp)" : "=&r"(td))ENDREP DELTA 295041 30927 3173 SVNÊ Ë3‚N,€ŒTl€&† !‰¦^£-‚L(TF_SIZE) sd ra, (TF_RA)(sp) sd tp, (TF_TP)(sp) .if \el == 0 /* We came from userspace. Load our pcpu */ sd gp, (TF_GP)(sp) ld gp, (TF_SIZE)(sp) .endifWe go to userspace. Load user sp */ ld t0, (TF_SP)(sp) csrw sscratch, t0 /* And store our pcpu */ sd gp, (TF_SIZE)(sp) ld gp, (TF_GP)(sp) .endif ld ra, (TF_RA(TF_SIZE)ENDREP DELTA 295041 34113 1478 SVNŸŸ. ! šV „8šL SIZE, sizeof(struct trapframe));ENDREP DELTA 295041 42273 6158 SVNŒgŒ+2¬4„·¬2¤ãC­„ˆQ1; __asm __volatile("mv gp, %0" :: "r"(pcpup));ENDREP DELTA 295041 78427 2352 SVN¶¶J‚W”o‡ •‰œg1¦.€‚U´h‚ULoad user ra and sp */ ld tp, (TF_TP)(sp) ld ra, (TF_RA)(sp) /* * Store our pcpup on stack, we will load it back * on kernel mode trap. */ sd gp, (TF_SIZE)(sp) ld gp, (TF_GP)(sp) /* Save kernel stack so we can use it doing a user trap */ addi sp, sp, TF_SIZE csrw sscratch, sp /* Load user stack */ ld sp, (TF_SP - TF_SIZEENDREP DELTA 295250 148 46 SVN´´8 3 ®n²…®|2(caddr_t)td->td_pcb - 8 - sizeof(struct trapframe)ENDREP id: 21-292407.0.r295253/1384 type: file pred: 21-292407.0.r292407/50416 count: 1 text: 295253 0 232 2362 52f42839f2232fa1441472021d8cbad6 7e0c9698eb541159177c9323119d97b6f999b501 295252-6c50/_5 props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/include/pcpu.h copyroot: 0 / PLAIN K 8 _align.h V 29 file 6-292407.0.r292407/41168 K 6 _bus.h V 29 file 9-292407.0.r292407/41445 K 11 _inttypes.h V 29 file b-292407.0.r292407/41723 K 9 _limits.h V 29 file d-292407.0.r292407/42006 K 9 _stdint.h V 29 file f-292407.0.r292407/42287 K 8 _types.h V 29 file h-292407.0.r292407/42568 K 5 asm.h V 29 file j-292407.0.r292407/42845 K 8 atomic.h V 29 file l-292407.0.r292407/43122 K 5 bus.h V 29 file n-292407.0.r292407/43403 K 9 bus_dma.h V 29 file p-292407.0.r292407/43682 K 7 clock.h V 29 file r-292407.0.r292407/43962 K 9 counter.h V 29 file t-292407.0.r292407/44233 K 5 cpu.h V 29 file v-292407.0.r292407/44515 K 9 cpufunc.h V 29 file x-292407.0.r292407/44792 K 12 db_machdep.h V 29 file z-292407.0.r292407/45073 K 6 dump.h V 30 file 11-292407.0.r292407/45358 K 5 elf.h V 30 file 13-292407.0.r292407/45638 K 8 endian.h V 30 file 15-292407.0.r292407/45918 K 6 exec.h V 30 file 17-292407.0.r292407/46201 K 7 float.h V 30 file 19-292407.0.r292407/46473 K 15 floatingpoint.h V 30 file 1b-292407.0.r292407/46755 K 7 frame.h V 30 file 1d-292407.0.r292407/47037 K 8 ieeefp.h V 30 file 1f-292407.0.r292407/47319 K 10 in_cksum.h V 30 file 1h-292407.0.r292407/47600 K 6 intr.h V 30 file 1j-292407.0.r292407/47880 K 5 kdb.h V 30 file 1l-292407.0.r292407/48161 K 9 machdep.h V 30 file 1n-292407.0.r292407/48440 K 8 md_var.h V 30 file 1p-292407.0.r292407/48724 K 8 memdev.h V 30 file 1r-292407.0.r292407/49002 K 10 minidump.h V 30 file 1t-292407.0.r292407/49283 K 13 ofw_machdep.h V 30 file 1v-292407.0.r292407/49567 K 7 param.h V 30 file 1x-292407.0.r292407/49854 K 5 pcb.h V 30 file 1z-292407.0.r292407/50136 K 6 pcpu.h V 29 file 21-292407.0.r295253/1384 K 6 pmap.h V 30 file 23-292407.0.r292407/50697 K 10 pmc_mdep.h V 30 file 25-292407.0.r292407/50974 K 6 proc.h V 30 file 27-292407.0.r292407/51259 K 9 profile.h V 30 file 29-292407.0.r292407/51540 K 5 psl.h V 30 file 2b-292407.0.r292407/51819 K 5 pte.h V 30 file 2d-292407.0.r292407/52090 K 8 ptrace.h V 30 file 2f-292407.0.r292407/52370 K 5 reg.h V 30 file 2h-292407.0.r292407/52644 K 7 reloc.h V 30 file 2j-292407.0.r292407/52924 K 10 resource.h V 30 file 2l-292407.0.r292407/53197 K 10 riscvreg.h V 28 file 2n-292407.0.r294282/312 K 6 runq.h V 30 file 2p-292407.0.r292407/53763 K 8 setjmp.h V 30 file 2r-292407.0.r292407/54043 K 8 sf_buf.h V 30 file 2t-292407.0.r292407/54326 K 8 signal.h V 30 file 2v-292407.0.r292407/54609 K 5 smp.h V 30 file 2x-292407.0.r292407/54888 K 8 stdarg.h V 30 file 2z-292407.0.r292407/55159 K 9 sysarch.h V 30 file 31-292407.0.r292407/55442 K 6 trap.h V 30 file 33-292407.0.r292407/55726 K 10 ucontext.h V 30 file 35-292407.0.r292407/55998 K 6 vdso.h V 30 file 37-292407.0.r292407/56283 K 4 vm.h V 30 file 39-292407.0.r292407/56563 K 9 vmparam.h V 30 file 3b-292407.0.r292407/56841 END ENDREP id: 4-292407.0.r295253/4473 type: dir pred: 4-292407.0.r294282/3405 count: 2 text: 295253 1690 2770 0 2466f577d681c3f823c459201808b47f cpath: /head/sys/riscv/include copyroot: 0 / id: 2c-295041.0.r295253/4654 type: file pred: 2c-295041.0.r295041/131930 count: 1 text: 295253 263 373 9651 1a7a7b89a842e947d10e89456895047e e5ed6145e584e2a6d7a87eec25b07a8a3c5b3b32 295252-6c50/_7 props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/riscv/exception.S copyroot: 0 / id: 2e-295041.0.r295253/4966 type: file pred: 2e-295041.0.r295041/132215 count: 1 text: 295253 667 55 4014 c13312bfb41b942a64699fd335d74c8a f1ca0eb711ab2f0e9b74617d69a53d39827a478e 295252-6c50/_8 props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/riscv/genassym.c copyroot: 0 / id: 2o-295041.0.r295253/5276 type: file pred: 2o-295041.0.r295041/133633 count: 1 text: 295253 753 86 17963 abc38da9f00558b922e99ede5688247b 2daae96db3d02080592375457e0bf86f5b5611af 295252-6c50/_9 props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/riscv/machdep.c copyroot: 0 / id: 30-295041.0.r295253/5586 type: file pred: 30-295041.0.r295041/135334 count: 1 text: 295253 870 383 6986 159598abe76235591ab191c9a15a4e3b 4c040da0f30470bde03c39429a25c12f7eb02715 295252-6c50/_a props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/riscv/swtch.S copyroot: 0 / id: 3c-295041.0.r295253/5894 type: file pred: 3c-295041.0.r295250/7792 count: 2 text: 295253 1284 73 6712 78e1f0e73a6f5cf57e8504c1f05d6ec0 aaae7d375dc611e1b0c250dc6afef1aeed2921db 295252-6c50/_b props: 179448 45543 103 0 bb58aa814bbdf5f7c1ab04a05656f5a5 cpath: /head/sys/riscv/riscv/vm_machdep.c copyroot: 0 / PLAIN K 10 autoconf.c V 31 file 1p-295041.0.r295041/128796 K 7 bcopy.c V 31 file 1s-295041.0.r295041/129080 K 13 bus_machdep.c V 31 file 1u-295041.0.r295041/129360 K 16 busdma_machdep.c V 31 file 1w-295041.0.r295041/129647 K 7 clock.c V 31 file 1y-295041.0.r295041/129937 K 11 copyinout.S V 31 file 20-295041.0.r295041/130218 K 9 copystr.c V 31 file 22-295041.0.r295041/130503 K 13 cpufunc_asm.S V 31 file 24-295041.0.r295041/130786 K 8 devmap.c V 31 file 26-295041.0.r295041/131073 K 14 dump_machdep.c V 31 file 28-295041.0.r295041/131355 K 13 elf_machdep.c V 31 file 2a-295041.0.r295041/131643 K 11 exception.S V 29 file 2c-295041.0.r295253/4654 K 10 genassym.c V 29 file 2e-295041.0.r295253/4966 K 10 identcpu.c V 31 file 2g-295041.0.r295041/132499 K 10 in_cksum.c V 31 file 2i-295041.0.r295041/132783 K 14 intr_machdep.c V 31 file 2k-295041.0.r295041/133063 K 8 locore.S V 31 file 2m-295041.0.r295041/133351 K 9 machdep.c V 29 file 2o-295041.0.r295253/5276 K 5 mem.c V 31 file 2q-295041.0.r295041/133917 K 18 minidump_machdep.c V 31 file 2s-295041.0.r295041/134196 K 7 nexus.c V 31 file 2u-295041.0.r295041/134487 K 6 pmap.c V 31 file 2w-295041.0.r295041/134769 K 9 support.S V 31 file 2y-295041.0.r295041/135051 K 7 swtch.S V 29 file 30-295041.0.r295253/5586 K 13 sys_machdep.c V 31 file 32-295041.0.r295041/135615 K 7 timer.c V 31 file 34-295041.0.r295041/135902 K 6 trap.c V 31 file 36-295041.0.r295041/136183 K 13 uio_machdep.c V 31 file 38-295041.0.r295041/136463 K 13 uma_machdep.c V 30 file 3a-295041.0.r295231/11939 K 12 vm_machdep.c V 29 file 3c-295041.0.r295253/5894 END ENDREP id: 1o-295041.0.r295253/7797 type: dir pred: 1o-295041.0.r295250/9704 count: 3 text: 295253 6205 1579 0 cc570a54328ccdc9351181e6ef21b144 cpath: /head/sys/riscv/riscv copyroot: 0 / PLAIN K 4 conf V 30 dir 17-295041.0.r295041/127138 K 4 htif V 30 dir 1e-295041.0.r295041/128644 K 7 include V 27 dir 4-292407.0.r295253/4473 K 5 riscv V 28 dir 1o-295041.0.r295253/7797 END ENDREP id: 2-292407.0.r295253/8174 type: dir pred: 2-292407.0.r295250/10082 count: 5 text: 295253 7978 183 0 46ea0f8510f1fd5622d41e819dd9e5f4 cpath: /head/sys/riscv copyroot: 0 / PLAIN K 8 Makefile V 24 file 2-1598.0.r283743/47 K 5 amd64 V 22 dir o-5.0.r295222/4018 K 3 arm V 27 dir 2-70651.0.r295252/11662 K 5 arm64 V 27 dir 2-280364.0.r295250/3541 K 4 boot V 27 dir 6j-38465.0.r295210/3025 K 3 bsm V 27 dir 2-141144.0.r292522/7745 K 3 cam V 26 dir 2-39212.0.r295114/3601 K 4 cddl V 29 dir br-168404.0.r295125/11443 K 6 compat V 25 dir k-9313.0.r295233/2995 K 4 conf V 23 dir y-5.0.r295200/23931 K 7 contrib V 27 dir 2-23283.0.r295126/35807 K 6 crypto V 26 dir 7-55009.0.r292963/8709 K 3 ddb V 23 dir 10-5.0.r291407/2111 K 3 dev V 24 dir 12-5.0.r295218/14006 K 2 fs V 25 dir 2-1541.0.r295209/2705 K 3 gdb V 29 dir h-131899.0.r283291/118078 K 4 geom V 26 dir 2-13041.0.r294616/3123 K 3 gnu V 25 dir 2-1421.0.r287698/1649 K 4 i386 V 24 dir 1c-5.0.r294930/23390 K 3 isa V 25 dir 1w-5.0.r294883/159351 K 4 kern V 24 dir 20-5.0.r295249/11704 K 7 kgssapi V 28 dir 13-184588.0.r295134/3151 K 7 libkern V 25 dir 9-1542.0.r289766/5803 K 4 mips V 27 dir 2-178171.0.r295250/7605 K 7 modules V 26 dir i-2834.0.r295017/33985 K 3 net V 26 dir x-1542.0.r295126/91258 K 8 net80211 V 29 dir 2-116742.0.r295126/100952 K 8 netgraph V 29 dir 69-52419.0.r295126/108005 K 7 netinet V 27 dir 4f-1541.0.r295136/21529 K 8 netinet6 V 28 dir q-52904.0.r295126/119970 K 8 netipsec V 29 dir 2-105197.0.r295126/122012 K 7 netnatm V 27 dir 7-25604.0.r257179/42996 K 7 netpfil V 30 dir 11-240494.0.r295126/124422 K 6 netsmb V 26 dir u-75374.0.r291035/1725 K 3 nfs V 27 dir 4l-1541.0.r294706/44759 K 9 nfsclient V 27 dir 4r-1541.0.r281691/29780 K 9 nfsserver V 26 dir 5l-1541.0.r276780/4259 K 3 nlm V 29 dir 1i-177633.0.r273707/29853 K 4 ofed V 30 dir 1hj-219820.0.r294837/26194 K 10 opencrypto V 28 dir 2-104476.0.r292963/19008 K 4 pc98 V 28 dir p-10097.0.r294883/203770 K 7 powerpc V 24 dir 22-5.0.r295231/11768 K 5 riscv V 27 dir 2-292407.0.r295253/8174 K 3 rpc V 27 dir u-1839.0.r295126/126962 K 8 security V 26 dir 2-86630.0.r294137/2508 K 7 sparc64 V 26 dir 2-79054.0.r295251/9998 K 3 sys V 24 dir 28-5.0.r295233/30443 K 5 teken V 34 dir h-186681.0-196775.r287098/1015 K 5 tests V 27 dir f-290663.0.r290714/2475 K 5 tools V 27 dir 6k-1541.0.r295137/20577 K 3 ufs V 26 dir 1a-1542.0.r294983/1449 K 2 vm V 27 dir 1k-1542.0.r295222/20775 K 3 x86 V 30 dir 11-204309.0.r294883/246599 K 3 xdr V 29 dir 46-177633.0.r248318/15729 K 3 xen V 27 dir 2-181624.0.r294090/2051 END ENDREP id: g-5.0.r295253/10716 type: dir pred: g-5.0.r295252/14205 count: 105342 text: 295253 8347 2356 0 1d71c1c14ff91888e93bbe3fe1c255fb props: 292679 16366 1438 0 83fc2b09b1bf4750a1fde3e818e0b793 cpath: /head/sys copyroot: 0 / minfo-cnt: 29 minfo-here: y PLAIN K 10 .arcconfig V 26 file 1-265842.0.r285064/64 K 8 .arclint V 27 file 1-266959.0.r281789/766 K 9 COPYRIGHT V 25 file 1-2656.0.r292983/104 K 5 LOCKS V 27 file 1-146890.0.r255635/270 K 11 MAINTAINERS V 26 file 1-94742.0.r292839/448 K 8 Makefile V 29 file 3-1594.0-1595.r295161/76 K 13 Makefile.inc1 V 25 file 5-38666.0.r295217/97 K 17 ObsoleteFiles.inc V 27 file 4-148330.0.r294199/202 K 6 README V 26 file 1-21173.0.r281727/580 K 8 UPDATING V 26 file 1-41806.0.r295045/910 K 3 bin V 22 dir 1-5.0.r295224/2675 K 4 cddl V 27 dir 1-168404.0.r295047/7302 K 7 contrib V 26 dir 1-16755.0.r295202/6861 K 6 crypto V 27 dir 1-25405.0.r295139/19478 K 3 etc V 23 dir 1-38.0.r295032/6300 K 3 gnu V 22 dir 1-3.0.r294935/1815 K 7 include V 25 dir 1-697.0.r294540/12890 K 9 kerberos5 V 27 dir 4q-29815.0.r291972/7663 K 3 lib V 22 dir 6-5.0.r295226/6291 K 7 libexec V 22 dir c-5.0.r295079/7621 K 7 release V 25 dir 1-3027.0.r293831/1773 K 6 rescue V 26 dir 7-117035.0.r291491/793 K 4 sbin V 23 dir fa-4.0.r295121/5272 K 6 secure V 27 dir r-1553.0.r295009/331602 K 5 share V 22 dir e-3.0.r295234/4742 K 3 sys V 23 dir g-5.0.r295253/10716 K 7 targets V 34 dir 2-242818.1-284345.r293287/9574 K 5 tests V 27 dir g-257097.0.r295117/3296 K 5 tools V 26 dir 43-1590.0.r295065/7669 K 7 usr.bin V 23 dir m-3.0.r295136/54638 K 8 usr.sbin V 23 dir q-3.0.r295212/21107 END ENDREP id: 5-1.0.r295253/12326 type: dir pred: 5-1.0.r295252/15816 count: 199941 text: 295253 10968 1345 0 87659d9c12e99c9962e3aaab400fa117 props: 294647 6688 2376 0 223e0b967d761fd3eda2e1209da48baf cpath: /head copyroot: 0 / minfo-cnt: 168 minfo-here: y PLAIN K 11 ROADMAP.txt V 26 file 0-179453.0.r285589/70 K 4 head V 23 dir 5-1.0.r295253/12326 K 8 projects V 23 dir 6-1.0.r295225/50195 K 7 release V 22 dir 7-1.0.r286717/3051 K 6 releng V 23 dir 8-1.0.r295061/48391 K 6 stable V 23 dir 9-1.0.r295211/76879 K 8 svnadmin V 27 dir 0-179447.0.r295084/1684 K 4 user V 24 dir a-1.0.r295248/894751 K 6 vendor V 22 dir b-1.0.r295111/5669 K 13 vendor-crypto V 25 dir 0-1575.0.r295005/4236 K 10 vendor-sys V 27 dir 0-12116.0.r294835/11794 END ENDREP id: 0.0.r295253/13064 type: dir pred: 0.0.r295252/16554 count: 295253 text: 295253 12575 476 0 f46f7c22304038aa12a1125078303269 props: 289270 0 4229 0 20f578acc837c5e58fc64b9eaa493aea cpath: / copyroot: 0 / minfo-cnt: 44831 21-292407.0.t295252-6c50 modify-file true false /head/sys/riscv/include/pcpu.h 2c-295041.0.t295252-6c50 modify-file true false /head/sys/riscv/riscv/exception.S 2e-295041.0.t295252-6c50 modify-file true false /head/sys/riscv/riscv/genassym.c 2o-295041.0.t295252-6c50 modify-file true false /head/sys/riscv/riscv/machdep.c 30-295041.0.t295252-6c50 modify-file true false /head/sys/riscv/riscv/swtch.S 3c-295041.0.t295252-6c50 modify-file true false /head/sys/riscv/riscv/vm_machdep.c 13064 13289