Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-13 Thread Jonathon Jongsma
On Tue, 2018-11-13 at 11:21 +0100, Lukáš Hrázký wrote: > Hi, > > On Tue, 2018-11-13 at 09:04 +0100, Gerd Hoffmann wrote: > > Hi, > > > > > To look up a PCI device by address, I could use the /sys > > > filesystem. So > > > for pci//02.0, I would translate the domain into the > > >

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-13 Thread Gerd Hoffmann
On Tue, Nov 13, 2018 at 11:21:26AM +0100, Lukáš Hrázký wrote: > Hi, > > On Tue, 2018-11-13 at 09:04 +0100, Gerd Hoffmann wrote: > > Hi, > > > > > To look up a PCI device by address, I could use the /sys filesystem. So > > > for pci//02.0, I would translate the domain into the > > >

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-13 Thread Lukáš Hrázký
Hi, On Tue, 2018-11-13 at 09:04 +0100, Gerd Hoffmann wrote: > Hi, > > > To look up a PCI device by address, I could use the /sys filesystem. So > > for pci//02.0, I would translate the domain into the > > filesystem path '/sys/devices/pci:00/' assuming bus '00'? And then > > look

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-13 Thread Gerd Hoffmann
Hi, > To look up a PCI device by address, I could use the /sys filesystem. So > for pci//02.0, I would translate the domain into the > filesystem path '/sys/devices/pci:00/' assuming bus '00'? And then > look inside that directory for the the path ':00:02.0'. And then > look

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-12 Thread Jonathon Jongsma
On Thu, 2018-11-08 at 14:21 +0100, Lukáš Hrázký wrote: > Hello, > > On Mon, 2018-11-05 at 17:09 -0600, Jonathon Jongsma wrote: > > This is just a proof of concept utility that takes a PCI device > > address > > and a monitor ID and finds the xrandr output associated with that > > monitor id. > >

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-08 Thread Lukáš Hrázký
Hello, On Mon, 2018-11-05 at 17:09 -0600, Jonathon Jongsma wrote: > This is just a proof of concept utility that takes a PCI device address > and a monitor ID and finds the xrandr output associated with that > monitor id. > --- > > Changes in v2: > - used different format for specifying the PCI

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-07 Thread Jonathon Jongsma
On Wed, 2018-11-07 at 05:51 -0500, Frediano Ziglio wrote: > > > > This is just a proof of concept utility that takes a PCI device > > address > > and a monitor ID and finds the xrandr output associated with that > > monitor id. > > In title and comment "monitor ID" -> "device display ID". > I

Re: [Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-07 Thread Frediano Ziglio
> > This is just a proof of concept utility that takes a PCI device address > and a monitor ID and finds the xrandr output associated with that > monitor id. In title and comment "monitor ID" -> "device display ID". I would add some explanation on the comment like how this is supposed to be

[Spice-devel] [RFC linux vdagent] Add POC for getting xrandr output from monitor ID

2018-11-05 Thread Jonathon Jongsma
This is just a proof of concept utility that takes a PCI device address and a monitor ID and finds the xrandr output associated with that monitor id. --- Changes in v2: - used different format for specifying the PCI address (pci/$domain/$dev.$fn) - used err()/errx() to report errors (from