From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id BD0A294184D for ; Tue, 12 Dec 2023 14:54:35 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=O+9xTDN78tM2pMPjY/zJVz3lhQRph3/yTOQsR1LiABw=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20140610; t=1702392874; v=1; b=kOxfLhCbq6Y+zu8g8nLkmL+fLbICFPkCnwdebC6T06IhrZdZvhLE0hLoXYWWsTICBt8gFpeI biJM6s0WYiypok4Blni3Syh3YpLN1/YhAq4hiJ8yxYivp6w0E1q4tjCYYYYtjCLhS6oUURW0x6i KL3bH8DBkw4eZDJW2mSxJP3I= X-Received: by 127.0.0.2 with SMTP id tNAmYY7687511xPc8Jtw1EE8; Tue, 12 Dec 2023 06:54:34 -0800 X-Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com [209.85.167.41]) by mx.groups.io with SMTP id smtpd.web10.3584.1702392873062825927 for ; Tue, 12 Dec 2023 06:54:33 -0800 X-Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-50be10acaf9so5691815e87.1 for ; Tue, 12 Dec 2023 06:54:32 -0800 (PST) X-Gm-Message-State: djK2HRVFSCCAAdLTs0vRVCnUx7686176AA= X-Google-Smtp-Source: AGHT+IG/9vJElDTe5DMGqqwQmUUl4RDSbKWpL3qeWgn4dJV9htzdZxaiC3fBTSj2dEIBZhjzVFraUg== X-Received: by 2002:a19:5e1d:0:b0:50b:f03c:1eb2 with SMTP id s29-20020a195e1d000000b0050bf03c1eb2mr2898719lfb.20.1702392870972; Tue, 12 Dec 2023 06:54:30 -0800 (PST) X-Received: from localhost.localdomain ([79.164.221.98]) by smtp.gmail.com with ESMTPSA id m21-20020a0565120a9500b0050d1d8674d2sm952008lfu.292.2023.12.12.06.54.30 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 12 Dec 2023 06:54:30 -0800 (PST) From: "Mike Maslenkin" To: devel@edk2.groups.io Cc: abner.chang@amd.com, nicklew@nvidia.com, igork@ami.com, Mike Maslenkin Subject: [edk2-devel] [PATCH 7/9] RedfishPkg: add proper initialization of IPMI request Date: Tue, 12 Dec 2023 17:54:10 +0300 Message-Id: <20231212145412.50434-8-mike.maslenkin@gmail.com> In-Reply-To: <20231212145412.50434-1-mike.maslenkin@gmail.com> References: <20231212145412.50434-1-mike.maslenkin@gmail.com> MIME-Version: 1.0 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,mike.maslenkin@gmail.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=kOxfLhCb; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io All fields of IPMI_CHANNEL_INFO_CHANNEL_NUMBER union must be initialized to avoid error condition on BMC side. Cc: Abner Chang Cc: Nickle Wang Cc: Igor Kulchytskyy Signed-off-by: Mike Maslenkin --- .../PlatformHostInterfaceBmcUsbNicLib.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/RedfishPkg/Library/PlatformHostInterfaceBmcUsbNicLib/PlatformH= ostInterfaceBmcUsbNicLib.c b/RedfishPkg/Library/PlatformHostInterfaceBmcUsb= NicLib/PlatformHostInterfaceBmcUsbNicLib.c index 7f295fe7f1c0..c73e76df5791 100644 --- a/RedfishPkg/Library/PlatformHostInterfaceBmcUsbNicLib/PlatformHostInte= rfaceBmcUsbNicLib.c +++ b/RedfishPkg/Library/PlatformHostInterfaceBmcUsbNicLib/PlatformHostInte= rfaceBmcUsbNicLib.c @@ -616,9 +616,10 @@ HostInterfaceIpmiCheckMacAddress ( }=0D =0D // Initial the get MAC address request.=0D - GetLanConfigReq.SetSelector =3D 0;=0D - GetLanConfigReq.BlockSelector =3D 0;=0D - GetLanConfigReq.ParameterSelector =3D IpmiLanMacAddress;=0D + GetLanConfigReq.ChannelNumber.Uint8 =3D 0;=0D + GetLanConfigReq.SetSelector =3D 0;=0D + GetLanConfigReq.BlockSelector =3D 0;=0D + GetLanConfigReq.ParameterSelector =3D IpmiLanMacAddress;=0D =0D ExitStatus =3D EFI_NOT_FOUND;=0D for (ChannelNum =3D IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1;=0D @@ -640,6 +641,7 @@ HostInterfaceIpmiCheckMacAddress ( } else {=0D DEBUG ((DEBUG_REDFISH_HOST_INTERFACE, " No cached IPMI LAN info\n")= );=0D DEBUG ((DEBUG_REDFISH_HOST_INTERFACE, " Send NetFn =3D App, Command= =3D 0x42 to channel %d\n", ChannelNum));=0D + GetChanelInfoRequest.ChannelNumber.Uint8 =3D 0;=0D GetChanelInfoRequest.ChannelNumber.Bits.ChannelNo =3D (UINT8)Channel= Num;=0D Status =3D IpmiGetChannel= Info (=0D &GetChanelInfo= Request,=0D --=20 2.32.0 (Apple Git-132) -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#112443): https://edk2.groups.io/g/devel/message/112443 Mute This Topic: https://groups.io/mt/103130785/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-