Commit b3d80535 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'for-linus-6.17-rc3-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip

Pull xen fixes from Juergen Gross:
 "Two small cleanups which are both relevant only when running as a Xen
  guest"

* tag 'for-linus-6.17-rc3-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
  drivers/xen/xenbus: remove quirk for Xen 3.x
  compiler: remove __ADDRESSABLE_ASM{_STR,}() again
parents 272aa18f efdaa61d
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -94,12 +94,13 @@ DECLARE_STATIC_CALL(xen_hypercall, xen_hypercall_func);
#ifdef MODULE
#define __ADDRESSABLE_xen_hypercall
#else
#define __ADDRESSABLE_xen_hypercall __ADDRESSABLE_ASM_STR(__SCK__xen_hypercall)
#define __ADDRESSABLE_xen_hypercall \
	__stringify(.global STATIC_CALL_KEY(xen_hypercall);)
#endif

#define __HYPERCALL					\
	__ADDRESSABLE_xen_hypercall			\
	"call __SCT__xen_hypercall"
	__stringify(call STATIC_CALL_TRAMP(xen_hypercall))

#define __HYPERCALL_ENTRY(x)	"a" (x)

+0 −23
Original line number Diff line number Diff line
@@ -718,26 +718,6 @@ int xs_watch_msg(struct xs_watch_event *event)
	return 0;
}

/*
 * Certain older XenBus toolstack cannot handle reading values that are
 * not populated. Some Xen 3.4 installation are incapable of doing this
 * so if we are running on anything older than 4 do not attempt to read
 * control/platform-feature-xs_reset_watches.
 */
static bool xen_strict_xenbus_quirk(void)
{
#ifdef CONFIG_X86
	uint32_t eax, ebx, ecx, edx, base;

	base = xen_cpuid_base();
	cpuid(base + 1, &eax, &ebx, &ecx, &edx);

	if ((eax >> 16) < 4)
		return true;
#endif
	return false;

}
static void xs_reset_watches(void)
{
	int err;
@@ -745,9 +725,6 @@ static void xs_reset_watches(void)
	if (!xen_hvm_domain() || xen_initial_domain())
		return;

	if (xen_strict_xenbus_quirk())
		return;

	if (!xenbus_read_unsigned("control",
				  "platform-feature-xs_reset_watches", 0))
		return;
+0 −8
Original line number Diff line number Diff line
@@ -288,14 +288,6 @@ static inline void *offset_to_ptr(const int *off)
#define __ADDRESSABLE(sym) \
	___ADDRESSABLE(sym, __section(".discard.addressable"))

#define __ADDRESSABLE_ASM(sym)						\
	.pushsection .discard.addressable,"aw";				\
	.align ARCH_SEL(8,4);						\
	ARCH_SEL(.quad, .long) __stringify(sym);			\
	.popsection;

#define __ADDRESSABLE_ASM_STR(sym) __stringify(__ADDRESSABLE_ASM(sym))

/*
 * This returns a constant expression while determining if an argument is
 * a constant expression, most importantly without evaluating the argument.