[casper] Call for awesome commits

2015-05-27 Thread Jack Hickish
Hi All,

I believe I have a version of the QDR block / software that works at
every conceivable clock frequency anyone could want. Tomorrow
(Berkeley time), I'm going to merge this into the main casper-astro
github repository. This seems like as good a time as any to ask: does
anyone have any bugfixes/features/new blocks they would like to add to
the main repository? So far I've got the following

-- everything in ska-sa as of now. (I based my fix off ska-sa:master)
-- tweaked qdr interface
-- remove spaces from xps blocks (because that now throws errors)
-- add a "ucf" yellow block to add custom constraints to models

If you have suggestions/requests, feel free to raise github pull
requests or email me repo addresses / commit hashes / patches / other
useful info. If you want to contribute something but aren't sure
exactly how best to do this, just drop me an email and we'll figure
something out!

Cheers,
Jack



[casper] constraints for qdr2/ROACH2

2015-05-27 Thread Homin Jiang
Dear All:

Recently i found out the locations I/O pins for qdr2/ROACH2 are not in the
same FPGA area.(from the Planahead/device map). Some of them are in the
left edge of the device, and some of them are in the middle of the device.
Is there someone experienced this problem and have constraints in hand to
share with ?

regards
homin jiang


Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread David MacMahon
Hi, Brad,

On May 27, 2015, at 1:15 PM, Brad Dober wrote:

> Kernel command line: console=ttyS0,115200 
> mtdparts=physmap-flash.0:1792k(linux),256k@0x1c(fdt),8192k@0x20(root),54656k@0xa0(usr),256k@0x3f6(env),384k@0x3fa(uboot)fdt_addr=0xfc1c
>  root=192.168.40.1:/srv/roach_boot/etch ip=dhcp

I think you want "root=/dev/nfs rootpath=192.168.40.1:/srv/roach_boot/etch" 
instead of "root=192.168.40.1:/srv/roach_boot/etch".

Interrupt the u-boot startup and run "printenv" to see how this line gets 
constructed, then fix it, then run "saveenv" nd reboot.

The fact that this roach1 gets this far indicates that something is bad with 
the other one.

Dave




Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread John Ford
There was a very long thread about this new problem a few weeks ago. 
Bottom line is that it's likely that your host isn't exporting the
filesystem correctly, there's a typo in the DHCP offer, or some other such
host problem.  Look in the mail archives...

John


