From owner-freebsd-current@FreeBSD.ORG Wed Jul 16 02:46:19 2008 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F30F4106564A for ; Wed, 16 Jul 2008 02:46:19 +0000 (UTC) (envelope-from thinker@branda.to) Received: from msr20.hinet.net (msr20.hinet.net [168.95.4.120]) by mx1.freebsd.org (Postfix) with ESMTP id 580AC8FC12 for ; Wed, 16 Jul 2008 02:46:18 +0000 (UTC) (envelope-from thinker@branda.to) Received: from cowboy.branda.to (122-120-5-211.dynamic.hinet.net [122.120.5.211]) by msr20.hinet.net (8.9.3/8.9.3) with ESMTP id KAA14954 for ; Wed, 16 Jul 2008 10:30:54 +0800 (CST) Received: from cowboy.branda.to (localhost [127.0.0.1]) by cowboy.branda.to (8.14.2/8.14.2) with ESMTP id m6G2UvH2010430 for ; Wed, 16 Jul 2008 10:30:57 +0800 (CST) (envelope-from thinker@branda.to) Message-ID: <487D5D60.1010102@branda.to> Date: Wed, 16 Jul 2008 10:30:56 +0800 From: Thinker User-Agent: Thunderbird 2.0.0.14 (X11/20080701) MIME-Version: 1.0 To: freebsd-current@freebsd.org X-Enigmail-Version: 0.95.2 Content-Type: text/plain; charset=Big5 Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Wed, 16 Jul 2008 03:02:35 +0000 Subject: A patch of MBR for Vortex86 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Jul 2008 02:46:20 -0000 Hi all, DM&P is the vendor of Vortex86 series SoCs. As I know, most Vortex86 SoC chips have a hardware watchdog timer included. It can be configured to trigger PCIRST signal to reset the system. I have a driver for Vortex86 watchdog timer, it is here, http://www.freebsd.org/cgi/query-pr.cgi?pr=125409 The driver is compatible with watchdog(9). Although the driver seems work, but sometimes, for some reason, the system was hanged when kernel is still booting. So, I have a patch for mbr boot code to initialize the watchdog timer to reset the system if it is not been cleared in 20 minutes. It provides capability and chance to recover the system from hanging when booting. Following is the patch. If you have a Vortex86 board, maybe you can help me to test it. Thanks you! begin 644 mbr-vortex86-watchdog.diff M9&EF9B`M#@P"0DC($9L862!%1$0*(`H@"0DN#0W-0D)(R!.=6UB97(@;V8@:&%R9"!D"!I;FET:6%L('9A;'5E M(')E9RX**PD)+G-E="!65%A?5$E-14]55"PP>#4*(`H@"0DN9VQO8FP@0H@(R!O;F4@<&%R=&ET:6]N(&ES(&UA M&]R=R`E`HK"0EM;W9B("165%A?5$E-14]55"PE86P**PD);W5T8B`E86PL)61X"0D) M(R!65%A?5$E-14]55"`J(#0@;6EN`HK"0EM;W9B("0P M>&%C+"5A;`HK"0EO=71B("5A;"PE9'@**PHK"0EX;W)W("5S:2PE`D)(R!0 M87)T:71I;VX@=&%B;&4*(`D);6]V8B`D,'@T+"5C;`D)"2,@3G5M8F5R(&]F M(&5N=')I97,*(&UA:6XN,3H@"6-M<&(@)6-H+"@E8G@I"0D)(R!.=6QL(&5N %=')Y/PH` ` end