Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-11 Thread Markus Armbruster
Peter Maydell writes: > On 7 January 2016 at 22:43, Max Reitz wrote: >> I hope that the above explanation helped you understand why it bled into >> tray-less devices, from a technical perspective. > > Yes, thanks, that was definitely a helpful

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-08 Thread Peter Maydell
On 7 January 2016 at 22:43, Max Reitz wrote: > I hope that the above explanation helped you understand why it bled into > tray-less devices, from a technical perspective. Yes, thanks, that was definitely a helpful explanation for why the design is the way it is. I'm still not

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Peter Maydell
On 7 January 2016 at 19:37, Max Reitz wrote: > Compare floppy disks, for which we now have a "virtual" tray status: > Whenever a medium is inserted, the "tray" is considered closed. > Otherwise, it is open. This works pretty much like a physical tray would > work; whenever the

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Peter Maydell
On 10 November 2015 at 14:09, Kevin Wolf wrote: > From: Max Reitz > > Implement 'change' on block devices by calling blockdev-open-tray, > blockdev-remove-medium, blockdev-insert-medium (a variation of that > which does not need a node-name) and

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Max Reitz
On 07.01.2016 22:42, Peter Maydell wrote: > On 7 January 2016 at 20:14, Max Reitz wrote: >> On 07.01.2016 20:56, Peter Maydell wrote: >>> It looks like sd.c is the only one which implements a change_media_cb >>> but no is_tray_open, but it would be nice if we could implement

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Peter Maydell
On 7 January 2016 at 20:14, Max Reitz wrote: > On 07.01.2016 20:56, Peter Maydell wrote: >> It looks like sd.c is the only one which implements a change_media_cb >> but no is_tray_open, but it would be nice if we could implement this >> in the default blk_dev_is_tray_open()

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Peter Maydell
On 7 January 2016 at 21:57, Max Reitz wrote: > On 07.01.2016 22:42, Peter Maydell wrote: >> Well, previously sd.c didn't need to have any state for this >> to all work right (or indeed care about implementing a fake >> tray status for a device that doesn't have a tray), so it

Re: [Qemu-block] [Qemu-devel] [PULL v2 10/40] blockdev: Implement change with basic operations

2016-01-07 Thread Max Reitz
On 07.01.2016 23:19, Peter Maydell wrote: > On 7 January 2016 at 21:57, Max Reitz wrote: >> On 07.01.2016 22:42, Peter Maydell wrote: >>> Well, previously sd.c didn't need to have any state for this >>> to all work right (or indeed care about implementing a fake >>> tray status