Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions linux/ps4-kexec-common/firmware.c
Original file line number Diff line number Diff line change
Expand Up @@ -384,8 +384,8 @@ ssize_t firmware_extract(void *dest)
cpio_hdr(&p, "lib", DIR, 0);
cpio_hdr(&p, "lib/firmware", DIR, 0);

/** We need detect the size of edid first, on some monitor it is 128 on other 256 bytes, so for now remove it **/
int edid_sz = (((unsigned char*)kern.edid)[126]?256:128);
int ext_blocks = ((unsigned char*)kern.edid)[126];
int edid_sz = 128 * (1 + ext_blocks);
cpio_hdr(&p, "lib/firmware/edid", DIR, 0);
cpio_hdr(&p, "lib/firmware/edid/my_edid.bin", FILE, edid_sz);
copy_edid(&p, edid_sz);
Expand Down
4 changes: 2 additions & 2 deletions linux/ps4-kexec-common/firmware.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

//sizes eap_hdd_key
#define EAP_HDD_KEY_SIZE 0x20
#define EDID_SIZE 256
#define EDID_SIZE (128 * 256)

// sizes for liverpool
#define LVP_FW_CE_SIZE 8576
Expand Down Expand Up @@ -54,7 +54,7 @@
#define FW_HEADER_SIZE 256

// Leave space for 16 files (currently 12)
#define FW_CPIO_SIZE (EAP_HDD_KEY_SIZE /* + EDID_SIZE */ + (CPIO_HEADER_SIZE * 16) + FW_CE_SIZE + FW_ME_SIZE + \
#define FW_CPIO_SIZE (EAP_HDD_KEY_SIZE + EDID_SIZE + (CPIO_HEADER_SIZE * 16) + FW_CE_SIZE + FW_ME_SIZE + \
FW_MEC_SIZE + FW_MEC2_SIZE + FW_PFP_SIZE + \
FW_RLC_SIZE + FW_SDMA_SIZE + FW_SDMA1_SIZE + \
FW_HEADER_SIZE * 8)
Expand Down
Loading