> So I plugged my other Roach1 that's in the lab into where the troubled
> Roach1 was sitting and started up the netboot. The uImage transferred fine
> this time, but I got another problem: *VFS: Unable to mount root fs via
> NFS, trying floppy.*
> *VFS: Cannot open root device "192.168.40.1:/srv/roach_boot/etch" or
> unknown-block(2,0)*
> *Please append a correct "root=" boot option; here are the available
> partitions:*
>
> Full boot up dump below:
>
> Hit any key to stop autoboot: 10 \0x08\0x08\0x08 0
>
> => run netboot
>
> Waiting for PHY auto negotiation to complete.. done
>
> ENET Speed is 100 Mbps - FULL duplex connection (EMAC0)
>
> BOOTP broadcast 1
>
> DHCP client bound to address 192.168.100.51
>
> Using ppc_4xx_eth0 device
>
> TFTP from server 192.168.40.1; our IP address is 192.168.100.51
>
> Filename 'uImage'.
>
> Load address: 0x40
>
> Loading:
> *\0x08#
>
> \0x09 #
>
> \0x09 #
>
> \0x09 #
>
> \0x09 
>
> done
>
> Bytes transferred = 1390149 (153645 hex)
>
> ## Booting kernel from Legacy Image at 0040 ...
>
> Image Name: Linux-2.6.25-svn3489
>
> Image Type: PowerPC Linux Kernel Image (gzip compressed)
>
> Data Size: 1390085 Bytes = 1.3 MB
>
> Load Address: 
>
> Entry Point: 
>
> Verifying Checksum ... OK
>
> Uncompressing Kernel Image ... OK
>
>
> id mach(): done
>
>
>
> MMU:enter
>
>
>
> MMU:hw init
>
>
>
> MMU:mapin
>
>
>
> MMU:setio
>
>
>
> MMU:exit
>
>
>
> setup_arch: enter
>
>
>
> setup_arch: bootmem
>
>
>
> ocp: exit
>
>
>
> arch: exit
>
>
> Linux version 2.6.25-svn3489 (dave@lapster) (gcc version 4.2.2) #6 Fri Aug
> 12 09:36:28 SAST 2011
>
> AMCC PowerPC 440EPx Roach Platform
>
> Zone PFN ranges:
>
> DMA 0 -> 131071
>
> Normal 131071 -> 131071
>
> Movable zone start PFN for each node
>
> early_node_map[1] active PFN ranges
>
> 0: 0 -> 131071
>
> Built 1 zonelists in Zone order, mobility grouping on. Total pages: 130048
>
> Kernel command line: console=ttyS0,115200
> mtdparts=physmap-flash.0:1792k(linux),256k@0x1c(fdt),8192k@0x20
> (root),54656k@0xa0(usr),256k@0x3f6(env),384k@0x3fa(uboot)fdt_addr=0xfc1c
> root=192.168.40.1:/srv/roach_boot/etch ip=dhcp
>
> PID hash table entries: 2048 (order: 11, 8192 bytes)
>
> console [ttyS0] enabled
>
> Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
>
> Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
>
> Memory: 516608k available (2084k kernel code, 720k data, 132k init, 0k
> highmem)
>
> Mount-cache hash table entries: 512
>
> BORPH version CVS-$Revision: 1.10 $ Initialized
>
> net_namespace: 152 bytes
>
> NET: Registered protocol family 16
>
>
>
> PCI: Probing PCI hardware
>
> SCSI subsystem initialized
>
> usbcore: registered new interface driver usbfs
>
> usbcore: registered new interface driver hub
>
> usbcore: registered new device driver usb
>
> NET: Registered protocol family 2
>
> IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
>
> TCP established hash table entries: 16384 (order: 5, 131072 bytes)
>
> TCP bind hash table entries: 16384 (order: 4, 65536 bytes)
>
> TCP: Hash tables configured (established 16384 bind 16384)
>
> TCP reno registered
>
> hwrtype_roach version CVS-$Revision: 1.1 $ registered
>
> JFFS2 version 2.2. (NAND) \0xc2\0xa9 2001-2006 Red Hat, Inc.
>
> io scheduler noop registered (default)
>
> Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
>
> serial8250: ttyS0 at MMIO 0x0 (irq = 0) is a 16550A
>
> serial8250: ttyS1 at MMIO 0x0 (irq = 1) is a 16550A
>
> serial8250: ttyS2 at MMIO 0x0 (irq = 35) is a 16550A
>
> serial8250: ttyS3 at MMIO 0x0 (irq = 36) is a 16550A
>
> brd: module loaded
>
> PPC 4xx OCP EMAC driver, version 3.54
>
> mal0: initialized, 2 TX channels, 2 RX channels
>
> rgmii0: input 0 in RGMII mode
>
> eth0: emac0, MAC 02:00:00:02:01:02
>
> eth0: found Generic MII PHY (0x1e)
>
> rgmii0: input 1 in RGMII mode
>
> emac1: can't find PHY!
>
> tun: Universal TUN/TAP device driver, 1.6
>
> tun: (C) 1999-2004 Max Krasnyansky 
>
> Driver 'sd' needs updating - please use bus_type methods
>
> physmap platform flash device: 0400 at fc00
>
> physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank
>
> Amd/Fujitsu Extended Query Table at 0x0040
>
> physmap-flash.0: CFI does not contain boot bank location. Assuming top.
>
> number of CFI chips: 1
>
> cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
>
> mtd: bad character after partition (f)
>
> 6 cmdli

Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread Brad Dober
So I plugged my other Roach1 that's in the lab into where the troubled
Roach1 was sitting and started up the netboot. The uImage transferred fine
this time, but I got another problem: *VFS: Unable to mount root fs via
NFS, trying floppy.*
*VFS: Cannot open root device "192.168.40.1:/srv/roach_boot/etch" or
unknown-block(2,0)*
*Please append a correct "root=" boot option; here are the available
partitions:*

Full boot up dump below:

Hit any key to stop autoboot: 10 \0x08\0x08\0x08 0

=> run netboot

Waiting for PHY auto negotiation to complete.. done

ENET Speed is 100 Mbps - FULL duplex connection (EMAC0)

BOOTP broadcast 1

DHCP client bound to address 192.168.100.51

Using ppc_4xx_eth0 device

TFTP from server 192.168.40.1; our IP address is 192.168.100.51

Filename 'uImage'.

Load address: 0x40

Loading:
*\0x08#

\0x09 #

\0x09 #

\0x09 #

\0x09 

done

Bytes transferred = 1390149 (153645 hex)

## Booting kernel from Legacy Image at 0040 ...

Image Name: Linux-2.6.25-svn3489

Image Type: PowerPC Linux Kernel Image (gzip compressed)

Data Size: 1390085 Bytes = 1.3 MB

Load Address: 

Entry Point: 

Verifying Checksum ... OK

Uncompressing Kernel Image ... OK


id mach(): done



MMU:enter



MMU:hw init



MMU:mapin



MMU:setio



MMU:exit



setup_arch: enter



setup_arch: bootmem



ocp: exit



arch: exit


Linux version 2.6.25-svn3489 (dave@lapster) (gcc version 4.2.2) #6 Fri Aug
12 09:36:28 SAST 2011

AMCC PowerPC 440EPx Roach Platform

Zone PFN ranges:

DMA 0 -> 131071

Normal 131071 -> 131071

Movable zone start PFN for each node

early_node_map[1] active PFN ranges

0: 0 -> 131071

Built 1 zonelists in Zone order, mobility grouping on. Total pages: 130048

Kernel command line: console=ttyS0,115200
mtdparts=physmap-flash.0:1792k(linux),256k@0x1c(fdt),8192k@0x20
(root),54656k@0xa0(usr),256k@0x3f6(env),384k@0x3fa(uboot)fdt_addr=0xfc1c
root=192.168.40.1:/srv/roach_boot/etch ip=dhcp

PID hash table entries: 2048 (order: 11, 8192 bytes)

console [ttyS0] enabled

Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)

Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)

Memory: 516608k available (2084k kernel code, 720k data, 132k init, 0k
highmem)

Mount-cache hash table entries: 512

BORPH version CVS-$Revision: 1.10 $ Initialized

net_namespace: 152 bytes

NET: Registered protocol family 16



PCI: Probing PCI hardware

SCSI subsystem initialized

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

NET: Registered protocol family 2

IP route cache hash table entries: 4096 (order: 2, 16384 bytes)

TCP established hash table entries: 16384 (order: 5, 131072 bytes)

TCP bind hash table entries: 16384 (order: 4, 65536 bytes)

TCP: Hash tables configured (established 16384 bind 16384)

TCP reno registered

hwrtype_roach version CVS-$Revision: 1.1 $ registered

JFFS2 version 2.2. (NAND) \0xc2\0xa9 2001-2006 Red Hat, Inc.

io scheduler noop registered (default)

Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled

serial8250: ttyS0 at MMIO 0x0 (irq = 0) is a 16550A

serial8250: ttyS1 at MMIO 0x0 (irq = 1) is a 16550A

serial8250: ttyS2 at MMIO 0x0 (irq = 35) is a 16550A

serial8250: ttyS3 at MMIO 0x0 (irq = 36) is a 16550A

brd: module loaded

PPC 4xx OCP EMAC driver, version 3.54

mal0: initialized, 2 TX channels, 2 RX channels

rgmii0: input 0 in RGMII mode

eth0: emac0, MAC 02:00:00:02:01:02

eth0: found Generic MII PHY (0x1e)

rgmii0: input 1 in RGMII mode

emac1: can't find PHY!

tun: Universal TUN/TAP device driver, 1.6

tun: (C) 1999-2004 Max Krasnyansky 

Driver 'sd' needs updating - please use bus_type methods

physmap platform flash device: 0400 at fc00

physmap-flash.0: Found 1 x16 devices at 0x0 in 16-bit bank

Amd/Fujitsu Extended Query Table at 0x0040

physmap-flash.0: CFI does not contain boot bank location. Assuming top.

number of CFI chips: 1

cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.

mtd: bad character after partition (f)

6 cmdlinepart partitions found on MTD device physmap-flash.0

Creating 6 MTD partitions on "physmap-flash.0":

0x-0x001c : "linux"

0x001c-0x0020 : "fdt"

0x0020-0x00a0 : "root"

0x00a0-0x03f6 : "usr"

0x03f6-0x03fa : "env"

0x03fa-0x0400 : "uboot"

ppc-soc-ohci ppc-soc-ohci.0: USB Host Controller

ppc-soc-ohci ppc-soc-ohci.0: new USB bus registered, assigned bus number 1

ppc-soc-ohci ppc-soc-ohci.0: irq 21, io mem 0xe400

usb usb1: configuration #1 chosen from 1 choice

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 1 port detected

usb usb1:

Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread David MacMahon
Hi, Brad,

On May 27, 2015, at 9:37 AM, Brad Dober wrote:

> I have no issues with the Roach2 that is also connected to this host computer.

No issues meaning that you can tftp the uImage file from the server to the 
roach2?  Does tcpdump/wireshark show any clues vis a vis the ROACH1's attempted 
tftp transfer?

> I switched the Roach1's and Roach'2 ethernet cables and still have the same 
> problem on the Roach1 and Roach2 is still working fine.

Did this also swap the switch ports?

> Which pins / voltages should I be checking on the power supply?

I'd check all of them.  I think it's a standard ATX power supply, but the wiki 
might have more details.

Maybe try reseating (or replacing) the ROACH1 PPC's DIMM module?  I guess it 
was working OK with soloboot/usbboot until the root filesystem got corrupted, 
so maybe this isn't really relevant?

> U-Boot 2008.10-svn3231 (Jul 15 2010 - 14:58:38)

I don't know of any specific problems, but you might want to consider updating 
uboot...

https://casper.berkeley.edu/wiki/ROACH_kernel_uboot_update

https://casper.berkeley.edu/wiki/LatestVersions

Dave




Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread Brad Dober
I have no issues with the Roach2 that is also connected to this host
computer.
I switched the Roach1's and Roach'2 ethernet cables and still have the same
problem on the Roach1 and Roach2 is still working fine.

Which pins / voltages should I be checking on the power supply?


Brad Dober
Ph.D. Candidate
Department of Physics and Astronomy
University of Pennsylvania
Cell: 262-949-4668

On Wed, May 27, 2015 at 11:59 AM, David MacMahon 
wrote:

> Hi, Brad,
>
> On May 27, 2015, at 8:09 AM, Brad Dober wrote:
>
> > TFTP from server 192.168.40.1; our IP address is 192.168.100.50
> > Filename 'uImage'.
> > Load address: 0x40
> > Loading: *\0x08###T T T #T ##T T T #T ##T T #
>
> The 'T' characters are timeouts waiting for data from the tftp server.
> The '#' characters show that some data is getting through.  This suggests
> an intermittent communication problem and/or marginal operating
> conditions.  Have you tried a different (and known good) network cable?
> Can other hosts (e.g. a laptop) DHCP and tftp from the server OK?  Have you
> checked the ROACH1 power supply voltages?
>
> Dave
>
>


Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread David MacMahon
Hi, Brad,

On May 27, 2015, at 8:09 AM, Brad Dober wrote:

> TFTP from server 192.168.40.1; our IP address is 192.168.100.50
> Filename 'uImage'.
> Load address: 0x40
> Loading: *\0x08###T T T #T ##T T T #T ##T T #

The 'T' characters are timeouts waiting for data from the tftp server.  The '#' 
characters show that some data is getting through.  This suggests an 
intermittent communication problem and/or marginal operating conditions.  Have 
you tried a different (and known good) network cable?  Can other hosts (e.g. a 
laptop) DHCP and tftp from the server OK?  Have you checked the ROACH1 power 
supply voltages?

Dave




Re: [casper] Roach1 Host name lookup error.

2015-05-27 Thread Brad Dober
So this is new. When I rebooted to check the boot process, it took the IP
address immediately, started loading Uboot, but restarted around block 162.
Wireshark shows multiple packets of the same number being send and
acknowledged.

Yes, I'm using dnsmasq.


U-Boot 2008.10-svn3231 (Jul 15 2010 - 14:58:38)


CPU: AMCC PowerPC 440EPx Rev. A at 533.333 MHz (PLB=133, OPB=66, EBC=66 MHz)

No Security/Kasumi support

Bootstrap Option C - Boot ROM Location EBC (16 bits)

32 kB I-Cache 32 kB D-Cache

Board: Roach

I2C: ready

DTT: 1 is 27 C

DRAM: (spd v1.2) dram: notice: ecc ignored

1 GB

FLASH: 64 MB

USB: Host(int phy) Device(ext phy)

Net: ppc_4xx_eth0


Roach Information

Serial Number: 030191

Monitor Revision: 8.3.1698

CPLD Revision: 8.0.1588


type run netboot to boot via dhcp+tftp+nfs

type run soloboot to run from flash without network

type run mmcboot to boot using filesystem on mmc/sdcard

type run usbboot to boot using filesystem on usb

type run bit to run tests


Hit any key to stop autoboot: 2 \0x08\0x08\0x08 0

=> run netboot

Waiting for PHY auto negotiation to complete.. done

ENET Speed is 100 Mbps - FULL duplex connection (EMAC0)

BOOTP broadcast 1

BOOTP broadcast 2

