Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 154937 Details for
Bug 240454
RHEL4 Kernel crash when specifying mem= or highmem= kernel parameter
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
RHEL4 version of the patch to fix memory parameter at PV boot-time when specifying mem=
linux-2.6.9-xen-fix-mem-parm.patch (text/plain), 2.98 KB, created by
Chris Lalancette
on 2007-05-17 17:15:04 UTC
(
hide
)
Description:
RHEL4 version of the patch to fix memory parameter at PV boot-time when specifying mem=
Filename:
MIME Type:
Creator:
Chris Lalancette
Created:
2007-05-17 17:15:04 UTC
Size:
2.98 KB
patch
obsolete
>--- linux-2.6.9/arch/i386/kernel/setup-xen.c.orig >+++ linux-2.6.9/arch/i386/kernel/setup-xen.c >@@ -1592,6 +1592,29 @@ void __init setup_arch(char **cmdline_p) > find_smp_config(); > #endif > >+ if (xen_start_info->nr_pages > max_pfn) { >+ /* >+ * the max_pfn was shrunk (probably by mem= or highmem= >+ * kernel parameter); shrink reservation with the HV >+ */ >+ struct xen_memory_reservation reservation = { >+ .address_bits = 0, >+ .extent_order = 0, >+ .domid = DOMID_SELF >+ }; >+ unsigned int difference; >+ int ret; >+ >+ difference = xen_start_info->nr_pages - max_pfn; >+ >+ set_xen_guest_handle(reservation.extent_start, >+ ((unsigned long *)xen_start_info->mfn_list) + max_pfn); >+ reservation.nr_extents = difference; >+ ret = HYPERVISOR_memory_op(XENMEM_decrease_reservation, >+ &reservation); >+ BUG_ON (ret != difference); >+ } >+ > /* Make sure we have a correctly sized P->M table. */ > if (!xen_feature(XENFEAT_auto_translated_physmap)) { > phys_to_machine_mapping = alloc_bootmem_low_pages( >@@ -1600,10 +1623,10 @@ void __init setup_arch(char **cmdline_p) > max_pfn * sizeof(unsigned long)); > memcpy(phys_to_machine_mapping, > (unsigned long *)xen_start_info->mfn_list, >- xen_start_info->nr_pages * sizeof(unsigned long)); >+ max_pfn * sizeof(unsigned long)); > free_bootmem( > __pa(xen_start_info->mfn_list), >- PFN_PHYS(PFN_UP(xen_start_info->nr_pages * >+ PFN_PHYS(PFN_UP(max_pfn * > sizeof(unsigned long)))); > > /* >--- linux-2.6.9/arch/x86_64/kernel/setup-xen.c.orig >+++ linux-2.6.9/arch/x86_64/kernel/setup-xen.c >@@ -829,6 +829,29 @@ void __init setup_arch(char **cmdline_p) > HYPERVISOR_update_va_mapping(va, __pte_ma(0), 0); > } > >+ if (xen_start_info->nr_pages > end_pfn) { >+ /* >+ * the end_pfn was shrunk (probably by mem= or highmem= >+ * kernel parameter); shrink reservation with the HV >+ */ >+ struct xen_memory_reservation reservation = { >+ .address_bits = 0, >+ .extent_order = 0, >+ .domid = DOMID_SELF >+ }; >+ unsigned int difference; >+ int ret; >+ >+ difference = xen_start_info->nr_pages - end_pfn; >+ >+ set_xen_guest_handle(reservation.extent_start, >+ ((unsigned long *)xen_start_info->mfn_list) + end_pfn); >+ reservation.nr_extents = difference; >+ ret = HYPERVISOR_memory_op(XENMEM_decrease_reservation, >+ &reservation); >+ BUG_ON (ret != difference); >+ } >+ > if (!xen_feature(XENFEAT_auto_translated_physmap)) { > /* Make sure we have a large enough P->M table. */ > phys_to_machine_mapping = alloc_bootmem( >@@ -837,10 +860,10 @@ void __init setup_arch(char **cmdline_p) > end_pfn * sizeof(unsigned long)); > memcpy(phys_to_machine_mapping, > (unsigned long *)xen_start_info->mfn_list, >- xen_start_info->nr_pages * sizeof(unsigned long)); >+ end_pfn * sizeof(unsigned long)); > free_bootmem( > __pa(xen_start_info->mfn_list), >- PFN_PHYS(PFN_UP(xen_start_info->nr_pages * >+ PFN_PHYS(PFN_UP(end_pfn * > sizeof(unsigned long)))); > > /* Destroyed 'initial mapping' of old p2m table. */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 240454
:
154937
|
154963
|
155743