~ubuntu-branches/ubuntu/trusty/linux-linaro-omap/trusty

« back to all changes in this revision

Viewing changes to arch/um/kernel/trap.c

  • Committer: Package Import Robot
  • Author(s): John Rigby, John Rigby
  • Date: 2011-09-26 10:44:23 UTC
  • Revision ID: package-import@ubuntu.com-20110926104423-57i0gl3v99b3lkfg
Tags: 3.0.0-1007.9
[ John Rigby ]

Enable crypto modules and remove crypto-modules from
exclude-module files
LP: #826021

Show diffs side-by-side

added added

removed removed

Lines of Context:
113
113
        return 0;
114
114
}
115
115
 
 
116
static void show_segv_info(struct uml_pt_regs *regs)
 
117
{
 
118
        struct task_struct *tsk = current;
 
119
        struct faultinfo *fi = UPT_FAULTINFO(regs);
 
120
 
 
121
        if (!unhandled_signal(tsk, SIGSEGV))
 
122
                return;
 
123
 
 
124
        if (!printk_ratelimit())
 
125
                return;
 
126
 
 
127
        printk("%s%s[%d]: segfault at %lx ip %p sp %p error %x",
 
128
                task_pid_nr(tsk) > 1 ? KERN_INFO : KERN_EMERG,
 
129
                tsk->comm, task_pid_nr(tsk), FAULT_ADDRESS(*fi),
 
130
                (void *)UPT_IP(regs), (void *)UPT_SP(regs),
 
131
                fi->error_code);
 
132
 
 
133
        print_vma_addr(KERN_CONT " in ", UPT_IP(regs));
 
134
        printk(KERN_CONT "\n");
 
135
}
 
136
 
116
137
static void bad_segv(struct faultinfo fi, unsigned long ip)
117
138
{
118
139
        struct siginfo si;
141
162
        struct faultinfo * fi = UPT_FAULTINFO(regs);
142
163
 
143
164
        if (UPT_IS_USER(regs) && !SEGV_IS_FIXABLE(fi)) {
 
165
                show_segv_info(regs);
144
166
                bad_segv(*fi, UPT_IP(regs));
145
167
                return;
146
168
        }
202
224
                      address, ip);
203
225
        }
204
226
 
 
227
        show_segv_info(regs);
 
228
 
205
229
        if (err == -EACCES) {
206
230
                si.si_signo = SIGBUS;
207
231
                si.si_errno = 0;