From 9ccb0eb027679351e81d9cf41d0cfd494fe05e24 Mon Sep 17 00:00:00 2001 From: Jacob Pease Date: Tue, 23 Jul 2024 15:46:18 -0500 Subject: [PATCH] Removed references to card_type. --- fpga/zsbl/gpt.c | 12 ++++++------ fpga/zsbl/gpt.h | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/fpga/zsbl/gpt.c b/fpga/zsbl/gpt.c index 97e3e4e46..65f56924b 100644 --- a/fpga/zsbl/gpt.c +++ b/fpga/zsbl/gpt.c @@ -10,7 +10,7 @@ */ -int gpt_load_partitions(BYTE card_type) { +int gpt_load_partitions() { // In this version of the GPT partition code // I'm going to assume that the SD card is already initialized. @@ -21,7 +21,7 @@ int gpt_load_partitions(BYTE card_type) { int ret = 0; //ret = disk_read(/* BYTE * buf, LBA_t sector, UINT count, BYTE card_type */); - ret = disk_read(lba1_buf, 1, 1, card_type); + ret = disk_read(lba1_buf, 1, 1); /* Possible error handling with UART message if ( ret != 0 ) { @@ -31,16 +31,16 @@ int gpt_load_partitions(BYTE card_type) { gpt_pth_t *lba1 = (gpt_pth_t *)lba1_buf; BYTE lba2_buf[512]; - ret = disk_read(lba2_buf, (LBA_t)lba1->partition_entries_lba, 1, card_type); + ret = disk_read(lba2_buf, (LBA_t)lba1->partition_entries_lba, 1); // Load parition entries for the relevant boot partitions. partition_entries_t *fdt = (partition_entries_t *)(lba2_buf); partition_entries_t *opensbi = (partition_entries_t *)(lba2_buf + 128); partition_entries_t *kernel = (partition_entries_t *)(lba2_buf + 256); - ret = disk_read((BYTE *)FDT_ADDRESS, fdt->first_lba, fdt->last_lba - fdt->first_lba + 1, card_type); - ret = disk_read((BYTE *)OPENSBI_ADDRESS, opensbi->first_lba, opensbi->last_lba - opensbi->first_lba + 1, card_type); - ret = disk_read((BYTE *)KERNEL_ADDRESS, kernel->first_lba,kernel->last_lba - kernel->first_lba + 1, card_type); + ret = disk_read((BYTE *)FDT_ADDRESS, fdt->first_lba, fdt->last_lba - fdt->first_lba + 1); + ret = disk_read((BYTE *)OPENSBI_ADDRESS, opensbi->first_lba, opensbi->last_lba - opensbi->first_lba + 1); + ret = disk_read((BYTE *)KERNEL_ADDRESS, kernel->first_lba,kernel->last_lba - kernel->first_lba + 1); return 0; } diff --git a/fpga/zsbl/gpt.h b/fpga/zsbl/gpt.h index 4aefae229..5ce5e1d4b 100644 --- a/fpga/zsbl/gpt.h +++ b/fpga/zsbl/gpt.h @@ -37,4 +37,4 @@ typedef struct partition_entries } partition_entries_t; // Find boot partition and load it to the destination -int gpt_load_partitions(BYTE card_type); +int gpt_load_partitions();