[prev in list] [next in list] [prev in thread] [next in thread] 

List:       fedora-extras-commits
Subject:    rpms/kernel/devel kernel.spec, 1.1294.2.95,
From:       myoung <myoung () fedoraproject ! org>
Date:       2010-03-31 21:53:40
Message-ID: 20100331215340.C6AE511C04C3 () cvs01 ! phx2 ! fedoraproject ! org
[Download RAW message or body]

Author: myoung

Update of /cvs/pkgs/rpms/kernel/devel
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv17224

Modified Files:
      Tag: private-myoung-dom0-branch
	kernel.spec xen.pvops.patch 
Log Message:
Follow xen/stable-2.6.32.x branch (this was previously the same as xen/stable)



Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/kernel.spec,v
retrieving revision 1.1294.2.95
retrieving revision 1.1294.2.96
diff -u -p -r1.1294.2.95 -r1.1294.2.96
--- kernel.spec	31 Mar 2010 21:07:33 -0000	1.1294.2.95
+++ kernel.spec	31 Mar 2010 21:53:26 -0000	1.1294.2.96
@@ -2113,7 +2113,7 @@ fi
 
 %changelog
 * Wed Mar 31 2010 Michael Young <m.a.young@durham.ac.uk>
-- update pvops which introduces PAT support
+- update pvops (xen/stable-2.6.32.x branch) which introduces PAT support
 
 * Tue Mar 30 2010 John W. Linville <linville@redhat.com> 2.6.32.10-94
 - Avoid null pointer dereference introduced by 'ssb: check for sprom' (#577463)

xen.pvops.patch:
 Documentation/x86/x86_64/boot-options.txt       |    6 
 arch/ia64/include/asm/dma-mapping.h             |    2 
 arch/ia64/include/asm/swiotlb.h                 |    2 
 arch/ia64/include/asm/xen/events.h              |    4 
 arch/ia64/kernel/pci-swiotlb.c                  |    4 
 arch/powerpc/include/asm/dma-mapping.h          |    2 
 arch/powerpc/kernel/setup_32.c                  |    2 
 arch/powerpc/kernel/setup_64.c                  |    2 
 arch/x86/Kconfig                                |    4 
 arch/x86/include/asm/amd_iommu.h                |    4 
 arch/x86/include/asm/calgary.h                  |    2 
 arch/x86/include/asm/dma-mapping.h              |    7 
 arch/x86/include/asm/gart.h                     |    9 
 arch/x86/include/asm/hpet.h                     |    2 
 arch/x86/include/asm/io.h                       |   15 
 arch/x86/include/asm/io_apic.h                  |    3 
 arch/x86/include/asm/iommu.h                    |    2 
 arch/x86/include/asm/irq_vectors.h              |   14 
 arch/x86/include/asm/microcode.h                |    9 
 arch/x86/include/asm/mmu.h                      |    3 
 arch/x86/include/asm/paravirt.h                 |    7 
 arch/x86/include/asm/paravirt_types.h           |    2 
 arch/x86/include/asm/pci.h                      |    8 
 arch/x86/include/asm/pci_x86.h                  |    2 
 arch/x86/include/asm/pgtable.h                  |    6 
 arch/x86/include/asm/pgtable_64.h               |    2 
 arch/x86/include/asm/processor.h                |    4 
 arch/x86/include/asm/swiotlb.h                  |   11 
 arch/x86/include/asm/syscalls.h                 |    8 
 arch/x86/include/asm/tlbflush.h                 |    6 
 arch/x86/include/asm/x86_init.h                 |   10 
 arch/x86/include/asm/xen/hypercall.h            |   36 
 arch/x86/include/asm/xen/hypervisor.h           |   27 
 arch/x86/include/asm/xen/interface.h            |    8 
 arch/x86/include/asm/xen/interface_32.h         |    5 
 arch/x86/include/asm/xen/interface_64.h         |   13 
 arch/x86/include/asm/xen/iommu.h                |   12 
 arch/x86/include/asm/xen/page.h                 |   16 
 arch/x86/include/asm/xen/pci.h                  |  104 +
 arch/x86/include/asm/xen/swiotlb-xen.h          |   14 
 arch/x86/kernel/Makefile                        |    1 
 arch/x86/kernel/acpi/boot.c                     |   21 
 arch/x86/kernel/acpi/processor.c                |   14 
 arch/x86/kernel/acpi/sleep.c                    |    2 
 arch/x86/kernel/amd_iommu.c                     |   23 
 arch/x86/kernel/amd_iommu_init.c                |   25 
 arch/x86/kernel/aperture_64.c                   |    4 
 arch/x86/kernel/apic/io_apic.c                  |   53 
 arch/x86/kernel/cpu/mtrr/Makefile               |    1 
 arch/x86/kernel/cpu/mtrr/amd.c                  |    6 
 arch/x86/kernel/cpu/mtrr/centaur.c              |    6 
 arch/x86/kernel/cpu/mtrr/cyrix.c                |    6 
 arch/x86/kernel/cpu/mtrr/generic.c              |   13 
 arch/x86/kernel/cpu/mtrr/main.c                 |   20 
 arch/x86/kernel/cpu/mtrr/mtrr.h                 |   11 
 arch/x86/kernel/cpu/mtrr/xen.c                  |  109 +
 arch/x86/kernel/crash.c                         |    5 
 arch/x86/kernel/hpet.c                          |    2 
 arch/x86/kernel/ioport.c                        |   40 
 arch/x86/kernel/ldt.c                           |    3 
 arch/x86/kernel/microcode_core.c                |    6 
 arch/x86/kernel/microcode_xen.c                 |  201 ++
 arch/x86/kernel/paravirt.c                      |    1 
 arch/x86/kernel/pci-calgary_64.c                |   73 -
 arch/x86/kernel/pci-dma.c                       |   38 
 arch/x86/kernel/pci-gart_64.c                   |   40 
 arch/x86/kernel/pci-nommu.c                     |   11 
 arch/x86/kernel/pci-swiotlb.c                   |   21 
 arch/x86/kernel/process.c                       |   27 
 arch/x86/kernel/reboot.c                        |    4 
 arch/x86/kernel/setup.c                         |    4 
 arch/x86/kernel/x86_init.c                      |    8 
 arch/x86/mm/Makefile                            |    5 
 arch/x86/mm/gup.c                               |    5 
 arch/x86/mm/pat.c                               |    2 
 arch/x86/mm/pgtable.c                           |   19 
 arch/x86/mm/tlb.c                               |   37 
 arch/x86/pci/Makefile                           |    1 
 arch/x86/pci/common.c                           |   18 
 arch/x86/pci/i386.c                             |    2 
 arch/x86/pci/init.c                             |    6 
 arch/x86/pci/xen.c                              |  154 ++
 arch/x86/xen/Kconfig                            |   37 
 arch/x86/xen/Makefile                           |    5 
 arch/x86/xen/apic.c                             |   33 
 arch/x86/xen/enlighten.c                        |   96 +
 arch/x86/xen/mmu.c                              |  527 +++++++
 arch/x86/xen/pci-swiotlb-xen.c                  |   52 
 arch/x86/xen/pci.c                              |  296 ++++
 arch/x86/xen/setup.c                            |  119 +
 arch/x86/xen/smp.c                              |    9 
 arch/x86/xen/time.c                             |   16 
 arch/x86/xen/vga.c                              |   67 
 arch/x86/xen/xen-ops.h                          |   20 
 block/blk-core.c                                |    2 
 drivers/acpi/Makefile                           |    1 
 drivers/acpi/acpi_memhotplug.c                  |   19 
 drivers/acpi/acpica/hwsleep.c                   |   16 
 drivers/acpi/processor_core.c                   |   26 
 drivers/acpi/processor_idle.c                   |   17 
 drivers/acpi/processor_perflib.c                |    4 
 drivers/acpi/processor_xen.c                    |  616 +++++++++
 drivers/acpi/sleep.c                            |   19 
 drivers/block/Kconfig                           |    1 
 drivers/block/xen-blkfront.c                    |  134 +
 drivers/char/agp/intel-agp.c                    |   23 
 drivers/char/hvc_xen.c                          |  101 +
 drivers/gpu/drm/drm_drv.c                       |    2 
 drivers/gpu/drm/drm_gem.c                       |    2 
 drivers/gpu/drm/drm_scatter.c                   |   67 
 drivers/gpu/drm/ttm/ttm_bo_vm.c                 |    2 
 drivers/input/xen-kbdfront.c                    |    5 
 drivers/net/Kconfig                             |    1 
 drivers/net/xen-netfront.c                      |   11 
 drivers/pci/Kconfig                             |   10 
 drivers/pci/Makefile                            |    4 
 drivers/pci/bus.c                               |    1 
 drivers/pci/dmar.c                              |    7 
 drivers/pci/intel-iommu.c                       |    6 
 drivers/pci/msi.c                               |   17 
 drivers/pci/xen-iommu.c                         |  271 ++++
 drivers/pci/xen-pcifront.c                      | 1156 +++++++++++++++++
 drivers/video/Kconfig                           |    1 
 drivers/video/broadsheetfb.c                    |    2 
 drivers/video/fb_defio.c                        |    4 
 drivers/video/hecubafb.c                        |    2 
 drivers/video/metronomefb.c                     |    2 
 drivers/video/xen-fbfront.c                     |    7 
 drivers/xen/Kconfig                             |  125 +
 drivers/xen/Makefile                            |   26 
 drivers/xen/acpi.c                              |   23 
 drivers/xen/acpi_processor.c                    |  417 ++++++
 drivers/xen/balloon.c                           |  264 +++
 drivers/xen/biomerge.c                          |   14 
 drivers/xen/blkback/Makefile                    |    4 
 drivers/xen/blkback/blkback-pagemap.c           |  109 +
 drivers/xen/blkback/blkback-pagemap.h           |   36 
 drivers/xen/blkback/blkback.c                   |  675 ++++++++++
 drivers/xen/blkback/common.h                    |  143 ++
 drivers/xen/blkback/interface.c                 |  186 ++
 drivers/xen/blkback/vbd.c                       |  161 ++
 drivers/xen/blkback/xenbus.c                    |  546 ++++++++
 drivers/xen/blktap/Makefile                     |    3 
 drivers/xen/blktap/blktap.h                     |  253 +++
 drivers/xen/blktap/control.c                    |  284 ++++
 drivers/xen/blktap/device.c                     | 1138 ++++++++++++++++
 drivers/xen/blktap/request.c                    |  297 ++++
 drivers/xen/blktap/ring.c                       |  615 +++++++++
 drivers/xen/blktap/sysfs.c                      |  451 ++++++
 drivers/xen/blktap/wait_queue.c                 |   40 
 drivers/xen/cpu_hotplug.c                       |    1 
 drivers/xen/events.c                            |  475 ++++++-
 drivers/xen/evtchn.c                            |   83 -
 drivers/xen/features.c                          |    2 
 drivers/xen/gntdev.c                            |  626 +++++++++
 drivers/xen/grant-table.c                       |  106 +
 drivers/xen/netback/Makefile                    |    3 
 drivers/xen/netback/common.h                    |  227 +++
 drivers/xen/netback/interface.c                 |  410 ++++++
 drivers/xen/netback/netback.c                   | 1613 ++++++++++++++++++++++++
 drivers/xen/netback/xenbus.c                    |  523 +++++++
 drivers/xen/pci.c                               |  124 +
 drivers/xen/pciback/Makefile                    |   17 
 drivers/xen/pciback/conf_space.c                |  435 ++++++
 drivers/xen/pciback/conf_space.h                |  126 +
 drivers/xen/pciback/conf_space_capability.c     |   66 
 drivers/xen/pciback/conf_space_capability.h     |   26 
 drivers/xen/pciback/conf_space_capability_msi.c |   84 +
 drivers/xen/pciback/conf_space_capability_pm.c  |  113 +
 drivers/xen/pciback/conf_space_capability_vpd.c |   40 
 drivers/xen/pciback/conf_space_header.c         |  379 +++++
 drivers/xen/pciback/conf_space_quirks.c         |  140 ++
 drivers/xen/pciback/conf_space_quirks.h         |   35 
 drivers/xen/pciback/controller.c                |  442 ++++++
 drivers/xen/pciback/passthrough.c               |  178 ++
 drivers/xen/pciback/pci_stub.c                  | 1287 +++++++++++++++++++
 drivers/xen/pciback/pciback.h                   |  133 +
 drivers/xen/pciback/pciback_ops.c               |  139 ++
 drivers/xen/pciback/slot.c                      |  191 ++
 drivers/xen/pciback/vpci.c                      |  244 +++
 drivers/xen/pciback/xenbus.c                    |  722 ++++++++++
 drivers/xen/pcpu.c                              |  420 ++++++
 drivers/xen/sys-hypervisor.c                    |    1 
 drivers/xen/xen_acpi_memhotplug.c               |  209 +++
 drivers/xen/xenbus/Makefile                     |    5 
 drivers/xen/xenbus/xenbus_client.c              |    2 
 drivers/xen/xenbus/xenbus_probe.c               |  378 +----
 drivers/xen/xenbus/xenbus_probe.h               |   29 
 drivers/xen/xenbus/xenbus_probe_backend.c       |  293 ++++
 drivers/xen/xenbus/xenbus_probe_frontend.c      |  287 ++++
 drivers/xen/xenbus/xenbus_xs.c                  |   57 
 drivers/xen/xenfs/Makefile                      |    3 
 drivers/xen/xenfs/privcmd.c                     |  404 ++++++
 drivers/xen/xenfs/super.c                       |  100 +
 drivers/xen/xenfs/xenfs.h                       |    3 
 drivers/xen/xenfs/xenstored.c                   |   67 
 include/acpi/acpi_drivers.h                     |   21 
 include/acpi/processor.h                        |   10 
 include/asm-generic/pci.h                       |    2 
 include/drm/drmP.h                              |    2 
 include/linux/bootmem.h                         |    1 
 include/linux/dmar.h                            |   15 
 include/linux/fb.h                              |    1 
 include/linux/hrtimer.h                         |   13 
 include/linux/interrupt.h                       |    1 
 include/linux/mm.h                              |   15 
 include/linux/page-flags.h                      |   20 
 include/linux/swiotlb.h                         |  115 +
 include/linux/vmalloc.h                         |    2 
 include/xen/Kbuild                              |    1 
 include/xen/acpi.h                              |  106 +
 include/xen/balloon.h                           |    8 
 include/xen/blkif.h                             |  123 +
 include/xen/events.h                            |   34 
 include/xen/gntdev.h                            |  119 +
 include/xen/grant_table.h                       |   43 
 include/xen/interface/grant_table.h             |   22 
 include/xen/interface/io/pciif.h                |  124 +
 include/xen/interface/io/ring.h                 |    3 
 include/xen/interface/io/xenbus.h               |    8 
 include/xen/interface/memory.h                  |   92 +
 include/xen/interface/physdev.h                 |   68 +
 include/xen/interface/platform.h                |  381 +++++
 include/xen/interface/xen.h                     |   45 
 include/xen/pcpu.h                              |   30 
 include/xen/privcmd.h                           |   80 +
 include/xen/xen-ops.h                           |   11 
 include/xen/xen.h                               |   32 
 include/xen/xenbus.h                            |    2 
 kernel/hrtimer.c                                |   96 -
 kernel/irq/manage.c                             |    3 
 kernel/time/timer_list.c                        |    5 
 lib/Makefile                                    |    3 
 lib/swiotlb-core.c                              |  572 ++++++++
 lib/swiotlb-xen.c                               |  504 +++++++
 lib/swiotlb.c                                   |  551 --------
 mm/bootmem.c                                    |   24 
 mm/memory.c                                     |   43 
 mm/mmap.c                                       |   12 
 mm/page_alloc.c                                 |   14 
 mm/vmalloc.c                                    |   14 
 241 files changed, 24255 insertions(+), 1477 deletions(-)

Index: xen.pvops.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/Attic/xen.pvops.patch,v
retrieving revision 1.1.2.62
retrieving revision 1.1.2.63
diff -u -p -r1.1.2.62 -r1.1.2.63
--- xen.pvops.patch	31 Mar 2010 21:07:34 -0000	1.1.2.62
+++ xen.pvops.patch	31 Mar 2010 21:53:26 -0000	1.1.2.63
@@ -1663,13 +1663,15 @@ index a501dee..98569c3 100644
  extern int mtrr_cleanup(unsigned address_bits);
 diff --git a/arch/x86/kernel/cpu/mtrr/xen.c b/arch/x86/kernel/cpu/mtrr/xen.c
 new file mode 100644
-index 0000000..54ced4b
+index 0000000..852018b
 --- /dev/null
 +++ b/arch/x86/kernel/cpu/mtrr/xen.c
-@@ -0,0 +1,105 @@
+@@ -0,0 +1,109 @@
 +#include <linux/init.h>
 +#include <linux/mm.h>
-+#
++
++#include <asm/pat.h>
++
 +#include "mtrr.h"
 +
 +#include <xen/xen.h>
@@ -1769,8 +1771,10 @@ index 0000000..54ced4b
 +	if (cpu_has_mtrr ||
 +	    cpu_has_k6_mtrr ||
 +	    cpu_has_cyrix_arr ||
-+	    cpu_has_centaur_mcr)
++	    cpu_has_centaur_mcr) {
 +		mtrr_if = &xen_mtrr_ops;
++		pat_init();
++	}
 +}
 diff --git a/arch/x86/kernel/crash.c b/arch/x86/kernel/crash.c
 index 5e409dc..a4849c1 100644
