mirror of
https://github.com/aaru-dps/Aaru.Server.git
synced 2025-12-16 19:24:27 +00:00
ATA pass through needs buffer position to be relative to structure so use accordingly.
This commit is contained in:
@@ -74,6 +74,7 @@ namespace DiscImageChef.Devices.Windows
|
||||
/// <summary>
|
||||
/// Indicates transfer direction and kind of operation
|
||||
/// </summary>
|
||||
[MarshalAs(UnmanagedType.U2)]
|
||||
public AtaFlags AtaFlags;
|
||||
/// <summary>
|
||||
/// Indicates IDE port or bus, set by driver
|
||||
@@ -104,7 +105,7 @@ namespace DiscImageChef.Devices.Windows
|
||||
/// </summary>
|
||||
public uint ReservedAsUlong;
|
||||
/// <summary>
|
||||
/// Pointer to data buffer
|
||||
/// Pointer to data buffer relative to start of this structure
|
||||
/// </summary>
|
||||
public IntPtr DataBuffer;
|
||||
/// <summary>
|
||||
@@ -117,6 +118,15 @@ namespace DiscImageChef.Devices.Windows
|
||||
public AtaTaskFile CurrentTaskFile;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct AtaPassThroughDirectWithBuffer
|
||||
{
|
||||
public AtaPassThroughDirect aptd;
|
||||
public uint filler;
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 64 * 512)]
|
||||
public byte[] dataBuffer;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Explicit)]
|
||||
struct AtaTaskFile
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user