mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-09 04:15:52 +00:00
usb_block: fix 'Request_sense_repsonse' MMIO size
Due to a bug in the original implementation, the size of the MMIO range covering the 'Request_sense_response' data was set too large during the MMIO boundary change. This rendered devices that were not yet ready and required an 'Request_sense' command unusable. The commit also adapts all other commands where the MMIO size does not match the expected one. Fixes #5133.
This commit is contained in:
parent
229f01b153
commit
ff728eb6ce
@ -134,7 +134,7 @@ struct Scsi::Inquiry_response : Genode::Const_mmio<0x24>
|
||||
};
|
||||
|
||||
|
||||
struct Scsi::Request_sense_response : Genode::Const_mmio<0x13>
|
||||
struct Scsi::Request_sense_response : Genode::Const_mmio<0x12>
|
||||
{
|
||||
enum { LENGTH = 18 };
|
||||
|
||||
@ -153,7 +153,11 @@ struct Scsi::Request_sense_response : Genode::Const_mmio<0x13>
|
||||
struct Asc : Register<0xc, 8> { }; /* additional sense code */
|
||||
struct Asq : Register<0xd, 8> { }; /* additional sense code qualifier */
|
||||
struct Fru : Register<0xe, 8> { }; /* field replaceable unit code */
|
||||
struct Sks : Register<0xf, 32> { }; /* sense key specific (3 byte) */
|
||||
|
||||
struct Sks_0 : Register<0xf, 8> { };
|
||||
struct Sks_1 : Register<0x10, 8> { };
|
||||
struct Sks_2 : Register<0x11, 8> { };
|
||||
struct Sks : Bitset_3<Sks_0, Sks_1, Sks_2> { }; /* sense key specific (3 byte) */
|
||||
|
||||
Request_sense_response(Const_byte_range_ptr const &range, bool verbose)
|
||||
: Const_mmio(range) { if (verbose) dump(); }
|
||||
@ -192,7 +196,7 @@ struct Scsi::Capacity_response_10 : Genode::Const_mmio<0x8>
|
||||
};
|
||||
|
||||
|
||||
struct Scsi::Capacity_response_16 : Genode::Const_mmio<0xc>
|
||||
struct Scsi::Capacity_response_16 : Genode::Const_mmio<0x20>
|
||||
{
|
||||
enum { LENGTH = 32 };
|
||||
|
||||
@ -267,7 +271,7 @@ struct Scsi::Inquiry : Cmd_6
|
||||
};
|
||||
|
||||
|
||||
struct Scsi::Start_stop : Genode::Mmio<0x5>
|
||||
struct Scsi::Start_stop : Genode::Mmio<0x6>
|
||||
{
|
||||
enum { LENGTH = 6 };
|
||||
struct Op : Register<0x0, 8> { }; /* SCSI command */
|
||||
@ -279,6 +283,7 @@ struct Scsi::Start_stop : Genode::Mmio<0x5>
|
||||
struct Loej : Bitfield<1, 1> { }; /* load eject */
|
||||
struct St : Bitfield<0, 1> { }; /* start */
|
||||
}; /* flags */
|
||||
struct Ctl : Register<0x5, 8> { }; /* control */
|
||||
|
||||
Start_stop(Byte_range_ptr const &range) : Mmio(range)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user