Added entry points for ANSI C
This commit is contained in:
		
							parent
							
								
									73bfa1d1ab
								
							
						
					
					
						commit
						ee026dd2ab
					
				
					 24 changed files with 575 additions and 0 deletions
				
			
		|  | @ -37,3 +37,26 @@ exit2.s | ||||||
| time.s | time.s | ||||||
| cleanup.s | cleanup.s | ||||||
| pause.s | pause.s | ||||||
|  | _alarm.s | ||||||
|  | _close.s | ||||||
|  | _creat.s | ||||||
|  | _dup.s | ||||||
|  | _exec.s | ||||||
|  | _fork.s | ||||||
|  | _fstat.s | ||||||
|  | _getpid.s | ||||||
|  | _gtty.s | ||||||
|  | _ioctl.s | ||||||
|  | _kill.s | ||||||
|  | _link.s | ||||||
|  | _lseek.s | ||||||
|  | _open.s | ||||||
|  | _pause.s | ||||||
|  | _pipe.s | ||||||
|  | _read.s | ||||||
|  | _sbrk.s | ||||||
|  | _stty.s | ||||||
|  | _time.s | ||||||
|  | _unlink.s | ||||||
|  | _wait.s | ||||||
|  | _write.s | ||||||
|  |  | ||||||
							
								
								
									
										20
									
								
								mach/pmds/libsys/_alarm.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								mach/pmds/libsys/_alarm.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,20 @@ | ||||||
|  | .define __alarm
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __alarm
 | ||||||
|  | .sect .text | ||||||
|  | __alarm: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 8(a6),-(sp) | ||||||
|  | clr.w -(sp) | ||||||
|  | jsr __Salarm | ||||||
|  | add.l #4,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Salarm:		trap #0 | ||||||
|  | .data2	0x1B
 | ||||||
|  | 			rts | ||||||
							
								
								
									
										25
									
								
								mach/pmds/libsys/_close.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								mach/pmds/libsys/_close.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,25 @@ | ||||||
|  | .define __close
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __close
 | ||||||
