From owner-cvs-src-old@FreeBSD.ORG Thu Dec 2 12:45:08 2010 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 320C3106564A for ; Thu, 2 Dec 2010 12:45:08 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 17D868FC14 for ; Thu, 2 Dec 2010 12:45:08 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.4/8.14.4) with ESMTP id oB2Cj7eT006662 for ; Thu, 2 Dec 2010 12:45:07 GMT (envelope-from kib@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.4/8.14.4/Submit) id oB2Cj7Dd006661 for cvs-src-old@freebsd.org; Thu, 2 Dec 2010 12:45:07 GMT (envelope-from kib@repoman.freebsd.org) Message-Id: <201012021245.oB2Cj7Dd006661@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to kib@repoman.freebsd.org using -f From: Konstantin Belousov Date: Thu, 2 Dec 2010 12:44:51 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/fs/procfs procfs_fpregs.c procfs_regs.c X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2010 12:45:08 -0000 kib 2010-12-02 12:44:51 UTC FreeBSD src repository Modified files: sys/fs/procfs procfs_fpregs.c procfs_regs.c Log: SVN rev 216120 on 2010-12-02 12:44:51Z by kib For non-stopped threads, td_frame pointer is undefined. As a consequence, fill_regs() and fill_fpregs() access random data, usually on the thread kernel stack. Most often the td_frame points to the previous frame saved by last kernel entry sequence, but this is not guaranteed. For /proc//{regs,fpregs} read access, require the thread to be in stopped state. Otherwise, return EBUSY as is done for write case. Reported and tested by: pho Approved by: des (procfs maintainer) MFC after: 1 week Revision Changes Path 1.36 +4 -0 src/sys/fs/procfs/procfs_fpregs.c 1.35 +4 -0 src/sys/fs/procfs/procfs_regs.c