All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: Call for Gardening Tasks
@ 2020-04-20 17:05 Sui Chen
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Sui Chen @ 2020-04-20 17:05 UTC (permalink / raw)
  To: openbmc

[-- Attachment #1: Type: text/html, Size: 4684 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* about power control.回复: Call for Gardening Tasks
  2020-04-20 17:05 Call for Gardening Tasks Sui Chen
@ 2020-04-21 14:50 ` zhouyuanqing8
  2020-04-22  5:34   ` Li, Yong
                     ` (2 more replies)
  2020-04-21 23:18 ` Richard Hanley
  2020-04-23  3:58 ` Andrew Jeffery
  2 siblings, 3 replies; 9+ messages in thread
From: zhouyuanqing8 @ 2020-04-21 14:50 UTC (permalink / raw)
  To: Sui Chen, openbmc; +Cc: uperic, shinerocky

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="gb2312", Size: 6976 bytes --]

Hi

    This is a very good idea. As the first time to do openbmc, I look forward to it. Currently, I am being troubled by the problems you describe.

    The following questions, please also help you answer it, thank you very much.

    1.I modified the dts file, how to use the command "bitbake -f linux-aspeed" to Generate fitimage and dub£¿
     Now, I modify the dts file in the kernel source directory. When I compile, bitbake will re-fetch the source code, decompress, patch, configure, and compile, causing my changes to be overwritten. I currently use manual call scripts to compile dts files and make images for debugging.Is there a way to make bitbake skip the previous steps and compile directly£¿


     2.The size of image-rwfs is 0, I want to use rwfs debugging, how to configure to generate a normal image-rwfs?
     -rw-r--r--. 2 harleyzhou harleyzhou     9443             4ÔÂ        7 17:27 obmc-phosphor-image-xxh-20200407092558.rootfs.manifest
     -rw-r--r--. 2 harleyzhou harleyzhou 18214912         4ÔÂ    7 17:27 obmc-phosphor-image-xxh-20200407092558.rootfs.squashfs-xz
     -rw-rw-r--. 2 harleyzhou harleyzhou 33554432        4ÔÂ   7 17:27 obmc-phosphor-image-xxh-20200407092558.static.mtd
     -rw-rw-r--. 2 harleyzhou harleyzhou 33566720        4ÔÂ   7 17:28 obmc-phosphor-image-xxh-20200407092558.static.mtd.all.tar
     -rw-rw-r--. 2 harleyzhou harleyzhou 22384640        4ÔÂ   7 17:28 obmc-phosphor-image-xxh-20200407092558.static.mtd.tar
     -rw-r--r--. 2 harleyzhou harleyzhou   308218            4ÔÂ      7 17:27 obmc-phosphor-image-xxh-20200407092558.testdata.json
     -rw-r--r--. 2 harleyzhou harleyzhou           0               4ÔÂ   7 17:27 obmc-phosphor-image-xxh.jffs2


    3. I did not find the source code of "pgood_wait" and "power_control.exe" in obmc-op-control-power? where can I get it ?


    4.OpenBMC uses systemd<https://www.freedesktop.org/wiki/Software/systemd/> to manage all processes, So i analyzed the process of systemd starting process and saw "default.target-> basic.target-> sysinit.target-> local-fs.target", there is no content behind.please help to provide clues of systemd starting process.

    5.I understand the following execution process of power-on , help check if it is correct.
       a).rest or busctl send power-on commands to systemd through d-bus messages.
       b).systemd find the obmc-chassis-poweron@.target
        c).systemd find the obmc-power-start@.target
        d).systemd find the op-power-start@0.service
        e).systemd start a thread and execute "busctl call `mapper get-service /org/openbmc/control/power%i` /org/openbmc/control/power%i org.openbmc.control.Power setPowerState I 1"

appendix£º

ls obmc-chassis-poweron@0.target.requires

op-power-start@0.service  op-wait-power-on@0.service


cat obmc-chassis-poweron@.target

[Unit]

Description=Chassis%i (Power On)

Wants=multi-user.target

After=multi-user.target

Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service

After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service

Wants=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service

After=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service


cat op-power-start@0.service

[Unit]

Description=Start Power%i

Wants=obmc-power-start@%i.target

Before=obmc-power-start@%i.target

After=obmc-power-start-pre@%i.target

After=obmc-fan-control.target

Wants=mapper-wait@-org-openbmc-control-power%i.service

After=mapper-wait@-org-openbmc-control-power%i.service

[Service]

RemainAfterExit=yes

Type=oneshot

ExecStart=/bin/sh -c "busctl call `mapper get-service /org/openbmc/control/power%i` /org/openbmc/control/power%i org.openbmc.control.Power setPowerState i 1"

SyslogIdentifier=op-power-start

[Install]

WantedBy=obmc-host-start@%i.target


cat obmc-power-start@.target

[Unit]

Description=Power%i On

After=obmc-power-start-pre@%i.target

Wants=multi-user.target

Conflicts=obmc-chassis-poweroff@%i.target

RefuseManualStart=yes

RefuseManualStop=yes

Thanks
Harley
________________________________
·¢¼þÈË: openbmc <openbmc-bounces+zhouyuanqing8=outlook.com@lists.ozlabs.org> ´ú±í Sui Chen <suichen6@gmail.com>
·¢ËÍʱ¼ä: 2020Äê4ÔÂ21ÈÕ 1:05
ÊÕ¼þÈË: openbmc@lists.ozlabs.org <openbmc@lists.ozlabs.org>
Ö÷Ìâ: Re: Call for Gardening Tasks


> On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com> wrote:

> Systemd Visualization

> Another complicated area of OpenBMC is our systemd targets and services. Building on the upstream tools to visualize our systemd targets and services would be useful to new people.



+1 to visualization, and I have a few thoughts on this ---

My lacking a mental model of how an OpenBMC system works had been my pain point in the first few months working with OpenBMC (I¡¯m a bit new to this area), so after learning the minimal set of survival skills I did something similar to what you mentioned ¨C visualizing the messages passed between different dbus peers (and conveniently, IPMI traffic, as IPMI-related dbus messages exposing all IPMI payload comprise most of the dbus traffic on that particular system I was working on.)



I think packet analysis tools such as Wireshark and graphics frame analysis tools such as RenderDoc, or system event-based Windows Performance tool like GPUView provide great examples of what people might expect to achieve with a visualization tool: capture, inspect and (sometimes) playback, across multiple layers in the software/hardware stack. Many similar existing tools process sequences of events, and in this case of BMCs, the events could be dbus messages. I found a prototype visualizer made at work greatly helpful in explaining to new team members some basic concepts and the IPMI stack on the BMC.



The IPMI stack is interesting because it¡¯s one noticeable workload on the particular BMC system I had been working on; in my current limited understanding, having lots of I/O capability to connect to hundreds of sensors is one of the many features that set apart a BMC chip and a similarly powerful smartphone chip, and the broad use of dbus is what sets apart OpenBMC and the desktop Linux distro I had been using. I heard optimization is best done workload by workload, perhaps this rationale applies to visualization too?



I realize I was mostly talking about visualizing the run-time state of the system rather than build-time, but we could visualize the run-time aspect of systemd units too since I have seen many times a dbus message eventually triggering a systemd target to acutate the system, so it would be good to consider both dbus and systemd (and maybe other parts of the system?) to have a more holistic view of the BMC¡¯s operations.



Thanks

Sui

[-- Attachment #2: Type: text/html, Size: 24446 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Call for Gardening Tasks
  2020-04-20 17:05 Call for Gardening Tasks Sui Chen
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
@ 2020-04-21 23:18 ` Richard Hanley
  2020-04-22 14:04   ` krtaylor
  2020-04-23  3:58 ` Andrew Jeffery
  2 siblings, 1 reply; 9+ messages in thread
From: Richard Hanley @ 2020-04-21 23:18 UTC (permalink / raw)
  To: Sui Chen; +Cc: openbmc

[-- Attachment #1: Type: text/plain, Size: 3811 bytes --]

Thank you everyone for your suggestions.

Scanning through this it's clear that documentation is one of the biggest
most generally agreed upon area to work on.

Build tools and package management seems like another area with some agreed
on improvements. I like the idea of moving to meson. Getting tidy files and
revising our style guides also sound like good ideas. I also really agree
that we could stand to do some consolidation of processes/repos.

There is also some use for DBus tooling for both improved code, and for
visualizations.

So here are my next steps:
  1) Since we have some new people getting started, I've asked them to add
documentation at the points they get stuck during on-boarding.
  2) I'm going to take the ideas in this thread and put together a .md doc
