- 21 8月, 2011 1 次提交
-
-
由 Anthony Liguori 提交于
qemu_malloc/qemu_free no longer exist after this commit. Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 20 8月, 2011 1 次提交
-
-
由 Blue Swirl 提交于
The variable 'status' does not exist anymore, adjust DPRINTF accordingly. Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
-
- 12 8月, 2011 9 次提交
-
-
由 Paolo Bonzini 提交于
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
Also introduce the first occurrence of "independent" SCSIReqOps, to handle invalid commands in common code. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
This will let allow requests to be dispatched through different callbacks, either common or per-device. This patch adjusts the API, the next one will move members to SCSIReqOps. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
With this patch, sense data is stored in the generic data structures for SCSI devices and requests. The SCSI layer takes care of storing sense data in the SCSIDevice for the subsequent REQUEST SENSE command. At the same time, get_sense is removed and scsi_req_get_sense can use an entirely generic implementation. Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
A small improvement in the SCSI request API. Pass the status at the time the request is completed, so that we can assert that no request is completed twice. This would have detected the problem fixed in the previous patch. Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
由 Paolo Bonzini 提交于
In fact, if the HBA's transfer_data callback goes on with scsi_req_continue the request will be completed successfully instead of showing a failure. It can even cause a segmentation fault. An easy way to trigger it is "eject -f cd" during installation (during media test if the installer does something like that). Reviewed-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 01 8月, 2011 4 次提交
-
-
由 Hannes Reinecke 提交于
Instead of using its own definitions scsi-disk should be using the device type of the parent device. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
Sanitize SCSI command definitions. Add _10 suffix to READ_CAPACITY, WRITE_VERIFY, VERIFY, READ_LONG, WRITE_LONG, and WRITE_SAME. Add new command definitions for LOCATE_10, UNMAP, VARLENGTH_CDB, WRITE_FILEMARKS_16, EXTENDED_COPY, ATA_PASSTHROUGH, ACCESS_CONTROL_IN, ACCESS_CONTROL_OUT, COMPARE_AND_WRITE, VERIFY_16, SYNCHRONIZE_CACHE_16, LOCATE_16, ERASE_16, WRITE_LONG_16, LOAD_UNLOAD, VERIFY_12. Remove invalid definition of WRITE_LONG_2. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
REZERO_UNIT command is obsolete. Remove support for it. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
Replace tabs with spaces. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 24 7月, 2011 1 次提交
-
-
由 Matthew Fernandez 提交于
Correct typos of "licenced" to "licensed". Reviewed-by: NStefan Weil <weil@mail.berlios.de> Reviewed-by: NAndreas F=E4rber <andreas.faerber@web.de> Signed-off-by: NMatthew Fernandez <matthew.fernandez@gmail.com> Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
-
- 19 7月, 2011 3 次提交
-
-
由 Hannes Reinecke 提交于
If the serial number is not set we should mask it out in the list of supported VPD pages and mark it as not supported. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
A debugging statement wasn't converted to the new interface. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
'tag' is just an abstraction to identify the command from the driver. So we should make that explicit by replacing 'tag' with a driver-defined pointer 'hba_private'. This saves the lookup for driver handling several commands in parallel. 'tag' is still being kept for tracing purposes. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 26 5月, 2011 11 次提交
-
-
由 Paolo Bonzini 提交于
The LUN field in the CDB is a historical relic. Ignore it as reserved, which is what modern SCSI specifications actually say. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
The return value is unused anyway. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Hannes Reinecke 提交于
scsi_req_parse() already provides for a data direction setting, so we should be using it to check for correct direction. And we should return the sense code 'INVALID FIELD IN CDB' in these cases. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Hannes Reinecke 提交于
The get_sense callback copies existing sense information into the provided buffer. This is required if sense information should be transferred together with the command response. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
Move the common part of scsi-disk.c and scsi-generic.c to the SCSI layer. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Hannes Reinecke 提交于
The SCSI spec has a quite detailed list of sense codes available. It even mandates the use of specific ones for some failure cases. The current implementation just has one type of generic error which is actually a violation of the spec in certain cases. This patch introduces various predefined sense codes to have the sense code reporting more in line with the spec. On top of Hannes's patch I fixed the reply to REQUEST SENSE commands with DESC=0 and a small (<18) length. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
This is for when the request must be dropped in the void, but still memory should be freed. To this end, the devices register a second callback in SCSIBusOps. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
The code for canceling requests upon reset is already the same. Clean it up and move it to scsi-bus.c. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Hannes Reinecke 提交于
Currently the SCSIRequest structure is abstracted away and cannot accessed directly from the driver. This requires the handler to do a lookup on an abstract 'tag' which identifies the SCSIRequest structure. With this patch the SCSIRequest structure is exposed to the driver. This allows use to use it directly as an argument to the SCSIDeviceInfo callback functions and remove the lookup. A new callback function 'alloc_req' is introduced matching 'free req'; unref'ing to free up resources after use is moved into the scsi_command_complete callbacks. This temporarily introduces a leak of requests that are cancelled, when they are removed from the queue and not from the driver. This is fixed later by introducing scsi_req_cancel. That patch in turn depends on this one, because the argument to scsi_req_cancel is a SCSIRequest. Signed-off-by: NHannes Reinecke <hare@suse.de> Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
With the next patch, a device may hold SCSIRequest for an indefinite time. Split a rather big patch, and protect against access errors, by reference counting them. There is some ugliness in scsi_send_command implementation due to the need to unref the request when it fails. This will go away with the next patches, which move the unref'ing to the devices. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Cc: Christoph Hellwig <hch@lst.de>
-
由 Paolo Bonzini 提交于
This abstracts calling the command_complete callback, reducing churn in the following patches. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NChristoph Hellwig <hch@lst.de>
-
- 19 5月, 2011 2 次提交
-
-
由 Markus Armbruster 提交于
DriveInfo is closely tied to -drive, and like -drive, it mixes information about host and guest part of the block device. Unlike DriveInfo, BlockDriverState should be about the host part only. One of the remaining guest bits there is the "type hint". -drive option media sets it, and qdevs "ide-drive", "scsi-disk" and non-qdev IF_XEN devices check it to pick HD vs. CD. Communicate -drive option media via new DriveInfo member media_cd instead. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Markus Armbruster 提交于
A "scsi-disk" is either a hard disk or a CD-ROM, depending on the associated BlockDriverState's type hint. Unclean; disk vs. CD belongs to the guest part, not the host part. Have separate qdevs "scsi-hd" and "scsi-cd" to model disk vs. CD in the guest part. Keep scsi-disk for backward compatibility. Don't copy scsi-disk property removable to scsi-cd. It's not used and always zero(!) there. Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 14 2月, 2011 1 次提交
-
-
由 Jan Kiszka 提交于
Define and use dedicated constants for vm_stop reasons, they actually have nothing to do with the EXCP_* defines used so far. At this chance, specify more detailed reasons so that VM state change handlers can evaluate them. Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com> Signed-off-by: NMarcelo Tosatti <mtosatti@redhat.com>
-
- 25 1月, 2011 1 次提交
-
-
由 Stefan Hajnoczi 提交于
Provide the "removable" qdev property bit to override the SCSI INQUIRY removable (RMB) bit for non-CDROM devices. This will be used by USB Mass Storage Devices, which sometimes have this guest-visible bit set and sometimes do not. They therefore requires a means for user configuration. Signed-off-by: NStefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 17 12月, 2010 1 次提交
-
-
由 Christoph Hellwig 提交于
Support discards via the WRITE SAME command with the unmap bit set, and tell the initiator about the support for it via the block limit and the new thin provisioning EVPD pages. Also fix the comment which incorrectly describedthe block limits EVPD page. Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 12 12月, 2010 2 次提交
-
-
由 Gleb Natapov 提交于
If bootindex is specified on command line a string that describes device in firmware readable way is added into sorted list. Later this list will be passed into firmware to control boot order. Signed-off-by: NGleb Natapov <gleb@redhat.com> Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
-
由 Gleb Natapov 提交于
Add "fw_name" to DeviceInfo to use in device path building. In contrast to "name" "fw_name" should refer to functionality device provides instead of particular device model like "name" does. Signed-off-by: NGleb Natapov <gleb@redhat.com> Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
-
- 25 11月, 2010 3 次提交
-
-
由 Hannes Reinecke 提交于
We parse the CDB twice, which is completely unnecessary. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
The current sense handling in scsi-bus is only used by the scsi-disk driver; the scsi-generic driver is using its own. So we should move the current sense handling into the scsi-disk driver. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Hannes Reinecke 提交于
We should announce and support the block device characterics page only on block devices, not on CDROMs. And the VPD page 0x83 has an off-by-one error. Signed-off-by: NHannes Reinecke <hare@suse.de> Acked-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-