From: "Chris Chen (TPI)" <Chris.Chen3@flex.com> To: Andrei Kartashev <firstname.lastname@example.org>, "email@example.com" <firstname.lastname@example.org> Subject: 回覆: 回覆: [phosphor-host-ipmid] Questions about IPMI (OEM) command development Date: Tue, 7 Sep 2021 09:52:00 +0000 [thread overview] Message-ID: <DM6PR08MB5514D3E2103969E07D4F0AC7DCD39@DM6PR08MB5514.namprd08.prod.outlook.com> (raw) In-Reply-To: <DM6PR08MB5514F694AEC078DF0E0A4E9BDCD39@DM6PR08MB5514.namprd08.prod.outlook.com> [-- Attachment #1: Type: text/plain, Size: 5500 bytes --] Hi Andrei, One more thing would like to consult you is I have tried to add our own xxx-ipmi-oem, but got the "Insufficient privilege level" feedback after executing an oem command. However, it would be successful in case I removed intel-ipmi-oem. Do you have experience with this? If yes, may I know how to fix it? I currently would like to keep leveraging the intel-ipmi-oem until I integrate the commands I needed into our own xxx-ipmi-oem. Thank you. Regards, Chris Chen ________________________________ 寄件者: openbmc <email@example.com> 代表 Chris Chen (TPI) <Chris.Chen3@flex.com> 寄件日期: 2021年9月7日 上午 08:35 收件者: Andrei Kartashev <firstname.lastname@example.org>; email@example.com <firstname.lastname@example.org> 主旨: 回覆: 回覆: [phosphor-host-ipmid] Questions about IPMI (OEM) command development Hi Anrdrei, Thank you for your helpful comments. Regards, Chris Chen ________________________________ 寄件者: Andrei Kartashev <email@example.com> 寄件日期: 2021年9月6日 下午 06:15 收件者: Chris Chen (TPI) <Chris.Chen3@flex.com>; firstname.lastname@example.org <email@example.com> 主旨: Re: 回覆: [phosphor-host-ipmid] Questions about IPMI (OEM) command development Hello, I don't represent Intel, but have some considerations about this topic: 1) Try to not reuse intel-ipmi-oem. Much better solution would be to create your own xxx-ipmi-oem package and implement only methods you really need. 2) Better way would be to implement required logic in phosphor-host- ipmid and submit changes there. I didn't investigate this yet since we also pull intel-ipmi-oem to our project, but I believe, it should not be too difficult. Don't repeat our mistakes ). 3) There is priority argument which you can use to determine handler call order. 4) Most functions there are specific for Intel servers, so the useless even is you use Intel CPUs but your own platform. 5) Use "journalctl -t ipmid -o pretty-json" or something like this. But now it is recommended to use new syntax: https://urldefense.com/v3/__https://github.com/openbmc/phosphor-logging/blob/master/docs/structured-logging.md__;!!HSntlCg!G61XcVxUr8Hli8HqIlebVYji3tTPXsn33W5oyo-FlU8fbm6Zd66S0H6cseru6Bcw$ On Mon, 2021-09-06 at 09:40 +0000, Chris Chen (TPI) wrote: > Hi all, > > I guess this mail was got overwhelmed by bunches of emails, so please > let me resend it and hope someone could help me. Another, I add one > more question marked #5 below. > > Thank you. > > Regards, > Chris Chen > > 寄件者: openbmc <firstname.lastname@example.org> 代表 > Chris Chen (TPI) <Chris.Chen3@flex.com> > 寄件日期: 2021年9月2日 下午 06:34 > 收件者: email@example.com <firstname.lastname@example.org> > 主旨: [phosphor-host-ipmid] Questions about IPMI (OEM) command > development > Hi all, > > I have studied "phosphor-host-ipmid" package for a couple of weeks and > got understanding that it has implemented some mandatory and optional > commands already. And I also knew that I'm able to leverage "intel- > ipmi-oem" package to get more command handlers. But there're some > questions raised in my mind, I hope someone could give me some > suggestions. > 1. What's the normal development procedure in case I want to make > our own OEM commands? I mean do you guys encourage me to create a new > "xxx-ipmi-oem" package or to leverage "intel-ipmi-oem" and then add our > own commands in it? > 2. I for now added "intel-ipmi-oem" package only for using its > "<Chassis>:<Set Front Panel Enables>" command because I figured out the > same command in the "phosphor-host-ipmid" is not able to match the d- > bus interface in the "x86-power-control". I'm not sure if I will need > other commands in the "intel-ipmi-oem", but what if I don't need other > commands, how to remove them? to use the whitelist mechanism? > 3. Is it okay to add more than 1 xxx-ipmi-ome packages? If yes, how > to manage the whitelist between these 2 OEM packages? > 4. Am I able to use "intel-ipmi-oem" on a platform that is using AMD > CPU? > 5. How to print the "entry("SENDER=%s", sender.c_str())" parts? I > mean I for now can print out "Set up ipmi context" string after > following the instruction listed in > "https://urldefense.com/v3/__https://github.com/openbmc/openbmc/wiki/Debugging-OpenBMC*enabling-application-debug__;Iw!!HSntlCg!G61XcVxUr8Hli8HqIlebVYji3tTPXsn33W5oyo-FlU8fbm6Zd66S0H6csVZtHYM2$ > ", but I don't see "SENDER=" when I executed "journalctl -t ipmid" > command. > 6. 1. log<level::DEBUG>("Set up ipmi > context",entry("SENDER=%s",sender.c_str()), > entry("NETFN=0x%X", netFn),entry("LUN=0x%X", lun), > entry("CMD=0x%X", cmd),entry("CHANNEL=%u", channel), > entry("USERID=%u", userId), > entry("SESSIONID=0x%X", sessionId), > entry("PRIVILEGE=%u",static_cast<uint8_t>(privilege)), > entry("RQSA=%x", rqSA)); > Thank you. > > Regards, > Chris Chen > Legal Disclaimer : > The information contained in this message may be privileged and > confidential. > It is intended to be read only by the individual or entity to whom it > is addressed > or by their designee. If the reader of this message is not the intended > recipient, > is strictly prohibited. If you have received this message in error, > please immediately notify the sender and delete or destroy any copy of > this message! -- Best regards, Andrei Kartashev [-- Attachment #2: Type: text/html, Size: 10205 bytes --]
next prev parent reply other threads:[~2021-09-07 9:53 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-09-02 10:34 Chris Chen (TPI) 2021-09-06 9:40 ` 回覆: " Chris Chen (TPI) 2021-09-06 10:03 ` Troy Lee 2021-09-07 0:25 ` 回覆: " Chris Chen (TPI) 2021-09-06 10:15 ` Andrei Kartashev 2021-09-07 0:35 ` 回覆: " Chris Chen (TPI) 2021-09-07 9:52 ` Chris Chen (TPI) [this message] 2021-09-07 11:45 ` Chris Chen (TPI) 2021-09-09 20:15 ` Vernon Mauery 2021-09-11 3:56 ` 回覆: " Chris Chen (TPI) 2021-09-15 2:35 ` Vernon Mauery 2021-09-17 0:13 ` Chris Chen (TPI)
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=DM6PR08MB5514D3E2103969E07D4F0AC7DCD39@DM6PR08MB5514.namprd08.prod.outlook.com \ --email@example.com \ --firstname.lastname@example.org \ --email@example.com \ --subject='Re: 回覆: 回覆: [phosphor-host-ipmid] Questions about IPMI (OEM) command development' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).