Page MenuHomeFreeBSD

D16586.id46270.diff
No OneTemporary

D16586.id46270.diff

Index: stand/efi/loader/arch/i386/efimd.c
===================================================================
--- stand/efi/loader/arch/i386/efimd.c
+++ stand/efi/loader/arch/i386/efimd.c
@@ -70,14 +70,14 @@
UINTN mmsz, pages, sz;
UINT32 mmver;
- bi->bi_systab = (uint64_t)ST;
- bi->bi_hcdp = (uint64_t)efi_get_table(&hcdp_guid);
+ bi->bi_systab = (uintptr_t)ST;
+ bi->bi_hcdp = (uintptr_t)efi_get_table(&hcdp_guid);
sz = sizeof(EFI_HANDLE);
status = BS->LocateHandle(ByProtocol, &fpswa_guid, 0, &sz, &handle);
if (status == 0)
status = BS->HandleProtocol(handle, &fpswa_guid, &fpswa);
- bi->bi_fpswa = (status == 0) ? (uint64_t)fpswa : 0;
+ bi->bi_fpswa = (status == 0) ? (uintptr_t)fpswa : 0;
bisz = (sizeof(struct bootinfo) + 0x0f) & ~0x0f;
@@ -109,7 +109,7 @@
* aligned).
*/
*bi_addr = addr;
- mm = (void *)(addr + bisz);
+ mm = (void *)(uintptr_t)(addr + bisz);
sz = (EFI_PAGE_SIZE * pages) - bisz;
status = BS->GetMemoryMap(&sz, mm, &mapkey, &mmsz, &mmver);
if (EFI_ERROR(status)) {
@@ -117,12 +117,12 @@
(long)status);
return (EINVAL);
}
- bi->bi_memmap = (uint64_t)mm;
+ bi->bi_memmap = (uintptr_t)mm;
bi->bi_memmap_size = sz;
bi->bi_memdesc_size = mmsz;
bi->bi_memdesc_version = mmver;
- bcopy(bi, (void *)(*bi_addr), sizeof(*bi));
+ bcopy(bi, (void *)(uintptr_t)(*bi_addr), sizeof(*bi));
return (0);
}
Index: stand/efi/loader/bootinfo.c
===================================================================
--- stand/efi/loader/bootinfo.c
+++ stand/efi/loader/bootinfo.c
@@ -363,7 +363,7 @@
* memory map on a 16-byte boundary (the bootinfo block is page
* aligned).
*/
- efihdr = (struct efi_map_header *)addr;
+ efihdr = (struct efi_map_header *)(uintptr_t)addr;
mm = (void *)((uint8_t *)efihdr + efisz);
sz = (EFI_PAGE_SIZE * pages) - efisz;
Index: stand/efi/loader/copy.c
===================================================================
--- stand/efi/loader/copy.c
+++ stand/efi/loader/copy.c
@@ -278,9 +278,9 @@
{
uint64_t *src, *dst, *last;
- src = (uint64_t *)staging;
- dst = (uint64_t *)(staging - stage_offset);
- last = (uint64_t *)staging_end;
+ src = (uint64_t *)(uintptr_t)staging;
+ dst = (uint64_t *)(uintptr_t)(staging - stage_offset);
+ last = (uint64_t *)(uintptr_t)staging_end;
while (src < last)
*dst++ = *src++;

File Metadata

Mime Type
text/plain
Expires
Tue, May 19, 12:25 AM (18 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33279682
Default Alt Text
D16586.id46270.diff (2 KB)

Event Timeline