DHCP client bound to address 192.168.100.50

Using ppc_4xx_eth0 device

TFTP from server 192.168.40.1; our IP address is 192.168.100.50

Filename 'uImage'.

Load address: 0x40

Loading: *\0x08###T T T #T ##T T T #T ##T T #

Retry count exceeded; starting again

BOOTP broadcast 1

DHCP client bound to address 192.168.100.50

Using ppc_4xx_eth0 device

TFTP from server 192.168.40.1; our IP address is 192.168.100.50

Filename 'uImage'.

Load address: 0x40

Loading: *\0x08T T T #T #T T T T T T

Retry count exceeded; starting again

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

BOOTP broadcast 4

DHCP client bound to address 192.168.100.50

Using ppc_4xx_eth0 device

TFTP from server 192.168.40.1; our IP address is 192.168.100.50

Filename 'uImage'.

Load address: 0x40

Loading: *\0x08##T #T T T





Brad Dober
Ph.D. Candidate
Department of Physics and Astronomy
University of Pennsylvania
Cell: 262-949-4668

On Tue, May 26, 2015 at 11:17 PM, David MacMahon 
wrote:

> Nothing obvious comes to mind (yet).  Can you watch the roach1 boot
> process via serial console?  What does that show?  Are you using dnsmasq
> for the DHCP server?  What if you try direct connect with mii-tool to set
> the speed of eth1 to 100 Mbps?
>
> Dave
>
> On May 26, 2015, at 5:00 PM, Brad Dober wrote:
>
> > Hi Dave,
> >
> > Here is the configuration of the network. The host computer, a ROACH1
> and a working ROACH2 running in soloboot are the only ones connected. The
> host is 192.168.40.1 and is offering 192.168.100.50 and the ROACH2 is
> assigned to 192.168.40.50. Is there anything weird about how the ROACH1
> handles larger subnets like below? Or maybe infinite address leases?
> >
> > eth1  Link encap:Ethernet  HWaddr 00:08:54:54:d3:f5
> >   inet addr:192.168.40.1  Bcast:192.168.255.255  Mask:255.255.0.0
> >   inet6 addr: fe80::208:54ff:fe54:d3f5/64 Scope:Link
> >   UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
> >   RX packets:705 errors:0 dropped:0 overruns:0 frame:0
> >   TX packets:1377 errors:0 dropped:0 overruns:0 carrier:0
> >   collisions:0 txqueuelen:1000
> >   RX bytes:210574 (210.5 KB)  TX bytes:302407 (302.4 KB)
> >   Interrupt:20 Base address:0x6000
> >
> > Here is the tcpdump:
> >
> > tcpdump: listening on eth1, link-type EN10MB (Ethernet), capture size
> 65535 bytes
> > 19:46:49.968388 02:00:00:03:01:91 > ff:ff:ff:ff:ff:ff, ethertype IPv4
> (0x0800), length 343: (tos 0x0, ttl 255, id 225, offset 0, flags [DF],
> proto UDP (17), length 329)
> > 0.0.0.0.68 > 255.255.255.255.67: BOOTP/DHCP, Request from
> 02:00:00:03:01:91, length 301, xid 0x144252, secs 1130, Flags [none]
> > Client-Ethernet-Address 02:00:00:03:01:91
> > Vendor-rfc1048 Extensions
> >   Magic Cookie 0x63825363
> >   DHCP-Message Option 53, length 1: Discover
> >   MSZ Option 57, length 2: 576
> >   Parameter-Request Option 55, length 5:
> > Subnet-Mask, Default-Gateway, Hostname, BS
> > RP
> > 19:46:49.968953 00:08:54:54:d3:f5 > 02:00:00:03:01:91, ethertype IPv4
> (0x0800), length 349: (tos 0x0, ttl 64, id 33388, offset 0, flags [none],
> proto UDP (17), length 335)
> > 192.168.40.1.67 > 192.168.100.50.68: BOOTP/DHCP, Reply, length 307,
> xid 0x144252, secs 1130, Flags [none]
> > Your-IP 192.168.100.50
> > Server-IP 192.168.40.1
> > Client-Ethernet-Address 02:00:00:03:01:91
> > file "uImage"
> > Vendor-rfc1048 Extensions
> >   Magic Cookie 0x63825363
> >   DHCP-Message Option 53, length 1: Offer
> >   Server-ID Option 54, length 4: 192.168.40.1
> >   Lease-Time Option 51, length 4: 4294967295
> >   Subnet-Mask Option 1,