"Fossies" - the Fresh Open Source Software Archive

Member "usbutils-015/names.h" (22 Feb 2021, 1592 Bytes) of package /linux/misc/usbutils-015.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "names.h" see the Fossies "Dox" file reference documentation and the last Fossies "Diffs" side-by-side code changes report: 013_vs_014.

    1 // SPDX-License-Identifier: GPL-2.0-or-later
    2 /*
    3  * USB name database manipulation routines
    4  *
    5  * Copyright (C) 1999, 2000 Thomas Sailer (sailer@ife.ee.ethz.ch)
    6  */
    7 
    8 #ifndef _NAMES_H
    9 #define _NAMES_H
   10 
   11 /* ---------------------------------------------------------------------- */
   12 
   13 extern const char *names_vendor(uint16_t vendorid);
   14 extern const char *names_product(uint16_t vendorid, uint16_t productid);
   15 extern const char *names_class(uint8_t classid);
   16 extern const char *names_subclass(uint8_t classid, uint8_t subclassid);
   17 extern const char *names_protocol(uint8_t classid, uint8_t subclassid,
   18                   uint8_t protocolid);
   19 extern const char *names_audioterminal(uint16_t termt);
   20 extern const char *names_videoterminal(uint16_t termt);
   21 extern const char *names_hid(uint8_t hidd);
   22 extern const char *names_reporttag(uint8_t rt);
   23 extern const char *names_huts(unsigned int data);
   24 extern const char *names_hutus(unsigned int data);
   25 extern const char *names_langid(uint16_t langid);
   26 extern const char *names_physdes(uint8_t ph);
   27 extern const char *names_bias(uint8_t b);
   28 extern const char *names_countrycode(unsigned int countrycode);
   29 
   30 extern int get_vendor_string(char *buf, size_t size, uint16_t vid);
   31 extern int get_product_string(char *buf, size_t size, uint16_t vid, uint16_t pid);
   32 extern int get_class_string(char *buf, size_t size, uint8_t cls);
   33 extern int get_subclass_string(char *buf, size_t size, uint8_t cls, uint8_t subcls);
   34 
   35 extern int names_init(void);
   36 extern void names_exit(void);
   37 
   38 /* ---------------------------------------------------------------------- */
   39 #endif /* _NAMES_H */