Hi everyone, I'm wondering if there is any safe way to reboot the board w/o rebooting the host system? I have the board installed in Linux and hated to reboot it just to rebooot the enp board. Thanks.
On Wed, Jul 17, 2002 at 05:15:03PM -0700, Tommy Tran wrote:
Hi everyone, I'm wondering if there is any safe way to reboot the board w/o rebooting the host system? I have the board installed in Linux and hated to reboot it just to rebooot the enp board. Thanks.
I don't know about the ENP-2505 board, but we reboot the evaluation systems all the time without rebooting Linux. The thing to watch for is that when the board is rebooted, it is taken off the PCI bus. Any accesses to the board will hang Linux. We deal with this in the VERA distribution by retaining the values of the PCI registers on the board when the device driver is started. If we ever reset the IXP1200 board, we run a program called "pcirestore" which uses the stored values to re-configure the board to be in the same place in the PCI address space as it was before the reset. Scott
You should be able to attach an external switch to the reset pins which appear on an external header. On Thu, 2002-07-18 at 05:13, Scott C. Karlin wrote:
On Wed, Jul 17, 2002 at 05:15:03PM -0700, Tommy Tran wrote:
Hi everyone, I'm wondering if there is any safe way to reboot the board w/o rebooting the host system? I have the board installed in Linux and hated to reboot it just to rebooot the enp board. Thanks.
I don't know about the ENP-2505 board, but we reboot the evaluation systems all the time without rebooting Linux. The thing to watch for is that when the board is rebooted, it is taken off the PCI bus. Any accesses to the board will hang Linux. We deal with this in the VERA distribution by retaining the values of the PCI registers on the board when the device driver is started. If we ever reset the IXP1200 board, we run a program called "pcirestore" which uses the stored values to re-configure the board to be in the same place in the PCI address space as it was before the reset.
Scott
Thank you all for your help in reboot the enp-2505 card. I ended up manually issuing the "reboot" command with minicom, quite minicom, ifconfig eth1 down, rmmod pciDgNet, rmmod pciDg, and then run the "bootixp" script to reboot. I have walked through 2 of the intel's "count packet" tutorial and see it works on the board. I'm wondering how do I start writing an application from scratch using the Inte's workbench (so that I can write code in Micro C and not in MicroCode). I want to be able to use the work bench and debug code using the workbench's debugger similar to "ms visual c++." Thanks.
works on the board. I'm wondering how do I start writing an application from scratch using the Inte's workbench (so that I can write code in Micro C and not in MicroCode). I want to be able to use the work bench and debug code using the workbench's debugger similar to "ms visual c++." Thanks.
For using the workbench and the debugger with the ENP-2505 card, you would need to do the following: - reserve a real IP address for the IXP card (Routable in your network ) - have another IP for the linux host side of the interface on the same subnet. - enable ip forwarding on the linux host Eg. if eth0 on the linux host is on the external network and eth1 is the pciDg device to the IXP, then set up proxy arp for the IXP's network address on eth0. This way, the linux host would do a proxy arp and then forward packets to the IXP. You should then be able to ping between the NT machine (which has the developer workbench) and the IXP. Once this is done, then to run an ACE sample (eg. tutorial1) using the workbench - * set mode=1 (downloading via workbench in ixsys.config) * Then run ./ixstart as usual * once it runs, you would see files such as ue0syms, ue1syms etc. in / on the board. Basically, in the workbench mode, the ixconfig app does not download the microcode, but creates these files with the symbol info to be patched. * This file contains the nam=value pairs for symbols that need to be patched into the microcode. Go to the workbench, define these symbols and rebuild the project. * Then download the .uof file generated by the workbench on to the target. * Then send packets again, you should be able to see them been recd. in the IXP Hope this helps. - Abhijeet
[Tommy wrote:]
Hi everyone, I'm wondering if there is any safe way to reboot the board w/o rebooting the host system? I have the board installed in Linux and hated to reboot it just to rebooot the enp board. Thanks.
[Scott wrote:]
I don't know about the ENP-2505 board, but we reboot the evaluation systems all the time without rebooting Linux. The thing to watch for
Hi Tommy, The ENP-2505 is nicer about this because it has the PCI bridge chip in it. The bridge chip's PCI registers survive at least a soft reset of the IXP (what you get if you type "reboot" to linux on the IXP). So you do not have to do anything special on the host if you just type reboot to linux on the IXP. If you do *hard* reset of the ENP-2505 (by making a wiring change to the board to short the two reset pins), I suspect you will have to save/restore the bridge chip registers as Scott describes. There's yet a third way to reset the IXP (a squishy reset?) which is to write one the PCI space configuration registers. We don't actively use this one since early experiments we did suggested it didn't actually reset everything and we had to resort to the hard reset. In practice, I've found that for the things we do the soft reset covers almost all the problems we have. As a result we've been lazy and not even wired up a hard reset on most of our boards. In other words, we do a soft reset if we can and for a hard reset reboot the workstation. The latter is sufficiently rare that it hasn't been an annoyance. Here's a script we use that uses kermit to log into a card (via serial in case the pciDg connection is hosed), issue the reboot command, then remove the drivers from the host making it ready to boot again. It's specific to our site (uses one of our drivers, has serial port assignments wired in etc) but gives you an idea of what you could do. Scripting these sorts of things will measureably lower your blood pressure... regards, -- Ken ---------------- #!/bin/sh # 30-May-02 # # RCS: $Id: unbootixp,v 1.1 2002/06/13 20:24:46 kenmac Exp $ # unbootixp #********************************************************************# # # # this script shuts down IXP cards so that they can be rebooted from # # scratch. To shut down a card, do this: # # # # PHASE 1: (per bv) invoke "reboot" on the card # # PHASE 2: ifconfig down, rmmod drivers # # # #********************************************************************# PATH=/bin:/sbin:/usr/sbin:/usr/bin:. DEVICE=eth2 PASSWORD=******* KERMIT=/usr/bin/kermit phase0 () { echo START PHASE 0 ON IXP $IXPNO rm -f /tmp/bootit.tmp touch /tmp/bootit.tmp echo set line $SERIAL_LINE >> /tmp/bootit.tmp echo set baud 38400 >> /tmp/bootit.tmp echo set carrier-watch off >> /tmp/bootit.tmp echo output \\13 >> /tmp/bootit.tmp echo input 10 ogin: >> /tmp/bootit.tmp echo output root\\13 >> /tmp/bootit.tmp echo input 10 ssword: >> /tmp/bootit.tmp echo output $PASSWORD\\13 >> /tmp/bootit.tmp echo input 10 \$ >> /tmp/bootit.tmp echo output reboot\\13 >> /tmp/bootit.tmp echo input 10 \$ >> /tmp/bootit.tmp echo output exit\\13 >> /tmp/bootit.tmp echo hangup >> /tmp/bootit.tmp echo exit >> /tmp/bootit.tmp $KERMIT /tmp/bootit.tmp -0 rm -f /tmp/bootit.tmp echo END PHASE 0 ON IXP $IXPNO } #*****************# # # # guts of phase 0 # # # #*****************# echo START PHASE 0 if [ -e /proc/driver/ixp0 ]; then IXPNO=0 CARDNO=1 CARD_INTERNAL_IP=192.168.0.2 SERIAL_LINE=/dev/ttyS1 phase0 fi if [ -e /proc/driver/ixp1 ]; then IXPNO=1 CARDNO=2 CARD_INTERNAL_IP=192.168.0.3 SERIAL_LINE=/dev/ttyS0 phase0 fi echo END PHASE 0 #*************************# # # # phase 1: remove drivers # # # #*************************# echo START PHASE 1 ifconfig $DEVICE down rmmod pciDgNet rmmod pciDg rmmod ixp1200 echo END PHASE 1 echo "Done unbooting. Wait 10 seconds before running bootixp"
participants (5)
-
Abhijeet Joglekar
-
Kenneth M. Mackenzie
-
Mandeep Baines
-
Scott C. Karlin
-
Tommy Tran