with any relevant information I can find. I'll be adding it to openbmc/docs.
  3) I'll follow up in another thread about some of the ideas around DBus
tooling and package consolidation. That seems to be an area where most
people agree some improvements can be made, but I'm not sure there is an
agreement on how we should do it.

-Richard



On Mon, Apr 20, 2020 at 10:19 AM Sui Chen <suichen6@gmail.com> wrote:

> > On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com>
> wrote:
>
> > Systemd Visualization
>
> > Another complicated area of OpenBMC is our systemd targets and services.
> Building on the upstream tools to visualize our systemd targets and
> services would be useful to new people.
>
>
>
> +1 to visualization, and I have a few thoughts on this ---
>
> My lacking a mental model of how an OpenBMC system works had been my pain
> point in the first few months working with OpenBMC (I’m a bit new to this
> area), so after learning the minimal set of survival skills I did something
> similar to what you mentioned – visualizing the messages passed between
> different dbus peers (and conveniently, IPMI traffic, as IPMI-related dbus
> messages exposing all IPMI payload comprise most of the dbus traffic on
> that particular system I was working on.)
>
>
>
> I think packet analysis tools such as Wireshark and graphics frame
> analysis tools such as RenderDoc, or system event-based Windows Performance
> tool like GPUView provide great examples of what people might expect to
> achieve with a visualization tool: capture, inspect and (sometimes)
> playback, across multiple layers in the software/hardware stack. Many
> similar existing tools process sequences of events, and in this case of
> BMCs, the events could be dbus messages. I found a prototype visualizer
> made at work greatly helpful in explaining to new team members some basic
> concepts and the IPMI stack on the BMC.
>
>
>
> The IPMI stack is interesting because it’s one noticeable workload on the
> particular BMC system I had been working on; in my current limited
> understanding, having lots of I/O capability to connect to hundreds of
> sensors is one of the many features that set apart a BMC chip and a
> similarly powerful smartphone chip, and the broad use of dbus is what sets
> apart OpenBMC and the desktop Linux distro I had been using. I heard
> optimization is best done workload by workload, perhaps this rationale
> applies to visualization too?
>
>
>
> I realize I was mostly talking about visualizing the run-time state of the
> system rather than build-time, but we could visualize the run-time aspect
> of systemd units too since I have seen many times a dbus message eventually
> triggering a systemd target to acutate the system, so it would be good to
> consider both dbus and systemd (and maybe other parts of the system?) to
> have a more holistic view of the BMC’s operations.
>
>
>
> Thanks
>
> Sui
>

