Quellcodebibliothek Statistik Leitseite products/sources/formale Sprachen/C/Linux/arch/mips/loongson64/   (Open Source Betriebssystem Version 6.17.9©)  Datei vom 24.10.2025 mit Größe 1 kB image not shown  

Quelle  boardinfo.c   Sprache: C

 
// SPDX-License-Identifier: GPL-2.0
#include <linux/kobject.h>
#include <boot_param.h>

static ssize_t boardinfo_show(struct kobject *kobj,
         struct kobj_attribute *attr, char *buf)
{
 char board_manufacturer[64] = {0};
 char *tmp_board_manufacturer = board_manufacturer;
 char bios_vendor[64] = {0};
 char *tmp_bios_vendor = bios_vendor;

 strcpy(board_manufacturer, eboard->name);
 strcpy(bios_vendor, einter->description);

 return sprintf(buf,
         "Board Info\n"
         "Manufacturer\t\t: %s\n"
         "Board Name\t\t: %s\n"
         "Family\t\t\t: LOONGSON3\n\n"
         "BIOS Info\n"
         "Vendor\t\t\t: %s\n"
         "Version\t\t\t: %s\n"
         "Release Date\t\t: %s\n",
         strsep(&tmp_board_manufacturer, "-"),
         eboard->name,
         strsep(&tmp_bios_vendor, "-"),
         einter->description,
         especial->special_name);
}
static struct kobj_attribute boardinfo_attr = __ATTR(boardinfo, 0444,
           boardinfo_show, NULL);

static int __init boardinfo_init(void)
{
 struct kobject *lefi_kobj;

 lefi_kobj = kobject_create_and_add("lefi", firmware_kobj);
 if (!lefi_kobj) {
  pr_err("lefi: Firmware registration failed.\n");
  return -ENOMEM;
 }

 return sysfs_create_file(lefi_kobj, &boardinfo_attr.attr);
}
late_initcall(boardinfo_init);

Messung V0.5
C=97 H=98 G=97

¤ Dauer der Verarbeitung: 0.3 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.