mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-20 16:46:23 +08:00
Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: powerpc/cell/axon-msi: Fix MSI after kexec powerpc: Fix bootmem reservation on uninitialized node powerpc: Check for valid hugepage size in hugetlb_get_unmapped_area
This commit is contained in:
commit
eef70b217a
@ -507,6 +507,9 @@ unsigned long hugetlb_get_unmapped_area(struct file *file, unsigned long addr,
|
||||
{
|
||||
struct hstate *hstate = hstate_file(file);
|
||||
int mmu_psize = shift_to_mmu_psize(huge_page_shift(hstate));
|
||||
|
||||
if (!mmu_huge_psizes[mmu_psize])
|
||||
return -EINVAL;
|
||||
return slice_get_unmapped_area(addr, len, flags, mmu_psize, 1, 0);
|
||||
}
|
||||
|
||||
|
@ -901,10 +901,17 @@ static void mark_reserved_regions_for_nid(int nid)
|
||||
if (end_pfn > node_ar.end_pfn)
|
||||
reserve_size = (node_ar.end_pfn << PAGE_SHIFT)
|
||||
- (start_pfn << PAGE_SHIFT);
|
||||
dbg("reserve_bootmem %lx %lx nid=%d\n", physbase,
|
||||
reserve_size, node_ar.nid);
|
||||
reserve_bootmem_node(NODE_DATA(node_ar.nid), physbase,
|
||||
reserve_size, BOOTMEM_DEFAULT);
|
||||
/*
|
||||
* Only worry about *this* node, others may not
|
||||
* yet have valid NODE_DATA().
|
||||
*/
|
||||
if (node_ar.nid == nid) {
|
||||
dbg("reserve_bootmem %lx %lx nid=%d\n",
|
||||
physbase, reserve_size, node_ar.nid);
|
||||
reserve_bootmem_node(NODE_DATA(node_ar.nid),
|
||||
physbase, reserve_size,
|
||||
BOOTMEM_DEFAULT);
|
||||
}
|
||||
/*
|
||||
* if reserved region is contained in the active region
|
||||
* then done.
|
||||
@ -929,7 +936,6 @@ static void mark_reserved_regions_for_nid(int nid)
|
||||
void __init do_init_bootmem(void)
|
||||
{
|
||||
int nid;
|
||||
unsigned int i;
|
||||
|
||||
min_low_pfn = 0;
|
||||
max_low_pfn = lmb_end_of_DRAM() >> PAGE_SHIFT;
|
||||
|
@ -413,6 +413,9 @@ static int axon_msi_probe(struct of_device *device,
|
||||
MSIC_CTRL_IRQ_ENABLE | MSIC_CTRL_ENABLE |
|
||||
MSIC_CTRL_FIFO_SIZE);
|
||||
|
||||
msic->read_offset = dcr_read(msic->dcr_host, MSIC_WRITE_OFFSET_REG)
|
||||
& MSIC_FIFO_SIZE_MASK;
|
||||
|
||||
device->dev.platform_data = msic;
|
||||
|
||||
ppc_md.setup_msi_irqs = axon_msi_setup_msi_irqs;
|
||||
|
Loading…
Reference in New Issue
Block a user