[-- Attachment #2: Type: text/html, Size: 5446 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: about power control.回复: Call for Gardening Tasks
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
@ 2020-04-22  5:34   ` Li, Yong
  2020-04-22  7:25   ` Konstantin Klubnichkin
  2020-04-23  3:48   ` Andrew Jeffery
  2 siblings, 0 replies; 9+ messages in thread
From: Li, Yong @ 2020-04-22  5:34 UTC (permalink / raw)
  To: zhouyuanqing8, Sui Chen, openbmc; +Cc: uperic, shinerocky

[-- Attachment #1: Type: text/plain, Size: 7837 bytes --]

Regarding the power control related, sugest to check on the below:

https://github.com/openbmc/x86-power-control/blob/master/power-control-x86/src/power_control.cpp



It uses litter systems related services/targets, and monitor these gpio 
signals, to trigger different callback actions.


For the pgood_wait, it is in:

https://github.com/openbmc/skeleton/tree/master/op-pwrctl/pgood_wait

https://github.com/openbmc/skeleton/tree/master/op-pwrctl


Thanks,

Yong


在 4/21/2020 10:50 PM, zhouyuanqing8@outlook.com 写道:
> Hi
>
>     This is a very good idea. As the first time to do openbmc, I look 
> forward to it. Currently, I am being troubled by the problems you 
> describe.
>
>     The following questions, please also help you answer it, thank you 
> very much.
>
>     1.I modified the dts file, how to use the command "bitbake -f 
> linux-aspeed" to Generate fitimage and dub?
>      Now, I modify the dts file in the kernel source directory. When I 
> compile, bitbake will re-fetch the source code, decompress, patch, 
> configure, and compile, causing my changes to be overwritten. I 
> currently use manual call scripts to compile dts files and make images 
> for debugging.Is there a way to make bitbake skip the previous steps 
> and compile directly?
>
>
>      2.The size of image-rwfs is 0, I want to use rwfs debugging, how 
> to configure to generate a normal image-rwfs?
> -rw-r--r--. 2 harleyzhou harleyzhou     9443     4月        7 17:27 
> obmc-phosphor-image-xxh-20200407092558.rootfs.manifest
>      -rw-r--r--. 2 harleyzhou harleyzhou 18214912 4月    7 17:27 
> obmc-phosphor-image-xxh-20200407092558.rootfs.squashfs-xz
>      -rw-rw-r--. 2 harleyzhou harleyzhou 33554432        4月   7 17:27 
> obmc-phosphor-image-xxh-20200407092558.static.mtd
>      -rw-rw-r--. 2 harleyzhou harleyzhou 33566720        4月   7 17:28 
> obmc-phosphor-image-xxh-20200407092558.static.mtd.all.tar
>      -rw-rw-r--. 2 harleyzhou harleyzhou 22384640        4月   7 17:28 
> obmc-phosphor-image-xxh-20200407092558.static.mtd.tar
>      -rw-r--r--. 2 harleyzhou harleyzhou   308218  4月      7 17:27 
> obmc-phosphor-image-xxh-20200407092558.testdata.json
>      -rw-r--r--. 2 harleyzhou harleyzhou           0  4月   7 17:27 
> obmc-phosphor-image-xxh.jffs2
>
>
>     3. I did not find the source code of "pgood_wait" and 
> "power_control.exe" in obmc-op-control-power? where can I get it ?
>
>
>     4.OpenBMC usessystemd 
> <https://www.freedesktop.org/wiki/Software/systemd/>to manage all 
> processes, So i analyzed the process of systemd starting process and 
> saw "default.target-> basic.target-> sysinit.target-> 
> local-fs.target", there is no content behind.please help to provide 
> clues of systemd starting process.
>
>     5.I understand the following execution process of power-on , help 
> check if it is correct.
>        a).rest or busctl send power-on commands to systemd through 
> d-bus messages.
>        b).systemd find the obmc-chassis-poweron@.target
>   c).systemd find the obmc-power-start@.target
> d).systemd find the op-power-start@0.service
> e).systemd start a thread and execute "busctl call `mapper get-service 
> /org/openbmc/control/power%i` /org/openbmc/control/power%i 
> org.openbmc.control.Power setPowerState I 1"
>
> appendix:
>
> ls obmc-chassis-poweron@0.target.requires
>
> op-power-start@0.serviceop-wait-power-on@0.service
>
>
> cat obmc-chassis-poweron@.target
>
> [Unit]
>
> Description=Chassis%i (Power On)
>
> Wants=multi-user.target
>
> After=multi-user.target
>
> Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
>
> After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service
>
> Wants=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service
>
> After=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service
>
>
> cat op-power-start@0.service
>
> [Unit]
>
> Description=Start Power%i
>
> Wants=obmc-power-start@%i.target
>
> Before=obmc-power-start@%i.target
>
> After=obmc-power-start-pre@%i.target
>
> After=obmc-fan-control.target
>
> Wants=mapper-wait@-org-openbmc-control-power%i.service
>
> After=mapper-wait@-org-openbmc-control-power%i.service
>
> [Service]
>
> RemainAfterExit=yes
>
> Type=oneshot
>
> ExecStart=/bin/sh -c "busctl call `mapper get-service 
> /org/openbmc/control/power%i` /org/openbmc/control/power%i 
> org.openbmc.control.Power setPowerState i 1"
>
> SyslogIdentifier=op-power-start
>
> [Install]
>
> WantedBy=obmc-host-start@%i.target
>
>
> cat obmc-power-start@.target
>
> [Unit]
>
> Description=Power%i On
>
> After=obmc-power-start-pre@%i.target
>
> Wants=multi-user.target
>
> Conflicts=obmc-chassis-poweroff@%i.target
>
> RefuseManualStart=yes
>
> RefuseManualStop=yes
>
>
> Thanks
> Harley
> ------------------------------------------------------------------------
> *发件人:* openbmc 
> <openbmc-bounces+zhouyuanqing8=outlook.com@lists.ozlabs.org> 代表 Sui 
> Chen <suichen6@gmail.com>
> *发送时间:* 2020年4月21日 1:05
> *收件人:* openbmc@lists.ozlabs.org <openbmc@lists.ozlabs.org>
> *主题:* Re: Call for Gardening Tasks
>
> > On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com> wrote:
>
> > Systemd Visualization
>
> > Another complicated area of OpenBMC is our systemd targets and services. Building on the upstream 
> tools to visualize our systemd targets and services would be useful to 
> new people.
>
> +1 to visualization, and I have a few thoughts on this ---
>
> My lacking a mental model of how an OpenBMC system works had been my 
> pain point in the first few months working with OpenBMC (I’m a bit new 
> to this area), so after learning the minimal set of survival skills I 
> did something similar to what you mentioned – visualizing the messages 
> passed between different dbus peers (and conveniently, IPMI traffic, 
> as IPMI-related dbus messages exposing all IPMI payload comprise most 
> of the dbus traffic on that particular system I was working on.)
>
> I think packet analysis tools such as Wireshark and graphics frame 
> analysis tools such as RenderDoc, or system event-based Windows 
> Performance tool like GPUView provide great examples of what people 
> might expect to achieve with a visualization tool: capture, inspect 
> and (sometimes) playback, across multiple layers in the 
> software/hardware stack. Many similar existing tools process sequences 
> of events, and in this case of BMCs, the events could be dbus 
> messages. I found a prototype visualizer made at work greatly helpful 
> in explaining to new team members some basic concepts and the IPMI 
> stack on the BMC.
>
> The IPMI stack is interesting because it’s one noticeable workload on 
> the particular BMC system I had been working on; in my current limited 
> understanding, having lots of I/O capability to connect to hundreds of 
> sensors is one of the many features that set apart a BMC chip and a 
> similarly powerful smartphone chip, and the broad use of dbus is what 
> sets apart OpenBMC and the desktop Linux distro I had been using. I 
> heard optimization is best done workload by workload, perhaps this 
> rationale applies to visualization too?
>
> I realize I was mostly talking about visualizing the run-time state of 
> the system rather than build-time, but we could visualize the run-time 
> aspect of systemd units too since I have seen many times a dbus 
> message eventually triggering a systemd target to acutate the system, 
> so it would be good to consider both dbus and systemd (and maybe other 
> parts of the system?) to have a more holistic view of the BMC’s 
> operations.
>
> Thanks
>
> Sui
>

[-- Attachment #2: Type: text/html, Size: 33043 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: about power control.回复: Call for Gardening Tasks
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
  2020-04-22  5:34   ` Li, Yong
@ 2020-04-22  7:25   ` Konstantin Klubnichkin
  2020-04-22 12:38     ` 回复: " zhouyuanqing8
  2020-04-23  3:48   ` Andrew Jeffery
  2 siblings, 1 reply; 9+ messages in thread
From: Konstantin Klubnichkin @ 2020-04-22  7:25 UTC (permalink / raw)
  To: zhouyuanqing8, Sui Chen, openbmc; +Cc: uperic, shinerocky

[-- Attachment #1: Type: text/html, Size: 22978 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* 回复: about power control.回复: Call for Gardening Tasks
  2020-04-22  7:25   ` Konstantin Klubnichkin
@ 2020-04-22 12:38     ` zhouyuanqing8
  0 siblings, 0 replies; 9+ messages in thread
From: zhouyuanqing8 @ 2020-04-22 12:38 UTC (permalink / raw)
  To: Konstantin Klubnichkin, openbmc, Li, Yong; +Cc: uperic, shinerocky

[-- Attachment #1: Type: text/plain, Size: 9507 bytes --]

Thank you for the help, I will test it.

________________________________
发件人: Konstantin Klubnichkin <kitsok@yandex-team.ru>
发送时间: 2020年4月22日 15:25
收件人: zhouyuanqing8@outlook.com <zhouyuanqing8@outlook.com>; Sui Chen <suichen6@gmail.com>; openbmc@lists.ozlabs.org <openbmc@lists.ozlabs.org>
抄送: uperic@163.com <uperic@163.com>; shinerocky@yahoo.com <shinerocky@yahoo.com>
主题: Re: about power control.回复: Call for Gardening Tasks

Hello!

I'll try to answer your question about rwfs image.
I had the same issue plus I wanted to be able to create some data in rwfs segment.
Thus I've created obmc-phosphor-image.bbappend where I do the following:
======================================================================
RWFS_SIZE ?= "4194304"
OVERLAY_MKFS_OPTS = " --pad=${RWFS_SIZE}"

# Override JFFS image creation
do_generate_rwfs_static() {
rwdir=$(pwd)
rwdir=${rwdir}/jffs2
image=rwfs.jffs2

rm -rf $rwdir $image > /dev/null 2>&1
mkdir -p ${rwdir}/cow
rwdir=${rwdir}/cow

bbplain "DEBUG: Creating RWFS image "

mv ${IMAGE_ROOTFS}/rwfs/* ${rwdir}/
rm -rf ${IMAGE_ROOTFS}/rwfs

# Create necessary files, directories, etc in ${rwdir}
${JFFS2_RWFS_CMD} ${OVERLAY_MKFS_OPTS} ${OVERLAY_MKFS_OPTS} --squash-uids
}
======================================================================

At the end I have the normal JFFS2 image instead of empty.

Hope this can help.

21.04.2020, 18:24, "zhouyuanqing8@outlook.com" <zhouyuanqing8@outlook.com>:
Hi

    This is a very good idea. As the first time to do openbmc, I look forward to it. Currently, I am being troubled by the problems you describe.

    The following questions, please also help you answer it, thank you very much.

    1.I modified the dts file, how to use the command "bitbake -f linux-aspeed" to Generate fitimage and dub?
     Now, I modify the dts file in the kernel source directory. When I compile, bitbake will re-fetch the source code, decompress, patch, configure, and compile, causing my changes to be overwritten. I currently use manual call scripts to compile dts files and make images for debugging.Is there a way to make bitbake skip the previous steps and compile directly?


     2.The size of image-rwfs is 0, I want to use rwfs debugging, how to configure to generate a normal image-rwfs?
     -rw-r--r--. 2 harleyzhou harleyzhou     9443             4月        7 17:27 obmc-phosphor-image-xxh-20200407092558.rootfs.manifest
     -rw-r--r--. 2 harleyzhou harleyzhou 18214912         4月    7 17:27 obmc-phosphor-image-xxh-20200407092558.rootfs.squashfs-xz
     -rw-rw-r--. 2 harleyzhou harleyzhou 33554432        4月   7 17:27 obmc-phosphor-image-xxh-20200407092558.static.mtd
     -rw-rw-r--. 2 harleyzhou harleyzhou 33566720        4月   7 17:28 obmc-phosphor-image-xxh-20200407092558.static.mtd.all.tar
     -rw-rw-r--. 2 harleyzhou harleyzhou 22384640        4月   7 17:28 obmc-phosphor-image-xxh-20200407092558.static.mtd.tar
     -rw-r--r--. 2 harleyzhou harleyzhou   308218            4月      7 17:27 obmc-phosphor-image-xxh-20200407092558.testdata.json
     -rw-r--r--. 2 harleyzhou harleyzhou           0               4月   7 17:27 obmc-phosphor-image-xxh.jffs2


    3. I did not find the source code of "pgood_wait" and "power_control.exe" in obmc-op-control-power? where can I get it ?


    4.OpenBMC uses systemd<https://www.freedesktop.org/wiki/Software/systemd/> to manage all processes, So i analyzed the process of systemd starting process and saw "default.target-> basic.target-> sysinit.target-> local-fs.target", there is no content behind.please help to provide clues of systemd starting process.

    5.I understand the following execution process of power-on , help check if it is correct.
       a).rest or busctl send power-on commands to systemd through d-bus messages.
       b).systemd find the obmc-chassis-poweron@.target
        c).systemd find the obmc-power-start@.target
        d).systemd find the op-power-start@0.service<mailto:op-power-start@0.service>
        e).systemd start a thread and execute "busctl call `mapper get-service /org/openbmc/control/power%i` /org/openbmc/control/power%i org.openbmc.control.Power setPowerState I 1"

appendix:

ls obmc-chassis-poweron@0.target.requires<mailto:obmc-chassis-poweron@0.target.requires>

op-power-start@0.servic<mailto:op-power-start@0.servic>e  op-wait-power-on@0.service<mailto:op-wait-power-on@0.service>



cat obmc-chassis-poweron@.target

[Unit]

Description=Chassis%i (Power On)

Wants=multi-user.target

After=multi-user.target

Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service<mailto:Wants=mapper-wait@-xyz-openbmc_project-state-chassis%i.service>

After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service<mailto:After=mapper-wait@-xyz-openbmc_project-state-chassis%i.service>

Wants=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service

After=mapper-subtree-remove@-xyz-openbmc\x5fproject-software\x3Axyz.openbmc_project.Software.ActivationBlocksTransition.service



cat op-power-start@0.servic<mailto:op-power-start@0.servic>e

[Unit]

Description=Start Power%i

Wants=obmc-power-start@%i.target<mailto:Wants=obmc-power-start@%i.target>

Before=obmc-power-start@%i.target<mailto:Before=obmc-power-start@%i.target>

After=obmc-power-start-pre@%i.target<mailto:After=obmc-power-start-pre@%i.target>

After=obmc-fan-control.target

Wants=mapper-wait@-org-openbmc-control-power%i.service<mailto:Wants=mapper-wait@-org-openbmc-control-power%i.service>

After=mapper-wait@-org-openbmc-control-power%i.service<mailto:After=mapper-wait@-org-openbmc-control-power%i.service>

[Service]

RemainAfterExit=yes

Type=oneshot

ExecStart=/bin/sh -c "busctl call `mapper get-service /org/openbmc/control/power%i` /org/openbmc/control/power%i org.openbmc.control.Power setPowerState i 1"

SyslogIdentifier=op-power-start

[Install]

WantedBy=obmc-host-start@%i.target<mailto:WantedBy=obmc-host-start@%i.target>



cat obmc-power-start@.target

[Unit]

Description=Power%i On

After=obmc-power-start-pre@%i.target<mailto:After=obmc-power-start-pre@%i.target>

Wants=multi-user.target

Conflicts=obmc-chassis-poweroff@%i.target<mailto:Conflicts=obmc-chassis-poweroff@%i.target>

RefuseManualStart=yes

RefuseManualStop=yes


Thanks
Harley
________________________________
发件人: openbmc <openbmc-bounces+zhouyuanqing8=outlook.com@lists.ozlabs.org<mailto:openbmc-bounces+zhouyuanqing8=outlook.com@lists.ozlabs.org>> 代表 Sui Chen <suichen6@gmail.com<mailto:suichen6@gmail.com>>
发送时间: 2020年4月21日 1:05
收件人: openbmc@lists.ozlabs.org<mailto:openbmc@lists.ozlabs.org> <openbmc@lists.ozlabs.org<mailto:openbmc@lists.ozlabs.org>>
主题: Re: Call for Gardening Tasks


> On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com> wrote:

> Systemd Visualization

> Another complicated area of OpenBMC is our systemd targets and services. Building on the upstream tools to visualize our systemd targets and services would be useful to new people.



+1 to visualization, and I have a few thoughts on this ---

My lacking a mental model of how an OpenBMC system works had been my pain point in the first few months working with OpenBMC (I’m a bit new to this area), so after learning the minimal set of survival skills I did something similar to what you mentioned C visualizing the messages passed between different dbus peers (and conveniently, IPMI traffic, as IPMI-related dbus messages exposing all IPMI payload comprise most of the dbus traffic on that particular system I was working on.)



I think packet analysis tools such as Wireshark and graphics frame analysis tools such as RenderDoc, or system event-based Windows Performance tool like GPUView provide great examples of what people might expect to achieve with a visualization tool: capture, inspect and (sometimes) playback, across multiple layers in the software/hardware stack. Many similar existing tools process sequences of events, and in this case of BMCs, the events could be dbus messages. I found a prototype visualizer made at work greatly helpful in explaining to new team members some basic concepts and the IPMI stack on the BMC.



The IPMI stack is interesting because it’s one noticeable workload on the particular BMC system I had been working on; in my current limited understanding, having lots of I/O capability to connect to hundreds of sensors is one of the many features that set apart a BMC chip and a similarly powerful smartphone chip, and the broad use of dbus is what sets apart OpenBMC and the desktop Linux distro I had been using. I heard optimization is best done workload by workload, perhaps this rationale applies to visualization too?



I realize I was mostly talking about visualizing the run-time state of the system rather than build-time, but we could visualize the run-time aspect of systemd units too since I have seen many times a dbus message eventually triggering a systemd target to acutate the system, so it would be good to consider both dbus and systemd (and maybe other parts of the system?) to have a more holistic view of the BMC’s operations.



Thanks

Sui



--
Best regards,
Konstantin Klubnichkin,
lead firmware engineer,
server hardware R&D group,
Yandex Moscow office.
tel: +7-903-510-33-33


[-- Attachment #2: Type: text/html, Size: 25340 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Call for Gardening Tasks
  2020-04-21 23:18 ` Richard Hanley
@ 2020-04-22 14:04   ` krtaylor
  0 siblings, 0 replies; 9+ messages in thread
From: krtaylor @ 2020-04-22 14:04 UTC (permalink / raw)
  To: Richard Hanley; +Cc: openbmc

On 4/21/20 6:18 PM, Richard Hanley wrote:
> Thank you everyone for your suggestions.
> 
> Scanning through this it's clear that documentation is one of the 
> biggest most generally agreed upon area to work on.
> 
> Build tools and package management seems like another area with some 
> agreed on improvements. I like the idea of moving to meson. Getting tidy 
> files and revising our style guides also sound like good ideas. I also 
> really agree that we could stand to do some consolidation of 
> processes/repos.
> 
> There is also some use for DBus tooling for both improved code, and for 
> visualizations.
> 
> So here are my next steps:
>    1) Since we have some new people getting started, I've asked them to 
> add documentation at the points they get stuck during on-boarding.
>    2) I'm going to take the ideas in this thread and put together a .md 
> doc with any relevant information I can find. I'll be adding it to 
> openbmc/docs.

That would work, but I would also suggest a wiki page. Docs have a 
tendency to get stale quickly, where a wiki page has a lower pain point 
for a small changes. I can get that started if it would help.

Kurt Taylor (krtaylor)


>    3) I'll follow up in another thread about some of the ideas around 
> DBus tooling and package consolidation. That seems to be an area where 
> most people agree some improvements can be made, but I'm not sure there 
> is an agreement on how we should do it.
> 
> -Richard
> 
> 
> 
> On Mon, Apr 20, 2020 at 10:19 AM Sui Chen <suichen6@gmail.com 
> <mailto:suichen6@gmail.com>> wrote:
> 
>     > On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com <http://gmail.com>> wrote:
> 
>     > Systemd Visualization
> 
>     > Another complicated area of OpenBMC is our systemd targets and services. Building on the upstream tools to visualize our systemd targets and services would be useful to new people.
> 
>     __ __
> 
>     +1 to visualization, and I have a few thoughts on this ---____
> 
>     My lacking a mental model of how an OpenBMC system works had been my
>     pain point in the first few months working with OpenBMC (I’m a bit
>     new to this area), so after learning the minimal set of survival
>     skills I did something similar to what you mentioned – visualizing
>     the messages passed between different dbus peers (and conveniently,
>     IPMI traffic, as IPMI-related dbus messages exposing all IPMI
>     payload comprise most of the dbus traffic on that particular system
>     I was working on.)____
> 
>     __ __
> 
>     I think packet analysis tools such as Wireshark and graphics frame
>     analysis tools such as RenderDoc, or system event-based Windows
>     Performance tool like GPUView provide great examples of what people
>     might expect to achieve with a visualization tool: capture, inspect
>     and (sometimes) playback, across multiple layers in the
>     software/hardware stack. Many similar existing tools process
>     sequences of events, and in this case of BMCs, the events could be
>     dbus messages. I found a prototype visualizer made at work greatly
>     helpful in explaining to new team members some basic concepts and
>     the IPMI stack on the BMC.____
> 
>     __ __
> 
>     The IPMI stack is interesting because it’s one noticeable workload
>     on the particular BMC system I had been working on; in my current
>     limited understanding, having lots of I/O capability to connect to
>     hundreds of sensors is one of the many features that set apart a BMC
>     chip and a similarly powerful smartphone chip, and the broad use of
>     dbus is what sets apart OpenBMC and the desktop Linux distro I had
>     been using. I heard optimization is best done workload by workload,
>     perhaps this rationale applies to visualization too?____
> 
>     __ __
> 
>     I realize I was mostly talking about visualizing the run-time state
>     of the system rather than build-time, but we could visualize the
>     run-time aspect of systemd units too since I have seen many times a
>     dbus message eventually triggering a systemd target to acutate the
>     system, so it would be good to consider both dbus and systemd (and
>     maybe other parts of the system?) to have a more holistic view of
>     the BMC’s operations.____
> 
>     __ __
> 
>     Thanks____
> 
>     Sui____
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: about power control.回复: Call for Gardening Tasks
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
  2020-04-22  5:34   ` Li, Yong
  2020-04-22  7:25   ` Konstantin Klubnichkin
@ 2020-04-23  3:48   ` Andrew Jeffery
  2 siblings, 0 replies; 9+ messages in thread
From: Andrew Jeffery @ 2020-04-23  3:48 UTC (permalink / raw)
  To: zhouyuanqing8, Sui Chen, openbmc; +Cc: uperic, shinerocky



On Wed, 22 Apr 2020, at 00:20, zhouyuanqing8@outlook.com wrote:
>  Hi 
> 
>  This is a very good idea. As the first time to do openbmc, I look 
> forward to it. Currently, I am being troubled by the problems you 
> describe.
> 
>  The following questions, please also help you answer it, thank you very much.
> 
>  1.I modified the dts file, how to use the command "bitbake -f 
> linux-aspeed" to Generate fitimage and dub?
>  Now, I modify the dts file in the kernel source directory. When I 
> compile, bitbake will re-fetch the source code, decompress, patch, 
> configure, and compile, causing my changes to be overwritten. I 
> currently use manual call scripts to compile dts files and make images 
> for debugging.Is there a way to make bitbake skip the previous steps 
> and compile directly?

Two approaches here:

1. Use `devtool`[1], (`devtool modify linux-aspeed`), and then hack
on the source that gets extracted

2. Use your own fork of the kernel hack the linux-aspeed recipe to point
to your local repo.

[1] https://www.yoctoproject.org/docs/2.0/dev-manual/dev-manual.html#dev-modifying-source-code

Diverging further, you can just build your own kernel out of your kernel
source tree and netboot it on the BMC (either hardware or qemu). It
depends on what your needs are, but netbooting is great for doing kernel
development and testing (as opposed to building images to be deployed).

> 
> 
>  2.The size of image-rwfs is 0, I want to use rwfs debugging, how to 
> configure to generate a normal image-rwfs? 
> -rw-r--r--. 2 harleyzhou harleyzhou 9443 4月 7 17:27 
> obmc-phosphor-image-xxh-20200407092558.rootfs.manifest
>  -rw-r--r--. 2 harleyzhou harleyzhou 18214912 4月 7 17:27 
> obmc-phosphor-image-xxh-20200407092558.rootfs.squashfs-xz
>  -rw-rw-r--. 2 harleyzhou harleyzhou 33554432 4月 7 17:27 
> obmc-phosphor-image-xxh-20200407092558.static.mtd
>  -rw-rw-r--. 2 harleyzhou harleyzhou 33566720 4月 7 17:28 
> obmc-phosphor-image-xxh-20200407092558.static.mtd.all.tar
>  -rw-rw-r--. 2 harleyzhou harleyzhou 22384640 4月 7 17:28 
> obmc-phosphor-image-xxh-20200407092558.static.mtd.tar
>  -rw-r--r--. 2 harleyzhou harleyzhou 308218 4月 7 17:27 
> obmc-phosphor-image-xxh-20200407092558.testdata.json
>  -rw-r--r--. 2 harleyzhou harleyzhou 0  4月 7 17:27 
> obmc-phosphor-image-xxh.jffs2

As long as the flash partition is erased jffs2 will be happy to mount it, so
depending on your circumstances you may not need any data in
image-rwfs.

Hope that helps,

Andrew

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: Call for Gardening Tasks
  2020-04-20 17:05 Call for Gardening Tasks Sui Chen
  2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
  2020-04-21 23:18 ` Richard Hanley
@ 2020-04-23  3:58 ` Andrew Jeffery
  2 siblings, 0 replies; 9+ messages in thread
From: Andrew Jeffery @ 2020-04-23  3:58 UTC (permalink / raw)
  To: Sui Chen, openbmc



On Tue, 21 Apr 2020, at 02:35, Sui Chen wrote:
> > On Apr 11, 2020, at 8:15 AM, Andrew Geissler <geissonator at gmail.com> wrote:
> 

> 
> 
> I think packet analysis tools such as Wireshark and graphics frame 
> analysis tools such as RenderDoc, or system event-based Windows 
> Performance tool like GPUView provide great examples of what people 
> might expect to achieve with a visualization tool: capture, inspect and 
> (sometimes) playback, across multiple layers in the software/hardware 
> stack. Many similar existing tools process sequences of events, and in 
> this case of BMCs, the events could be dbus messages. I found a 
> prototype visualizer made at work greatly helpful in explaining to new 
> team members some basic concepts and the IPMI stack on the BMC.
> 

Not really a visualisation tool, but I'm going to plug my dbus pcap parser
here - it's helped me analyse a number of silly problems of dbus
interactions between a number of applications:

https://github.com/openbmc/openbmc-tools/blob/master/amboar/obmc-scripts/dbus-pcap/dbus-pcap

It desperately needs a README, but you can slice and dice `busctl capture`
output with DBus filter specifications, and if you like dump the output as
json for further processing.

Andrew

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-04-23  3:58 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-20 17:05 Call for Gardening Tasks Sui Chen
2020-04-21 14:50 ` about power control.回复: " zhouyuanqing8
2020-04-22  5:34   ` Li, Yong
2020-04-22  7:25   ` Konstantin Klubnichkin
2020-04-22 12:38     ` 回复: " zhouyuanqing8
2020-04-23  3:48   ` Andrew Jeffery
2020-04-21 23:18 ` Richard Hanley
2020-04-22 14:04   ` krtaylor
2020-04-23  3:58 ` Andrew Jeffery

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.