|
@@ -55,6 +55,20 @@
|
|
|
|
|
|
extern void sigset_from_compat(sigset_t *set, compat_sigset_t *compat);
|
|
extern void sigset_from_compat(sigset_t *set, compat_sigset_t *compat);
|
|
|
|
|
|
|
|
+int compat_log = 1;
|
|
|
|
+
|
|
|
|
+int compat_printk(const char *fmt, ...)
|
|
|
|
+{
|
|
|
|
+ va_list ap;
|
|
|
|
+ int ret;
|
|
|
|
+ if (!compat_log)
|
|
|
|
+ return 0;
|
|
|
|
+ va_start(ap, fmt);
|
|
|
|
+ ret = vprintk(fmt, ap);
|
|
|
|
+ va_end(ap);
|
|
|
|
+ return ret;
|
|
|
|
+}
|
|
|
|
+
|
|
/*
|
|
/*
|
|
* Not all architectures have sys_utime, so implement this in terms
|
|
* Not all architectures have sys_utime, so implement this in terms
|
|
* of sys_utimes.
|
|
* of sys_utimes.
|
|
@@ -359,7 +373,7 @@ static void compat_ioctl_error(struct file *filp, unsigned int fd,
|
|
sprintf(buf,"'%c'", (cmd>>24) & 0x3f);
|
|
sprintf(buf,"'%c'", (cmd>>24) & 0x3f);
|
|
if (!isprint(buf[1]))
|
|
if (!isprint(buf[1]))
|
|
sprintf(buf, "%02x", buf[1]);
|
|
sprintf(buf, "%02x", buf[1]);
|
|
- printk("ioctl32(%s:%d): Unknown cmd fd(%d) "
|
|
|
|
|
|
+ compat_printk("ioctl32(%s:%d): Unknown cmd fd(%d) "
|
|
"cmd(%08x){%s} arg(%08x) on %s\n",
|
|
"cmd(%08x){%s} arg(%08x) on %s\n",
|
|
current->comm, current->pid,
|
|
current->comm, current->pid,
|
|
(int)fd, (unsigned int)cmd, buf,
|
|
(int)fd, (unsigned int)cmd, buf,
|