Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2050d45d authored by Pavel Machek's avatar Pavel Machek Committed by Ingo Molnar
Browse files

x86: fix long standing bug with usb after hibernation with 4GB ram



aperture_64.c takes a piece of memory and makes it into iommu
window... but such window may not be saved by swsusp -- that leads to
oops during hibernation.

Signed-off-by: default avatarPavel Machek <pavel@suse.cz>
Acked-by: default avatar"Rafael J. Wysocki" <rjw@sisk.pl>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 96bcf458
Loading
Loading
Loading
Loading
+3 −0
Original line number Original line Diff line number Diff line
@@ -18,6 +18,7 @@
#include <linux/pci.h>
#include <linux/pci.h>
#include <linux/bitops.h>
#include <linux/bitops.h>
#include <linux/ioport.h>
#include <linux/ioport.h>
#include <linux/suspend.h>
#include <asm/e820.h>
#include <asm/e820.h>
#include <asm/io.h>
#include <asm/io.h>
#include <asm/gart.h>
#include <asm/gart.h>
@@ -76,6 +77,8 @@ static u32 __init allocate_aperture(void)
	printk(KERN_INFO "Mapping aperture over %d KB of RAM @ %lx\n",
	printk(KERN_INFO "Mapping aperture over %d KB of RAM @ %lx\n",
			aper_size >> 10, __pa(p));
			aper_size >> 10, __pa(p));
	insert_aperture_resource((u32)__pa(p), aper_size);
	insert_aperture_resource((u32)__pa(p), aper_size);
	register_nosave_region((u32)__pa(p) >> PAGE_SHIFT,
				(u32)__pa(p+aper_size) >> PAGE_SHIFT);


	return (u32)__pa(p);
	return (u32)__pa(p);
}
}