Page MenuHomeFreeBSD

D29759.diff
No OneTemporary

D29759.diff

diff --git a/sys/amd64/amd64/efirt_machdep.c b/sys/amd64/amd64/efirt_machdep.c
--- a/sys/amd64/amd64/efirt_machdep.c
+++ b/sys/amd64/amd64/efirt_machdep.c
@@ -204,7 +204,7 @@
descsz)) {
if ((p->md_attr & EFI_MD_ATTR_RT) == 0)
continue;
- if (p->md_virt != NULL && (uint64_t)p->md_virt != p->md_phys) {
+ if (p->md_virt != 0 && p->md_virt != p->md_phys) {
if (bootverbose)
printf("EFI Runtime entry %d is mapped\n", i);
goto fail;
diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c
--- a/sys/amd64/amd64/machdep.c
+++ b/sys/amd64/amd64/machdep.c
@@ -1107,7 +1107,7 @@
type = types[p->md_type];
else
type = "<INVALID>";
- printf("%23s %012lx %12p %08lx ", type, p->md_phys,
+ printf("%23s %012lx %012lx %08lx ", type, p->md_phys,
p->md_virt, p->md_pages);
if (p->md_attr & EFI_MD_ATTR_UC)
printf("UC ");
diff --git a/sys/arm/arm/machdep_boot.c b/sys/arm/arm/machdep_boot.c
--- a/sys/arm/arm/machdep_boot.c
+++ b/sys/arm/arm/machdep_boot.c
@@ -442,7 +442,7 @@
type = types[p->md_type];
else
type = "<INVALID>";
- printf("%23s %012llx %12p %08llx ", type, p->md_phys,
+ printf("%23s %012llx %012llx %08llx ", type, p->md_phys,
p->md_virt, p->md_pages);
if (p->md_attr & EFI_MD_ATTR_UC)
printf("UC ");
diff --git a/sys/arm64/arm64/efirt_machdep.c b/sys/arm64/arm64/efirt_machdep.c
--- a/sys/arm64/arm64/efirt_machdep.c
+++ b/sys/arm64/arm64/efirt_machdep.c
@@ -184,7 +184,7 @@
descsz)) {
if ((p->md_attr & EFI_MD_ATTR_RT) == 0)
continue;
- if (p->md_virt != NULL && (uint64_t)p->md_virt != p->md_phys) {
+ if (p->md_virt != 0 && p->md_virt != p->md_phys) {
if (bootverbose)
printf("EFI Runtime entry %d is mapped\n", i);
goto fail;
diff --git a/sys/arm64/arm64/machdep.c b/sys/arm64/arm64/machdep.c
--- a/sys/arm64/arm64/machdep.c
+++ b/sys/arm64/arm64/machdep.c
@@ -1046,7 +1046,7 @@
type = types[p->md_type];
else
type = "<INVALID>";
- printf("%23s %012lx %12p %08lx ", type, p->md_phys,
+ printf("%23s %012lx %012lx %08lx ", type, p->md_phys,
p->md_virt, p->md_pages);
if (p->md_attr & EFI_MD_ATTR_UC)
printf("UC ");
diff --git a/sys/dev/efidev/efirt.c b/sys/dev/efidev/efirt.c
--- a/sys/dev/efidev/efirt.c
+++ b/sys/dev/efidev/efirt.c
@@ -126,8 +126,8 @@
if ((p->md_attr & EFI_MD_ATTR_RT) == 0)
continue;
- if (addr >= (uintptr_t)p->md_virt &&
- addr < (uintptr_t)p->md_virt + p->md_pages * PAGE_SIZE)
+ if (addr >= p->md_virt &&
+ addr < p->md_virt + p->md_pages * PAGE_SIZE)
return (true);
}
diff --git a/sys/sys/efi.h b/sys/sys/efi.h
--- a/sys/sys/efi.h
+++ b/sys/sys/efi.h
@@ -74,7 +74,7 @@
#define EFI_MD_TYPE_PERSISTENT 14 /* Persistent memory. */
uint32_t __pad;
uint64_t md_phys;
- void *md_virt;
+ uint64_t md_virt;
uint64_t md_pages;
uint64_t md_attr;
#define EFI_MD_ATTR_UC 0x0000000000000001UL

File Metadata

Mime Type
text/plain
Expires
Tue, Jan 28, 5:31 AM (10 h, 17 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16252274
Default Alt Text
D29759.diff (2 KB)

Event Timeline