@@ -3272,7 +3276,7 @@ index 0000000..21a3089
 +#endif
 +}
 diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
-index 3578688..565ab25 100644
+index 3578688..cc0c7ed 100644
 --- a/arch/x86/xen/enlighten.c
 +++ b/arch/x86/xen/enlighten.c
 @@ -28,6 +28,7 @@
@@ -3334,11 +3338,8 @@ index 3578688..565ab25 100644
  	}
  
  	asm(XEN_EMULATE_PREFIX "cpuid"
-@@ -217,8 +230,11 @@ static __init void xen_init_cpuid_mask(void)
- 	cpuid_leaf1_edx_mask =
- 		~((1 << X86_FEATURE_MCE)  |  /* disable MCE */
+@@ -219,6 +232,8 @@ static __init void xen_init_cpuid_mask(void)
  		  (1 << X86_FEATURE_MCA)  |  /* disable MCA */
-+		  (1 << X86_FEATURE_PAT)  |  /* disable PAT */
  		  (1 << X86_FEATURE_ACC));   /* thermal monitoring */
  
 +	cpuid_leaf81_edx_mask = ~(1 << (X86_FEATURE_GBPAGES % 32));
@@ -3346,7 +3347,7 @@ index 3578688..565ab25 100644
  	if (!xen_initial_domain())
  		cpuid_leaf1_edx_mask &=
  			~((1 << X86_FEATURE_APIC) |  /* disable local APIC */
-@@ -406,7 +422,7 @@ static __init void xen_load_gdt_boot(const struct desc_ptr *dtr)
+@@ -406,7 +421,7 @@ static __init void xen_load_gdt_boot(const struct desc_ptr *dtr)
  
  		pte = pfn_pte(pfn, PAGE_KERNEL_RO);
  
@@ -3355,7 +3356,7 @@ index 3578688..565ab25 100644
  			BUG();
  
  		frames[f] = mfn;
-@@ -519,11 +535,10 @@ static int cvt_gate_to_trap(int vector, const gate_desc *val,
+@@ -519,11 +534,10 @@ static int cvt_gate_to_trap(int vector, const gate_desc *val,
  	} else if (addr == (unsigned long)machine_check) {
  		return 0;
  #endif
@@ -3371,7 +3372,7 @@ index 3578688..565ab25 100644
  #endif	/* CONFIG_X86_64 */
  	info->address = addr;
  
-@@ -679,6 +694,18 @@ static void xen_set_iopl_mask(unsigned mask)
+@@ -679,6 +693,18 @@ static void xen_set_iopl_mask(unsigned mask)
  	HYPERVISOR_physdev_op(PHYSDEVOP_set_iopl, &set_iopl);
  }
  
@@ -3390,7 +3391,7 @@ index 3578688..565ab25 100644
  static void xen_io_delay(void)
  {
  }
-@@ -716,7 +743,7 @@ static u32 xen_safe_apic_wait_icr_idle(void)
+@@ -716,7 +742,7 @@ static u32 xen_safe_apic_wait_icr_idle(void)
          return 0;
  }
  
@@ -3399,7 +3400,7 @@ index 3578688..565ab25 100644
  {
  	apic->read = xen_apic_read;
  	apic->write = xen_apic_write;
-@@ -728,7 +755,6 @@ static void set_xen_basic_apic_ops(void)
+@@ -728,7 +754,6 @@ static void set_xen_basic_apic_ops(void)
  
  #endif
  
@@ -3407,7 +3408,19 @@ index 3578688..565ab25 100644
  static void xen_clts(void)
  {
  	struct multicall_space mcs;
-@@ -978,6 +1004,7 @@ static const struct pv_cpu_ops xen_cpu_ops __initdata = {
+@@ -811,6 +836,11 @@ static int xen_write_msr_safe(unsigned int msr, unsigned low, unsigned high)
+ 		   Xen console noise. */
+ 		break;
+ 
++	case MSR_IA32_CR_PAT:
++		if (smp_processor_id() == 0)
++			xen_set_pat(((u64)high << 32) | low);
++		break;
++
+ 	default:
+ 		ret = native_write_msr_safe(msr, low, high);
+ 	}
+@@ -978,6 +1008,7 @@ static const struct pv_cpu_ops xen_cpu_ops __initdata = {
  	.load_sp0 = xen_load_sp0,
  
  	.set_iopl_mask = xen_set_iopl_mask,
@@ -3415,7 +3428,7 @@ index 3578688..565ab25 100644
  	.io_delay = xen_io_delay,
  
  	/* Xen takes care of %gs when switching to usermode for us */
-@@ -1020,6 +1047,14 @@ static void xen_machine_halt(void)
+@@ -1020,6 +1051,14 @@ static void xen_machine_halt(void)
  	xen_reboot(SHUTDOWN_poweroff);
  }
  
@@ -3430,7 +3443,7 @@ index 3578688..565ab25 100644
  static void xen_crash_shutdown(struct pt_regs *regs)
  {
  	xen_reboot(SHUTDOWN_crash);
-@@ -1028,7 +1063,7 @@ static void xen_crash_shutdown(struct pt_regs *regs)
+@@ -1028,7 +1067,7 @@ static void xen_crash_shutdown(struct pt_regs *regs)
  static const struct machine_ops __initdata xen_machine_ops = {
  	.restart = xen_restart,
  	.halt = xen_machine_halt,
@@ -3439,7 +3452,7 @@ index 3578688..565ab25 100644
  	.shutdown = xen_machine_halt,
  	.crash_shutdown = xen_crash_shutdown,
  	.emergency_restart = xen_emergency_restart,
-@@ -1061,6 +1096,8 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1061,6 +1100,8 @@ asmlinkage void __init xen_start_kernel(void)
  
  	xen_domain_type = XEN_PV_DOMAIN;
  
@@ -3448,7 +3461,7 @@ index 3578688..565ab25 100644
  	/* Install Xen paravirt ops */
  	pv_info = xen_info;
  	pv_init_ops = xen_init_ops;
-@@ -1086,6 +1123,12 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1086,6 +1127,12 @@ asmlinkage void __init xen_start_kernel(void)
  
  	xen_init_mmu_ops();
  
@@ -3461,7 +3474,7 @@ index 3578688..565ab25 100644
  	/* Prevent unwanted bits from being set in PTEs. */
  	__supported_pte_mask &= ~_PAGE_GLOBAL;
  	if (!xen_initial_domain())
-@@ -1116,6 +1159,10 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1116,6 +1163,10 @@ asmlinkage void __init xen_start_kernel(void)
  	 */
  	xen_setup_stackprotector();
  
@@ -3472,7 +3485,7 @@ index 3578688..565ab25 100644
  	xen_init_irq_ops();
  	xen_init_cpuid_mask();
  
-@@ -1144,6 +1191,8 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1144,6 +1195,8 @@ asmlinkage void __init xen_start_kernel(void)
  
  	pgd = (pgd_t *)xen_start_info->pt_base;
  
@@ -3481,7 +3494,7 @@ index 3578688..565ab25 100644
  	/* Don't do the full vcpu_info placement stuff until we have a
  	   possible map and a non-dummy shared_info. */
  	per_cpu(xen_vcpu, 0) = &HYPERVISOR_shared_info->vcpu_info[0];
-@@ -1153,6 +1202,7 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1153,6 +1206,7 @@ asmlinkage void __init xen_start_kernel(void)
  
  	xen_raw_console_write("mapping kernel into physical memory\n");
  	pgd = xen_setup_kernel_pagetable(pgd, xen_start_info->nr_pages);
@@ -3489,7 +3502,7 @@ index 3578688..565ab25 100644
  
  	init_mm.pgd = pgd;
  
-@@ -1162,6 +1212,14 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1162,6 +1216,14 @@ asmlinkage void __init xen_start_kernel(void)
  	if (xen_feature(XENFEAT_supervisor_mode_kernel))
  		pv_info.kernel_rpl = 0;
  
@@ -3504,7 +3517,7 @@ index 3578688..565ab25 100644
  	/* set the limit of our address space */
  	xen_reserve_top();
  
-@@ -1184,6 +1242,16 @@ asmlinkage void __init xen_start_kernel(void)
+@@ -1184,6 +1246,16 @@ asmlinkage void __init xen_start_kernel(void)
  		add_preferred_console("xenboot", 0, NULL);
  		add_preferred_console("tty", 0, NULL);
  		add_preferred_console("hvc", 0, NULL);
@@ -3522,7 +3535,7 @@ index 3578688..565ab25 100644
  
  	xen_raw_console_write("about to get started...\n");
 diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c
-index 350a3de..fdee4fa 100644
+index 350a3de..8c6a858 100644
 --- a/arch/x86/xen/mmu.c
 +++ b/arch/x86/xen/mmu.c
 @@ -42,6 +42,7 @@
@@ -3533,17 +3546,18 @@ index 350a3de..fdee4fa 100644
  #include <linux/module.h>
  
  #include <asm/pgtable.h>
-@@ -50,7 +51,9 @@
+@@ -50,7 +51,10 @@
  #include <asm/mmu_context.h>
  #include <asm/setup.h>
  #include <asm/paravirt.h>
 +#include <asm/e820.h>
  #include <asm/linkage.h>
++#include <asm/pat.h>
 +#include <asm/page.h>
  
  #include <asm/xen/hypercall.h>
  #include <asm/xen/hypervisor.h>
-@@ -58,6 +61,7 @@
+@@ -58,6 +62,7 @@
  #include <xen/page.h>
  #include <xen/interface/xen.h>
  #include <xen/interface/version.h>
@@ -3551,7 +3565,7 @@ index 350a3de..fdee4fa 100644
  #include <xen/hvc-console.h>
  
  #include "multicalls.h"
-@@ -66,6 +70,13 @@
+@@ -66,6 +71,13 @@
  
  #define MMU_UPDATE_HISTO	30
  
@@ -3565,7 +3579,7 @@ index 350a3de..fdee4fa 100644
  #ifdef CONFIG_XEN_DEBUG_FS
  
  static struct {
-@@ -184,6 +195,26 @@ static inline unsigned p2m_index(unsigned long pfn)
+@@ -184,6 +196,26 @@ static inline unsigned p2m_index(unsigned long pfn)
  	return pfn % P2M_ENTRIES_PER_PAGE;
  }
  
@@ -3592,7 +3606,7 @@ index 350a3de..fdee4fa 100644
  /* Build the parallel p2m_top_mfn structures */
  void xen_build_mfn_list_list(void)
  {
-@@ -315,6 +346,7 @@ unsigned long arbitrary_virt_to_mfn(void *vaddr)
+@@ -315,6 +347,7 @@ unsigned long arbitrary_virt_to_mfn(void *vaddr)
  
  	return PFN_DOWN(maddr.maddr);
  }
@@ -3600,7 +3614,7 @@ index 350a3de..fdee4fa 100644
  
  xmaddr_t arbitrary_virt_to_machine(void *vaddr)
  {
-@@ -376,6 +408,34 @@ static bool xen_page_pinned(void *ptr)
+@@ -376,6 +409,34 @@ static bool xen_page_pinned(void *ptr)
  	return PagePinned(page);
  }
  
@@ -3635,7 +3649,7 @@ index 350a3de..fdee4fa 100644
  static void xen_extend_mmu_update(const struct mmu_update *update)
  {
  	struct multicall_space mcs;
-@@ -452,6 +512,11 @@ void set_pte_mfn(unsigned long vaddr, unsigned long mfn, pgprot_t flags)
+@@ -452,6 +513,11 @@ void set_pte_mfn(unsigned long vaddr, unsigned long mfn, pgprot_t flags)
  void xen_set_pte_at(struct mm_struct *mm, unsigned long addr,
  		    pte_t *ptep, pte_t pteval)
  {
@@ -3647,7 +3661,7 @@ index 350a3de..fdee4fa 100644
  	ADD_STATS(set_pte_at, 1);
  //	ADD_STATS(set_pte_at_pinned, xen_page_pinned(ptep));
  	ADD_STATS(set_pte_at_current, mm == current->mm);
-@@ -522,8 +587,25 @@ static pteval_t pte_pfn_to_mfn(pteval_t val)
+@@ -522,9 +588,34 @@ static pteval_t pte_pfn_to_mfn(pteval_t val)
  	return val;
  }
  
@@ -3667,19 +3681,69 @@ index 350a3de..fdee4fa 100644
 +
  pteval_t xen_pte_val(pte_t pte)
  {
-+	if (xen_initial_domain() && (pte.pte & _PAGE_IOMAP))
-+		return pte.pte;
+-	return pte_mfn_to_pfn(pte.pte);
++	pteval_t pteval = pte.pte;
++
++	/* If this is a WC pte, convert back from Xen WC to Linux WC */
++	if ((pteval & (_PAGE_PAT | _PAGE_PCD | _PAGE_PWT)) == _PAGE_PAT) {
++		WARN_ON(!pat_enabled);
++		pteval = (pteval & ~_PAGE_PAT) | _PAGE_PWT;
++	}
++
++	if (xen_initial_domain() && (pteval & _PAGE_IOMAP))
++		return pteval;
 +
- 	return pte_mfn_to_pfn(pte.pte);
++	return pte_mfn_to_pfn(pteval);
  }
  PV_CALLEE_SAVE_REGS_THUNK(xen_pte_val);
-@@ -536,7 +618,22 @@ PV_CALLEE_SAVE_REGS_THUNK(xen_pgd_val);
  
+@@ -534,9 +625,62 @@ pgdval_t xen_pgd_val(pgd_t pgd)
+ }
+ PV_CALLEE_SAVE_REGS_THUNK(xen_pgd_val);
+ 
++/*
++ * Xen's PAT setup is part of its ABI, though I assume entries 6 & 7
++ * are reserved for now, to correspond to the Intel-reserved PAT
++ * types.
++ *
++ * We expect Linux's PAT set as follows:
++ *
++ * Idx  PTE flags        Linux    Xen    Default
++ * 0                     WB       WB     WB
++ * 1            PWT      WC       WT     WT
++ * 2        PCD          UC-      UC-    UC-
++ * 3        PCD PWT      UC       UC     UC
++ * 4    PAT              WB       WC     WB
++ * 5    PAT     PWT      WC       WP     WT
++ * 6    PAT PCD          UC-      UC     UC-
++ * 7    PAT PCD PWT      UC       UC     UC
++ */
++
++void xen_set_pat(u64 pat)
++{
++	/* We expect Linux to use a PAT setting of
++	 * UC UC- WC WB (ignoring the PAT flag) */
++	WARN_ON(pat != 0x0007010600070106ull);
++}
++
  pte_t xen_make_pte(pteval_t pte)
  {
 -	pte = pte_pfn_to_mfn(pte);
 +	phys_addr_t addr = (pte & PTE_PFN_MASK);
 +
++	/* If Linux is trying to set a WC pte, then map to the Xen WC.
++	 * If _PAGE_PAT is set, then it probably means it is really
++	 * _PAGE_PSE, so avoid fiddling with the PAT mapping and hope
++	 * things work out OK...
++	 *
++	 * (We should never see kernel mappings with _PAGE_PSE set,
++	 * but we could see hugetlbfs mappings, I think.).
++	 */
++	if (pat_enabled && !WARN_ON(pte & _PAGE_PAT)) {
++		if ((pte & (_PAGE_PCD | _PAGE_PWT)) == _PAGE_PWT)
++			pte = (pte & ~(_PAGE_PCD | _PAGE_PWT)) | _PAGE_PAT;
++	}
++
 +	/*
 +	 * Unprivileged domains are allowed to do IOMAPpings for
 +	 * PCI passthrough, but not map ISA space.  The ISA
@@ -3697,7 +3761,7 @@ index 350a3de..fdee4fa 100644
  	return native_make_pte(pte);
  }
  PV_CALLEE_SAVE_REGS_THUNK(xen_make_pte);
-@@ -592,6 +689,11 @@ void xen_set_pud(pud_t *ptr, pud_t val)
+@@ -592,6 +736,11 @@ void xen_set_pud(pud_t *ptr, pud_t val)
  
  void xen_set_pte(pte_t *ptep, pte_t pte)
  {
@@ -3709,7 +3773,7 @@ index 350a3de..fdee4fa 100644
  	ADD_STATS(pte_update, 1);
  //	ADD_STATS(pte_update_pinned, xen_page_pinned(ptep));
  	ADD_STATS(pte_update_batched, paravirt_get_lazy_mode() == PARAVIRT_LAZY_MMU);
-@@ -608,6 +710,11 @@ void xen_set_pte(pte_t *ptep, pte_t pte)
+@@ -608,6 +757,11 @@ void xen_set_pte(pte_t *ptep, pte_t pte)
  #ifdef CONFIG_X86_PAE
  void xen_set_pte_atomic(pte_t *ptep, pte_t pte)
  {
@@ -3721,7 +3785,7 @@ index 350a3de..fdee4fa 100644
  	set_64bit((u64 *)ptep, native_pte_val(pte));
  }
  
-@@ -934,8 +1041,6 @@ static int xen_pin_page(struct mm_struct *mm, struct page *page,
+@@ -934,8 +1088,6 @@ static int xen_pin_page(struct mm_struct *mm, struct page *page,
     read-only, and can be pinned. */
  static void __xen_pgd_pin(struct mm_struct *mm, pgd_t *pgd)
  {
@@ -3730,7 +3794,7 @@ index 350a3de..fdee4fa 100644
  	xen_mc_batch();
  
  	if (__xen_pgd_walk(mm, pgd, xen_pin_page, USER_LIMIT)) {
-@@ -1219,7 +1324,7 @@ void xen_exit_mmap(struct mm_struct *mm)
+@@ -1219,7 +1371,7 @@ void xen_exit_mmap(struct mm_struct *mm)
  	spin_lock(&mm->page_table_lock);
  
  	/* pgd may not be pinned in the error exit path of execve */
@@ -3739,7 +3803,7 @@ index 350a3de..fdee4fa 100644
  		xen_pgd_unpin(mm);
  
  	spin_unlock(&mm->page_table_lock);
-@@ -1288,12 +1393,19 @@ static void xen_flush_tlb_single(unsigned long addr)
+@@ -1288,12 +1440,19 @@ static void xen_flush_tlb_single(unsigned long addr)
  	preempt_enable();
  }
  
@@ -3760,7 +3824,7 @@ index 350a3de..fdee4fa 100644
  	} *args;
  	struct multicall_space mcs;
  
-@@ -1417,6 +1529,13 @@ static int xen_pgd_alloc(struct mm_struct *mm)
+@@ -1417,6 +1576,13 @@ static int xen_pgd_alloc(struct mm_struct *mm)
  	return ret;
  }
  
@@ -3774,7 +3838,7 @@ index 350a3de..fdee4fa 100644
  static void xen_pgd_free(struct mm_struct *mm, pgd_t *pgd)
  {
  #ifdef CONFIG_X86_64
-@@ -1448,10 +1567,17 @@ static void *xen_kmap_atomic_pte(struct page *page, enum km_type type)
+@@ -1448,10 +1614,17 @@ static void *xen_kmap_atomic_pte(struct page *page, enum km_type type)
  #ifdef CONFIG_X86_32
  static __init pte_t mask_rw_pte(pte_t *ptep, pte_t pte)
  {
@@ -3794,7 +3858,7 @@ index 350a3de..fdee4fa 100644
  
  	return pte;
  }
-@@ -1517,7 +1643,6 @@ static void xen_alloc_ptpage(struct mm_struct *mm, unsigned long pfn, unsigned l
+@@ -1517,7 +1690,6 @@ static void xen_alloc_ptpage(struct mm_struct *mm, unsigned long pfn, unsigned l
  	if (PagePinned(virt_to_page(mm->pgd))) {
  		SetPagePinned(page);
  
@@ -3802,7 +3866,7 @@ index 350a3de..fdee4fa 100644
  		if (!PageHighMem(page)) {
  			make_lowmem_page_readonly(__va(PFN_PHYS((unsigned long)pfn)));
  			if (level == PT_PTE && USE_SPLIT_PTLOCKS)
-@@ -1620,6 +1745,7 @@ static void *m2v(phys_addr_t maddr)
+@@ -1620,6 +1792,7 @@ static void *m2v(phys_addr_t maddr)
  	return __ka(m2p(maddr));
  }
  
@@ -3810,7 +3874,7 @@ index 350a3de..fdee4fa 100644
  static void set_page_prot(void *addr, pgprot_t prot)
  {
  	unsigned long pfn = __pa(addr) >> PAGE_SHIFT;
-@@ -1675,6 +1801,20 @@ static __init void xen_map_identity_early(pmd_t *pmd, unsigned long max_pfn)
+@@ -1675,6 +1848,20 @@ static __init void xen_map_identity_early(pmd_t *pmd, unsigned long max_pfn)
  	set_page_prot(pmd, PAGE_KERNEL_RO);
  }
  
@@ -3831,7 +3895,7 @@ index 350a3de..fdee4fa 100644
  #ifdef CONFIG_X86_64
  static void convert_pfn_mfn(void *v)
  {
-@@ -1766,6 +1906,7 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
+@@ -1766,6 +1953,7 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
  					 unsigned long max_pfn)
  {
  	pmd_t *kernel_pmd;
@@ -3839,7 +3903,7 @@ index 350a3de..fdee4fa 100644
  
  	max_pfn_mapped = PFN_DOWN(__pa(xen_start_info->pt_base) +
  				  xen_start_info->nr_pt_frames * PAGE_SIZE +
-@@ -1777,6 +1918,20 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
+@@ -1777,6 +1965,20 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
  	xen_map_identity_early(level2_kernel_pgt, max_pfn);
  
  	memcpy(swapper_pg_dir, pgd, sizeof(pgd_t) * PTRS_PER_PGD);
@@ -3860,7 +3924,7 @@ index 350a3de..fdee4fa 100644
  	set_pgd(&swapper_pg_dir[KERNEL_PGD_BOUNDARY],
  			__pgd(__pa(level2_kernel_pgt) | _PAGE_PRESENT));
  
-@@ -1799,6 +1954,8 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
+@@ -1799,6 +2001,8 @@ __init pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd,
  }
  #endif	/* CONFIG_X86_64 */
  
@@ -3869,7 +3933,7 @@ index 350a3de..fdee4fa 100644
  static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
  {
  	pte_t pte;
-@@ -1828,9 +1985,26 @@ static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
+@@ -1828,9 +2032,26 @@ static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
  		pte = pfn_pte(phys, prot);
  		break;
  
@@ -3897,7 +3961,7 @@ index 350a3de..fdee4fa 100644
  	}
  
  	__native_set_fixmap(idx, pte);
-@@ -1845,6 +2019,29 @@ static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
+@@ -1845,6 +2066,29 @@ static void xen_set_fixmap(unsigned idx, phys_addr_t phys, pgprot_t prot)
  #endif
  }
  
@@ -3927,7 +3991,7 @@ index 350a3de..fdee4fa 100644
  static __init void xen_post_allocator_init(void)
  {
  	pv_mmu_ops.set_pte = xen_set_pte;
-@@ -1960,7 +2157,270 @@ void __init xen_init_mmu_ops(void)
+@@ -1960,7 +2204,270 @@ void __init xen_init_mmu_ops(void)
  	x86_init.paging.pagetable_setup_start = xen_pagetable_setup_start;
  	x86_init.paging.pagetable_setup_done = xen_pagetable_setup_done;
  	pv_mmu_ops = xen_mmu_ops;
@@ -4872,18 +4936,20 @@ index 0000000..1cd7f4d
 +	}
 +}
 diff --git a/arch/x86/xen/xen-ops.h b/arch/x86/xen/xen-ops.h
-index f9153a3..5afc1fe 100644
+index f9153a3..1c1eff4 100644
 --- a/arch/x86/xen/xen-ops.h
 +++ b/arch/x86/xen/xen-ops.h
-@@ -30,6 +30,7 @@ void xen_setup_machphys_mapping(void);
+@@ -30,6 +30,9 @@ void xen_setup_machphys_mapping(void);
  pgd_t *xen_setup_kernel_pagetable(pgd_t *pgd, unsigned long max_pfn);
  void xen_ident_map_ISA(void);
  void xen_reserve_top(void);
 +void xen_ident_map_ISA(void);
++
++void xen_set_pat(u64);
  
  char * __init xen_memory_setup(void);
  void __init xen_arch_setup(void);
-@@ -82,6 +83,23 @@ static inline void xen_uninit_lock_cpu(int cpu)
+@@ -82,6 +85,23 @@ static inline void xen_uninit_lock_cpu(int cpu)
  }
  #endif
  
@@ -30740,7 +30806,7 @@ index 36992b6..bc1b6e9 100644
  		page->mapping = NULL;
  	if (free_pages_check(page))
 diff --git a/mm/vmalloc.c b/mm/vmalloc.c
-index c228731..63dac28 100644
+index c228731..c82216f 100644
 --- a/mm/vmalloc.c
 +++ b/mm/vmalloc.c
 @@ -31,6 +31,7 @@
@@ -30771,8 +30837,12 @@ index c228731..63dac28 100644
  	/*
  	 * If sync is 0 but force_flush is 1, we'll go sync anyway but callers
  	 * should not expect such behaviour. This just simplifies locking for
-@@ -564,10 +571,9 @@ static void __purge_vmap_area_lazy(unsigned long *start, unsigned long *end,
- 	if (nr)
+@@ -561,13 +568,12 @@ static void __purge_vmap_area_lazy(unsigned long *start, unsigned long *end,
+ 	}
+ 	rcu_read_unlock();
+ 
+-	if (nr)
++	if (nr) {
  		atomic_sub(nr, &vmap_lazy_nr);
  
 -	if (nr || force_flush)

-- 
scm-commits mailing list
scm-commits@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/scm-commits
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic