[Barrelfish-users] 答复: barrelfish on scc, how to ping the cores

Pravin shindep at student.ethz.ch
Tue Mar 6 12:38:33 CET 2012


Hi Zhuwangbin,

By looking at your menu.lst.scc and output, my understanding is that
you are using PHY connection 0 out of 4 PHY ethernet ports provided by
SCC.  Unfortunately, the eMAC driver was programmed to work with PHY
2.  This is mostly due to some hard-coded function calls in file
usr/drivers/eMAC/eMAC_hwinit.c.  You can find these function calls by
searching for a string "eMAC_eMAC2_".  In all these function calls,
eMAC2 specifies that PHY2 is to be used.  Ideally this should have
been decided by device-id provided as command line argument, but this
driver was written in little hurry and hence ended up having
hard-coded PHY.

So, my suggestion will be to re-connect the ethernet cable to PHY2 on
SCC and modify the menu.lst.scc accordingly, and hopefully this should
work.  Other option is to keep the ethernet cable on PHY0 and edit
eMAC_hwinit.c to replace "eMAC_eMAC2_" with "eMAC_eMAC0_".  I have
attached a patch with this email for this.  As per my understanding,
this patch should work, but I haven't tested it!  So, I can't assure
that it will work.  I would recommend connecting the cable to PHY2, as
we know that our code works with PHY2.

I hope this helps.
Pravin

2012/3/6 Zhuwangbin <zhuwangbin at huawei.com>:
> Hi Simon,
>
> Thank you for your reply, my /opt/sccKit/systemSettings.ini is as follows:
>
> [General]
> CRBServer=192.168.2.127:5010
> memorySize=8
> platform=RockyLake
> maxTransId=64
> sccGateway=192.168.10.254
> sccFirstMac=00:45:4D:41:44:31
> sccHostIp=192.168.10.254
> sccFirstIp=192.168.10.1
> sccMacEnable=a
>
> and emac a is functional when I boot the sccLinux.
>
> Wangbin Zhu
>
> -----邮件原件-----
> 发件人: Simon Peter [mailto:speter at inf.ethz.ch]
> 发送时间: 2012年3月6日 18:31
> 收件人: Zhuwangbin
> 抄送: barrelfish-users at lists.inf.ethz.ch
> 主题: Re: [Barrelfish-users] barrelfish on scc, how to ping the cores
>
> Hi Zhuwangbin,
>
> The performance meter widget isn't supported by Barrelfish. It seems the
> system came up just fine. You might want to make sure the driver is
> actually speaking to eMAC a. Is the printed MAC address the one you
> would expect?
>
> Simon
>
> On 06.03.2012 07:56, Zhuwangbin wrote:
>> Hi all,
>>
>> I’m trying to run barrelfish(release2012-01-30) on scc(sccKit 1.4.2 with
>> emac enabled, the port is emac a), but I can’t ping the cores, and in
>> the SCC performance meter widget, I can’t see any alive cores.
>>
>> The menu.lst.scc is as follows:
>>
>> timeout 0
>>
>> # spawnd is used to control which cpus are booted
>>
>> #
>>
>> # "spawnd boot" will use the skb and pci to figure out and
>>
>> # boot all cores in the machine
>>
>> #
>>
>> # "spawnd boot bootscc=1-6" will not use the skb and
>>
>> # boot the list of cores passed as argument.
>>
>> # The hardware id of the cores to boot should be specified.
>>
>> # This list may not include the bsp core id.
>>
>> title Barrelfish
>>
>> root (nd)
>>
>> kernel /scc/sbin/cpu loglevel=4
>>
>> module /scc/sbin/cpu
>>
>> module /scc/sbin/init
>>
>> # Domains spawned by init
>>
>> module /scc/sbin/mem_serv
>>
>> module /scc/sbin/monitor
>>
>> module /scc/sbin/chips boot
>>
>> module /scc/sbin/ramfsd boot
>>
>> module /scc/sbin/spawnd boot bootscc=1
>>
>> module /scc/sbin/startd boot
>>
>> # modules needed to start the networking
>>
>> module /scc/sbin/eMAC core=0 device=0
>>
>> module /scc/sbin/netd core=0 cardname=eMAC0_0
>>
>> module /scc/sbin/eMAC core=1 device=0
>>
>> module /scc/sbin/netd core=1 cardname=eMAC0_1
>>
>> module /scc/sbin/echoserver core=1 cardname=eMAC0_1
>>
>> # RCK memory map
>>
>> # Everything up til VGA is private RAM (maybe we want to throw it away)
>>
>> mmap map 0x0 0xa000 2
>>
>> # Everything after VGA is private RAM (we also live in this area)
>>
>> mmap map 0xe800 0x26ff1800 1
>>
>> # Shared RAM (over all MCs) in the middle of address space
>>
>> #mmap map 0x80000000 0x4000000 1
>>
>> mmap map 0x80000000 0x40000000 1
>>
>> # At the very end we have some platform memory (bootup EEPROM)
>>
>> mmap map 0xfffc0000 0x40000 2
>>
>> and the output is as follows(cat /dev/crbif0rb0c0ttyS0):
>>
>> Kernel starting at address 0x80100000
>>
>> My APIC ID: 0
>>
>> Barrelfish CPU driver starting on scc core 0
>>
>> init: invoked as: init 2097152
>>
>> Spawning memory server (scc/sbin/mem_serv)...
>>
>> Spawning monitor (scc/sbin/monitor)...
>>
>> starting monitor as 'scc/sbin/monitor 327680 '
>>
>> monitor: invoked as: scc/sbin/monitor 327680
>>
>> RAM allocator initialised, 1608 MB (of 1624 MB) available
>>
>> Spawning chips on core 0
>>
>> Spawning /scc/sbin/ramfsd on core 0
>>
>> Spawning /scc/sbin/spawnd on core 0
>>
>> Spawning /scc/sbin/startd on core 0
>>
>> chips: client waiting for ramfs
>>
>> ramfsd.0: pre-populating from boot image...
>>
>> chips: client waiting for ramfs
>>
>> ramfsd.0: /scc/sbin/eMAC already exists, skipping it
>>
>> ramfsd.0: /scc/sbin/netd already exists, skipping it
>>
>> ramfsd.0: ready
>>
>> chips: notifying client about ramfs
>>
>> chips: notifying client about ramfs
>>
>> kernel 0: Allocating RAM at 0x80000000 uninitialized
>>
>> kernel 0: Allocating RAM at 0x80010000 uninitialized
>>
>> spawnd.0: coreid 1 is arch id 1
>>
>> chips: client waiting for all_spawnds_up
>>
>> Monitor 0: booting scc core 1 as '/scc/sbin/cpu'
>>
>> kernel 0: Allocating RAM at 0x80020000 uninitialized
>>
>> all 2 monitors up
>>
>> chips: client waiting for spawn.1.ready
>>
>> chips: notifying client about spawn.1.ready
>>
>> chips: client waiting for all_spawnds_up
>>
>> chips: notifying client about all_spawnds_up
>>
>> chips: notifying client about all_spawnds_up
>>
>> startd.0: starting app /scc/sbin/eMAC on core 0
>>
>> spawnd.0: spawning /scc/sbin/eMAC on core 0
>>
>> startd.0: starting app /scc/sbin/netd on core 0
>>
>> Starting EMAC for hardware
>>
>> #### base 13000000, 2097152
>>
>> #### myroute = 0, 6 13
>>
>> #### phywsical addr 13000000
>>
>> Base mac address:[31:44:41:4d:45:00]
>>
>> Core MAC address:[31:45:41:4d:45:00]
>>
>> #### base 13200000, 2097152
>>
>> #### myroute = 0, 6 13
>>
>> spawnd.0: spawning /scc/sbin/netd on core 0
>>
>> startd.0: starting app /scc/sbin/eMAC on core 1
>>
>> kernel 0: Allocating RAM at 0x80021000 uninitialized
>>
>> #### [0] [BIG] [1] MEM_SIZE[31457280], MEMP_NUM_PBUF[256],
>> PBUF_POOL_SIZE[256], NR_PREALLOCATED_PBUFS[31], PBUF_POOL_BUFSIZE[256] ####
>>
>> memp_init: allocating 1e3fb memory for index 0
>>
>> @@@@@@ mem alloc 1e0001c, 1e0001c for index 1
>>
>> startd.0: starting app /scc/sbin/netd on core 1
>>
>> Allocating 31 pbufs
>>
>> pbuf is from buff 1 -------
>>
>> Registered 31 no. of pbufs for receiving -------
>>
>> ##################################################
>>
>> MAC address: 00:45:4d:41:45:31
>>
>> startd.0: starting app /scc/sbin/echoserver on core 1
>>
>> No bootscript
>>
>> chips: client waiting for eMAC0_1_CTRL
>>
>> Whether the barrelfish is successfully booted? I can’t ping the
>> cores(core0, core1). How can I access the cores?
>>
>> Many thanks for your help,
>>
>> Best regards,
>>
>> Wangbin Zhu
>>
>>
>>
>> _______________________________________________
>> Barrelfish-users mailing list
>> Barrelfish-users at lists.inf.ethz.ch
>> https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users
>
> _______________________________________________
> Barrelfish-users mailing list
> Barrelfish-users at lists.inf.ethz.ch
> https://lists.inf.ethz.ch/mailman/listinfo/barrelfish-users
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-patch
Size: 12202 bytes
Desc: not available
Url : https://lists.inf.ethz.ch/pipermail/barrelfish-users/attachments/20120306/9049b956/attachment.bin 


More information about the Barrelfish-users mailing list