Commit 5fd09ba6 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'for-linus-5.2b-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip

Pull xen updates from Juergen Gross:

 - some minor cleanups

 - two small corrections for Xen on ARM

 - two fixes for Xen PVH guest support

 - a patch for a new command line option to tune virtual timer handling

* tag 'for-linus-5.2b-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
  xen/arm: Use p2m entry with lock protection
  xen/arm: Free p2m entry if fail to add it to RB tree
  xen/pvh: correctly setup the PV EFI interface for dom0
  xen/pvh: set xen_domain_type to HVM in xen_pvh_init
  xenbus: drop useless LIST_HEAD in xenbus_write_watch() and xenbus_file_write()
  xen-netfront: mark expected switch fall-through
  xen: xen-pciback: fix warning Using plain integer as NULL pointer
  x86/xen: Add "xen_timer_slop" command line option
parents 8a635ffb fe846979
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -5260,6 +5260,13 @@
			with /sys/devices/system/xen_memory/xen_memory0/scrub_pages.
			Default value controlled with CONFIG_XEN_SCRUB_PAGES_DEFAULT.

	xen_timer_slop=	[X86-64,XEN]
			Set the timer slop (in nanoseconds) for the virtual Xen
			timers (default is 100000). This adjusts the minimum
			delta of virtualized Xen timers, where lower values
			improve timer resolution at the expense of processing
			more timer interrupts.

	xirc2ps_cs=	[NET,PCMCIA]
			Format:
			<irq>,<irq_mask>,<io>,<full_duplex>,<do_sound>,<lockup_hack>[,<irq2>[,<irq3>[,<irq4>]]]
+3 −1
Original line number Diff line number Diff line
@@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long pfn)
		entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
		if (entry->pfn <= pfn &&
				entry->pfn + entry->nr_pages > pfn) {
			unsigned long mfn = entry->mfn + (pfn - entry->pfn);
			read_unlock_irqrestore(&p2m_lock, irqflags);
			return entry->mfn + (pfn - entry->pfn);
			return mfn;
		}
		if (pfn < entry->pfn)
			n = n->rb_left;
@@ -156,6 +157,7 @@ bool __set_phys_to_machine_multi(unsigned long pfn,
	rc = xen_add_phys_to_mach_entry(p2m_entry);
	if (rc < 0) {
		write_unlock_irqrestore(&p2m_lock, irqflags);
		kfree(p2m_entry);
		return false;
	}
	write_unlock_irqrestore(&p2m_lock, irqflags);
+4 −4
Original line number Diff line number Diff line
@@ -44,8 +44,6 @@ void __init __weak mem_map_via_hcall(struct boot_params *ptr __maybe_unused)

static void __init init_pvh_bootparams(bool xen_guest)
{
	memset(&pvh_bootparams, 0, sizeof(pvh_bootparams));

	if ((pvh_start_info.version > 0) && (pvh_start_info.memmap_entries)) {
		struct hvm_memmap_table_entry *ep;
		int i;
@@ -103,7 +101,7 @@ static void __init init_pvh_bootparams(bool xen_guest)
 * If we are trying to boot a Xen PVH guest, it is expected that the kernel
 * will have been configured to provide the required override for this routine.
 */
void __init __weak xen_pvh_init(void)
void __init __weak xen_pvh_init(struct boot_params *boot_params)
{
	xen_raw_printk("Error: Missing xen PVH initialization\n");
	BUG();
@@ -112,7 +110,7 @@ void __init __weak xen_pvh_init(void)
static void hypervisor_specific_init(bool xen_guest)
{
	if (xen_guest)
		xen_pvh_init();
		xen_pvh_init(&pvh_bootparams);
}

/*
@@ -131,6 +129,8 @@ void __init xen_prepare_pvh(void)
		BUG();
	}

	memset(&pvh_bootparams, 0, sizeof(pvh_bootparams));

	hypervisor_specific_init(xen_guest);

	init_pvh_bootparams(xen_guest);
+6 −6
Original line number Diff line number Diff line
@@ -158,7 +158,7 @@ static enum efi_secureboot_mode xen_efi_get_secureboot(void)
	return efi_secureboot_mode_unknown;
}

void __init xen_efi_init(void)
void __init xen_efi_init(struct boot_params *boot_params)
{
	efi_system_table_t *efi_systab_xen;

@@ -167,12 +167,12 @@ void __init xen_efi_init(void)
	if (efi_systab_xen == NULL)
		return;

	strncpy((char *)&boot_params.efi_info.efi_loader_signature, "Xen",
			sizeof(boot_params.efi_info.efi_loader_signature));
	boot_params.efi_info.efi_systab = (__u32)__pa(efi_systab_xen);
	boot_params.efi_info.efi_systab_hi = (__u32)(__pa(efi_systab_xen) >> 32);
	strncpy((char *)&boot_params->efi_info.efi_loader_signature, "Xen",
			sizeof(boot_params->efi_info.efi_loader_signature));
	boot_params->efi_info.efi_systab = (__u32)__pa(efi_systab_xen);
	boot_params->efi_info.efi_systab_hi = (__u32)(__pa(efi_systab_xen) >> 32);

	boot_params.secure_boot = xen_efi_get_secureboot();
	boot_params->secure_boot = xen_efi_get_secureboot();

	set_bit(EFI_BOOT, &efi.flags);
	set_bit(EFI_PARAVIRT, &efi.flags);
+1 −1
Original line number Diff line number Diff line
@@ -1403,7 +1403,7 @@ asmlinkage __visible void __init xen_start_kernel(void)
	/* We need this for printk timestamps */
	xen_setup_runstate_info(0);

	xen_efi_init();
	xen_efi_init(&boot_params);

	/* Start the world */
#ifdef CONFIG_X86_32
Loading