public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-platforms PATCH 0/2] Platform/RPi3: PlatformSmbios improvements
@ 2019-09-04 12:14 Pete Batard
  2019-09-04 12:14 ` [edk2-platforms PATCH 1/2] Platform/RPi3: Add more query functions in RpiFirmwareDxe Pete Batard
  2019-09-04 12:14 ` [edk2-platforms PATCH 2/2] Platform/RPi3: Improve the population of PlatformSmbiosDxe elements Pete Batard
  0 siblings, 2 replies; 5+ messages in thread
From: Pete Batard @ 2019-09-04 12:14 UTC (permalink / raw)
  To: devel; +Cc: ard.biesheuvel, leif.lindholm

This series of patches improves the data reported by the firmware for SMB queries.
This is achieved by first introducing new calls in RpiFirmwareDxe and then cleaning
up the existing PlatformSmbiosDxe code. These modifications should ensure that
the drivers can be reused on other Raspberry Pi platforms (such as the Pi 4).

It should be noted that, with these changes, if one passes a  build option like
--pcd gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVersionString=L"UEFI Firmware v1.7"
the BIOS major and minor will be populated from that version data.

Attached below is the report from dmidecode on Linux/Debian for a Raspberry Pi 3 B+
using a firmware with the above. Similar data can also be obtained through
smbiosview in the UEFI Shell.

Regards,

/Pete

----------------------------------------------------------------------------------
root@pi3:~# dmidecode
# dmidecode 3.2
Getting SMBIOS data from sysfs.
SMBIOS 3.2.0 present.
Table at 0x37260000.

Handle 0x0000, DMI type 0, 26 bytes
BIOS Information
        Vendor: TianoCore
        Version: UEFI Firmware v1.7
        Release Date: Sep  3 2019 19:44:54
        ROM Size: 2048 kB
        Characteristics:
                Selectable boot is supported
                ACPI is supported
                Function key-initiated network boot is supported
                Targeted content distribution is supported
                UEFI is supported
        BIOS Revision: 1.7
        Firmware Revision: 85.210

Handle 0x0001, DMI type 1, 27 bytes
System Information
        Manufacturer: Sony UK
        Product Name: Raspberry Pi 3 Model B+
        Version: A020D3
        Serial Number: 0000B827EB123456
        UUID: 00a020d3-0000-0000-0000-b827eb123456
        Wake-up Type: Power Switch
        SKU Number: 0000000000A020D3
        Family: Raspberry Pi

Handle 0x0002, DMI type 2, 17 bytes
Base Board Information
        Manufacturer: Sony UK
        Product Name: Raspberry Pi 3 Model B+
        Version: A020D3
        Serial Number: 0000B827EB123456
        Asset Tag: Not Specified
        Features:
                Board is a hosting board
        Location In Chassis: Not Specified
        Chassis Handle: 0x0000
        Type: Motherboard
        Contained Object Handles: 0

Handle 0x0003, DMI type 3, 24 bytes
Chassis Information
        Manufacturer: Sony UK
        Type: Embedded PC
        Lock: Not Present
        Version: Raspberry Pi 3 Model B+
        Serial Number: 0000B827EB123456
        Asset Tag: Not Specified
        Boot-up State: Safe
        Power Supply State: Safe
        Thermal State: Safe
        Security Status: None
        OEM Information: 0x00000000
        Height: Unspecified
        Number Of Power Cords: Unspecified
        Contained Elements: 0
        SKU Number: Not Specified

Handle 0x0004, DMI type 4, 48 bytes
Processor Information
        Socket Designation: Socket
        Type: Central Processor
        Family: ARM
        Manufacturer: Broadcom
        ID: 00 00 00 00 00 00 00 00
        Version: BCM2837 (ARM Cortex-A53)
        Voltage: 5.0 V 3.3 V 2.9 V
        External Clock: Unknown
        Max Speed: 1400 MHz
        Current Speed: 600 MHz
        Status: Populated, Enabled
        Upgrade: Other
        L1 Cache Handle: 0x0000
        L2 Cache Handle: 0x0000
        L3 Cache Handle: 0x0000
        Serial Number: Not Specified
        Asset Tag: Not Specified
        Part Number: Not Specified
        Core Count: 4
        Core Enabled: 4
        Thread Count: 4
        Characteristics:
                64-bit capable
                Multi-Core
                Execute Protection
                Enhanced Virtualization

