| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To use this API, you need to import dmidecodeXML. This is a wrapper class for
the internal XML API which has been implemented. In addition, you might also
want to import libxml2 as well.
dmidecodeXML::QuerySection(<string>)
Valid section strings can be found in the pymap.xml file, in the <GroupMapping>
tag section.
dmidecodeXML::TypeId(<integer between 0-255>)
Valid values should match the DMI/SMBIOS specification.
dmidecodeXML::SetResultType(resultType)
Result type can be either dmidecodeXML.DMIXML_NODE or dmidecodeXML.DMIXML_DOC
----------------------------------------------------------
import libxml2
import dmidecodeXML
dmixml = dmidecodeXML.dmidecodeXML()
section_nodes = dmixml.QuerySection('processor')
dmixml.SetResultType(dmidecodeXML.DMIXML_DOC)
typeid_doc = dmixml.QueryTypeId(0x10)
dmixml.SetResultType(dmidecodeXML.DMIXML_NODE)
typeid_doc.saveFormatFileEnc("-", "UTF-8", 1)
----------------------------------------------------------
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Instead of building up an u8 array with 255 cells where we only use one
cell at the time now, just pass the type id value as an int the whole way
through.
|
|
|
|
|
|
|
| |
Removed the `dmi_table_string' function, and `const struct
string_keyword *string' from the `options' struct. Also modified
the function calls that are now free of this, namely, `legacy_decode'
and `smbios_decode'.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
names
Also changed dmiMAP_ParseMappingXML(...) to dmiMAP_ParseMappingXML_GroupName(...). In the
dmidecode_get(...) function. This is just a quick fix for making it compile. It's also
needed to implement usage of dmiMAP_ParseMappingXML_TypeID(...) as well.
|
| |
|
|
|
|
|
|
|
|
| |
Merged the two XML files into one, and amended relevant code. I still
want to modify the XML tag names, but not yet.
The calls to dmidecode.type() not function as expected, but the others
are broken - this is next.
|
| |
|
|
|
|
|
|
|
| |
Updated test unit to match.
Throw an exception instead of returning None/False in some
functions.
|
|
|
|
|
|
|
|
|
| |
Don't write to stdout unless in debug mode (with respect to writing
to memory devices.
Added the xml datafile to setup (distutils).
Updated test case (incorporating color and cleaning up tests).
|
|
|
|
|
|
|
|
|
|
|
| |
The version is of now, v3.10.6. The version major field has been
upped due to the newly added XML functionality.
The version has been reverted to GPLv2.
Some headers have been cleaned up, copyright notices added etc.
Credits given where due.
|
| |
|
| |
|
|
|
|
|
|
| |
The default file is now set to /usr/share/python-dmidecode/pythonmap.xml
(defined in config.h) and can be overridden with the dmidecode.pythonmap()
function in Python.
|
|
|
|
|
|
|
|
| |
When calling dmidecode_get_xml(...) several times could cause a crash
due to the opt.dmiversion_n pointer being freed by a mistake when the
generated dmixml_n got freed later on in the function.
Also fixed an assertion typo
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@180 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@179 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
|
|
| |
Added the second type of stuffed bios (upstream).
Integrated dmidecode the binary into the test case for a more objective result.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@163 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
| |
memory file or device.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@155 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@137 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
| |
Updated test cases to test for this too.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@136 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
|
|
| |
Bettered test cases.
Case 127 magically fixed.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@135 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
|
|
|
|
|
| |
should be implemented to return this string, so further cleanup is still
required; as it stands, there is no access to this information anymore!
Updated test case.
Further general cleanup.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@133 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@127 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@125 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
|
|
| |
Don't crash when writing to a read-only file, return False instead.
Missing an INCREF in get_dev() fixed.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@124 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
| |
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@123 abc39116-655e-4be6-ad55-d661dc543056
|
|
|
|
|
|
|
| |
Adding an example directory.
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@115 abc39116-655e-4be6-ad55-d661dc543056
|
|
git-svn-id: svn://svn.autonomy.net.au/python-dmidecode@108 abc39116-655e-4be6-ad55-d661dc543056
|