From owner-p4-projects@FreeBSD.ORG Sun Dec 31 13:00:33 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 5A5C316A412; Sun, 31 Dec 2006 13:00:33 +0000 (UTC) X-Original-To: perforce@FreeBSD.org Delivered-To: perforce@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 35FC816A403 for ; Sun, 31 Dec 2006 13:00:33 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id 0F38E13C45B for ; Sun, 31 Dec 2006 13:00:33 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id kBVD0WK2070243 for ; Sun, 31 Dec 2006 13:00:32 GMT (envelope-from rdivacky@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id kBVD0Weo070231 for perforce@freebsd.org; Sun, 31 Dec 2006 13:00:32 GMT (envelope-from rdivacky@FreeBSD.org) Date: Sun, 31 Dec 2006 13:00:32 GMT Message-Id: <200612311300.kBVD0Weo070231@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rdivacky@FreeBSD.org using -f From: Roman Divacky To: Perforce Change Reviews Cc: Subject: PERFORCE change 112352 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 Dec 2006 13:00:33 -0000 http://perforce.freebsd.org/chv.cgi?CH=112352 Change 112352 by rdivacky@rdivacky_witten on 2006/12/31 13:00:07 Fix style in linux_rt_sigtimedwait. Affected files ... .. //depot/projects/linuxolator/src/sys/compat/linux/linux_signal.c#6 edit Differences ... ==== //depot/projects/linuxolator/src/sys/compat/linux/linux_signal.c#6 (text+ko) ==== @@ -429,9 +429,6 @@ linux_rt_sigtimedwait(struct thread *td, struct linux_rt_sigtimedwait_args *args) { -#ifdef DEBUG - struct proc *p = td->td_proc; -#endif int error; l_timeval ltv; struct timeval tv; @@ -446,25 +443,26 @@ printf(ARGS(rt_sigtimedwait, "*")); #endif if (args->sigsetsize != sizeof(l_sigset_t)) - return(EINVAL); + return (EINVAL); if ((error = copyin(args->mask, &lset, sizeof(lset)))) - return(error); + return (error); linux_to_bsd_sigset(&lset, &bset); tsa = NULL; if (args->timeout) { if ((error = copyin(args->timeout, <v, sizeof(ltv)))) - return(error); + return (error); #ifdef DEBUG if (ldebug(rt_sigtimedwait)) - printf("Linux-emul rt_sigtimedwait (%d): incoming timeout (%d/%d)\n", - p->p_pid, ltv.tv_sec, ltv.tv_usec); + printf(LMSG("linux_rt_sigtimedwait: incoming timeout (%d/%d)\n"), + ltv.tv_sec, ltv.tv_usec); #endif tv.tv_sec = (long)ltv.tv_sec; tv.tv_usec = (suseconds_t)ltv.tv_usec; if (itimerfix(&tv)) { - /* The timeout was invalid. Convert it to something + /* + * The timeout was invalid. Convert it to something * valid that will act as it does under Linux. */ tv.tv_sec += tv.tv_usec / 1000000; @@ -474,11 +472,11 @@ tv.tv_usec += 1000000; } if (tv.tv_sec < 0) - timevalclear(&tv); + timevalclear(&tv); #ifdef DEBUG if (ldebug(rt_sigtimedwait)) - printf("Linux-emul rt_sigtimedwait (%d): converted timeout (%d/%ld)\n", - p->p_pid, tv.tv_sec, tv.tv_usec); + printf(LMSG("linux_rt_sigtimedwait: converted timeout (%d/%ld)\n"), + tv.tv_sec, tv.tv_usec); #endif } TIMEVAL_TO_TIMESPEC(&tv, &ts); @@ -487,11 +485,10 @@ error = kern_sigtimedwait(td, bset, &info, tsa); #ifdef DEBUG if (ldebug(rt_sigtimedwait)) - printf("Linux-emul rt_sigtimedwait (%ld): sigtimedwait returning (%d)\n", - (long)p->p_pid, error); + printf(LMSG("linux_rt_sigtimedwait: sigtimedwait returning (%d)\n"), error); #endif if (error) - return error; + return (error); if (args->ptr) { memset(&linfo, 0, sizeof(linfo)); @@ -504,11 +501,10 @@ PROC_LOCK(td->td_proc); tdsignal(td->td_proc, td, info.ksi_signo, &info); PROC_UNLOCK(td->td_proc); - } else { + } else td->td_retval[0] = info.ksi_signo; - } - return error; + return (error); } int