Fork me on GitHub
sc                467 drivers/block/floppy.c void irq_floppy(int num, struct sigcontext *sc)
sc                411 drivers/block/ide.c void irq_ide0(int num, struct sigcontext *sc)
sc                422 drivers/block/ide.c void irq_ide1(int num, struct sigcontext *sc)
sc                430 drivers/char/keyboard.c void irq_keyboard(int num, struct sigcontext *sc)
sc                326 drivers/char/serial.c void irq_serial(int num, struct sigcontext *sc)
sc                401 fs/elf.c       int elf_load(struct inode *i, struct binargs *barg, struct sigcontext *sc, char *data)
sc                570 fs/elf.c       	sc->oldesp = sp;
sc                571 fs/elf.c       	sc->eflags = 0x202;	/* FIXME: linux 2.2 = 0x292 */
sc                572 fs/elf.c       	sc->eip = current->entry_address;
sc                573 fs/elf.c       	sc->err = 0;
sc                574 fs/elf.c       	sc->eax = 0;
sc                575 fs/elf.c       	sc->ecx = 0;
sc                576 fs/elf.c       	sc->edx = 0;
sc                577 fs/elf.c       	sc->ebx = 0;
sc                578 fs/elf.c       	sc->ebp = 0;
sc                579 fs/elf.c       	sc->esi = 0;
sc                580 fs/elf.c       	sc->edi = 0;
sc                648 fs/procfs/data.c 	struct sigcontext *sc;
sc                690 fs/procfs/data.c 			sc = (struct sigcontext *)p->sp;
sc                691 fs/procfs/data.c 			esp = sc->oldesp;
sc                692 fs/procfs/data.c 			eip = sc->eip;
sc                142 include/fiwix/process.h 	struct sigcontext sc[NSIG];	/* each signal has its own context */
sc                126 kernel/pic.c   void irq_handler(int num, struct sigcontext sc)
sc                168 kernel/pic.c   		irq->handler(num, &sc);
sc                151 kernel/signal.c 	struct sigcontext *sc;
sc                154 kernel/signal.c 	sc = (struct sigcontext *)stack;
sc                166 kernel/signal.c 				memcpy_b(&current->sc[signum - 1], sc, sizeof(struct sigcontext));
sc                169 kernel/signal.c 				sc->oldesp -= len;
sc                170 kernel/signal.c 				sc->oldesp -= 4;
sc                171 kernel/signal.c 				sc->oldesp &= ~3;	/* round up */
sc                172 kernel/signal.c 				memcpy_b((void *)sc->oldesp, sighandler_trampoline, len);
sc                173 kernel/signal.c 				sc->ecx = (unsigned int)current->sigaction[signum - 1].sa_handler;
sc                174 kernel/signal.c 				sc->eax= signum;
sc                175 kernel/signal.c 				sc->eip = sc->oldesp;
sc                213 kernel/signal.c 	if(sc->err > 0) {
sc                214 kernel/signal.c 		if(sc->eax == -ERESTART) {
sc                215 kernel/signal.c 			sc->eax = sc->err;	/* syscall was saved in 'err' */
sc                216 kernel/signal.c 			sc->eip -= 2;		/* point again to 'int 0x80' */
sc                392 kernel/syscalls.c int do_syscall(unsigned int num, int arg1, int arg2, int arg3, int arg4, int arg5, struct sigcontext sc)
sc                405 kernel/syscalls.c 	current->sp = (unsigned int)≻
sc                406 kernel/syscalls.c 	return sys_func(arg1, arg2, arg3, arg4, arg5, &sc);
sc                235 kernel/syscalls/execve.c static int do_execve(const char *filename, char *argv[], char *envp[], struct sigcontext *sc)
sc                308 kernel/syscalls/execve.c 	errno = elf_load(i, &barg, sc, data);
sc                342 kernel/syscalls/execve.c int sys_execve(const char *filename, char *argv[], char *envp[], int arg4, int arg5, struct sigcontext *sc)
sc                353 kernel/syscalls/execve.c 	if((errno = do_execve(filename, &(*argv), &(*envp), sc))) {
sc                 21 kernel/syscalls/fork.c int sys_fork(int arg1, int arg2, int arg3, int arg4, int arg5, struct sigcontext *sc)
sc                 91 kernel/syscalls/fork.c 	memset_b(&child->sc, NULL, sizeof(struct sigcontext));
sc                123 kernel/syscalls/fork.c 	memcpy_b((unsigned int *)(child->tss.esp0 & PAGE_MASK), (void *)((unsigned int)(sc) & PAGE_MASK), PAGE_SIZE);
sc                124 kernel/syscalls/fork.c 	stack = (struct sigcontext *)((child->tss.esp0 & PAGE_MASK) + ((unsigned int)(sc) & ~PAGE_MASK));
sc                 35 kernel/syscalls/iopl.c int sys_iopl(int level, int arg2, int arg3, int arg4, int arg5, struct sigcontext *sc)
sc                 53 kernel/syscalls/iopl.c 	sc->eflags = (sc->eflags & 0xFFFFCFFF) | (level << EF_IOPL);
sc                 16 kernel/syscalls/sigreturn.c int sys_sigreturn(unsigned int signum, int arg2, int arg3, int arg4, int arg5, struct sigcontext *sc)
sc                 24 kernel/syscalls/sigreturn.c 	memcpy_b(sc, &current->sc[signum - 1], sizeof(struct sigcontext));
sc                 30 kernel/syscalls/sigreturn.c 	return current->sc[signum - 1].eax;
sc                173 kernel/timer.c void irq_timer(int num, struct sigcontext *sc)
sc                182 kernel/timer.c 	if(sc->cs == KERNEL_CS) {
sc                 68 kernel/traps.c void do_divide_error(unsigned int trap, struct sigcontext *sc)
sc                 70 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                 77 kernel/traps.c void do_debug(unsigned int trap, struct sigcontext *sc)
sc                 79 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                 86 kernel/traps.c void do_nmi_interrupt(unsigned int trap, struct sigcontext *sc)
sc                102 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                109 kernel/traps.c void do_breakpoint(unsigned int trap, struct sigcontext *sc)
sc                111 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                118 kernel/traps.c void do_overflow(unsigned int trap, struct sigcontext *sc)
sc                120 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                127 kernel/traps.c void do_bound(unsigned int trap, struct sigcontext *sc)
sc                129 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                136 kernel/traps.c void do_invalid_opcode(unsigned int trap, struct sigcontext *sc)
sc                138 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                145 kernel/traps.c void do_no_math_coprocessor(unsigned int trap, struct sigcontext *sc)
sc                149 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                156 kernel/traps.c void do_double_fault(unsigned int trap, struct sigcontext *sc)
sc                158 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                165 kernel/traps.c void do_coprocessor_segment_overrun(unsigned int trap, struct sigcontext *sc)
sc                167 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                174 kernel/traps.c void do_invalid_tss(unsigned int trap, struct sigcontext *sc)
sc                176 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                183 kernel/traps.c void do_segment_not_present(unsigned int trap, struct sigcontext *sc)
sc                185 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                192 kernel/traps.c void do_stack_segment_fault(unsigned int trap, struct sigcontext *sc)
sc                194 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                201 kernel/traps.c void do_general_protection(unsigned int trap, struct sigcontext *sc)
sc                203 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                212 kernel/traps.c void do_reserved(unsigned int trap, struct sigcontext *sc)
sc                214 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                221 kernel/traps.c void do_floating_point_error(unsigned int trap, struct sigcontext *sc)
sc                223 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                230 kernel/traps.c void do_alignment_check(unsigned int trap, struct sigcontext *sc)
sc                232 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                239 kernel/traps.c void do_machine_check(unsigned int trap, struct sigcontext *sc)
sc                241 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                248 kernel/traps.c void do_simd_fault(unsigned int trap, struct sigcontext *sc)
sc                250 kernel/traps.c 	if(dump_registers(trap, sc)) {
sc                257 kernel/traps.c void trap_handler(unsigned int trap, struct sigcontext sc)
sc                259 kernel/traps.c 	traps_table[trap].handler(trap, &sc);
sc                262 kernel/traps.c 	sc.err = -sc.err;
sc                311 kernel/traps.c int dump_registers(unsigned int trap, struct sigcontext *sc)
sc                318 kernel/traps.c 		printk("%s at 0x%08x (%s) with error code 0x%08x (0b%b)\n", traps_table[trap].name, cr2, sc->err & PFAULT_W ? "writing" : "reading", sc->err, sc->err);
sc                322 kernel/traps.c 			printk(": error code 0x%08x (0b%b)", sc->err, sc->err);
sc                328 kernel/traps.c 	if(sc->cs == KERNEL_CS) {
sc                329 kernel/traps.c 		printk(" in '%s()'.", elf_lookup_symbol(sc->eip));
sc                333 kernel/traps.c 	printk(" cs: 0x%08x\teip: 0x%08x\tefl: 0x%08x\t ss: 0x%08x\tesp: 0x%08x\n", sc->cs, sc->eip, sc->eflags, sc->oldss, sc->oldesp);
sc                334 kernel/traps.c 	printk("eax: 0x%08x\tebx: 0x%08x\tecx: 0x%08x\tedx: 0x%08x\n", sc->eax, sc->ebx, sc->ecx, sc->edx);
sc                335 kernel/traps.c 	printk("esi: 0x%08x\tedi: 0x%08x\tesp: 0x%08x\tebp: 0x%08x\n", sc->esi, sc->edi, sc->esp, sc->ebp);
sc                336 kernel/traps.c 	printk(" ds: 0x%08x\t es: 0x%08x\t fs: 0x%08x\t gs: 0x%08x\n", sc->ds, sc->es, sc->fs, sc->gs);
sc                338 kernel/traps.c 	if(sc->cs == KERNEL_CS) {
sc                343 kernel/traps.c 	if(current->flags & PF_KPROC || sc->cs == KERNEL_CS) {
sc                 22 mm/fault.c     static void send_sigsegv(struct sigcontext *sc)
sc                 25 mm/fault.c     	dump_registers(14, sc);
sc                 32 mm/fault.c     static int page_protection_violation(struct vma *vma, unsigned int cr2, struct sigcontext *sc)
sc                 53 mm/fault.c     			send_sigsegv(sc);
sc                 73 mm/fault.c     				send_sigsegv(sc);
sc                 85 mm/fault.c     static int page_not_present(struct vma *vma, unsigned int cr2, struct sigcontext *sc)
sc                 91 mm/fault.c     		if(cr2 >= (sc->oldesp - 32) && cr2 < KERNEL_BASE_ADDR) {
sc                 94 mm/fault.c     				send_sigsegv(sc);
sc                106 mm/fault.c     		send_sigsegv(sc);
sc                200 mm/fault.c     void do_page_fault(unsigned int trap, struct sigcontext *sc)
sc                209 mm/fault.c     		if(sc->err & PFAULT_U) {
sc                210 mm/fault.c     			if(sc->err & PFAULT_V) {	/* violation */
sc                211 mm/fault.c     				if(sc->err & PFAULT_W) {
sc                212 mm/fault.c     					if((page_protection_violation(vma, cr2, sc))) {
sc                217 mm/fault.c     				send_sigsegv(sc);
sc                219 mm/fault.c     				if((page_not_present(vma, cr2, sc))) {
sc                231 mm/fault.c     			if(!(sc->err & PFAULT_V)) {	/* page not present */
sc                232 mm/fault.c     				if((page_not_present(vma, cr2, sc))) {
sc                238 mm/fault.c     			if(sc->err & PFAULT_W) {	/* copy-on-write? */
sc                239 mm/fault.c     				if((page_protection_violation(vma, cr2, sc))) {
sc                248 mm/fault.c     		if(sc->err & PFAULT_U) {
sc                249 mm/fault.c     			if(sc->err & PFAULT_V) {	/* violation */
sc                250 mm/fault.c     				send_sigsegv(sc);
sc                252 mm/fault.c     				if((page_not_present(vma, cr2, sc))) {
sc                260 mm/fault.c     	dump_registers(trap, sc);