Bug#891674: Patch to fix the problem
> "Michel" == Michel Dänzerwrites: Michel> On 2018-02-28 02:41 AM, peter.ch...@data61.csiro.au wrote: Michel> Doing it like this breaks ABI. This is fixed in libpciaccess Michel> 0.14 by Michel> https://cgit.freedesktop.org/xorg/lib/libpciaccess/commit/?id=a167bd6474522a709ff3cbb00476c0e4309cb66f Michel> , though Xorg needs to be rebuilt against that for it to take Michel> effect. Any idea when this'll hit Debian's archives? Because this bug will prevent X11 working on any machine that has VMD storage. Peter C -- Dr Peter Chubb Tel: +61 2 9490 5852 http://ts.data61.csiro.au/ Trustworthy Systems Group Data61 (formerly NICTA)
Bug#891674: Patch to fix the problem
On 2018-02-28 02:41 AM, peter.ch...@data61.csiro.au wrote: > The linux kernel treats PCI domains as 32 bit ints. > > diff -ru libpciaccess-0.13.4/include/pciaccess.h > libpciaccess-0.13.4-fixed/include/pciaccess.h > --- libpciaccess-0.13.4/include/pciaccess.h 2015-05-01 14:44:47.0 > +1000 > +++ libpciaccess-0.13.4-fixed/include/pciaccess.h 2018-02-28 > 12:21:12.280963252 +1100 > @@ -321,7 +321,7 @@ > * the domain will always be zero. > */ > /*@{*/ > -uint16_tdomain; > +uint32_tdomain; > uint8_t bus; > uint8_t dev; > uint8_t func; > diff -ru libpciaccess-0.13.4/src/linux_sysfs.c > libpciaccess-0.13.4-fixed/src/linux_sysfs.c > --- libpciaccess-0.13.4/src/linux_sysfs.c 2015-05-01 14:44:47.0 > +1000 > +++ libpciaccess-0.13.4-fixed/src/linux_sysfs.c 2018-02-28 > 12:21:32.676941130 +1100 > @@ -157,7 +157,7 @@ > (struct pci_device_private *) >devices[i]; > > > - sscanf(devices[i]->d_name, "%04x:%02x:%02x.%1u", > + sscanf(devices[i]->d_name, "%x:%02x:%02x.%1u", > & dom, & bus, & dev, & func); > > device->base.domain = dom; > Doing it like this breaks ABI. This is fixed in libpciaccess 0.14 by https://cgit.freedesktop.org/xorg/lib/libpciaccess/commit/?id=a167bd6474522a709ff3cbb00476c0e4309cb66f , though Xorg needs to be rebuilt against that for it to take effect. -- Earthling Michel Dänzer | http://www.amd.com Libre software enthusiast | Mesa and X developer
Bug#891674: Patch to fix the problem
The linux kernel treats PCI domains as 32 bit ints. diff -ru libpciaccess-0.13.4/include/pciaccess.h libpciaccess-0.13.4-fixed/include/pciaccess.h --- libpciaccess-0.13.4/include/pciaccess.h 2015-05-01 14:44:47.0 +1000 +++ libpciaccess-0.13.4-fixed/include/pciaccess.h 2018-02-28 12:21:12.280963252 +1100 @@ -321,7 +321,7 @@ * the domain will always be zero. */ /*@{*/ -uint16_tdomain; +uint32_tdomain; uint8_t bus; uint8_t dev; uint8_t func; diff -ru libpciaccess-0.13.4/src/linux_sysfs.c libpciaccess-0.13.4-fixed/src/linux_sysfs.c --- libpciaccess-0.13.4/src/linux_sysfs.c 2015-05-01 14:44:47.0 +1000 +++ libpciaccess-0.13.4-fixed/src/linux_sysfs.c 2018-02-28 12:21:32.676941130 +1100 @@ -157,7 +157,7 @@ (struct pci_device_private *) >devices[i]; - sscanf(devices[i]->d_name, "%04x:%02x:%02x.%1u", + sscanf(devices[i]->d_name, "%x:%02x:%02x.%1u", & dom, & bus, & dev, & func); device->base.domain = dom; -- Dr Peter Chubb Tel: +61 2 9490 5852 http://ts.data61.csiro.au/ Trustworthy Systems Group Data61 (formerly NICTA)