From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 3A0891381F3 for ; Mon, 3 Jun 2013 23:35:18 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id BF966E0A0B; Mon, 3 Jun 2013 23:35:14 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 64F7BE0A0B for ; Mon, 3 Jun 2013 23:35:09 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 6B7C033E1AC for ; Mon, 3 Jun 2013 23:35:03 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 2AD47E5469 for ; Mon, 3 Jun 2013 23:35:01 +0000 (UTC) From: "Richard Yao" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Richard Yao" Message-ID: <1367229291.108f1daf60acfb48e94cf025252ce9d8cb71191a.ryao@gentoo> Subject: [gentoo-commits] proj/genkernel:ryao commit in: defaults/ X-VCS-Repository: proj/genkernel X-VCS-Files: defaults/initrd.scripts defaults/linuxrc X-VCS-Directories: defaults/ X-VCS-Committer: ryao X-VCS-Committer-Name: Richard Yao X-VCS-Revision: 108f1daf60acfb48e94cf025252ce9d8cb71191a X-VCS-Branch: ryao Date: Mon, 3 Jun 2013 23:35:01 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 5e1c487e-5ed0-4bd3-808e-d4ca1dfcd8eb X-Archives-Hash: 3396a411cc034ea1897c7902dd220c5b commit: 108f1daf60acfb48e94cf025252ce9d8cb71191a Author: Fabio Erculiani sabayon org> AuthorDate: Thu Apr 25 15:55:56 2013 +0000 Commit: Richard Yao gentoo org> CommitDate: Mon Apr 29 09:54:51 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/genkernel.git;a=commit;h=108f1daf linuxrc: run the debug shell multiple times, add a hook before switch_root --- defaults/initrd.scripts | 1 + defaults/linuxrc | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts index c1969d1..9b0e899 100644 --- a/defaults/initrd.scripts +++ b/defaults/initrd.scripts @@ -1055,6 +1055,7 @@ rundebugshell() { if [ -n "$DEBUG" ] then good_msg 'Starting debug shell as requested by "debug" option.' + good_msg "Stopping by: ${1}" do_rundebugshell fi } diff --git a/defaults/linuxrc b/defaults/linuxrc index 1d26aaf..4bbe5e2 100644 --- a/defaults/linuxrc +++ b/defaults/linuxrc @@ -424,7 +424,7 @@ mkdir -p "${NEW_ROOT}" CHROOT="${NEW_ROOT}" # Run debug shell if requested -rundebugshell +rundebugshell "before setting up the root filesystem" if [ "${CDROOT}" = '1' ] then @@ -937,6 +937,9 @@ then bad_msg "ERROR: your real /dev is missing tty1, required for splash" fi +# Run debug shell if requested +rundebugshell "before entering switch_root" + exec /sbin/switch_root -c "/dev/console" "${CHROOT}" "${REAL_INIT:-/sbin/init}" "${INIT_OPTS}" # If we get here, something bad has happened