Handle 0x0005, DMI type 7, 27 bytes
Cache Information
        Socket Designation: Cache1
        Configuration: Enabled, Socketed, Level 3
        Operational Mode: Write Back
        Location: Internal
        Installed Size: 0 kB
        Maximum Size: 0 kB
        Supported SRAM Types:
                Burst
                Synchronous
        Installed SRAM Type: Burst Synchronous
        Speed: Unknown
        Error Correction Type: Multi-bit ECC
        System Type: Unknown
        Associativity: 2-way Set-associative

Handle 0x0006, DMI type 9, 24 bytes
System Slot Information
        Designation: SD Card
        Type: Other
        Current Usage: Available
        Length: Other
        Characteristics: Unknown
        Bus Address: 0000:00:00.0

Handle 0x0007, DMI type 16, 23 bytes
Physical Memory Array
        Location: System Board Or Motherboard
        Use: System Memory
        Error Correction Type: Unknown
        Maximum Capacity: 1 TB
        Error Information Handle: Not Provided
        Number Of Devices: 1

Handle 0x0008, DMI type 17, 84 bytes
Memory Device
        Array Handle: 0x0007
        Error Information Handle: Not Provided
        Total Width: Unknown
        Data Width: Unknown
        Size: 1024 MB
        Form Factor: Unknown
        Set: Unknown
        Locator: OS Virtual Memory
        Bank Locator: malloc
        Type: DRAM
        Type Detail: Unknown
        Speed: Unknown
        Manufacturer: OSV
        Serial Number: Not Specified
        Asset Tag: Not Specified
        Part Number: Not Specified
        Rank: Unknown
        Configured Memory Speed: Unknown
        Minimum Voltage: Unknown
        Maximum Voltage: Unknown
        Configured Voltage: Unknown
        Memory Technology: <OUT OF SPEC>
        Memory Operating Mode Capability: None
        Firmware Version: Not Specified
        Module Manufacturer ID: Unknown
        Module Product ID: Unknown
        Memory Subsystem Controller Manufacturer ID: Unknown
        Memory Subsystem Controller Product ID: Unknown
        Non-Volatile Size: None
        Volatile Size: None
        Cache Size: None
        Logical Size: None

Handle 0x0009, DMI type 19, 31 bytes
Memory Array Mapped Address
        Starting Address: 0x00000000000
        Ending Address: 0x0003B3FFFFF
        Range Size: 948 MB
        Physical Array Handle: 0x0000
        Partition Width: 1

Handle 0x000A, DMI type 32, 11 bytes
System Boot Information
        Status: No errors detected

Handle 0xFEFF, DMI type 127, 4 bytes
End Of Table
----------------------------------------------------------------------------------

Pete Batard (2):
  Platform/RPi3: Add more query functions in RpiFirmwareDxe
  Platform/RPi3: Improve the population of PlatformSmbiosDxe elements

 Platform/RaspberryPi/RPi3/Drivers/PlatformSmbiosDxe/PlatformSmbiosDxe.c   | 193 ++++++++++++--------
 Platform/RaspberryPi/RPi3/Drivers/PlatformSmbiosDxe/PlatformSmbiosDxe.inf |   1 +
 Platform/RaspberryPi/RPi3/Drivers/RpiFirmwareDxe/RpiFirmwareDxe.c         | 166 ++++++++++++++++-
 Platform/RaspberryPi/RPi3/Include/Protocol/RpiFirmware.h                  |  58 ++++--
 Platform/RaspberryPi/RPi3/RPi3.dsc                                        |   2 +-
 5 files changed, 322 insertions(+), 98 deletions(-)

-- 
2.21.0.windows.1


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

end of thread, other threads:[~2019-09-27 19:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-04 12:14 [edk2-platforms PATCH 0/2] Platform/RPi3: PlatformSmbios improvements Pete Batard
2019-09-04 12:14 ` [edk2-platforms PATCH 1/2] Platform/RPi3: Add more query functions in RpiFirmwareDxe Pete Batard
2019-09-27 18:34   ` Leif Lindholm
2019-09-04 12:14 ` [edk2-platforms PATCH 2/2] Platform/RPi3: Improve the population of PlatformSmbiosDxe elements Pete Batard
2019-09-27 19:03   ` Leif Lindholm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox