diff options
author | marha <marha@users.sourceforge.net> | 2014-07-19 15:12:53 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2014-07-19 15:12:53 +0200 |
commit | 61c36feba19d918885022042ea62d068a698c83d (patch) | |
tree | fd351953eb2193fe548e7d0e2dca06b34b7c4f4d /xorg-server/include/hotplug.h | |
parent | 3865d60ef607cbb00c819e905e40d3628b8eca29 (diff) | |
parent | d0c30e7945e76ac119f6d867e27137c8a76f7e15 (diff) | |
download | vcxsrv-61c36feba19d918885022042ea62d068a698c83d.tar.gz vcxsrv-61c36feba19d918885022042ea62d068a698c83d.tar.bz2 vcxsrv-61c36feba19d918885022042ea62d068a698c83d.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
mesalib/src/glsl/ir.cpp
xorg-server/config/config.c
xorg-server/include/callback.h
xorg-server/include/colormap.h
xorg-server/include/cursor.h
xorg-server/include/dix.h
xorg-server/include/dixfont.h
xorg-server/include/dixgrabs.h
xorg-server/include/gc.h
xorg-server/include/gcstruct.h
xorg-server/include/input.h
xorg-server/include/os.h
xorg-server/include/pixmap.h
xorg-server/include/property.h
xorg-server/include/resource.h
xorg-server/include/scrnintstr.h
xorg-server/include/window.h
xorg-server/include/xkbsrv.h
xorg-server/mi/mi.h
Diffstat (limited to 'xorg-server/include/hotplug.h')
-rw-r--r-- | xorg-server/include/hotplug.h | 69 |
1 files changed, 23 insertions, 46 deletions
diff --git a/xorg-server/include/hotplug.h b/xorg-server/include/hotplug.h index c4268a0c4..6fe76c806 100644 --- a/xorg-server/include/hotplug.h +++ b/xorg-server/include/hotplug.h @@ -32,64 +32,41 @@ extern _X_EXPORT void config_pre_init(void); extern _X_EXPORT void config_init(void); extern _X_EXPORT void config_fini(void); -enum { ODEV_ATTRIB_STRING, ODEV_ATTRIB_INT }; - -struct OdevAttribute { - struct xorg_list member; - int attrib_id; - union { - char *attrib_name; - int attrib_value; - }; - int attrib_type; -}; +/* Bump this each time you add something to the struct + * so that drivers can easily tell what is available + */ +#define ODEV_ATTRIBUTES_VERSION 1 struct OdevAttributes { - struct xorg_list list; -}; + /* path to kernel device node - Linux e.g. /dev/dri/card0 */ + char *path; -/* Note starting with xserver 1.16 this function never fails */ -struct OdevAttributes * -config_odev_allocate_attribute_list(void); + /* system device path - Linux e.g. /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0/drm/card1 */ + char *syspath; -void -config_odev_free_attribute_list(struct OdevAttributes *attribs); + /* DRI-style bus id */ + char *busid; -/* Note starting with xserver 1.16 this function never fails */ -Bool -config_odev_add_attribute(struct OdevAttributes *attribs, int attrib, - const char *attrib_name); + /* Server managed FD */ + int fd; -char * -config_odev_get_attribute(struct OdevAttributes *attribs, int attrib_id); + /* Major number of the device node pointed to by ODEV_ATTRIB_PATH */ + int major; -/* Note starting with xserver 1.16 this function never fails */ -Bool -config_odev_add_int_attribute(struct OdevAttributes *attribs, int attrib, - int attrib_value); + /* Minor number of the device node pointed to by ODEV_ATTRIB_PATH */ + int minor; + + /* kernel driver name */ + char *driver; +}; -int -config_odev_get_int_attribute(struct OdevAttributes *attribs, int attrib, - int def); +/* Note starting with xserver 1.16 this function never fails */ +struct OdevAttributes * +config_odev_allocate_attributes(void); void config_odev_free_attributes(struct OdevAttributes *attribs); -/* path to kernel device node - Linux e.g. /dev/dri/card0 */ -#define ODEV_ATTRIB_PATH 1 -/* system device path - Linux e.g. /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0/drm/card1 */ -#define ODEV_ATTRIB_SYSPATH 2 -/* DRI-style bus id */ -#define ODEV_ATTRIB_BUSID 3 -/* Server managed FD */ -#define ODEV_ATTRIB_FD 4 -/* Major number of the device node pointed to by ODEV_ATTRIB_PATH */ -#define ODEV_ATTRIB_MAJOR 5 -/* Minor number of the device node pointed to by ODEV_ATTRIB_PATH */ -#define ODEV_ATTRIB_MINOR 6 -/* kernel driver name */ -#define ODEV_ATTRIB_DRIVER 4 - typedef void (*config_odev_probe_proc_ptr)(struct OdevAttributes *attribs); void config_odev_probe(config_odev_probe_proc_ptr probe_callback); |