mirror of
https://github.com/siderolabs/talos.git
synced 2025-10-28 06:51:34 +01:00
Update to some dependencies moved to siderolabs/ path. Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
27 lines
547 B
Go
27 lines
547 B
Go
// This Source Code Form is subject to the terms of the Mozilla Public
|
|
// License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
package smbios
|
|
|
|
import (
|
|
"sync"
|
|
|
|
"github.com/siderolabs/go-smbios/smbios"
|
|
)
|
|
|
|
var (
|
|
syncSMBIOS sync.Once
|
|
connSMBIOS *smbios.SMBIOS
|
|
errSMBIOS error
|
|
)
|
|
|
|
// GetSMBIOSInfo returns the SMBIOS info.
|
|
func GetSMBIOSInfo() (*smbios.SMBIOS, error) {
|
|
syncSMBIOS.Do(func() {
|
|
connSMBIOS, errSMBIOS = smbios.New()
|
|
})
|
|
|
|
return connSMBIOS, errSMBIOS
|
|
}
|