Displaying 6 results from an estimated 6 matches for "s_dmi".
2012 Sep 19
1
[PATCH 1/1] lua: Cleaned up the dmi table structure in Lua.c32 and added all missing DMI subtables
.../lua/src/dmi.c
@@ -9,275 +9,487 @@
#include "lualib.h"
#include "dmi/dmi.h"
-static int dmi_gettable(lua_State *L)
+extern void add_string_item(lua_State*, const char*, const char*);
+extern void add_int_item(lua_State*, const char*, int);
+typedef int (*table_fn)(lua_State*, s_dmi*);
+
+/* Add a Lua_String entry to the table on stack
+ xxx_P is the poiter version (i.e., pBase is a pointer)
+ xxx_S is the staic version (i.e., Base is the struct)
+*/
+#define LUA_ADD_STR_P(pLua_state, pBase, Field) \
+ add_string_item(pLua_state, #Field, pBase->Field);
+#define LUA_ADD...
2006 Aug 14
0
First attempt to use DMI in a com32 module
...s the core program that makes the dmi tables accessible.
dmi_utils.c
Just a small util file to display some more complicated messages
dmitest.c
The program that show how to use the dmi inside a com32 module.
The way the API works :
dmi_interate() tells if a DMI table is present or not.
s_dmi is the structure that contains the dmi informations.
parse_dmitable(&dmi) fills a dmi structure with the elements founds in
the table.
And.... that's all ;)
So the following code is enough :
s_dmi dmi;
if (dmi_iterate()) parse_dmitable(&dmi);
Simple isn't it ?
Then, if you like...
2015 Feb 10
0
[PATCH 3/6] gpllib: fix sizeof(char *) misuse
...- strlcpy(array, "Unknown", sizeof array);
+ strlcpy(array, "Unknown", len);
else
- snprintf(array, sizeof array, "%u min", code);
+ snprintf(array, len, "%u min", code);
}
/*
@@ -947,13 +947,17 @@ void dmi_decode(struct dmi_header *h, uint16_t ver, s_dmi * dmi)
dmi_system_reset_boot_option((data[0x04] >> 3) & 0x3),
sizeof dmi->system.system_reset.boot_option_on_limit);
dmi_system_reset_count(WORD(data + 0x05),
- dmi->system.system_reset.reset_count);
+ dmi->system.system_reset.reset_count,
+ siz...
2015 Feb 10
6
[PATCH 0/6] fix some compiler warnings
These patches fix a few compiler warnings.
Tested on top of commit aee0dc5565711ef5be7c30fb5fc1c5f3f98db09f
Jonathan Boeing (6):
Use z width specifier when printing size_t variable
pxe: fix truncation warning
gpllib: fix sizeof(char *) misuse
hdt: fix sizeof(char *) misuse
hdt: fix sizeof(char *) misuse
hdt: fix sizeof(char *) misuse
com32/gpllib/dmi/dmi.c | 24 +++---
2013 Oct 15
23
[PATCH 00/21] Upgrade to Lua 5.2.2, add filesystem module and get_key binding
Hi,
This series targets automatic boot menu generation, but most of it
is the Lua upgrade, because I got tired reading deprecated API docs.
It's mostly a straightforward forward port of the earlier Syslinux
specific changes to Lua 5.1, except that:
* I chose the add a stub getenv() implementation to the COM32 API
instead of #ifdefing out all the references in Lua, and
* I kept oslib
2011 Apr 16
20
[PATCH 00/20] Switch to ELF modules
From: Matt Fleming <matt.fleming at linux.intel.com>
This series fixes some bugs and switches the elflink branch to be
entirely ELF modules. It applies on top of,
http://syslinux.zytor.com/archives/2011-April/016369.html
The deletions in the diff stat below are mainly from deleting
com32/elflink/modules (finally!). Now there should be no duplicate
code because we don't need COM32 and