Other functions

The following functions are in the C library for use in processing the hwinfo section:

hwi_tag2off()
unsigned hwi_tag2off(void *);

Given a pointer to the start of a tag, return the offset, in bytes, from the beginning of the start of the hwinfo section.

hwi_off2tag()
void *hwi_off2tag(unsigned);

Given an offset, in bytes, from the start of the hwinfo section, return a pointer to the start of the tag.

hwi_find_tag()
unsigned hwi_find_tag(unsigned start, int curr_item, const char *tagname);

Find the tag named tagname. The start parameter works the same as the one in hwi_find_item(). If curr_item is nonzero, the search stops at the end of the current item (whatever item the start parameter points into). If curr_item is zero, the search continues until the end of the section. If the tag isn't found, HWI_NULL_OFF is returned.

hwi_next_item()
unsigned hwi_next_item( unsigned off );

Get the offset of the next item after the given offset from the start of the hwinfo section.

hwi_next_tag()
unsigned hwi_next_tag( unsigned off, int curr_item );

Get the offset of the next tag after the given offset from the start of the hwinfo section. As it is for hwi_find_tag(), the curr_item restricts the search to the current item.

For more information about these functions, see the QNX Neutrino C Library Reference.