[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <lsq.1479082460.51615576@decadent.org.uk>
Date: Mon, 14 Nov 2016 00:14:20 +0000
From: Ben Hutchings <ben@...adent.org.uk>
To: linux-kernel@...r.kernel.org, stable@...r.kernel.org
CC: akpm@...ux-foundation.org,
"Stephan Mueller" <stephan.mueller@...ec.com>,
"Theodore Ts'o" <tytso@....edu>,
"Stephan Mueller" <smueller@...onox.de>
Subject: [PATCH 3.16 011/346] random: add interrupt callback to VMBus IRQ
handler
3.16.39-rc1 review patch. If anyone has any objections, please let me know.
------------------
From: Stephan Mueller <smueller@...onox.de>
commit 4b44f2d18a330565227a7348844493c59366171e upstream.
The Hyper-V Linux Integration Services use the VMBus implementation for
communication with the Hypervisor. VMBus registers its own interrupt
handler that completely bypasses the common Linux interrupt handling.
This implies that the interrupt entropy collector is not triggered.
This patch adds the interrupt entropy collection callback into the VMBus
interrupt handler function.
Signed-off-by: Stephan Mueller <stephan.mueller@...ec.com>
Signed-off-by: Stephan Mueller <smueller@...onox.de>
Signed-off-by: Theodore Ts'o <tytso@....edu>
[bwh: Backported to 3.16: adjust context]
Signed-off-by: Ben Hutchings <ben@...adent.org.uk>
---
drivers/char/random.c | 1 +
drivers/hv/vmbus_drv.c | 3 +++
2 files changed, 4 insertions(+)
--- a/drivers/char/random.c
+++ b/drivers/char/random.c
@@ -956,6 +956,7 @@ static void _xfer_secondary_pool(struct
mix_pool_bytes(r, tmp, bytes, NULL);
credit_entropy_bits(r, bytes*8);
}
+EXPORT_SYMBOL_GPL(add_interrupt_randomness);
/*
* Used as a workqueue function so that when the input pool is getting
--- a/drivers/hv/vmbus_drv.c
+++ b/drivers/hv/vmbus_drv.c
@@ -33,6 +33,7 @@
#include <linux/hyperv.h>
#include <linux/kernel_stat.h>
#include <linux/cpu.h>
+#include <linux/random.h>
#include <asm/hyperv.h>
#include <asm/hypervisor.h>
#include <asm/mshyperv.h>
@@ -795,6 +796,8 @@ int __vmbus_driver_register(struct hv_dr
EXPORT_SYMBOL_GPL(__vmbus_driver_register);
/**
+
+ add_interrupt_randomness(HYPERVISOR_CALLBACK_VECTOR, 0);
* vmbus_driver_unregister() - Unregister a vmbus's driver
* @drv: Pointer to driver structure you want to un-register
*
Powered by blists - more mailing lists