|  | .sect .text | ||||||
|  | __close: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 8(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | jsr __Sclose | ||||||
|  | add.l #4,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sclose:		trap #0 | ||||||
|  | .data2	0x6
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										25
									
								
								mach/pmds/libsys/_creat.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								mach/pmds/libsys/_creat.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,25 @@ | ||||||
|  | .define __creat
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __creat
 | ||||||
|  | .sect .text | ||||||
|  | __creat: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 12(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l 8(a6),-(sp) | ||||||
|  | jsr __Screat | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Screat:		trap #0 | ||||||
|  | .data2	0x8
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
							
								
								
									
										41
									
								
								mach/pmds/libsys/_dup.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										41
									
								
								mach/pmds/libsys/_dup.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,41 @@ | ||||||
|  | .define __dup
 | ||||||
|  | .define __dup2
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __dup
 | ||||||
|  | .sect .text | ||||||
|  | __dup: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 8(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | jsr __Sdup | ||||||
|  | add.l #4,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | .extern __dup2
 | ||||||
|  | __dup2: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 10(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Sdup2 | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sdup2:		or.l	#64,4(sp) | ||||||
|  | 
 | ||||||
|  | __Sdup:			trap #0 | ||||||
|  | .data2	0x29
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
							
								
								
									
										32
									
								
								mach/pmds/libsys/_exec.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										32
									
								
								mach/pmds/libsys/_exec.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,32 @@ | ||||||
|  | .define __execl
 | ||||||
|  | .define __execve
 | ||||||
|  | .define __execv
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __execl
 | ||||||
|  | .extern __execve
 | ||||||
|  | .extern __execv
 | ||||||
|  | __execl:		tst.b -48(sp) | ||||||
|  | 		link a6,#0 | ||||||
|  | 		move.l _environ,-(sp) | ||||||
|  | 		pea 12(a6) | ||||||
|  | 		move.l 8(a6),-(sp) | ||||||
|  | 		jsr __execve | ||||||
|  | 		add.l #12,sp | ||||||
|  | 		unlk a6 | ||||||
|  | 		rts | ||||||
|  | __execve:	trap #0 | ||||||
|  | .data2 59
 | ||||||
|  | 		jmp cerror | ||||||
|  | __execv:		tst.b -48(sp) | ||||||
|  | 		link a6,#0 | ||||||
|  | 		move.l _environ,-(sp) | ||||||
|  | 		move.l 12(a6),-(sp) | ||||||
|  | 		move.l 8(a6),-(sp) | ||||||
|  | 		jsr __execve | ||||||
|  | 		add.l #12,sp | ||||||
|  | 		unlk a6 | ||||||
|  | 		rts | ||||||
							
								
								
									
										17
									
								
								mach/pmds/libsys/_fork.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								mach/pmds/libsys/_fork.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,17 @@ | ||||||
|  | .define __fork
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __fork
 | ||||||
|  | __fork:		trap #0 | ||||||
|  | .data2 0x2
 | ||||||
|  | 		bra 3f | ||||||
|  | 		rts | ||||||
|  | 3: | ||||||
|  | 		bcc 2f | ||||||
|  | 		jmp cerror | ||||||
|  | 2: | ||||||
|  | 		clr.l d0 | ||||||
|  | 		rts | ||||||
							
								
								
									
										26
									
								
								mach/pmds/libsys/_fstat.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								mach/pmds/libsys/_fstat.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,26 @@ | ||||||
|  | .define __fstat
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __fstat
 | ||||||
|  | .sect .text | ||||||
|  | __fstat: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 8(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.l d2,-(sp) | ||||||
|  | jsr __Sfstat | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sfstat:		trap #0 | ||||||
|  | .data2	0x1C
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										10
									
								
								mach/pmds/libsys/_getpid.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								mach/pmds/libsys/_getpid.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,10 @@ | ||||||
|  | .define __getpid
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __getpid
 | ||||||
|  | __getpid:		trap #0 | ||||||
|  | .data2	0x14
 | ||||||
|  | 			rts | ||||||
							
								
								
									
										18
									
								
								mach/pmds/libsys/_gtty.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								mach/pmds/libsys/_gtty.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | ||||||
|  | .define __gtty
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __gtty
 | ||||||
|  | .sect .text | ||||||
|  | __gtty: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.w #29704,-(sp) | ||||||
|  | move.w 8(a6),-(sp) | ||||||
|  | jsr __ioctl | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
							
								
								
									
										29
									
								
								mach/pmds/libsys/_ioctl.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								mach/pmds/libsys/_ioctl.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,29 @@ | ||||||
|  | .define __ioctl
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __ioctl
 | ||||||
|  | .sect .text | ||||||
|  | __ioctl: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 10(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l 12(a6),-(sp) | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Sioctl | ||||||
|  | lea 12(sp),sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sioctl:		trap #0 | ||||||
|  | .data2	0x36
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										28
									
								
								mach/pmds/libsys/_kill.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								mach/pmds/libsys/_kill.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,28 @@ | ||||||
|  | .define __kill
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __kill
 | ||||||
|  | .sect .text | ||||||
|  | __kill: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 10(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Skill | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Skill:		trap #0 | ||||||
|  | .data2	0x25
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										14
									
								
								mach/pmds/libsys/_link.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								mach/pmds/libsys/_link.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,14 @@ | ||||||
|  | .define __link
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __link
 | ||||||
|  | __link:			trap #0 | ||||||
|  | .data2	0x9
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										28
									
								
								mach/pmds/libsys/_lseek.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								mach/pmds/libsys/_lseek.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,28 @@ | ||||||
|  | .define __lseek
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __lseek
 | ||||||
|  | .sect .text | ||||||
|  | __lseek: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 14(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Slseek | ||||||
|  | lea 12(sp),sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Slseek:		trap #0 | ||||||
|  | .data2	0x13
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
							
								
								
									
										25
									
								
								mach/pmds/libsys/_open.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								mach/pmds/libsys/_open.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,25 @@ | ||||||
|  | .define __open
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __open
 | ||||||
|  | .sect .text | ||||||
|  | __open: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 12(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l 8(a6),-(sp) | ||||||
|  | jsr __Sopen | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sopen:		trap #0 | ||||||
|  | .data2	0x5
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
							
								
								
									
										13
									
								
								mach/pmds/libsys/_pause.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								mach/pmds/libsys/_pause.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,13 @@ | ||||||
|  | .define __pause
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __pause
 | ||||||
|  | __pause:		trap #0 | ||||||
|  | .data2 29
 | ||||||
|  | 		bcc 1f | ||||||
|  | 		jmp cerror | ||||||
|  | 1: | ||||||
|  | 		rts | ||||||
							
								
								
									
										17
									
								
								mach/pmds/libsys/_pipe.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								mach/pmds/libsys/_pipe.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,17 @@ | ||||||
|  | .define __pipe
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __pipe
 | ||||||
|  | __pipe:		trap #0 | ||||||
|  | .data2 0x2A
 | ||||||
|  | 		bcc 1f | ||||||
|  | 		jmp cerror | ||||||
|  | 1: | ||||||
|  | 		move.l 4(sp),a0 | ||||||
|  | 		move.w d0,(a0)+ | ||||||
|  | 		move.w d1,(a0) | ||||||
|  | 		clr.l d0 | ||||||
|  | 		rts | ||||||
							
								
								
									
										28
									
								
								mach/pmds/libsys/_read.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								mach/pmds/libsys/_read.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,28 @@ | ||||||
|  | .define __read
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __read
 | ||||||
|  | .sect .text | ||||||
|  | __read: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 14(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Sread | ||||||
|  | lea 12(sp),sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Sread:		trap #0 | ||||||
|  | .data2	0x3
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
							
								
								
									
										52
									
								
								mach/pmds/libsys/_sbrk.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										52
									
								
								mach/pmds/libsys/_sbrk.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,52 @@ | ||||||
|  | .define __brk
 | ||||||
|  | .define __sbrk
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __brk
 | ||||||
|  | .sect .text | ||||||
|  | __brk: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.l 8(a6),-(sp) | ||||||
|  | jsr __Sbrk | ||||||
|  | add.l #4,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | .extern __sbrk
 | ||||||
|  | __sbrk: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 8(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | jsr __Ssbrk | ||||||
|  | add.l #4,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Ssbrk:		tst.b	-8(sp) | ||||||
|  | 			move.l	4(sp),d0 | ||||||
|  | 			beq	1f | ||||||
|  | 			add.l	.limhp,d0 | ||||||
|  | 			move.l	d0,-(sp) | ||||||
|  | 			clr.l	-(sp) | ||||||
|  | 			trap #0 | ||||||
|  | .data2	0x11
 | ||||||
|  | 			add.l	#8,sp | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			move.l	.limhp,d0 | ||||||
|  | 			move.l	4(sp),d1 | ||||||
|  | 			add.l	d1,.limhp | ||||||
|  | 			rts | ||||||
|  | __Sbrk:			trap #0 | ||||||
|  | .data2	0x11
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			move.l	4(sp),.limhp | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										18
									
								
								mach/pmds/libsys/_stty.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								mach/pmds/libsys/_stty.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | ||||||
|  | .define __stty
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __stty
 | ||||||
|  | .sect .text | ||||||
|  | __stty: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.w #29705,-(sp) | ||||||
|  | move.w 8(a6),-(sp) | ||||||
|  | jsr __ioctl | ||||||
|  | add.l #8,sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
							
								
								
									
										26
									
								
								mach/pmds/libsys/_time.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								mach/pmds/libsys/_time.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,26 @@ | ||||||
|  | .define __time
 | ||||||
|  | .define __ftime
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __time
 | ||||||
|  | __time: | ||||||
|  | 	trap #0 | ||||||
|  | .data2	0xD
 | ||||||
|  | 	tst.l 4(sp) | ||||||
|  | 	beq 1f | ||||||
|  | 	move.l 4(sp),a0 | ||||||
|  | 	move.l d0,(a0) | ||||||
|  | 1: | ||||||
|  | 	rts | ||||||
|  | .extern __ftime
 | ||||||
|  | __ftime: | ||||||
|  | 	trap #0 | ||||||
|  | .data2 0x23
 | ||||||
|  | 	bcc 1f | ||||||
|  | 	jmp cerror | ||||||
|  | 1: | ||||||
|  | 	clr.l d0 | ||||||
|  | 	rts | ||||||
							
								
								
									
										14
									
								
								mach/pmds/libsys/_unlink.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								mach/pmds/libsys/_unlink.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,14 @@ | ||||||
|  | .define __unlink
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __unlink
 | ||||||
|  | __unlink:		trap #0 | ||||||
|  | .data2	0xA
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			clr.l	d0 | ||||||
|  | 			rts | ||||||
							
								
								
									
										18
									
								
								mach/pmds/libsys/_wait.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								mach/pmds/libsys/_wait.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | ||||||
|  | .define __wait
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __wait
 | ||||||
|  | __wait:		trap #0 | ||||||
|  | .data2 0x7
 | ||||||
|  | 		bcc 1f | ||||||
|  | 		jmp cerror | ||||||
|  | 1: | ||||||
|  | 		tst.l 4(sp) | ||||||
|  | 		beq 2f | ||||||
|  | 		move.l 4(sp),a0 | ||||||
|  | 		move.w d1,(a0) | ||||||
|  | 2: | ||||||
|  | 		rts | ||||||
							
								
								
									
										28
									
								
								mach/pmds/libsys/_write.s
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								mach/pmds/libsys/_write.s
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,28 @@ | ||||||
|  | .define __write
 | ||||||
|  | .sect .text | ||||||
|  | .sect .rom | ||||||
|  | .sect .data | ||||||
|  | .sect .bss | ||||||
|  | .sect .text | ||||||
|  | .extern __write
 | ||||||
|  | .sect .text | ||||||
|  | __write: | ||||||
|  | tst.b -40(sp) | ||||||
|  | link	a6,#-0 | ||||||
|  | move.w 14(a6), d2 | ||||||
|  | ext.l d2 | ||||||
|  | move.w 8(a6), d1 | ||||||
|  | ext.l d1 | ||||||
|  | move.l d2,-(sp) | ||||||
|  | move.l 10(a6),-(sp) | ||||||
|  | move.l d1,-(sp) | ||||||
|  | jsr __Swrite | ||||||
|  | lea 12(sp),sp | ||||||
|  | unlk a6 | ||||||
|  | rts | ||||||
|  | __Swrite:		trap #0 | ||||||
|  | .data2	0x4
 | ||||||
|  | 			bcc	1f | ||||||
|  | 			jmp	cerror | ||||||
|  | 1: | ||||||
|  | 			rts | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue