DEV9: fix incorrect max hdd size

PS2 support 28-bit addressing not the the 24-bit addressing. 24-bit addressing is limited by 8Gb storage, while 28-bit is limited by 128Gb
This commit is contained in:
AKuHAK 2023-12-17 20:41:00 +02:00 committed by refractionpcsx2
parent c3bafa2a40
commit 669cadf1ee
1 changed files with 2 additions and 2 deletions

View File

@ -47,8 +47,8 @@ void ATA::WritePaddedString(u8* data, int* index, const std::string& value, u32
void ATA::CreateHDDinfo(u64 sizeSectors)
{
//PS2 is limited to 32bit size HDD (2TB), however,
//we don't yet support 48bit, so limit to 24bit size
constexpr u32 maxSize = 1 << 24;
//we don't yet support 48bit, so limit to 28bit size
constexpr u32 maxSize = (1 << 28) - 1; // 128Gb
sizeSectors = std::min<u32>(sizeSectors, maxSize);
constexpr u16 sectorSize = 512;